Wine 中文乱码的解决方案
2010-01-28 01:19
204 查看
wine中文乱码的终极解决方法
1. 初始设置
运行 winecfg,把模拟的 Windows 系统设置为 Windows XP 或者 Windows 2000。
2. 准备字体
为了让 Windows 应用程序看上去更美观,所以需要 Windows 下面的字体。
由于我已经将 simsun.ttc 复制到 /usr/share/fonts/windows/ 目录中了。所以我只需要在 ~/.wine/drive_c/windows/fonts/ 目录中为 simsun.ttc 创建一个符号连接:
cd ~/.wine/drive_c/windows/fonts
ln -s /usr/share/fonts/windows/simsun.ttc simsun.ttc
ln -s /usr/share/fonts/windows/simsun.ttc simfang.ttc
创建一个 simfang.ttc 是许多 Windows 应用默认使用 simfang.ttc 字体。
3. 最关键的一步
──把下面的代码保存为zh.reg,然后终端执行regedit zh.reg。
从Windows目录下的Fonts里的simsun.ttc复制到/home/user/.wine/drive_c/windows/fonts里面。
代码:
REGEDIT4
[HKEY_LOCAL_MACHINE/Software/Microsoft/Windows NT/CurrentVersion/FontSubstitutes]
"Arial"="simsun"
"Arial CE,238"="simsun"
"Arial CYR,204"="simsun"
"Arial Greek,161"="simsun"
"Arial TUR,162"="simsun"
"Courier New"="simsun"
"Courier New CE,238"="simsun"
"Courier New CYR,204"="simsun"
"Courier New Greek,161"="simsun"
"Courier New TUR,162"="simsun"
"FixedSys"="simsun"
"Helv"="simsun"
"Helvetica"="simsun"
"MS Sans Serif"="simsun"
"MS Shell Dlg"="simsun"
"MS Shell Dlg 2"="simsun"
"System"="simsun"
"Tahoma"="simsun"
"Times"="simsun"
"Times New Roman CE,238"="simsun"
"Times New Roman CYR,204"="simsun"
"Times New Roman Greek,161"="simsun"
"Times New Roman TUR,162"="simsun"
"Tms Rmn"="simsun"
之后,中文正常显示。
4. 英文系统下,使用wine :
1)输入命令: env LANG=zh_CN.UTF-8 wine "运行的程序"
2)或修改~/.bashrc 添加一句alias wine="env LANG=zh_CN.UTF-8 wine"
5. wine的字体美化:
打开字体的防锯齿:
REGEDIT4
[HKEY_CURRENT_USER/Software/Wine/X11 Driver]
"ClientSideAntiAliasWithCore"="Y"
"ClientSideAntiAliasWithRender"="Y"
"ClientSideWithRender"="Y"
打开字体的平滑功能:
REGEDIT4
[HKEY_CURRENT_USER/Control Panel/Desktop]
"FontSmoothing"="2"
"FontSmoothingType"=dword:00000002
"FontSmoothingGamma"=dword:00000578
"FontSmoothingOrientation"=dword:00000001
你也可以查看你机器的[HKEY_LOCAL_MACHINE/Software/Microsoft/Windows NT/CurrentVersion/FontLink/SystemLink]的"Tahoma"值,然后在windows的fonts里找相应的字体文件,复制到wine下的windows/fonts目录下。
1. 初始设置
运行 winecfg,把模拟的 Windows 系统设置为 Windows XP 或者 Windows 2000。
2. 准备字体
为了让 Windows 应用程序看上去更美观,所以需要 Windows 下面的字体。
由于我已经将 simsun.ttc 复制到 /usr/share/fonts/windows/ 目录中了。所以我只需要在 ~/.wine/drive_c/windows/fonts/ 目录中为 simsun.ttc 创建一个符号连接:
cd ~/.wine/drive_c/windows/fonts
ln -s /usr/share/fonts/windows/simsun.ttc simsun.ttc
ln -s /usr/share/fonts/windows/simsun.ttc simfang.ttc
创建一个 simfang.ttc 是许多 Windows 应用默认使用 simfang.ttc 字体。
3. 最关键的一步
──把下面的代码保存为zh.reg,然后终端执行regedit zh.reg。
从Windows目录下的Fonts里的simsun.ttc复制到/home/user/.wine/drive_c/windows/fonts里面。
代码:
REGEDIT4
[HKEY_LOCAL_MACHINE/Software/Microsoft/Windows NT/CurrentVersion/FontSubstitutes]
"Arial"="simsun"
"Arial CE,238"="simsun"
"Arial CYR,204"="simsun"
"Arial Greek,161"="simsun"
"Arial TUR,162"="simsun"
"Courier New"="simsun"
"Courier New CE,238"="simsun"
"Courier New CYR,204"="simsun"
"Courier New Greek,161"="simsun"
"Courier New TUR,162"="simsun"
"FixedSys"="simsun"
"Helv"="simsun"
"Helvetica"="simsun"
"MS Sans Serif"="simsun"
"MS Shell Dlg"="simsun"
"MS Shell Dlg 2"="simsun"
"System"="simsun"
"Tahoma"="simsun"
"Times"="simsun"
"Times New Roman CE,238"="simsun"
"Times New Roman CYR,204"="simsun"
"Times New Roman Greek,161"="simsun"
"Times New Roman TUR,162"="simsun"
"Tms Rmn"="simsun"
之后,中文正常显示。
4. 英文系统下,使用wine :
1)输入命令: env LANG=zh_CN.UTF-8 wine "运行的程序"
2)或修改~/.bashrc 添加一句alias wine="env LANG=zh_CN.UTF-8 wine"
5. wine的字体美化:
打开字体的防锯齿:
REGEDIT4
[HKEY_CURRENT_USER/Software/Wine/X11 Driver]
"ClientSideAntiAliasWithCore"="Y"
"ClientSideAntiAliasWithRender"="Y"
"ClientSideWithRender"="Y"
打开字体的平滑功能:
REGEDIT4
[HKEY_CURRENT_USER/Control Panel/Desktop]
"FontSmoothing"="2"
"FontSmoothingType"=dword:00000002
"FontSmoothingGamma"=dword:00000578
"FontSmoothingOrientation"=dword:00000001
你也可以查看你机器的[HKEY_LOCAL_MACHINE/Software/Microsoft/Windows NT/CurrentVersion/FontLink/SystemLink]的"Tahoma"值,然后在windows的fonts里找相应的字体文件,复制到wine下的windows/fonts目录下。
相关文章推荐
- Wine 中文乱码(换字体)最简单解决方案
- soapui-groovy脚本中文乱码及符号乱码、响应乱码解决方案
- java web中文乱码解决方案
- 中文乱码解决方案
- sublime 3中文乱码问题解决方案
- ervlet 中文乱码问题及解决方案剖析
- Linux下Eclipse中文乱码解决方案
- navicat 中文界面乱码 解决方案
- httpPost中文乱码解决方案(android)
- JSP页面与JSP页面之间传输参数出现中文乱码的解决方案
- Flex读取非UTF-8中文数据乱码问题的解决方案
- Servlet 中文乱码问题及解决方案剖析
- 网站开发笔记:PHP oci连接Oracle中文乱码问题解决方案
- JSP开发过程遇到的中文乱码问题及解决方案
- IntelliJ IDEA 12.1.6 中文乱码解决方案
- Struts中Jsp中文乱码解决方案
- MySQL+Tomcat+J2EE中文乱码问题的UTF-8的解决方案
- Java文件名包含中文的文件压缩后文件名乱码问题,完美解决方案
- servlet中文乱码及解决方案剖析
- pymssql中文乱码问题(一种可行的解决方案)