comp.lang.idl-pvwave archive
Messages from Usenet group comp.lang.idl-pvwave, compiled by Paulo Penteado

Home » Public Forums » archive » Can't position modal compound widget (such as cw_form)
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Switch to threaded view of this topic Create a new topic Submit Reply
Can't position modal compound widget (such as cw_form) [message #14688] Tue, 23 March 1999 00:00 Go to next message
Massimo Grion is currently offline  Massimo Grion
Messages: 1
Registered: March 1999
Junior Member
Using cw_form as a modal dialog, the widget always places itself on the
top left corner of the screen. Is there a way to center it, without
using cw_form inside an other widget?
I am using IDL 5.2, on VMS.

Thank you,
M. Grion
Re: Can't position modal compound widget (such as cw_form) [message #14736 is a reply to message #14688] Thu, 25 March 1999 00:00 Go to previous message
David Foster is currently offline  David Foster
Messages: 341
Registered: January 1996
Senior Member
Massimo Grion wrote:
>
> Using cw_form as a modal dialog, the widget always places itself on the
> top left corner of the screen. Is there a way to center it, without
> using cw_form inside an other widget?
> I am using IDL 5.2, on VMS.
>
> Thank you,
> M. Grion

Massimo -

You can use my POS_WIDGET.PRO routine to position a widget at:
(1) the center of the screen; (2) centered within a parent widget;
(3) to the right of a parent widget; or (4) "cascaded" relative
to a parent widget, offset in X and Y by a small amount. You can
call this before or after a widget has been realized.

You'll need to add a line like this inside a local copy of CW_FORM():

ret = POS_WIDGET(base)

to center the widget onscreen.

You can get POS_WIDGET.PRO at:

ftp://bial8.ucsd.edu/pub/software/idl/share

Dave
--

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ~~~~~~
David S. Foster Univ. of California, San Diego
Programmer/Analyst Brain Image Analysis Laboratory
foster@bial1.ucsd.edu Department of Psychiatry
(619) 622-5892 8950 Via La Jolla Drive, Suite 2240
La Jolla, CA 92037
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ~~~~~~
  Switch to threaded view of this topic Create a new topic Submit Reply
Previous Topic: How to link IDL files
Next Topic: Help: mapping image

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ] [ PDF ]

Current Time: Wed Oct 08 15:39:31 PDT 2025

Total time taken to generate the page: 0.00184 seconds