-
Bug
-
Resolution: Duplicate
-
P4
-
None
-
1.0.1
-
sparc
-
solaris_2.5.1
In a menu with both textual items and check box items the left edges
of the text should be aligned. In the Motif L+F, the left edge of the
check box is aligned with the left edge of the textual items.
Name: apR10133 Date: 08/16/2001
There is a testcase for this bug:
------------------------ bug4133790.java ---------------------------
import javax.swing.*;
public class bug4133790 {
public bug4133790() {
try {
UIManager.setLookAndFeel("com.sun.java.swing.plaf.motif.MotifLookAndFeel");
} catch (Exception e) {
e.printStackTrace();
}
JFrame fr = new JFrame("Test");
fr.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
JMenuBar bar = new JMenuBar();
fr.setJMenuBar(bar);
JMenu menu = new JMenu("Menu");
bar.add(menu);
menu.add(new JMenuItem("simple item"));
menu.add(new JCheckBoxMenuItem("checkbox item"));
menu.add(new JRadioButtonMenuItem("checkbox item"));
JMenu submenu = new JMenu("submenu");
menu.add(submenu);
submenu.add(new JMenuItem("simple item"));
submenu.add(new JMenuItem("simple item"));
JMenu menu2 = new JMenu("Test");
bar.add(menu2);
menu2.add(new JMenuItem("simple item"));
menu2.add(new JMenuItem("simple item"));
fr.setSize(200,200);
fr.setVisible(true);
}
public static void main(String[] argv) {
new bug4133790();
}
}
----------------------------------------------------------
###@###.###
======================================================================
of the text should be aligned. In the Motif L+F, the left edge of the
check box is aligned with the left edge of the textual items.
Name: apR10133 Date: 08/16/2001
There is a testcase for this bug:
------------------------ bug4133790.java ---------------------------
import javax.swing.*;
public class bug4133790 {
public bug4133790() {
try {
UIManager.setLookAndFeel("com.sun.java.swing.plaf.motif.MotifLookAndFeel");
} catch (Exception e) {
e.printStackTrace();
}
JFrame fr = new JFrame("Test");
fr.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
JMenuBar bar = new JMenuBar();
fr.setJMenuBar(bar);
JMenu menu = new JMenu("Menu");
bar.add(menu);
menu.add(new JMenuItem("simple item"));
menu.add(new JCheckBoxMenuItem("checkbox item"));
menu.add(new JRadioButtonMenuItem("checkbox item"));
JMenu submenu = new JMenu("submenu");
menu.add(submenu);
submenu.add(new JMenuItem("simple item"));
submenu.add(new JMenuItem("simple item"));
JMenu menu2 = new JMenu("Test");
bar.add(menu2);
menu2.add(new JMenuItem("simple item"));
menu2.add(new JMenuItem("simple item"));
fr.setSize(200,200);
fr.setVisible(true);
}
public static void main(String[] argv) {
new bug4133790();
}
}
----------------------------------------------------------
###@###.###
======================================================================
- duplicates
-
JDK-4729669 1.4 REGRESSION: Text edge of different types of JMenuItems are not aligned
-
- Resolved
-