Terence Heaford wrote:
> I am using the resizeStack message to know that the window has
> changed size, then I call a routine that redraws a chart. I need
> to send or dispatch to the group that will contain the chart.
>
> How else can I do it?

The simplest and most with-the-grain way to do it is to use the messages the engine is already providing.

So rather than write this:

on resizeStack pWidth,pHeight
   myUpdateGeometry
   dispatch "refreshChart" to group "netWorthChart"
   --pass resizeStack
end resizeStack

... you could write this:

on resizeStack pWidth,pHeight
   myUpdateGeometry
   set the rect of grp "netWorthChart" to the rect of me
   --- ...or whatever rect is desired
end resizeStack

The in the "netWorthChart" group you can trap the resizeControl message:

on resizeControl
   refreshChart
end resizeControl

In very old versions of LC (> 4 years old) the resizeControl message was only sent to objects when they were resized interactively by the user manipulating the selection handles with the pointer tool.

With the advent of custom controls this was changes some time in the v5 series so that a group can receive the resizeControl message ANY time it's resized, whether interactively or via script.

Apparently this powerful change to the resizeControl message hasn't made its way into that Dictionary entry yet, so I just filed a report for that:
http://quality.livecode.com/show_bug.cgi?id=17118

--
 Richard Gaskin
 Fourth World Systems
 Software Design and Development for the Desktop, Mobile, and the Web
 ____________________________________________________________________
 ambassa...@fourthworld.com                http://www.FourthWorld.com


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

Reply via email to