Skip to content
Prev 247239 / 398503 Next

unicode&pdf font problem

On Jan 13, 2011, at 7:01 AM, tdenes at cogpsyphy.hu wrote:

            
You are after what Adobe calls: udblacute; 0171.  It is recognized in  
the list of adobe glyphs:
 >  str(tools::Adobe_glyphs[371, ])
'data.frame':	1 obs. of  2 variables:
  $ adobe  : chr "udblacute"
  $ unicode: chr "0171"

Consulted the help pages
points {graphics}
postscript {grDevices}
pdf {grDevices}
charsets {tools}
postscriptFonts {grDevices}

I have tried a variety of the pdfFonts installed on my Mac without  
success. You can perhaps make a list of fonts on your machines with  
names(pdfFonts()). Perhaps the range of fonts and the glyphs they  
contain is different on your machines. I get consistently warning  
messages saying there is a conversion failure:

 > pdf("trial.pdf", family="Helvetica")
# also tried with font="Helvetica" but I think that is erroneous
 > plot(1,type="n")
 > text(1,1,"print \U0170\U0171")
Warning messages:
1: In text.default(1, 1, "print ??") :
   conversion failure on 'print ??' in 'mbcsToSbcs': dot substituted  
for <c5>
2: In text.default(1, 1, "print ??") :
   conversion failure on 'print ??' in 'mbcsToSbcs': dot substituted  
for <b0>
3: In text.default(1, 1, "print ??") :
   conversion failure on 'print ??' in 'mbcsToSbcs': dot substituted  
for <c5>
4: In text.default(1, 1, "print ??") :
   conversion failure on 'print ??' in 'mbcsToSbcs': dot substituted  
for <b1>
5: In text.default(1, 1, "print ??") :
   font metrics unknown for Unicode character U+0170
6: In text.default(1, 1, "print ??") :
   font metrics unknown for Unicode character U+0171
7: In text.default(1, 1, "print ??") :
   conversion failure on 'print ??' in 'mbcsToSbcs': dot substituted  
for <c5>
8: In text.default(1, 1, "print ??") :
   conversion failure on 'print ??' in 'mbcsToSbcs': dot substituted  
for <b0>
9: In text.default(1, 1, "print ??") :
   conversion failure on 'print ??' in 'mbcsToSbcs': dot substituted  
for <c5>
10: In text.default(1, 1, "print ??") :
   conversion failure on 'print ??' in 'mbcsToSbcs': dot substituted  
for <b1>

And this is despite my system saying the \U0170 and \U0171 are present  
in the Helvetica font. Also tried family=URWHelvetica and  
family=NimbusSanand and a bunch of others without success, but my last  
best hope after reading the material in help(postscript) in the  
"Families" section had been NimbusSan.  There is also information on  
that page regarding encodings that appears to be very machine specific.
David Winsemius, MD
West Hartford, CT