can't get rid of menu bar in Windows

Ken Ray kray at sonsothunder.com
Tue Jun 28 23:40:54 EDT 2011


> I used the Tools > Menu Builder to create a menu bar. This automatically
> moved all my controls down 22  pixels to make room for the group. But I want
> the menu only in Mac OS, so I put this in the openStack handler:

That's pretty unique - to only want a menubar in Mac OS; but if that's what
you really want, the best way to make this happen is to hide the group that
should be used for your menubar on MacOS, set the menubar of the stack to
empty, move all of your other controls on the card up 22 pixels, and then
set the *defaultMenuBar* to the hidden menu bar group.

Note that the defaultMenuBar is a global property, not a stack property.

> if the platform is "MacOS" then
>    set the menubar of this stack to "MainMenu"
> else
>    set the menubar of this stack to empty
> end if
> 
> However, when I build the standalone and run it in Windows, the menu bar is
> still there. Also, in editing the stack in the IDE (4.6.1) the menu group is
> also there, and all my controls remain shifted down 22 pixels.
> 
> Does "set the menubar of this stack to empty" do anything?

All that it does is identify a group to be used for the menubar; if you set
the emnubar of the stack to empty, you're in effect saying that there is no
group that should be used for the menubar... but that doesn't make the group
*itself* change in any way.

Ken Ray
Sons of Thunder Software, Inc.
Email: kray at sonsothunder.com
Web Site: http://www.sonsothunder.com/






More information about the use-livecode mailing list