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

Home » Public Forums » archive » Re: How can i get SCR_XSIZE, SCR_YSIZE of WIDGET_BASE
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
Re: How can i get SCR_XSIZE, SCR_YSIZE of WIDGET_BASE [message #16378] Fri, 23 July 1999 00:00
Pavel Romashkin is currently offline  Pavel Romashkin
Messages: 166
Registered: April 1999
Senior Member
Privet Dmitry,
Widget_info returns the original size of the top base, which it had when it
was first realized; I don't know why manual resizing does not alter this
values, I think it should. To get new size, use event.x and event.y fields
from the Resize event structure. However, once that event happened (and
you did not save new values from Resize event), that's it - the new size is
unknown (at least as far as I saw from playing with it). I think that if
the size of the top base changed through growth of child widgets (I posted
an annoying behavior like that to the group a few days ago), then the size
of the top base reported by widget_info, /geometry does change.
SCR_YSIZE is probably the same as YSIZE because the default units for YSIZE
are pixels, just as for SCR_YSIZE, and in this case YSIZE will be the same
as SCR_YSIZE.
Poka!
Pavel

Dmitriy Ryzhov wrote:

> Hi!
> I try to use construction "geom=Widget_Info(event.top, /GEOMETRY)" in
> OnSizeChange event but it returns equals numbers( for example
> { 0.000000 0.000000 1024.00 45.0000 1024.00
> 45.0000 0.000000 0.000000 0.000000 3.00000 3.00000
> 3.00000}) every time event happen. What does it mean?
> Why numbers don't changing? And why SCR_YSIZE is equal to YSIZE?
> What primary method to get SCR_XSIZE and other?
>
> --
> Regard, Dmitriy Ryzhov.
Re: How can i get SCR_XSIZE, SCR_YSIZE of WIDGET_BASE [message #16381 is a reply to message #16378] Fri, 23 July 1999 00:00 Go to previous message
davidf is currently offline  davidf
Messages: 2866
Registered: September 1996
Senior Member
Dmitriy Ryzhov (dryzhov@dialup.ptt.ru) writes:

> I try to use construction "geom=Widget_Info(event.top, /GEOMETRY)" in
> OnSizeChange event but it returns equals numbers( for example
> { 0.000000 0.000000 1024.00 45.0000 1024.00
> 45.0000 0.000000 0.000000 0.000000 3.00000 3.00000
> 3.00000}) every time event happen. What does it mean?
> Why numbers don't changing? And why SCR_YSIZE is equal to YSIZE?
> What primary method to get SCR_XSIZE and other?

Instead of printing the result, try this:

Help, geom, /Structure

The result is a structure. So, for example, to get the
X screen size:

x_screen_size = geom.scr_xsize

Cheers,

David

--
David Fanning, Ph.D.
Fanning Software Consulting
Phone: 970-221-0438 E-Mail: davidf@dfanning.com
Coyote's Guide to IDL Programming: http://www.dfanning.com/
Toll-Free IDL Book Orders: 1-888-461-0155
  Switch to threaded view of this topic Create a new topic Submit Reply
Previous Topic: Compile Problem with IDL5.2
Next Topic: Re: Using C++ classes with IDL

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

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

Total time taken to generate the page: 0.00616 seconds