From: Tom P. <tpi...@ad...> - 2006-01-31 15:50:45
|
And it was also brought to my attention that you can indeed re-parent a Qt widget that is initially created with a NULL parent - very good to know. The only question then is whether there's any significant overhead involved if this means each such widget is first created as a platform window and then changed to a child view when re-parented. I'll guess I'll cross that bridge... Thanks, Tom > If it helps with implementation issues, you can easily reparent a Window > to another parent using SetParent() (at least within the same process). > I suspect all controls could start with the same parent - an invisible > window hiding somewhere, and then be reparented 'when the time is right'. > > > Tony Van Eerd > Adobe Waterloo > -via Thunderbird- > > Tom Pinkerton wrote: >> Hi All, >> >> While digging into my Qt implementation of the widgets library, I've noticed >> that a widget's parent appears to be set after the underlying platform >> widget itself is created. On MacOS this is not a problem because a control >> can be initially created without a parent. However, the existing Windows >> implementation uses some kind of 'invisible parent' member as an initial >> parent when a control is created. In Qt, like on Windows, a widget needs a >> parent at creation time, so I'm wondering if I will need a similar >> 'invisible parent' mechanism for my Qt implementation. Does Eve somehow rely >> upon setting the parent after a widget is initially created? Is the sole >> purpose of the display_t object to provide a way to set the widget's parent >> hierarchy? Will the parent hierarchy ever change for a given Eve layout >> after the initial layout is created? >> >> Thanks, >> >> Tom |