Re: XYOUTS overwrites [message #2852] |
Fri, 09 September 1994 17:16 |
scott
Messages: 17 Registered: January 1994
|
Junior Member |
|
|
Frank Hoffsuemmer writes
> Hi,
>
> I want to plot some images using the TVSCL routine in IDL (ver 3.1.1).
> Basically, what I want to do is something like
>
> FOR counter=0,n DO BEGIN
> XYOUTS, 0.1, 0.9, /NORMAL, '!3 Image Number: '+STRING(counter)
> TVSCL, image(counter)
> ENDFOR
>
> The problem is, this way, XYOUTS doesn't clear the place before writing
on it.
> My XYOUTS print is just one of many in the actual window, and it's not
supposed to be
> a window- or plot-title (even if it might look like this in my example).
> So: how to do that??
> Any help appreciated. Thanx
>
>
>
-=-=-=-=-=-=-=-=-=-=-=-=--=-=--=-=-=-=-=-=-=-=-=-=-=-=--=-=- =-=-=-=-=-=-=-
=-=-=-
>
> Frank Hoffsuemmer
E-Mail:frank@chaos.uni-frankfurt.de
> Institut fuer Theor. Physik ,__o
> Robert-Mayer-Str. 8 -\_<, Office: Phone (49) 69 /
798-3359
> D-60054 Frankfurt am Main (*)/'(*) Fax (49) 69 /
798-8354
> Germany Home : Phone (49) 69 / 289447
>
>
-=-=-=-=-=-=-=-=-=-=-=-=--=-=--=-=-=-=-=-=-=-=-=-=-=-=--=-=- =-=-=-=-=-=-=-
=-=-=-
>
>
Use the procedure POLYFILL to draw a white rectangle over the area in
question just before calling XYOUTS.
--
A. Scott Denning (303)491-8346
<scott@abyss.atmos.colostate.edu>
Dept. of Atmospheric Science
Colorado State University
Fort Collins, CO 80523
|
|
|
Re: XYOUTS overwrites [message #2868 is a reply to message #2852] |
Wed, 07 September 1994 07:36  |
landers
Messages: 45 Registered: May 1993
|
Member |
|
|
In article <34i1qc$1092@jurpool0.rz.uni-frankfurt.de>, frank@chaos.uni-frankfurt.dbp.de (Frank Hoffsuemmer) writes:
|> Hi,
|>
|> I want to plot some images using the TVSCL routine in IDL (ver 3.1.1).
|> Basically, what I want to do is something like
|>
|> FOR counter=0,n DO BEGIN
|> XYOUTS, 0.1, 0.9, /NORMAL, '!3 Image Number: '+STRING(counter)
|> TVSCL, image(counter)
|> ENDFOR
|>
|> The problem is, this way, XYOUTS doesn't clear the place before writing on it.
|> My XYOUTS print is just one of many in the actual window, and it's not supposed to be
|> a window- or plot-title (even if it might look like this in my example).
|> So: how to do that??
|> Any help appreciated. Thanx
Not sure I understand.... If you want the entire plot window to be erased,
then use ERASE before the XYOUTS.
If you want the area "under" the XYOUTS string to be erased first (like a
solid background rather than overlaying the string, then you could do
*something* like this:
width = !D.X_Ch_Size * STRLEN( the_string )
height = !D.Y_Ch_Size
blank = REPLICATE( !P.Background, width, height )
TV, blank, x_out, y_out, /Normal
XYOUTS, x_out, y_out, /Normal, the_string
This is a bit rough, and doesn't exactly center the blank area oround the
text, but you can work that out for yourself....
----
Dave
|>
|>
|> -=-=-=-=-=-=-=-=-=-=-=-=--=-=--=-=-=-=-=-=-=-=-=-=-=-=--=-=- =-=-=-=-=-=-=-=-=-=-
|>
|> Frank Hoffsuemmer E-Mail:frank@chaos.uni-frankfurt.de
|> Institut fuer Theor. Physik ,__o
|> Robert-Mayer-Str. 8 -\_<, Office: Phone (49) 69 / 798-3359
|> D-60054 Frankfurt am Main (*)/'(*) Fax (49) 69 / 798-8354
|> Germany Home : Phone (49) 69 / 289447
|>
|> -=-=-=-=-=-=-=-=-=-=-=-=--=-=--=-=-=-=-=-=-=-=-=-=-=-=--=-=- =-=-=-=-=-=-=-=-=-=-
|>
|>
|>
|
|
|
Re: XYOUTS overwrites [message #2869 is a reply to message #2868] |
Wed, 07 September 1994 10:24  |
fast
Messages: 1 Registered: September 1994
|
Junior Member |
|
|
frank@chaos.uni-frankfurt.dbp.de writes
|> The problem is, this way, XYOUTS doesn't clear the place before writing on it.
|> My XYOUTS print is just one of many in the actual window, and it's not supposed to be
|> a window- or plot-title (even if it might look like this in my example).
|> So: how to do that??
|> Any help appreciated. Thanx
A simple way to erase just under and around the text,
print the string twice; the first time, thick and of
the desired background color, the second time, thin.
Quality of the result is mixed; it depends a lot on
the font and font size.
xyouts, x, y, the_string, charsize=1.5, charthick=9, color=255
xyouts, x, y, the_string, charsize=1.5, charthick=1, color=0
|
|
|