Location of stack

Paul D. DeRocco pderocco at ix.netcom.com
Sun May 16 02:34:36 EDT 2010


> From: Sarah Reichelt
>
> I'm guessing your stack has a menu. On Mac stacks, Rev does some funny
> business to hide the menu buttons off the top of the stacks window and
> create a real Mac menu. But this doesn't happen immediately.
>
> If you set the loc in a preOpenStack or startup handler, the menu bar
> will not have been hidden yet and the stack will effectively be
> taller. If you set the loc in an openStack handler, then the menu will
> have been hidden and the height of the stack the same as it was when
> you stored the loc, so it will work as expected.
>
> One workaround is to check if there is a menubar and, if so, check if
> there is a difference in height between the stack and the card. If
> they are the same, then the menu has not yet drawn and you need to
> compensate for this manually.

Thanks, Sarah. If I do it in openStack instead of preOpenStack, will it
still position the window before it's first displayed?

--

Ciao,               Paul D. DeRocco
Paul                mailto:pderocco at ix.netcom.com




More information about the use-livecode mailing list