[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Display widgets' scaling factors
- Subject: Re: Display widgets' scaling factors
- From: steinhh(at)ulrik.uio.no (Stein Vidar Hagfors Haugan)
- Date: 10 Sep 1998 08:31:06 GMT
- In-reply-to: davidf@dfanning.com's message of Wed, 9 Sep 1998 11:03:32 -0600
- Newsgroups: comp.lang.idl-pvwave
- Organization: University of Oslo, Norway
- Xref: news.doit.wisc.edu comp.lang.idl-pvwave:12104
David Fanning wrote:
> The proper thing would be to draw into the first window
> and *immediately* save the system variables.
Yep. That's the name of the game. I wrote a couple of routines
many years ago (ca 1994!) to deal with this kind of task. They're
used like this:
plot,something
p1 = pstore(1) ;; Returns a "plot region ID number"
plot,somethingelse ;; You may have more than one plot in
;; a window.
p2 = pstore(2) ;; Hence the number "2"
wset,some_other_window
plot,third_thing
p3 = pstore(1) ;; First plot this window
prestore,p1 ;; Restores variables + does wset
oplot,on_top_of_first_one
prestore,p3
oplot,on_top_of_third_plot
etc.
To get just these files, look at
http://sohowww.nascom.nasa.gov/softops/cds/idl/util/display/
Get files pstore.pro, prestore.pro, pfind.pro and pconvert.pro.
The routines were designed to work with scaled (rebinned), displayed
images as well (actually, mostly!), hence the mention in the
doc's about data X/Y size etc.
I think these routines are *mostly* independent of other
routines in that S/W tree, but you may have to change
TRIM() -> STRCOMPRESS(STRING(),??)
SETWINDOW -> WSET
Regards,
Stein Vidar