Moving controls smoothly around the screen
Peter Haworth
pete at lcsql.com
Sun Apr 14 13:19:36 EDT 2013
Hi Craig,
You pretty much have it. I've seen it referred to as "an accordion"
elsewhere.
Perhaps to clarify further, the initial display would be:
Button1
Button2
Button3
Button4
WHen Button 2 is clicked, the display would be:
Button1
Button2
Group2
Button3
Button4
If Button 1 was then clicked:
Button1
Group1
Button2
Group2
Button3
Button4
If Button1 was then clicked again:
Button1
Button2
Group2
Button3
Button4
In answer to your question, yes I could temporarily group the objects to be
moved and move them all as one entity. But I'm missing how that helps with
the need for smooth movement. The show command doesn't help since all the
objects to be moved are already visible and, so far, I haven't found a way
to make the move command do anything but snap the moved objects from their
original location to the new one.
Pete
lcSQL Software <http://www.lcsql.com>
On Sat, Apr 13, 2013 at 7:41 PM, <dunbarx at aol.com> wrote:
> Pete.
>
>
> I am not understanding. Are there several objects (buttons and/or groups),
> but at least one group, under each button?
>
>
> And there are a bunch of these "object stacks" vertically aligned, so
> there is a column of them?
>
>
> I would have thought you would show and hide as needed, within each "
> object stack".
>
>
>
> But you say:
>
>
> I need to move all the objects underneath down to make room for the hidden
> group associated with the button to be displayed.
>
>
>
> If you are moving these objects, where are they moving to? You don't mean
> they are moving from layer to layer, do you?
>
>
>
> You say you are using a "show" command to "move" the objects. If this is
> just how you are describing it, then why not just show or hide the objects
> in any particular "stack" by grouping them on the fly, if you need to, and
> applying the visual effect to the group. You would have to manage the
> members of the ad hoc group, but that should be straightforward.
>
>
> Craig Newman
>
>
>
>
> -----Original Message-----
> From: Peter Haworth <pete at lcsql.com>
> To: How to use LiveCode <use-livecode at lists.runrev.com>
> Sent: Sat, Apr 13, 2013 9:00 pm
> Subject: Moving controls smoothly around the screen
>
>
> 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>
> _______________________________________________
> 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
>
>
> _______________________________________________
> 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