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

Home » Public Forums » archive » Re: text aspect ratio when resizing object windows
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Return to the default flat view Create a new topic Submit Reply
Re: text aspect ratio when resizing object windows [message #18518] Tue, 04 January 2000 00:00
davidf is currently offline  davidf
Messages: 2866
Registered: September 1996
Senior Member
Brad Gom (b_gom@nospam.hotmail.com) writes:

> I wonder if there is an easy way to keep text legible when resizing an
> object graphics window. I am using object graphics to display a simple
> 2-d plot. To handle resizing events from the plot window, I use the
> following:
>
> PRO plot_Resize_Event, event
> Widget_Control, event.top, Get_UValue=info, /No_Copy
> ; Resize the draw widget.
> info.plotWindow->SetProperty, Dimension=[event.x, event.y]
> info.plotWindow->Draw, info.plotView
> Widget_Control, event.top, Set_UValue=info, /No_Copy
> END
>
> this works fine except for the text, which gets stretched out of
> proportion when the aspect ratio of the window is changed too much.
>
> How can I scale the plot properly while maintaining normal-looking text?

Set the Recompute_Dimensions keyword on your Axes objects
to 2. Here is an article that describes a similar problem
when adding new data to an object plot:

http://www.dfanning.com/tips/font_dimensions.html

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
[Message index]
 
Read Message
Previous Topic: Kudos to RSI
Next Topic: text aspect ratio when resizing object windows

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

Current Time: Sat Oct 11 12:53:53 PDT 2025

Total time taken to generate the page: 1.44080 seconds