Moving controls smoothly around the screen

Peter Haworth pete at lcsql.com
Sat Apr 13 20:59:51 EDT 2013


I have a stack with a number of buttons and groups on
it,all vertically aligned.  The groups are initially hidden so the screen
looks like it has a series of buttons on it.

When a button is clicked, I need to move all the objects underneath down to
make room for the hidden group associated with the button to be displayed.

Also have the same situation (but in reverse) when a button is clicked and
its group is already visible.  In that case, I need to hide the group and
slide all the objects under it up to fill the gap.

I use the "show group ... with visual effect" command to smoothly reveal
the group (hide group... with visual effect to hide it) but I'm stuck on
how to move the other objects in an equally smooth way.  Ideally, I'd like
them to move in lock step with the group.

I've tried various forms of the move command  and settings of the lockMove
property but can't seem to get it to work, probably because I'm not
understanding all the options.  After the group is shown/hidden, the rest
of the objects just snap to their new positions rather than move smoothly.

It's almost like I need the move command to have a "with visual effect"
option.  I have a horrible feeling this is going to involve a bunch of
repeat loops to move objects around in small increments at specified
intervals but clinging to the hope the there might be anLC built-in way to
do it.


Pete
lcSQL Software <http://www.lcsql.com>



More information about the use-livecode mailing list