Re: FONT setting [message #32934] |
Tue, 19 November 2002 18:24 |
David Fanning
Messages: 11724 Registered: August 2001
|
Senior Member |
|
|
tom (tom2959@21cn.com) writes:
> How to use other type of TTF? I have many TTF on my computer which can be
> used in MS WORD. Would you please insert code in the following if I want to
> use TTF named ABC.ttf?
>
> Pro test
> set_plot,'ps'
> set_plot,'win'
> !p.font=1
> plot,x,y,xtitle='TEST TTF'
> end
Well, I have a Batang True-Type font on my machine.
To see this plot in Batang, I would do this:
Pro test
thisDevice = !D.Name
set_plot,'ps'
device, set_font='batang', /tt_font
!p.font=1
plot,findgen(11),xtitle='TEST TTF', $
position=[0.1,0.2, 0.9, 0.9], charsize=2.5
if !d.name EQ 'PS' then device, /close_file
set_plot, thisDevice
end
>> For everything but the most demanding journal output,
>> I usually go with the good ol' Helvetica hardware
>> fonts. :-)
>
> When I set font=0 the two figure looks quit different. For example,
> !p.font=0
> plot,x,y,title='dfdjhfdjhfjghfjghfjghfgfjghfjgfghfjgfgfhfguf gju'
> end
> In win figure, the title is much shorter than that in PS. How to change it?
I didn't say they were "the same". It think I said they were "similar".
Obviously Helvetica is not the same as Hershey Simplex Roman.
> Sometimes there are many text in the figure, when I use xyouts to put them
> in the correct position in WIN, they are not on the correct position in PS.
Typically, we use normalized coordinates when we place
text on plots that we want to display in a window and on
a PostScript page. That gets things in roughly the correct
position. Sometimes you have to fiddle around a bit. If you
want presentation quality graphics buy Correl Draw, not IDL. :-)
Cheers,
David
--
David W. Fanning, Ph.D.
Fanning Software Consulting, Inc.
Phone: 970-221-0438, E-mail: david@dfanning.com
Coyote's Guide to IDL Programming: http://www.dfanning.com/
Toll-Free IDL Book Orders: 1-888-461-0155
|
|
|
Re: FONT setting [message #32935 is a reply to message #32934] |
Tue, 19 November 2002 17:38  |
tom
Messages: 28 Registered: April 1995
|
Junior Member |
|
|
Thanks David.
> If you really want "the same", I recommend you use
> True-Type fonts (!P.Font=1). IDL comes with four
> true-type fonts families (Times, Helvetica, Courier,
> and Symbol), but you can use any you can find on your
> computer.
How to use other type of TTF? I have many TTF on my computer which can be
used in MS WORD. Would you please insert code in the following if I want to
use TTF named ABC.ttf?
Pro test
set_plot,'ps'
set_plot,'win'
!p.font=1
plot,x,y,xtitle='TEST TTF'
end
> For everything but the most demanding journal output,
> I usually go with the good ol' Helvetica hardware
> fonts. :-)
When I set font=0 the two figure looks quit different. For example,
!p.font=0
plot,x,y,title='dfdjhfdjhfjghfjghfjghfgfjghfjgfghfjgfgfhfguf gju'
end
In win figure, the title is much shorter than that in PS. How to change it?
Sometimes there are many text in the figure, when I use xyouts to put them
in the correct position in WIN, they are not on the correct position in PS.
Best
TOM
|
|
|
Re: FONT setting [message #32942 is a reply to message #32935] |
Tue, 19 November 2002 10:00  |
K. Bowman
Messages: 330 Registered: May 2000
|
Senior Member |
|
|
In article <MPG.1843e803f72c4fa3989a31@news.frii.com>,
David Fanning <david@dfanning.com> wrote:
> If you really want "the same", I recommend you use
> True-Type fonts (!P.Font=1). IDL comes with four
> true-type fonts families (Times, Helvetica, Courier,
> and Symbol), but you can use any you can find on your
> computer. My experience is that these look pretty lame
> at small font sizes on the display, but they print
> wonderfully well.
Beware if you plan to 'tweak' Postscript plots containing Truetype fonts
using something like Adobe Illustrator. Truetype fonts are drawn in
Postscript output as polygons, not 'hardware' fonts. You cannot edit
them using the usual text editing tools.
My rule of thumb is: Hershey fonts for the screen; Postscripts fonts
for hardcopy, except for 3-D plots, when you have to use Truetype fonts
to get the 3-D rotation right.
Ken Bowman
|
|
|
Re: FONT setting [message #32947 is a reply to message #32942] |
Tue, 19 November 2002 05:18  |
David Fanning
Messages: 11724 Registered: August 2001
|
Senior Member |
|
|
tom (tom2959@21cn.com) writes:
> Hi, Generally, I plot a figure in window(set_plot,'win'), if it is good then
> I change the setting to set_plot,'ps'. But two figures are not different for
> the font(!p.font=3 or other). Are there any method to set font on order the
> two figures are the same?
Most people find they prefer Hershey vector
fonts in their display windows, but that these
are too thin for PostScript output. The typical
solution is to select hardware fonts (!P.Font=0)
when creating PostScript files. According to font
substitution rules built into IDL, the Simplex
Roman Hershey font is then replaced by a PostScript
Helvetica font. Not "the same", but not much of
a bother, either.
If you really want "the same", I recommend you use
True-Type fonts (!P.Font=1). IDL comes with four
true-type fonts families (Times, Helvetica, Courier,
and Symbol), but you can use any you can find on your
computer. My experience is that these look pretty lame
at small font sizes on the display, but they print
wonderfully well.
For everything but the most demanding journal output,
I usually go with the good ol' Helvetica hardware
fonts. :-)
Cheers,
David
--
David W. Fanning, Ph.D.
Fanning Software Consulting, Inc.
Phone: 970-221-0438, E-mail: david@dfanning.com
Coyote's Guide to IDL Programming: http://www.dfanning.com/
Toll-Free IDL Book Orders: 1-888-461-0155
|
|
|