星期五, 9月 05, 2008

cxoffice 中文調整

之前因為安裝了 cxoffice,覺得比 wine 好用很多,相容性也很棒
不過,中文部份還是有點問題
所以,參考了這篇文章,做了一點調整

依·稀·記·得: Wine / Crossover Office / Picasa Linux 繁體中文設置 UPDATED!!
Wine / Crossover Office / Picasa Linux 繁體中文設置 UPDATED!!
前幾天在 Ubuntu 台灣討論組裡賣了個廣告,丫小兄弟好像成功了。自已也覆看了那篇日誌,想著先前寫的是不是有點太亂了… 也因為那時沒有包括 Picasa Linux 的設定,就趁今天補充一下。

1. 首要解決UTF-8 環境下很慢的問題
估計在用非UTF-8環境的人不多了,所以這是大部份人都面對的問題,必需先處理掉。
# vi /usr/share/X11/locale/zh_TW.UTF-8/XLC_LOCALE

刪掉裡面包含 BIG5-0 的區段,其實就是 fs2 及 cs2 及其包含的內容如下圖,然後cat一下覆核操作結果。
# cat /usr/share/X11/locale/zh_TW.UTF-8/XLC_LOCALE

2. 修改 win.ini 設定預設字型 & 字體大小
win.ini 放置在 windows 目錄下,參考位置如下:

Wine:
~/.wine/drive_c/windows/win.ini

Crossover:
~/.cxoffice/bottlename/drive_c/Windows/win.ini
(注: bottlename 要對應實際的bottle,不懂的先看看 Crossover 的說明文件)

Picasa Linux:
~/.picasa/drive_c/windows/win.ini

打開該檔並在最後加入以下內容,留意這個檔案需維持原本的編碼,不要多手另存成 UTF-8。
[Desktop]
IconTitleFaceName=AR PL New Sung
menufontsize=13
messagefontsize=13
statusfontsize=13
IconTitleSize=13

3. Registry 的設定
登錄檔共需修改3個位置,見下:

3a) 停用 anti-alias
bitmap字體較適合屏幕觀看,opendesktop-fonts 或 uming 的話都內建了bitmap字體所以這項可以關掉。
[HKEY_CURRENT_USER\Software\Wine\X11 Driver]
"ClientSideAntiAliasWithCore"="N"
"ClientSideAntiAliasWithRender"="N"

3b) 設定 Wine 部份的替代字型
是的替代字型共需設定兩處,我不肯定那裡有較高的優先權,反正設了沒錯。
HKEY_CURRENT_USER\Software\Wine\Fonts\Replacements]
"Arial"="AR PL New Sung"
"Fixedsys"="AR PL New Sung"
"Microsoft Sans Serif"="AR PL New Sung"
"MingLiU"="AR PL New Sung"
"MS UI Gothic"="AR PL New Sung"
"PMingLiU"="AR PL New Sung"
"simsun"="AR PL New Sung"
"Songti"="AR PL New Sung"
"System"="AR PL New Sung"
"Tahoma"="AR PL New Sung"
"Terminal"="AR PL New Sung"

3c) 設定 Windows 部份的替代字型
HKEY_LOCAL_MACHINE\Software\Microsoft\Windows NT\CurrentVersion\FontSubstitutes]
"MingLiU"="AR PL New Sung"
"MS Shell Dlg"="AR PL New Sung"
"MS Shell Dlg 2"="AR PL New Sung"
"PMingLiU"="AR PL New Sung"
"simsun"="AR PL New Sung"
"Songti"="AR PL New Sung"
"System"="AR PL New Sung"

登錄檔就存放在 .picasa/.wine/bottlename 目錄下的 system.reg, user.reg userdef.reg 裡, 有網友是用文字編輯器如 gedit 直接修改的,小弟極不建議這樣做因為太容易出錯了。反之我建議利用 regedit 匯入預先準備好的登錄鍵,你也可以做用我下面貼出來的設定檔。

打開 regedit 的方法

Wine:
$ wine regedit

Crossover:
~/cxoffice/bin/cxrun,
選好目標 bottle, 然後輸入 regedit

Picasa Linux:
$ /opt/picasa/bin/wrapper regedit


我整理的登錄檔設定部份,複制並另存到非UTF-8的文字檔裡,就可以用 regedit 來匯入。
REGEDIT4

[HKEY_LOCAL_MACHINE]

[HKEY_LOCAL_MACHINE\Software]

[HKEY_LOCAL_MACHINE\Software\Microsoft]

[HKEY_LOCAL_MACHINE\Software\Microsoft\Windows NT]

[HKEY_LOCAL_MACHINE\Software\Microsoft\Windows NT\CurrentVersion]

[HKEY_LOCAL_MACHINE\Software\Microsoft\Windows NT\CurrentVersion\FontSubstitutes]
"MingLiU"="AR PL New Sung"
"MS Shell Dlg"="AR PL New Sung"
"MS Shell Dlg 2"="AR PL New Sung"
"PMingLiU"="AR PL New Sung"
"simsun"="AR PL New Sung"
"Songti"="AR PL New Sung"
"System"="AR PL New Sung"

[HKEY_LOCAL_MACHINE\System]

[HKEY_LOCAL_MACHINE\System\CurrentControlSet]

[HKEY_LOCAL_MACHINE\System\CurrentControlSet\Control]

[HKEY_LOCAL_MACHINE\System\CurrentControlSet\Control\Nls]

[HKEY_LOCAL_MACHINE\System\CurrentControlSet\Control\Nls\Language]
"Default"="0404"
"InstallLanguage"="0404"

[HKEY_LOCAL_MACHINE\System\CurrentControlSet\Control\Nls\Locale]
@="00000404"


[HKEY_CURRENT_USER]

[HKEY_CURRENT_USER\Software]

[HKEY_CURRENT_USER\Software\Wine]

[HKEY_CURRENT_USER\Software\Wine\Fonts]
"Locale"="00000404"

[HKEY_CURRENT_USER\Software\Wine\Fonts\Replacements]
"Arial"="AR PL New Sung"
"Fixedsys"="AR PL New Sung"
"Microsoft Sans Serif"="AR PL New Sung"
"MingLiU"="AR PL New Sung"
"MS UI Gothic"="AR PL New Sung"
"PMingLiU"="AR PL New Sung"
"simsun"="AR PL New Sung"
"Songti"="AR PL New Sung"
"System"="AR PL New Sung"
"Tahoma"="AR PL New Sung"
"Terminal"="AR PL New Sung"

[HKEY_CURRENT_USER\Software\Wine\X11 Driver]
"ClientSideAntiAliasWithCore"="N"
"ClientSideAntiAliasWithRender"="N"

沒有留言:

張貼留言

Powered By Blogger