Re: Switching Between Multiple XMANAGER Windows [message #17335] |
Fri, 08 October 1999 00:00  |
Pavel Romashkin
Messages: 166 Registered: April 1999
|
Senior Member |
|
|
I agree with this point. However, in the original message Michael writes:
> However, I need to be able to
> return to the first window to be able to do the same for a second pixel
> without losing the second window.
which I understood as he wants to have previous detailed pixel information window
preserved while another one may be created. It is east to program a way to control
the number of daughter windows and not let them hatch with no limit, for instance,
by destroying older ones if the total number of them exceeds 5. Or, a user can
take control and kill those he is done with.
Cheers,
Pavel
Harald Frey wrote:
> Pavel Romashkin wrote:
>
>> Although I am not quite clear about what an XMANAGER window is, I see no
>> obstacle to using WIDGET_DRAW to produce more than one popup daughter windows
>> when the mouse is clicked inside that WIDGET_DRAW. Why not just include a
>> base widget creation routine in the event handler for the draw widget, and
>> have event_handler create a base with an information widget, with pixel ID,
>> label, text, table or image zoom-in - anything you want, and leave it in case
>> you need that information. Then, when you click on another pixel, another
>> window, identical to the first info base, will pop up, and so on. To destroy
>> them easily, I'd use /group_leadre keyword. Or am I missing something
>> complicating here? I don't even see the need to use pointers.
>> Good luck,
>> Pavel
>>
>
> If you do this you may end up with dozens of similar
>
> widget windows. What I do to avoid this is to set a
>
> flag in my info structure which shows that the child
>
> widget already exists and it will be destroyed before
>
> the new one is created. It looks like this.
>
> IF (info.wiczoom NE 0l) then WIDGET_CONTROL,info.wiczoom,/DESTROY
> zoomBase = WIDGET_BASE(TITLE='WIC Zoom',ROW=3)
> info.wiczoom = zoomBase
>
> Harald
>
> =========================================================
> Harald U. Frey
> Space Sciences Lab phone: 510-643-3323
> University of California fax: 510-643-2624
> Berkeley, CA 94720-7450 email: hfrey@ssl.berkeley.edu
|
|
|