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

Home » Public Forums » archive » String length when FONT=1
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Return to the default flat view Create a new topic Submit Reply
String length when FONT=1 [message #29094] Thu, 31 January 2002 11:53 Go to previous message
Paul van Delst is currently offline  Paul van Delst
Messages: 364
Registered: March 1997
Senior Member
Hey there,

Anyone know how to determine string length in normalised units when you're using truetype
fonts?

Currently I have:

ch_size = CONVERT_COORD( !D.X_CH_SIZE, !D.Y_CH_SIZE, /DEVICE, /TO_NORMAL )
x_ch_size = ch_size[ 0 ] * charsize
x_length = STRLEN( my_string ) * x_ch_size )

which works great for the regular on-screen hershey type of fonts, but not for proportional
fonts.

any ideas? what I want to do is blank out the plot behind the text, e.g. like for legends etc.

paulv

--
Paul van Delst Religious and cultural
CIMSS @ NOAA/NCEP purity is a fundamentalist
Ph: (301)763-8000 x7274 fantasy
Fax:(301)763-8545 V.S.Naipaul
[Message index]
 
Read Message
Read Message
Read Message
Previous Topic: Re: String length when FONT=1
Next Topic: Tick formatting

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

Current Time: Fri Oct 10 06:44:23 PDT 2025

Total time taken to generate the page: 0.55775 seconds