Page 1 of 1

Rebar Menu

Posted: Sun Jun 17, 2007 2:02 am
by klaver
Image

Hi, I've made this nice menu because I like this kind of things in other programs.

http://www.freewebtown.com/tbiu/RbMenu.zip

Hope you will like it. It's tested only on WinXP so the icons would (possibly will) look ugly on older OS because of the XP transparency used.

There's a TODO thing: the menus should dymically change while moving the cursor when activated. Hope you will help me to do this.
All improvements are welcome.

Posted: Mon Jun 18, 2007 9:30 am
by eesau
This is exactly the same what I'm going to do with my own Office-style menus (search the forums for the code if interested). Remember though, that with toolbar/rebar-type menus you have to implement keyboard navigation of menus, which is a bit problematic. Here are the keys that should be implemented:

F10 -- for activating the menu.
Left and right arrows -- for moving between main item and menu sub-items.
Up and down arrows -- for moving between menu sub-items, down arrow also for activating a particular main item in the menu.
Alt-key -- for activating underscores.
Enter -- for selecting the current menu item, also expands sub-items in the menu.
Esc -- for cancelling keyboard navigation.

Implementing keyboard navigation is absolutely essential, because not everyone uses a mouse. And some people find it easier to navigate by keyboard even if they have a mouse.

Here is an article (MSDN) that explains keyboard navigation in toolbar/rebar -menus. Hope it helps.