Re: xmanager, /managed [message #44002] |
Thu, 12 May 2005 09:05  |
David Fanning
Messages: 11724 Registered: August 2001
|
Senior Member |
|
|
Benjamin Hornberger writes:
> Now I can confirm this behaviour on IDL 6.1.1 on Windows. But you have
> to mention that you store the original !d.window at the beginning of
> your widget definition procedure and restore it after the
> "widget_control, /managed" call. Maybe you should link to xcolors.pro as
> example code.
>
> It seems to work in my program as well now, even though I don't really
> understand it. If I store my original !d.window and reset it at the end
> of my widget definition procedure, and do the same in each event handler
> which plots something, I would logically expect that it works as
> described even without the "widget_control, /managed". But it doesn't.
Humm. Not another problem I don't know what I'm talking about!
Not two days in a row, surely! Oh, dear Lord. :-(
You are right, I was keeping track of !D.Window in XColors,
something I don't ordinarily do. And clearly MANAGED does
*something* here, but what!?
I'm thinking now that its use is more limited that I thought.
(I think I was fooled by using XCOLORS as my test program. I
should have used something simpler.) I think it probably prevents
your widget window from becoming the "active" window when a window
gets closed and !D.Window has to go looking for another "active"
window. As such, it is useful, just not as useful as I thought
it was.
> Well, if you follow the "every man for himself" motto, what are we
> talking about then anyway?
I don't know. I really don't know. :-)
Cheers,
David
--
David Fanning, Ph.D.
Fanning Software Consulting, Inc.
Coyote's Guide to IDL Programming: http://www.dfanning.com/
|
|
|