can grouping help me rezising objects?

Jan Schenkel janschenkel at yahoo.com
Wed Feb 9 15:16:18 EST 2011


--- On Wed, 2/9/11, Tiemo Hollmann TB <toolbook at kestner.de> wrote:
> Hello,
> 
> I have a bunch of objects grouped in several hierarchical
> groups in a stack
> which is resizable.
> 
> Up to now I resize every single object by script just how I
> need it. Up to
> now I experienced, that I can't resize the objects of a
> group by resizing
> the group. Ok, it isn't that easy how all objects should
> behave when a stack
> or group.
> 
> Now I just wanted to ask, if groups can help me in any kind
> with resizing
> all objects of a group in case I haven't noticed it yet and
> do a lot of
> unnecessary work, when extending my groups now.
> 
> Thanks for your experience
> 
> Tiemo
> 

Hi Tiemo,

Unless the 'lockLocation' of the group is set to true, it will 'snap back' to encompass its contained controls - leaving room for the margins, which are oddly enough in the 'Text' panel of the group inspector.

While the lockLocation is true, you can still resize the group from script, and do your magic in its 'resizeControl' handler. And since version 3.5 resizing a group interactively with the pointer tool continuously sends 'resizeControl' messages, allowing us to shuffle and resize the contained controls to fit the new size.

Combined with behavior scripts, groups are a powerful method of compositing custom controls that are very close to regular engine controls.

Jan Schenkel.
=====
Quartam Reports & PDF Library for LiveCode
www.quartam.com

=====
"As we grow older, we grow both wiser and more foolish at the same time."  (La Rochefoucauld)



      




More information about the use-livecode mailing list