Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-6358368

WinLAF:JFrame background is not looks similar while compare with native frame in winxp.

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Not an Issue
    • Icon: P3 P3
    • None
    • 6
    • client-libs

      Bug Info:
      =========
      JFrame background is not looks similar while compare with native frame in winxp.

      Run the below specify code in winxp and compare with native frame.

      Source Code:
      ============
      import javax.swing.*;
      public class FrameTest extends JFrame {

          /** Creates new form FrameTest */
          public FrameTest() {
              try{
                 javax.swing.UIManager.setLookAndFeel(javax.swing.UIManager.getSystemLookAndFeelClassName());
              }catch(Exception exp_){}
              initComponents();
          }

          private void initComponents() {

              setDefaultCloseOperation(javax.swing.WindowConstants.EXIT_ON_CLOSE);
              java.awt.Dimension screenSize = java.awt.Toolkit.getDefaultToolkit().getScreenSize();
              setBounds((screenSize.width-265)/2, (screenSize.height-248)/2, 265, 248);
              this.setVisible(true);
          }

          /**
           * @param args the command line arguments
           */
          public static void main(String args[]) {
               new FrameTest();
          }


      }

      Please check the attached image for finding the difference.

            shickeysunw Shannon Hickey (Inactive)
            vthotasunw Vinay Thota (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved:
              Imported:
              Indexed: