From maechler at stat.math.ethz.ch  Fri Nov 14 10:57:39 2003
From: maechler at stat.math.ethz.ch (Martin Maechler)
Date: Fri Nov 14 10:56:46 2003
Subject: [Rd] plotmath problems with X11 fonts (Redhat 9)
In-Reply-To: <Pine.LNX.4.44.0311140940510.24720-100000@gannet.stats>
References: <16308.40096.484250.936454@gargle.gargle.HOWL>
	<Pine.LNX.4.44.0311140940510.24720-100000@gannet.stats>
Message-ID: <16308.42771.805123.849158@gargle.gargle.HOWL>

>>>>> "BDR" == Prof Brian Ripley <ripley@stats.ox.ac.uk>
>>>>>     on Fri, 14 Nov 2003 09:47:58 +0000 (GMT) writes:

    BDR> On Fri, 14 Nov 2003, Martin Maechler wrote:
    >> We've only switched from redhat 7.3 to 9 several weeks ago, and
    >> I found today, that the last three pages
    >> of
    >> demo(plotmath)
    >> uses quite wrong plot symbols, e.g  
    >> sum(....) gives (+) {+ in circle} instead of the Sigma-like
    >> summation --- but only in "text" not in title, i.e., probably a
    >> font problem.
    >> With postscript() {and hence dev.print() of x11()} all is fine.
    >> Hence it must be an X font server problem of some kind.
    >> Here is a reproducible example:
    >> 
    >> xsum <- expression(sum(x[i], i = 1, n))
    >> plot(1.1, main=xsum, xlab=xsum, ylab=xsum)
    >> text(1,1,xsum)
    >> 
    >> which produces the graphic that I attach.
    >> If you can try this yourself _and_ if you see the same effect,
    >> could you tell me (or us) what OS / setup / ... you are using?
    >> 
    >> Could R try better to get proper X11 fonts?

    BDR> You mean the desired ones?  (Presumably they are proper.)
yes
    BDR> Yes. It tries

    BDR> "-*-symbol-*-*-*-*-%d-*-*-*-*-*-*-*"

    BDR> What does

    BDR> xlsfonts -fn "-*-symbol-*-*-*-*-*-*-*-*-*-*-*-*"

    BDR> give on your system?  I have

    BDR> -adobe-symbol-medium-r-normal--10-100-75-75-p-61-adobe-fontspecific
    BDR> -adobe-symbol-medium-r-normal--11-80-100-100-p-61-adobe-fontspecific
    BDR> -adobe-symbol-medium-r-normal--12-120-75-75-p-74-adobe-fontspecific
    BDR> -adobe-symbol-medium-r-normal--14-100-100-100-p-85-adobe-fontspecific
    BDR> -adobe-symbol-medium-r-normal--14-140-75-75-p-85-adobe-fontspecific
    BDR> -adobe-symbol-medium-r-normal--17-120-100-100-p-95-adobe-fontspecific
    BDR> -adobe-symbol-medium-r-normal--18-180-75-75-p-107-adobe-fontspecific
    BDR> -adobe-symbol-medium-r-normal--20-140-100-100-p-107-adobe-fontspecific
    BDR> -adobe-symbol-medium-r-normal--24-240-75-75-p-142-adobe-fontspecific
    BDR> -adobe-symbol-medium-r-normal--25-180-100-100-p-142-adobe-fontspecific
    BDR> -adobe-symbol-medium-r-normal--34-240-100-100-p-191-adobe-fontspecific
    BDR> -adobe-symbol-medium-r-normal--8-80-75-75-p-51-adobe-fontspecific
    BDR> -urw-symbol-medium-r-normal--0-0-0-0-p-0-adobe-fontspecific
    BDR> -urw-symbol-medium-r-normal--17-120-100-100-p-0-adobe-fontspecific

    BDR> I presume we should have

    BDR> "-*-symbol-*-*-*-*-%d-*-*-*-*-*-adobe-*"

    BDR> but your listing will tell us the problem.

Hmm, its beginning is identical to yours, and then goes on :

-adobe-symbol-medium-r-normal--10-100-75-75-p-61-adobe-fontspecific
-adobe-symbol-medium-r-normal--11-80-100-100-p-61-adobe-fontspecific
-adobe-symbol-medium-r-normal--12-120-75-75-p-74-adobe-fontspecific
-adobe-symbol-medium-r-normal--14-100-100-100-p-85-adobe-fontspecific
-adobe-symbol-medium-r-normal--14-140-75-75-p-85-adobe-fontspecific
-adobe-symbol-medium-r-normal--17-120-100-100-p-95-adobe-fontspecific
-adobe-symbol-medium-r-normal--18-180-75-75-p-107-adobe-fontspecific
-adobe-symbol-medium-r-normal--20-140-100-100-p-107-adobe-fontspecific
-adobe-symbol-medium-r-normal--24-240-75-75-p-142-adobe-fontspecific
-adobe-symbol-medium-r-normal--25-180-100-100-p-142-adobe-fontspecific
-adobe-symbol-medium-r-normal--34-240-100-100-p-191-adobe-fontspecific
-adobe-symbol-medium-r-normal--8-80-75-75-p-51-adobe-fontspecific
-urw-symbol-medium-r-normal--0-0-0-0-p-0-adobe-fontspecific
-urw-symbol-medium-r-normal--17-120-100-100-p-0-adobe-fontspecific
-zz_abiword-symbol-bold-i-normal--0-0-0-0-p-0-adobe-fontspecific
-zz_abiword-symbol-bold-i-normal--0-0-0-0-p-0-adobe-fontspecific
-zz_abiword-symbol-bold-i-normal--17-120-100-100-p-0-adobe-fontspecific
-zz_abiword-symbol-bold-i-normal--17-120-100-100-p-0-adobe-fontspecific
-zz_abiword-symbol-bold-r-normal--0-0-0-0-p-0-adobe-fontspecific
-zz_abiword-symbol-bold-r-normal--0-0-0-0-p-0-adobe-fontspecific
-zz_abiword-symbol-bold-r-normal--17-120-100-100-p-0-adobe-fontspecific
-zz_abiword-symbol-bold-r-normal--17-120-100-100-p-0-adobe-fontspecific
-zz_abiword-symbol-regular-i-normal--0-0-0-0-p-0-adobe-fontspecific
-zz_abiword-symbol-regular-i-normal--0-0-0-0-p-0-adobe-fontspecific
-zz_abiword-symbol-regular-i-normal--17-120-100-100-p-0-adobe-fontspecific
-zz_abiword-symbol-regular-i-normal--17-120-100-100-p-0-adobe-fontspecific
-zz_abiword-symbol-regular-r-normal--0-0-0-0-p-0-adobe-fontspecific
-zz_abiword-symbol-regular-r-normal--0-0-0-0-p-0-adobe-fontspecific
-zz_abiword-symbol-regular-r-normal--17-120-100-100-p-0-adobe-fontspecific
-zz_abiword-symbol-regular-r-normal--17-120-100-100-p-0-adobe-fontspecific

so, yes, I'll try to turn off the abiword fonts, but somehow
they shouldn't be the harm since they come after the other ones
(and they end in "....-adobe-*" as well!).


    BDR> BTW, I think we should be giving the user some control over this, to get
    BDR> adobe in preference to urw or iso10646 in preference to iso8859, or 
    BDR> whatever.

Yes, that control might become quite useful.
Martin


[Rd] plotmath problems with X11 fonts (Redhat 9)
Martin Maechler