2

How do I add mnemonics (i.e. Alt + something) to java.awt.Menu (not javax.swing.JMenu)?

For a JMenu it's simple:

mnFile.setMnemonic(KeyEvent.VK_F);

But I cannot find relevant information about Menu. Do I have to use low level mechanics (i.e. KeyListener) to accomplish this?

I'm using Windows 10 and Java 8.

johnchen902
  • 9,531
  • 1
  • 27
  • 69

0 Answers0