|
Re: Angstrom symbol in IDL/PvWave title [message #391 is a reply to message #390] |
Wed, 25 March 1992 07:19  |
hcohl
Messages: 2 Registered: May 1992
|
Junior Member |
|
|
Hi,
I wrote an IDL script a little while back that emulates
a vector drawn angstrom as a string.
You would do something like this:
IDL> xyouts,10,10,angstrom(),/dev
for instance...
Good luck
here it is,
Howie
------------------------------------------------------------ -------------
Howard Cohl HOME : (505)434-3717
National Solar Observatory WORK : (505)434-7000
Sunspot, New Mexico E-MAIL : hcohl@sunspot.noao.edu
88349
------------------------------------------------------------ -------------
;----------------------------------------------------------- --
;+
; NAME:
; ANGSTROM
; PURPOSE:
; This function, if called, returns a string containing
; the vector drawn signature of the angstrom symbol.
; CATEGORY:
; TEXT STRING ROUTINES
; CALLING SEQUENCE:
; sang = angstrom()
; INPUTS:
; NONE
; KEYWORD PARAMETERS:
; OUTPUTS:
; sang = A scalar string containing the vector drawn
; signature of the angstrom symbol.
; type: scalar,string
; COMMON BLOCKS:
; NOTES:
; MODIFICATION HISTORY:
; H. Cohl, 2 Apr, 1991 ---
;-
;----------------------------------------------------------- --
function angstrom,help=help
angstrom='!SA!R!U!9 %!17'
sang=string(angstrom)
return,sang
end
--
------------------------------------------------------------ -------------
Howard Cohl HOME : (505)434-3717
National Solar Observatory WORK : (505)434-7000
|
|
|
Re: Angstrom symbol in IDL/PvWave title [message #393 is a reply to message #391] |
Wed, 25 March 1992 05:51  |
dieh1232
Messages: 1 Registered: March 1992
|
Junior Member |
|
|
In article <1992Mar24.201306.16257@ucsu.Colorado.EDU> boroson@ucsu.Colorado.EDU (BOROSON BRAM S) writes:
> I'm making a plot and I need to use an Angstrom symbol in a title.
> I don't see this symbol listen in the vector-drawn fonts (chapter 12
> of the IDL manual) and I was wondering how other people solve this.
>
We got the same sort of problem here in Germany with our Umlauts ("a,"o,"u).
As a workaround I initialize a commmon block at the beginning of each
session that contains strings with base-character, the two dots and some
character-positioning-commands. It is not really perfect in the looks, but
PVI didn't offer anything better. For using these special characters I
concatenate them with the other parts of the string to print,
e.g.: title=aeg+'rger'
common umlaut ,ae,aeg,oe,oeg,ue,ueg
ae='!sa!r!u!e!9 . . !n!3' & aeg='!sA!r!u!e!9 . . !n!3'
oe='!so!r!u!e!9 . . !n!3' & oeg='!sO!r!u!e!9 . . !n!3'
ue='!su!r!u!e!9 . . !n!3' & ueg='!sU!r!u!e!9 . . !n!3'
I suppose you could create the Angstrom in a similar way.
rolf
rolf diehl technical university berlin
dieh1232@files1zrz.zrz.tu-berlin.de
|
|
|
|
Re: Angstrom symbol in IDL/PvWave title [message #395 is a reply to message #394] |
Tue, 24 March 1992 15:44  |
sterne
Messages: 15 Registered: March 1992
|
Junior Member |
|
|
||> I'm making a plot and I need to use an Angstrom symbol in a title.
|> I don't see this symbol listen in the vector-drawn fonts (chapter 12
|> of the IDL manual) and I was wondering how other people solve this.
Divide by 0.5292 and label it "atomic units" instead :-)
Depending on your output device, you may be able to find a hardware font with the Angstrom symbol in it. This brings up another problem, however, which I have found very irritating. Unlike the Hershey fonts, here seems to be no way of mixing fonts within a string for the hardware fonts, eg postscript. If you want to mix symbol and non-symbol characters in the same line, you have to use two different xyouts commands and line them up by hand. Anybody got a better way?
Phil
--
Philip Sterne | sterne@dublin.llnl.gov
Lawrence Livermore National Laboratory | Phone (510) 422-2510
Livermore, CA 94550 | Fax (510) 422-7300
|
|
|