Stack Height/Menubar

Rick Harrison harrison at all-auctions.com
Sun Nov 18 12:29:32 EST 2018


Hi Jacqueline,

Thanks for pointing out this routine.

I have some modifications I need to
make to it though.  

I have to check to see if any items 
are locked, and unlock them before 
changing the location and then
re-lock them after the change.

The number of controls also includes 
groups which are made up of buttons 
so I will have to modify my calculation 
there.

I also read your informative links to
the other menu tutorials.  

Thanks,

Rick


> On Nov 18, 2018, at 12:58 AM, J. Landman Gay via use-livecode <use-livecode at lists.runrev.com> wrote:
> 
> On 11/17/18 12:49 PM, Rick Harrison via use-livecode wrote:
>> Does anyone have a nice routine which
>> will compensate for the change in layout
>> by moving all other objects farther down?
>> I thought I saw a mention this before.
> 
> on pushDown
>  repeat with x = 1 to the number of bgs
>    set the top of bg x to the top of bg x + 22
>  end repeat
>  repeat with x = 1 to the number of cds
>    go cd x
>    repeat with n = 1 to the number of cd parts
>      set the top of cd part n to the top of cd part n + 22
>    end repeat
>  end repeat
> end pushDown
> 
> This is from a HyperCard-to-LC conversion tutorial. "Parts" is a HC synonym for "controls", which you can substitute if you want. The default menubar height used to be 22, but change that number if you need to.
> 
> Tutorial covering menus is here:
> <http://www.hyperactivesw.com/mctutorial/rraboutMenus.html>
> And the above handler is here:
> <http://www.hyperactivesw.com/mctutorial/rrcreateMenus.html>
> 
> -- 
> Jacqueline Landman Gay         |     jacque at hyperactivesw.com
> HyperActive Software           |     http://www.hyperactivesw.com
> 
> _______________________________________________
> use-livecode mailing list
> use-livecode at lists.runrev.com
> Please visit this url to subscribe, unsubscribe and manage your subscription preferences:
> http://lists.runrev.com/mailman/listinfo/use-livecode





More information about the use-livecode mailing list