Re: widget layout [message #31552 is a reply to message #31421] |
Mon, 15 July 2002 15:24   |
David Fanning
Messages: 11724 Registered: August 2001
|
Senior Member |
|
|
Ted Cary (tedcary@yahoo.com) writes:
> Finally, since this is really one of my few useful ideas, I was thinking
> about making it available to the IDL community along with some other stuff I
> 'm ironing out. My resizer's utility would be limited if every programmer
> had to store base layout information in uvalues when creating widget
> hierarchies; it even limits what type of uvalue the programmers can use! I
> want the helper object to continue to work like it does now: if you have a
> widget program, add a line or two of code to the widget definition module,
> and suddenly everything is dynamically resizable, no matter how complex the
> hierarchy is. This is the way widget resizing should be-it is not a problem
> worth all these posts :).
This automatic resizing idea is interesting to me.
I have a library of "widget objects", which wrap all
the IDL widgets up into object wrappers. Then, rather
then creating a widget hierarchy, you create an object
hierarchy, based on IDL container objects. This is really
a powerful way of programming, because we have figured
out how integrate widget events into our object hierarchy.
Events propagate up an object hierarchy in just the same
way they propagate up a widget hierarchy. In fact, widget
events can be sent to objects that are not even widgets!
In any case, our widget objects are all based on
low-level objects that give them the ability to
report what they are doing, self-document themselves,
reference count themselves so they are not destroyed
until they are no longer needed, etc. Putting the
automatic resizing feature into one of these lower-level
objects would be simple, I think, and -- as you say --
would give all the widget objects the ability to
resize themselves automatically.
If you care to share your code, I have a ready-made
system to test it out. :-)
Cheers,
David
--
David W. Fanning, Ph.D.
Fanning Software Consulting, Inc.
Phone: 970-221-0438, E-mail: david@dfanning.com
Coyote's Guide to IDL Programming: http://www.dfanning.com/
Toll-Free IDL Book Orders: 1-888-461-0155
|
|
|