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

JComboBox under Gnome/Nimbus L&F doesn't paint focus indicator

    Details

    • Type: Bug
    • Status: Closed
    • Priority: P3
    • Resolution: Duplicate
    • Affects Version/s: solaris_11
    • Fix Version/s: None
    • Component/s: client-libs
    • Labels:
    • Subcomponent:
    • CPU:
      generic
    • OS:
      solaris_nevada

      Description

      When I run a simple Swing app with a JComboBox under Gnome/Nimbus, I don't see any indication of focus when the JComboBox has focus. The attached screenshot, generated with the following code, shows a JComboBox with focus, but no focus indicator:

      import java.awt.BorderLayout;
      import javax.swing.*;

      public class Fred {
          public static void main(String args[]) {
      int gap = 15;
      JButton b = new JButton("Hello");
      JComboBox combo = new JComboBox(new Object[] {"one", "two", "three"});

      JFrame frame = new JFrame();
      JPanel cont = new JPanel();
      cont.setBorder(BorderFactory.createEmptyBorder(gap, gap, gap, gap));
      cont.setLayout(new BorderLayout(gap, gap));
      cont.add(b, BorderLayout.CENTER);
      cont.add(combo, BorderLayout.SOUTH);

      frame.getContentPane().add(cont);

      frame.setLocationByPlatform(true);
      frame.setDefaultCloseOperation(WindowConstants.EXIT_ON_CLOSE);
      frame.pack();
      frame.setVisible(true);
          }
      }

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                peterz Peter Zhelezniakov (Inactive)
                Reporter:
                stalley Stephen Talley (Inactive)
              • Votes:
                0 Vote for this issue
                Watchers:
                0 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved:
                  Imported:
                  Indexed: