Page 1 of 1

Option menu button behavior

Posted: Sun Jan 05, 2020 5:41 am
by rfarnold47
hi everyone. I searched for this but didn't find .I am porting an app I created on Mac to Windows. It has several Option Menu buttons. On the mac, the "enable" and "disable" menuitem commands work as expected. however, on Windows, instead of a menu item being greyed-out if disabled, it shows the "(" disable code character in the menu, and permits that option to be selected.

The other menu button styles seem to work properly in this regard, but the option menu is the one I would prefer.

Is there a way to disable/enable menuitems on the Option Menu button in Windows (so that they appear greyed-out and can not be selected in the menu)?

thank you

Re: Option menu button behavior

Posted: Sun Jan 05, 2020 10:45 am
by bogs
I think it is a glitch on Mac only that what your describing works there. I also think the only way you could simulate it on Windows would be through scripting, and while it wouldn't take a lot**, I'm not sure it would be worth the efforts, since your end user(s) on Win machines would see this as a non standard control.

**Basic method - insert a select/case or if/then structure, determine OS, if it is windows then use marker/variable/custom property that can be read by the rest of your handlers as 'disabled'. Update all handlers to look for the marker/variable/custom property, and set text color of that item to disabled color (gray, off-white, whatever).

Re: Option menu button behavior

Posted: Sun Jan 05, 2020 10:49 am
by FourthWorld
The Windows Human Interface Guidelines do not support disabled items in option controls. With those objects the recommendation for an item that isn't relevant is that it simply be removed.

Re: Option menu button behavior

Posted: Thu Jan 09, 2020 4:46 am
by rfarnold47
thanks for the helpful feedback!