MENUITEM = "<menu text>", LOAD= <preset> [, ICON= <icon name>] [,CHECKED|RADIO= <register name>[:<bitfieldname>]|STATE:<STATE variable> <condition>] [,ENABLED= <register name>[:<bitfield name]|STATE:<STATE variable> <condition>][,SHORTCUT=<key combination>] //<comment>
Defines a drop-down menu item for a User Toolbar button in DevWare. Only takes effect if the preset name begins with "Toolbar:" or "Toolbar2:". This command causes the toolbar button behavior to change to a drop-down menu action.
The ICON=, CHECKED=, RADIO= and ENABLED= attributes work as in the ICON= command, except they apply only to the menu item, not the toolbar button. The icon file must be a .bmp (32-bpp, R-G-B-alpha) file, 13x13 pixels for the normal Windows text size. SHORTCUT= attribute works like the SHORTCUT= command, but applies only to this menu item.
If ICON= is used then CHECKED= or RADIO= will may have no visible effect depending on OS or GUI library.
The maximum number of menu items on a single toolbar button is 25.
Example: Group multiple presets under one button, with a separator between Parallel and HiSPi.
[Toolbar: 1280x720]
MENUITEM= "Parallel 1280x720 36.19fps", LOAD= Parallel 1280x720 36.19fps XBin2YBin2_BinSum
MENUITEM= "Parallel 1280x720 51.69fps", LOAD= Parallel 1280x720 51.69fps XBin2YSkip2_ColSum2
MENUITEM="-"
MENUITEM= "HiSPi 1280x720 51.69fps", LOAD= HiSPi 1280x720 51.69fps XBin2YSkip2_ColSum2
Example: Image Orientation control for a SMIA sensor using radio button icons
[Toolbar: Orientation]
MENUITEM= "Normal", LOAD= Normal, RADIO= IMAGE_ORIENTATION==0
MENUITEM= "Mirror", LOAD= Horiz Mirror, RADIO= IMAGE_ORIENTATION==1
MENUITEM= "Flip", LOAD= Vertical Flip, RADIO= IMAGE_ORIENTATION==2
MENUITEM= "Rotate 180", LOAD= Rotate 180, RADIO= IMAGE_ORIENTATION==3
[Normal]
FIELD_WR= IMAGE_ORIENTATION, 0
[Horiz Mirror]
FIELD_WR= IMAGE_ORIENTATION, 1
[Vertical Flip]
FIELD_WR= IMAGE_ORIENTATION, 2
[Rotate 180]
FIELD_WR= IMAGE_ORIENTATION, 3
Note: if "LOAD=" is not supplied, then that MENUITEM will be disabled but still displayed. This can be used
To to provide visual separators between MENUITEM sections, use MENUITEM= "-".
See also the ICON=, SHORTCUT= and TOOLTIP= commands.