[R] how to add "arial" font in bitmap output?

Prof Brian Ripley ripley at stats.ox.ac.uk
Mon Aug 11 13:14:09 CEST 2008


On Mon, 11 Aug 2008, Hyunchul Kim wrote:

> I am using Linux (Ubuntu 8.04).
> I tried
> > dev.print(bitmap, file='test.png', family='arial')
> but it gave error message of
> 
> "Error in postscript(fild=cmd, width=width, height=height,
> pointsize=pointsize, : Unknown family 'arial' "
> 
> What should I do?

Create an Arial (not arial) postscript() family (and pay a lot closer 
attention to what your helpers advise you).  If you have Arial installed 
(msttcorefonts, I believe) you will need to create .afm files (perhaps via 
ttf2afm) for the family, and you will need to tell ghostscript about them.

See ?postscript and especially its 'See Also' items.

> 
> Thanks a lot in advance.
> 
> Hyunchul
> 
> 
> On Mon, Aug 11, 2008 at 4:09 PM, Prof Brian Ripley
> <ripley at stats.ox.ac.uk> wrote:
>       What OS are you using?
>       What device are you using to produce 'bitmap output'?
>
>       'Arial' (sic) is not a freely available font, but if you have
>       it on your system you may be able to make use of it by adding
>       a 'family'.  The details depend on details you failed to
>       give: please see the footer of this message.
> 
> 
> On Mon, 11 Aug 2008, Hyunchul Kim wrote:
> 
> Hi all,
> 
> I want to specify "arial" font in bitmap output but I found
> that the default
> is "helvetica" and "arial" is not supported.
> 
> How can I add "arial" in my bitmap output file?
> 
> Thanks,
> 
> Hyunchul
> 
>        [[alternative HTML version deleted]]
> 
> ______________________________________________
> R-help at r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide
> http://www.R-project.org/posting-guide.html
> and provide commented, minimal, self-contained, reproducible
> code.
> 
> 
> --
> Brian D. Ripley,                  ripley at stats.ox.ac.uk
> Professor of Applied Statistics,
>  http://www.stats.ox.ac.uk/~ripley/
> University of Oxford,             Tel:  +44 1865 272861 (self)
> 1 South Parks Road,                     +44 1865 272866 (PA)
> Oxford OX1 3TG, UK                Fax:  +44 1865 272595
> 
> 
> 
> 
> 
> 
>

-- 
Brian D. Ripley,                  ripley at stats.ox.ac.uk
Professor of Applied Statistics,  http://www.stats.ox.ac.uk/~ripley/
University of Oxford,             Tel:  +44 1865 272861 (self)
1 South Parks Road,                     +44 1865 272866 (PA)
Oxford OX1 3TG, UK                Fax:  +44 1865 272595


More information about the R-help mailing list