CUPS 1.4.3 && printing UTF-8 text

rebelde guru at unixarea.de
Wed Aug 4 01:28:03 PDT 2010


rebelde wrote:

> # generated with 'fontforge' out of freefont-sfd-20090104.tar.gz
> #
> 0000 00FF ltor single FreeMono.pfa FreeMonoBold.pfa FreeMonoOblique.pfa
> FreeMonoBoldOblique.pfa 0100 01FF ltor single FreeMono.pfa
> FreeMonoBold.pfa FreeMonoOblique.pfa FreeMonoBoldOblique.pfa 0200 02FF
> ltor single FreeMono.pfa FreeMonoBold.pfa FreeMonoOblique.pfa
> FreeMonoBoldOblique.pfa 0300 03FF ltor single FreeMono.pfa
> FreeMonoBold.pfa FreeMonoOblique.pfa FreeMonoBoldOblique.pfa 0400 04FF
> ltor single FreeMono.pfa FreeMonoBold.pfa FreeMonoOblique.pfa
> FreeMonoBoldOblique.pfa 1E00 1EFF ltor single FreeMono.pfa
> FreeMonoBold.pfa FreeMonoOblique.pfa FreeMonoBoldOblique.pfa 1F00 1FFF
> ltor single FreeMono.pfa FreeMonoBold.pfa FreeMonoOblique.pfa
> FreeMonoBoldOblique.pfa 2000 20FF ltor single FreeMono.pfa
> FreeMonoBold.pfa FreeMonoOblique.pfa FreeMonoBoldOblique.pfa 2300 23FF
> ltor single FreeMono.pfa FreeMonoBold.pfa FreeMonoOblique.pfa
> FreeMonoBoldOblique.pfa 2400 24FF ltor single FreeMono.pfa
> FreeMonoBold.pfa FreeMonoOblique.pfa FreeMonoBoldOblique.pfa 2500 25FF
> ltor single FreeMono.pfa FreeMonoBold.pfa FreeMonoOblique.pfa
> FreeMonoBoldOblique.pfa 2600 26FF ltor single FreeMono.pfa
> FreeMonoBold.pfa FreeMonoOblique.pfa FreeMonoBoldOblique.pfa
> 
> I've checked even with fontforge if in the file FreeMono.pfa in U+0370...
> are glyphs;
> 
> When I print something I can proof with 'ls -ltru' in the fonts dir that
> the file FreeMono.pfa is read by CUPS.

To get a fully understanding I've had a look in the source of CUPS's texttops 
filter, run this by hand as:

CHARSET=utf-8 cups-1.4.3/filter/texttops 1 rleigh myfile 1 "" < CUPS-UTF8.txt > /tmp/ps

and checked the resulting PS file... which contains lines like 

%%DocumentNeededResources: font FreeMonoBold.pfa
%%+ font FreeMono.pfa
%%DocumentSuppliedResources: procset texttops 1.1 0
%%EndComments

i.e. the provided fontnames are there;

CUPS-PDF uses Ghostscript to convert the PS file to PDF and this is where
the fault was. I detected this when y run 'gs' by hand with the file: Of course
the fonts must be provided as well in the fonts directory of Ghostscript, in my case
in /usr/local//share/ghostscript/8.70/Resource/Font

Now the PDF contains also Greek, but still no Hebrew. Will look deeper in the
GNU FreeFont project. In any case this is not a CUPS problem anymore.

Thanks for your helping hand, Helge!

    matthias




More information about the cups mailing list