From Bugzilla Helper: User-Agent: Mozilla/5.0 (X11; U; Linux i686; ja-JP; rv:1.2.1) Gecko/20030225 Description of problem: bg5ps-1.3.0-utf8.patch seems to be not enough. bg5ps itself actually works. but we use mpage as the page formatter bofore passing through bg5ps. so the problem here is, npsMode doesn't work with UTF-8. it means we can't print out the UTF-8 text on zh_CN and zh_TW locale. Version-Release number of selected component (if applicable): How reproducible: Always Steps to Reproduce: 1.LANG=zh_TW.UTF-8 lpr chinese-utf8.txt 2. 3. Additional info:
Created attachment 93704 [details] proposed patch
Please check 1.3.0-15. However I got the following: GNU Ghostscript 7.07 (2003-05-17) Copyright (C) 2003 artofcode LLC, Benicia, CA. All rights reserved. This software comes with NO WARRANTY: see the file PUBLIC for details. Loading NimbusRomNo9L-Regu font from /usr/share/fonts/default/Type1/n021003l.pfb... 2430764 1066949 1642520 351150 0 done. Loading NimbusSanL-Regu font from /usr/share/fonts/default/Type1/n019003l.pfb... 2785628 1380013 1682712 365686 0 done. Loading NimbusMonL-Regu font from /usr/share/fonts/default/Type1/n022003l.pfb... 3090216 1614401 1702808 371973 0 done. Can't find (or can't open) font file /usr/share/ghostscript/Resource/Font/OurCharSet-Bold. Can't find (or can't open) font file OurCharSet-Bold. Substituting font Helvetica-Bold for OurCharSet-Bold. Loading NimbusSanL-Bold font from /usr/share/fonts/default/Type1/n019004l.pfb... 3187264 1707091 1722904 384390 0 done. Loading NimbusRomNo9L-Medi font from /usr/share/fonts/default/Type1/n021004l.pfb... 3324504 1785217 1722904 363869 0 done. Error: /undefinedresource in --findresource-- Operand stack: unijis Ryumin-Light-UniJIS-UTF8-H Font Ryumin-Light-UniJIS-UTF8-H (Ryumin-Light-UniJIS-UTF8-H) 12 Ryumin-Light UniJIS-UTF8-H UniJIS-UTF8-H --dict:0/10(G)-- Ryumin-Light false Ryumin-Light Ryumin-Light CIDFont --nostringval-- CMap CIDFont CMap CIDFont Execution stack: %interp_exit .runexec2 --nostringval-- --nostringval-- --nostringval-- 2 %stopped_push --nostringval-- --nostringval-- --nostringval-- false 1 %stopped_push 1 3 %oparray_pop 1 3 %oparray_pop 1 3 %oparray_pop 1 3 %oparray_pop .runexec2 --nostringval-- --nostringval-- --nostringval-- 2 %stopped_push --nostringval-- 2 3 %oparray_pop 3 3 %oparray_pop --nostringval-- --nostringval-- 16 4 %oparray_pop --nostringval-- 19 5 %oparray_pop --nostringval-- --nostringval-- --nostringval-- --nostringval-- Dictionary stack: --dict:1060/1123(ro)(G)-- --dict:0/20(G)-- --dict:100/200(L)-- --dict:17/17(ro)(G)-- --dict:0/10(L)-- --dict:16/24(ro)(G)-- Current allocation mode is local Last OS error: 2 Current file position is 4269 GNU Ghostscript 7.07: Unrecoverable error, exit code 1
It looks like the gs bug. please install the latest ghostscript and try this again.
Thanks. it is working now. However I assume it is still a bit slower because it still search for OurCharSet-Bold font. GNU Ghostscript 7.07 (2003-05-17) Copyright (C) 2003 artofcode LLC, Benicia, CA. All rights reserved. This software comes with NO WARRANTY: see the file PUBLIC for details. Loading NimbusRomNo9L-Regu font from /usr/share/fonts/default/Type1/n021003l.pfb... 2430764 1068457 1642520 351150 0 done. Loading NimbusSanL-Regu font from /usr/share/fonts/default/Type1/n019003l.pfb... 2785628 1381521 1682712 365686 0 done. Loading NimbusMonL-Regu font from /usr/share/fonts/default/Type1/n022003l.pfb... 3090216 1615929 1702808 371973 0 done. Can't find (or can't open) font file /usr/share/ghostscript/Resource/Font/OurCharSet-Bold. Can't find (or can't open) font file OurCharSet-Bold. Substituting font Helvetica-Bold for OurCharSet-Bold. Loading NimbusSanL-Bold font from /usr/share/fonts/default/Type1/n019004l.pfb... 3187264 1708619 1722904 384390 0 done. Loading NimbusRomNo9L-Medi font from /usr/share/fonts/default/Type1/n021004l.pfb... 3324504 1786761 1722904 363869 0 done. >>showpage, press <return> to continue<<
No, finding non-existing fonts isn't a reason of slow. correctly mpage is using UTF-8 CMap to handle the UTF-8 characters, and UTF-8 CMap is bigger than other CMap. If it's called as bug, actually ghostscript should has the performance issue. that's all. I don't think this patch affects any performance issue.
Great thanks.