Setup CUPS-1.4.6 in Solaris 10?

Helge Blischke h.blischke at acm.org
Fri Feb 18 04:14:26 PST 2011


dickson wrote:

>> > dickson wrote:
>> >
>> > > recap my current printing problem in a dot matrix printer:
>> > >
>> > > case 1. print a pdf (without embedded Chinese font), fails and no
>> > > print out.
>> > > case 2. print a pdf (with embedded Chinese font), can print it out.
>> > > case 3. print a plain text (UTF-8 Chinese characters), only print out
>> > > strange character in the printout.
>> > >
>> > > (About the details and logging, please view my previous message)
>> > >
>> > > I need to fix the problem in Case 1 first and then go on to solve the
>> > > problem in Case 3. Thanks anyone's help in advance.
>> >
>> > From the latest error_log in your last message I see that your pdftops
>> > filter is configured to use Ghostscript for the PDF to PostScript
>> > conversion. And this invocation of Ghostscript does not contain the -I
>> > switch. Moreover, this invocation uses Ghostscript's pswrite device
>> > which causes all glyphs of all fonts to be converted to bitmaps.
>> >
>> > To solve your case 1 ptoblem, I'd suggest to implement the Xpdf
>> > utilities from
>> > http://www.foolabs.com/xpdf/download.html
>> > and use the alternate pdftops filter (which is a Perl wrapper around
>> > the Xpdf utility) from
>> > http://www.cups.org/links.php?V70+Qpdftops
>> > Together with the already modified pstoraster filter, this approach
>> > should do it.
>> >
>>
>> I'm confused. Actually, which filter or how many filter for this
>> PDF-to-PS conversion in CUPS. When I read the overview of CUPS, I think
>> that is useful and ease to use. Now I feel difficult and complicated.
>> Also, I wonder why some filter are script and other are executable (such
>> like pdftops). I want to keep using Ghostscript. Therefore, I will
>> recompile Ghostscript 9.00 that can include the font mapping. And try it
>> again.
> 
> 
> After recompile GS that include the font mapping, CUPS can print the pdf
> (without embedded font) to EPSON dot matrix printer finally. Should go
> Case 3 - plain text file.
> 
> 
> 
>>
>>
>> > If you will have succeeded, let us go to your case 3 and tweak the
>> > cups' utf-8 charset file using a suitable chinese font.
> 
> For case 3, how can CUPS realize which charset the target document use? As
> I know, cups depends on the file extension to use other filter (texttops,
> pdftops, ...etc) to do conversion. Any idea to solve this case?
> 
> 
>>
>> What's wrong? Supportedly, should it automatically convert UTF-8(Chinese
>> charater) to ps and then print it out. Is it right?
>>
>> >
>> > Helge
>> >
>>

Well, the filter that converts plain text (UTF-8 encoded) to PostScript 
depends on the configured monospaced font to contain the rquired glyph 
descriptions for the respective unicode range.
By default, CUPS comes with a font family named Monospace with the styles 
plain, Bold, Oblique, and BoldOblique.

This font does not provide chinese glyphs.

But by editing the utf-8 charset file which comes with cups, it is possible 
to specify a suitable font for the chinese unicode range.

But there is one problem: the filter requires by design that all fonts used 
are Type1 fonts (it builds a composite font from those byse fonts), but to 
my knowledge the available chenese fonts are either TrueType or CID fonts.

Unfortunately, the GNU free fonts (the FreeMono family) does not provide the 
chinese glyphs either, so the only chance is to convet a suitable font (be 
it TrueType of CID keyed) to a Type1 font. As this is not a trivial task 
(though the application to use, fontforge, is free software) - it may be 
necessary to edit the unicode to glyphname table - , I#d suggest you chose a 
suitable font for plain text that is installed on your Solaris system and 
send it to me (by e-mail), and I'll see if it can be adapted at a reasonable 
effort.

Helge





More information about the cups mailing list