Todd Fabacher wrote:

> I have a simple question. Sorry for my ignorance, but how does one
> create a Custom Control from a group? It seems to be just a group,
> but somehome there is a way to set the group to be a Custom Control.
> Is a "Custom Control" a defined stack in the Plugins folder?

A custom control is just a group of other controls put together to provide something, well, custom.

In many (if not most) cases it's helpful to set the group's selectGroupedControls property to false, so that the user can interact with it using the pointer tool without touching its interior controls, even if the global selectGroupedControls property may be true (the group property effectively overrides the global property).

Most custom controls benefit from using a behavior script, so you can use copied of the control anywhere and keep the code in one place for simpler maintenance and enhancement.

Depending on the nature of the control, it can be useful to take advantage of before and after message types in the behavior script, so the functionality the behavior provides can be reliably performed regardless whether the user traps the same message with a simple "on".

That's it. Not much to them, and that's the beauty of custom controls: they make great ad hoc solutions for a wide range of reusable components in an app because they can be built with all the development efficiencies LiveCode script provides.

--
 Richard Gaskin
 Fourth World Systems
 Software Design and Development for the Desktop, Mobile, and the Web
 ____________________________________________________________________
 [email protected]                http://www.FourthWorld.com


_______________________________________________
use-livecode mailing list
[email protected]
Please visit this url to subscribe, unsubscribe and manage your subscription 
preferences:
http://lists.runrev.com/mailman/listinfo/use-livecode

Reply via email to