這網頁的中文......看不到耶

Moderator: Forums Team

seifer
Posts: 248
Joined: Wed Dec 10, 2003 7:54 am
Location: 台灣/台南

Post by seifer »

我這樣設定好像跟KDE的中文字型無關

我甚至可以只設 FontPath "/usr/X11R6/lib/X11/fonts/misc"
因為不設他進不去X

至於
FontPath "/usr/X11R6/lib/X11/fonts/75dpi"
FontPath "/usr/X11R6/lib/X11/fonts/100dpi"
只是tcl/tk的介面文字美觀需要
seifer
Posts: 248
Joined: Wed Dec 10, 2003 7:54 am
Location: 台灣/台南

Post by seifer »

感謝feuer ^^

我做了 USE='cjk" emerge ghostscript 就好了
root@notebook lib # USE="cjk" emerge -pv ghostscript

These are the packages that I would merge, in order:

Calculating dependencies ...done!
[ebuild N ] media-fonts/baekmuk-fonts-2.1-r1 +X +truetype 20,700 kB
[ebuild N ] media-fonts/kochi-substitute-20030809 +X 8,472 kB
[ebuild R ] app-text/ghostscript-7.07.1-r1 +X +cjk +cups 13,813 kB

Total size of downloads: 42,986 kB


ps檔,跟flash中文都好了

附帶一提,kghostview 被 ggv比下去了

ggv才看的到中文

另外,我的XF86config沒更改

之前裝的時候沒用USE="cjk",不過有寫在/etc/make.conf裡面

Image
seifer
Posts: 248
Joined: Wed Dec 10, 2003 7:54 am
Location: 台灣/台南

Post by seifer »

對了/usr/share/ghostscript/Resource/CIDFont/還是空的

/usr/share/ghostscript/Resource/裡面也沒找到 cid.sh

所以不知道怎麼加入新字型到 CID
feuer
Posts: 218
Joined: Mon Jan 13, 2003 11:17 am
Location: 天涯

Post by feuer »

seifer wrote: 另外,我的XF86config沒更改
沒有用 xtt 和 truetype modules , 那您是開 xfs 囉?
seifer
Posts: 248
Joined: Wed Dec 10, 2003 7:54 am
Location: 台灣/台南

Post by seifer »

ㄟ xfs也沒開,因為佔資源

之前就是try過,能進X所需最少的FontPath數目 :D
feuer
Posts: 218
Joined: Mon Jan 13, 2003 11:17 am
Location: 天涯

Post by feuer »

奇怪,這樣子有中文 TrueType 字型可用喔?

-- -- --

順便參考一下:
預設增加 CID 是 /usr/share/fonts/ttf/big5/cidinst 這個 script ,
來自於 fonts-ttf-big5-1.0-20mdk 套件。
這是 cidinst 內容:

Code: Select all

#!/bin/sh

# gs-cjk uses TTF fonts to print CJK files. 
# We register the fonts to ghostscript 6.51.
#
# 2001-07-27 dxiaoming@mandrakesoft.com

if [ -x /usr/share/ghostscript/Resource/alias-ac13.sh ]; then
    cd /usr/share/ghostscript/Resource
    ./alias-ac13.sh install B5Song-Medium=bsmi00lp.ttf
    ./alias-ac13.sh install B5Kai-Medium=bkai00mp.ttf
    # MSung-Light and MOESung-Light are the font names used by qt/kde.
    # ./alias-ac13.sh install MSung-Light=Song-Medium
    # This causes conflict with gb2312 MSung-Light.
    ./alias-ac13.sh install MOESung-Regular=B5Song-Medium
    # ShanHeiSun-Light is used by Mozilla for printing
    ./alias-ac13.sh install ShanHeiSun-Light=B5Song-Medium
fi
mist07
Posts: 67
Joined: Wed Jan 22, 2003 11:13 pm
Location: 台灣

Post by mist07 »

哈哈~我用opera7.23 和 mozilla
甚麼都看不到 :(
(我只能看到HTML以上的,下面甚麼都沒有)
請問前輩們是如何看到的阿?
要加安裝甚麼嗎?
謝謝~
seifer
Posts: 248
Joined: Wed Dec 10, 2003 7:54 am
Location: 台灣/台南

Post by seifer »

大概是...........f..flash......沒裝..=.=
Linkey
Posts: 71
Joined: Mon Apr 26, 2004 4:41 am

Post by Linkey »

可不可以問一下
CID font在那一個套件?

我一直沒辦法搞好死氣象局網頁 恨! 期中考最後一晚還在來這種的
d2207197
Posts: 197
Joined: Sun Dec 21, 2003 5:46 pm
Location: 新竹市

Post by d2207197 »

也可以讓 mozilla 用 truetype font 列印喔! :D
參看 http://linux.tnc.edu.tw/techdoc/mozilla-print-zhtw.html

這篇雖然是給 Redhat, Fedora 用,
但只要確定 mozilla or firefox 有編入freetype2 支援,
然後字型路徑要設定正確,不要跟著照抄 /usr/share/fonts/zh_TW/TrueType/
,其他 distro 都可以使用

我把字型路徑指向 firefly new sung 字體安裝的目錄,
現在在 firefox 直接透過 cups 的 lpr 程式列印中文網頁,中文字顯示很正確。
User avatar
octapult
Posts: 27
Joined: Thu Feb 24, 2005 2:07 am

Post by octapult »

d2207197 wrote:也可以讓 mozilla 用 truetype font 列印喔! :D
參看 http://linux.tnc.edu.tw/techdoc/mozilla-print-zhtw.html

這篇雖然是給 Redhat, Fedora 用,
但只要確定 mozilla or firefox 有編入freetype2 支援,
然後字型路徑要設定正確,不要跟著照抄 /usr/share/fonts/zh_TW/TrueType/
,其他 distro 都可以使用

我把字型路徑指向 firefly new sung 字體安裝的目錄,
現在在 firefox 直接透過 cups 的 lpr 程式列印中文網頁,中文字顯示很正確。
小弟直接使用 freetype2 printing 的功能都會導致 mozilla 掛掉,
所以只好採用 postscript 的方法,也就是修改/usr/lib/mozilla/greprefs/all.js 的設定,請參考:
http://cle.linux.org.tw/index.php?LinuxChineseHowto

如果直接送到印表機列印的話,會印不出東西。
所以小弟先印到 mozilla.ps,再用以下指令

Code: Select all

ps2ps mozilla.ps output.ps
再用

Code: Select all

lp output.ps
指令就可以列印出中文了。

小弟的測試系統如下:
kernel 2.6.10
EPSON Stylus Color-460 (接在 parport0)
cups-1.1.23-r1
gimp-print-5.0.0_beta3 (提供印表機驅動程式)
ghostscript-7.07.1-r8

所有的設定都是預設值。

事實上 ghostscript 預設已經有設定好 ShanHeiSun-Light、ZenKai-Medium、MingLiU、PMingLiU 等繁體中文字型了,使用 gs mozilla.ps 指令都可以正確的看到 mozilla 列印出來的中文,只是如果不先使用 ps2ps 轉換的話,送到印表機的中文文件還是列不出中文。相同的狀況小弟仍然在使用 Debian 的時候也有遇到過。
Post Reply