Looking for Implementation Advice
alex at tweedly.net
Wed Oct 5 11:51:34 EDT 2005
Mike Doub wrote:
>How would you recommend managing setting up the locations of the buttons?
Depends on whether your app is going to have resizeable windows or not,
and whether you're going to put it in a scrolling group, and what else
scrolls, and ....
>Do I just pick an x,y location on the stack and just start making incrementing
>the coordinates? I guess I need to do some experimenting.
The way I usually start something like this is to create a graphic (just
a box), and make it be the size (and location) I want to put the fancy
graphics into. If I want to, I control it through the geometry manager
(or my own geometry management). Then I can calculate co-ords for the
text and boxes relative to that (and even use the size if I decide I
want to let the individual parts stretch). Then once I can see something
"done", I might get keep the box as a background, or hide it, or remove
it and use co-ords from the group instead, or ....
> I am wondering
>if it is possible to create a group, make it invisible, create all of the
>buttons in the group, set the location of the group, and then make the group
Should be - though the time to create and make visible a few hundred
buttons shouldn't be huge anyway. And the time to make existing buttons
visible and/or change their location should be even quicker. (Warning -
the time to delete them can be surprisingly large - so be wary of
deleting and recreating them).
In some ways, as a user, I quite like to see something happen - so
having them appear as you go may be OK. If you prefer not to, use
lockscreen and unlockscreen to make them all just "appear" at once.
Alex Tweedly http://www.tweedly.net
No virus found in this outgoing message.
Checked by AVG Anti-Virus.
Version: 7.0.344 / Virus Database: 267.11.10/119 - Release Date: 04/10/2005
More information about the Use-livecode