In AWT (Advanced Windowing Toolkit) you need: MenuBar, Menu and MenuItem. In Swing you use: JMenuBar, JMenu, JMenuItem, JRadioButtonMenuItem and JPopupMenu.
Even if you have only one JMenuItem, you still need to enclose it in a JMenuBar and and JMenu.
JMenuItems don’t have ticks to mark the selected item. To get that effect you must use a JRadioButtonMenuItem and a ButtonGroup.
|
|
You can get the freshest copy of this page from: | or possibly from your local J: drive (Java virtual drive/mindprod.com website mirror) |
| http://mindprod.com/jgloss/jmenuswing.html | J:\mindprod\jgloss\jmenuswing.html | |
![]() | ||
| Canadian Mind Products | ||
| mindprod.com IP:[65.110.21.43] | ||
| view Blog | Your face IP:[38.107.179.211] | |
| Feedback | You are visitor number 14,642. | |