0

Mnemonic, underline, Keystroke

asked 2013-05-20 20:28:27 +0800

inci02 gravatar image inci02
15

Hi ZK community,

I would like to underline the first character of a label.

In swing I would do it as follows:

menu = new JMenu("A Menu");

menu.setMnemonic(KeyEvent.VK_A);

Any ideas how to handle this in ZK?

Thanks, Murat Inci

delete flag offensive retag edit

Comments

Hi, ZK does not support this feature, you can post feature request in tracker.

vincentjian ( 2013-05-21 03:02:10 +0800 )edit

1 Answer

Sort by ยป oldest newest most voted
0

answered 2013-05-27 13:41:53 +0800

benbai gravatar image benbai
2228 6
http://www.zkoss.org

updated 2013-05-29 04:11:49 +0800

Currently you need to customize and override lots of widget functions to handle keystroke, I've tried to implement a sample at zkfiddle:

Mnemonic, underline, Keystroke

test steps

  1. click on listcell to let listcell get the focus (for ctrlkeys )

  2. press alt+first-letter (e.g., alt+d) to open a menu or trigger onclick on a menuitem

  3. when a menupopup is opened, you can press letters to access child menu/menupopup or press alt+letter to jump to another top most menu

link publish delete flag offensive edit
Your answer
Please start posting your answer anonymously - your answer will be saved within the current session and published after you log in or create a new account. Please try to give a substantial answer, for discussions, please use comments and please do remember to vote (after you log in)!

[hide preview]

Question tools

Follow
1 follower

RSS

Stats

Asked: 2013-05-20 20:28:27 +0800

Seen: 12 times

Last updated: May 29 '13

Support Options
  • Email Support
  • Training
  • Consulting
  • Outsourcing
Learn More