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

Home » Public Forums » archive » Re: writing to 2 "windows" in idl?
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: writing to 2 "windows" in idl? [message #5637 is a reply to message #5633] Thu, 18 January 1996 00:00 Go to previous messageGo to previous message
steinhh is currently offline  steinhh
Messages: 260
Registered: June 1994
Senior Member
In article <CAS.96Jan17130850@revelle.cdc.noaa.gov>, cas@revelle.cdc.noaa.gov (Cathy Smith) writes:
|>
|> Hi- I'd like to write out character strings to a gif imagee and determine
|> their lengths (in pixels). I can do this using xyouts and this works for
|> most of what I want to do. However, now I would like to find the length
|> of a character string BEFORE I write it out. I tried writing out
|> in the same color as my image to get the returned length and then writing
|> it out again in the color I want. This works except that I cover up some
|> lines on my original plot that I don't want covered. Is there a way to
|> write to a "fake" device instead?
|>

You could use e.g.,

GXnoop = 5 ; This graphics function does no operation on the screen
device,get_graphics_function=oldgraphics ; Store
device,set_graphics_function=GXnoop ; Plot with the color that's there

device,font='-adobe-helvetica-bold-r-normal--10-100-75-75-p- 60-iso8859-1'
xyouts, x+4, y, string, /device,width=namew ,charsize=1.2,color=44
mmwidth=namew*n1

device,set_graphics_function=oldgraphics ; Put it back

xyouts, x-mmwidth-4, y, string, /device, width=namew ,charsize=1.2,color=222

Stein Vidar
[Message index]
 
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: Wanted double Gaussian fit IDL routine
Next Topic: MPEG creation with IDL

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

Current Time: Wed Oct 15 13:48:06 PDT 2025

Total time taken to generate the page: 0.88193 seconds