Re: FC3 chinese printing - solved!
From: Kill Bill (xbill_at_msn.com)
Date: 10/12/05
- Next message: Ralf Fassel: "Re: Getting Fortran program compiled under SuSE 8.0 to run under SuSE 9.0"
- Previous message: davout: "Re: Suse 10 newbie - can't get FireFox to access internet"
- In reply to: Kill Bill: "Re: FC3 chinese printing"
- Next in thread: Kill Bill: "Re: FC3 chinese printing - solved!"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Date: Wed, 12 Oct 2005 08:36:22 GMT
Sorry, I am going to keep the whole lengthy post uncut in case later
someone else may find it useful. All in all, this problem is now solved.
Please see the details in the end of the post.
>>>> My system is running FC3 and was upgraded from FC2 a while ago.
>>>>
>>>> When access Chinese webpage, I can never print it with either
>>>> mozilla or
>>>> firefox, whatever version with FC2 and FC3. However I could print
>>>> Chinese webpages fine with epiphany browser. Just recently I found I
>>>> could print them with epiphany either. I cann't remember exactly when I
>>>> lost the chinese printing capability. I run yum every night. It might
>>>> happen when mozilla was updates from version 1.7.8 to 1.7.10 or around
>>>> that time. Although cups was updated a couple of times, I don't
>>>> think it
>>>> is related.
>>>>
>>>> Did anyone experience this? Or is it just me got this strange problem?
>>>>
>>>> Of course I have install Chinese font packages and enable truetype
>>>> printing settings in about:config with mozilla. I can also print
>>>> chinese from other applications such as gedit. Only mozilla/firefox
>>>> and now epiphany.
>>>>
>>>> I am confused, is it a ghostscript ptoblem or a mozilla problem? Or
>>>> just some improper settings?
>>>>
>>> I trend to believe this is a ghostscript problem.
>>>
>>> I have another RedHat 9 box with similar settings but able to print
>>> Chinese webpages fine with mozilla/firefox:
>>>
>>> 1.) Chinese TrueType fonts are the same on both RH9 and FC3 (I
>>> checked the md5sums of the font files) and in the same location
>>> (/usr/share/fonts/zh_CN/TrueType/* and
>>> /usr/sahre/fonts/zh_TW/TrueType/*)
>>> 2.) The font configuration file on /etc/X11/fs/config are the same;
>>> 3.) ghostscript on RH is version 7.05 and is 7.07 on FC3;
>>> 4.) tested mozilla versions on RH9 are 1.7.1, 1.7.3, 1.7.4, 1.7.5,
>>> 1.7.8, 1.7.10 (all were installed with rpms either from fedora
>>> Legacy projects or from kde-redhat projects) and also various
>>> versions of the .tar.gz files of firefox from mozilla foundation
>>> were tested and all works. While on FC3, all versions of mozilla
>>> and firefox provided by redhat (base and update repositories) do
>>> not print Chinese webpages. I have downloaded some versions of
>>> .tar.gz files of firefox from the mozilla website. They don't
>>> work either.
>>> 5.) the mozilla/firefox preference configurations, including:
>>> font.FreeType2.enable (set as true),
>>> font.FreeType2.printing (set as true),
>>> font.directory.truetype.1 (pointed to the CN font directory),
>>> fonts.directory.truetype.2 (pointed to the TW font directory).
>>> are the same on both RH9 and FC3. Actually I double-checked
>>> the contents of prefs.js to make this sure.
>>>
>>> The problem is that on FC3 when I print a Chinese webpage, all
>>> Chinese characters are replaced with rectangular boxes on paper.
>>> While on the print preview mode, all Chinese characters are there.
>>> Even if printed to a file instead of the printer, the generated ps
>>> file reads fine. Also I am pretty sure sometime ago I could print
>>> Chinese webpages with epiphany browser on FC3 and FC2. Now I lost the
>>> capability of print Chinese with epiphany browser, too. All other
>>> apps like gedit, openoffice.org, emacs can print Chinese characters
>>> fine (on FC3 and FC2).
>>>
>>> If I start epiphany browser from console and print a Chinese webpage,
>>> I can see lines of error message like these:
>>> NO FONT WAS FOUND Name [AR PL KaitiM GB]
>>> ...
>>> NO FONT WAS FOUND Name ["Sans"]
>>> ...
>>> where the "AR PL KaitiM GB" is the font I set to view Chinese
>>> webpages. If I tried to change this to other Chinese fonts I
>>> installed, it would be shown in the error message two.
>>> I did the same attempt with mozilla/firefox but no error message
>>> coming out, just the printout was bad (i.e., Chinese characters
>>> printed as blank rectangular boxes).
>>>
>>> I've googled around to no avail. I tried to search gs-cjk project for
>>> a clue but again no success.
>>>
>>> Anyone got a clue please?
>>>
>>> PS: I posted an earlier thread onto linux.redhat.misc but got no
>>> reply, so x-post to comp.os.linux.misc as this appears a higher volume.
>>
>>
>> Additional information:
>> If I chose to "print to file", I can read the generate ps file with
>> ggv but if print it with ggv, the rectangular boxes shown again.
>>
>> At the moment I am using an awkward workaround: I print the Chinese
>> webpage to a ps file and convert the ps to pdf with ps2pdf (the one
>> coming with ghostscript), then use acroread (both acrobat reader
>> version 5.0.x and adobe reader version 7.0.x will work as long as the
>> adobe Chinese fonts package are installed) to convert the pdf back to
>> ps. The newly-generated ps file has Chinese fonts embeded and can be
>> printed with lpr. Of course all these can be done in a shell script.
>> It is worth noting the intermediate pdf file can not be viewed with
>> xpdf/gpdf (Chinese characters will be missed and shown as
>> underscores). It can be read properly with acroread only.
>>
>> I knew about cnprint and bg5ps. In fact I used them before for my
>> Redhat9 box and managed to make them working. But now I don't want to
>> be bothered again, it was even more clumsy than the acroread method.
>>
>> Could anyone please confirm me that this is a ghostscript problem?
Someday I printed a webpage with Ubuntu v5.04 from firefox. The printer
failed to print out the webpage, instead it printed out an instruction
page explaining that the version of my postscript interpreter in my
system is 2013.111 and the printout requires at least version 2015 or
greater. The instruction page also suggested a solution to make the
Gecko browser produce a level 2 output that the postscript interpreter
will understand. It even listed the detailed command line options to
achieve this. And that is:
Change the print command (under mozilla/firefox menu File => Print... =>
Properties... => Print Command: box) from
lpr [OPTIONS]
to (all on one line)
gs -q -sDEVICE=pswrite -sOutputFile=- -dNOPAUSE -dBATCH
-dMozConvertedToLevel2=true - | lpr [OPTIONS]
Then problem solved!
Many thanks for Ubuntu team for the friendly, clear instructions. It
also solves my fedore problem!
KB
- Next message: Ralf Fassel: "Re: Getting Fortran program compiled under SuSE 8.0 to run under SuSE 9.0"
- Previous message: davout: "Re: Suse 10 newbie - can't get FireFox to access internet"
- In reply to: Kill Bill: "Re: FC3 chinese printing"
- Next in thread: Kill Bill: "Re: FC3 chinese printing - solved!"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]