[Rd] Re: [R] Problems using Computer Modern fonts

Brian D'Urso durso@hussle.harvard.edu
Sat, 30 Jun 2001 10:08:52 -0400 (EDT)

On Fri, 29 Jun 2001, Prof Brian Ripley wrote:

> The facility was not put in for Computer Modern, but for other more
> normally encoded fonts (specifically Monotone Times and Lucida).  The
> postscript help page does say
>      It is the user's responsibility to check that suitable fonts are
>      made available, and that they contain the needed characters when
>      re-encoded.
> and latter
>      ###  ---- Use TeX's Computer Modern fonts ---
>      ## Only use alphanumeric chars here.

Yes, the documentation was clear on this. I was just hopeful that it would
work well enough to do all basic plot labels with TeX's fonts.

> > The second problem is that I would prefer to use the computer modern
> > symbols as well, but R seems to have the symbol font hard coded in
> > devPS.c (and perhaps elsewhere). Also the computer modern symbols are
> > spread across many fonts.
> R has the encoding hard-coded in plotmath.c, which is *much* more
> serious, and is why Symbol is hardcoded.

This might be a reason to alter the font encodings in the ps file to match
R, rather than try to change R. I'll have to look at whether it really
makes sense to do that in postscript, though.

> I don't follows this. Only a single driver users afm files, and it has
> several versions (ps, pdf, xfig).  How would the below be relevant to the
> Windows drivers, say.
> >
> > To give a more driver independent fix, one would have to give R a list of
> > fonts instead of a single font for each style. Then R would look through
> > those fonts (via the afm files) until it found the character it was
> > looking for. The nice part about this is that it would eliminate the hard
> > coded separation of the symbols from the alphanumeric characters since any
> > character can be found by this procedure and it could allow for symbols of
> > different styles, for example bold, italic, etc to be used if the fonts
> > are available. The downside of this is that it almost surely requires more
> > changes to R.

I don't really know how fonts work in windows. Clearly this would only be
an improvement for output using the ps fonts.

> `Patches will be accepted' I think sums this up.  No other program I know
> allows the flexibility that is already in R, and that took a lot of hard
> work, which I am not sure you have appreciated.

I'm sorry that I gave the impression that I don't appreciate the work that
has gone into R. I really think it is a great program. It is just so close
to solving all the data analysis and plotting problems that I have had
that I am hopeful that a few small modifications could bring it the rest
of the way. I will look further at what changes would need to be made, but
I am a newbie to R, so I have a lot to learn.

Brian D'Urso

r-devel mailing list -- Read http://www.ci.tuwien.ac.at/~hornik/R/R-FAQ.html
Send "info", "help", or "[un]subscribe"
(in the "body", not the subject !)  To: r-devel-request@stat.math.ethz.ch