For me the setLabel
method of the java's JPopupMenu
does not work.
Here is a simple popup menu example:
http://www.java2s.com/Code/Java/Swing-JFC/AsimpleexampleofJPopupMenu.htm
Inside is:
public JPopupMenu popup;
popup = new JPopupMenu();
popup.setLabel("Justification");
But when I launch the script, my popup menu has no label "Justification":
However, the documentation says this is the right way to define labels:
public void setLabel(String label)
http://docs.oracle.com/javase/7/docs/api/javax/swing/JPopupMenu.html#setLabel%28java.lang.String%29
I am using Eclipse 3.7.2, with JRE 1.7_067.
Of course, the same problem occurs on my own project...
Any help would be greatly appreciated!
Regards,