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

Home » Public Forums » archive » width of xyouts?
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
width of xyouts? [message #19107] Thu, 24 February 2000 00:00
eddie haskell is currently offline  eddie haskell
Messages: 29
Registered: September 1998
Junior Member
Hello all,

I am trying to use the width keyword of xyouts to determine when a text
line extends past a boundry so that I can parse the line into smaller
pieces.

I have been obtaining the width of the text string by first calling
xyouts with a charsize of -1 to suppress printing. i.e.,

xyouts,0,0,charsize=-1,width=width,'whatever'

This works well until I try and use postscript fonts. Whenever I set
!p.font=0 the above xyouts call, instead of suppressing the text,
visibly writes the text upside down on the page.

If I try:

!p.font=-1
xyouts,0,0,charsize=-1,width=width,'whatever'
!p.font=0

I end up with a different value for width that I would get just using
!p.font=0. I also get different values when using the Z buffer so I
think I have to stay in the postscript device.

I could just call the xyouts with a position that will never be seen on
the page but that adds to the size of the postscript file whereas the
suppressed xyouts call does not. The same applies for writing the text
in the background colour.

So my question is: Is there a way to obtain the width of a text string
using postscript fonts without adding to the size of the postscript
file?

Cheers,
eddie

----- ---- --- --- ---- --- -- --- --- -- -- - - - -
|\ A G Edward Haskell
|\ Center for Coastal Physical Oceanography
|\ Old Dominion University, Norfolk VA 23529
|\ Voice 757.683.4816 Fax 757.683.5550
|\ e-mail haskell*ccpo.odu.edu
----- ---- --- ---- --- --- --- --- -- -- -- - - - -
  Switch to threaded view of this topic Create a new topic Submit Reply
Previous Topic: Re: Plotting double precision
Next Topic: Superresolution - MUSIC, MEM, MLM etc.

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

Current Time: Sat Oct 11 09:14:08 PDT 2025

Total time taken to generate the page: 0.51123 seconds