7

I have installed Wine on Ubuntu 14.04 LTS. When I run any program containing Chinese fonts, it shows some box type structure.

Tried: update, installing Chinese fonts in Ubuntu, adding Chinese language under system settings. None of them worked.

Jobayer Shajal
  • 133
  • 1
  • 2
  • 9

4 Answers4

6

First, u must download wqy-microhei.ttc font online (https://github.com/anthonyfok/fonts-wqy-microhei/blob/master/wqy-microhei.ttc)

After saving this Regedit file on pc (https://gist.github.com/swordfeng/c3fd6b6fcf6dc7d7fa8a)

Font file copy to wine folder under C: drive folder, under Windows folder, under Font (/home/YOURUSERNAME/.wine/drive_c/windows/Fonts)

If you cant see the .wine folder, enter any folder and push keyboard Ctrl+H (show/hide the hidden folder)

And the last one you have downloaded regedit file. Steps:

  1. Download winetricks (sudo apt-get install winetricks)
  2. Open wine tricks app
  3. First screen select 'Select the default wineprefix' and click OK (go to next)
  4. Select the option to 'Run regedit'. You will see the windows registry editor screen.
  5. Click on bar 'Registry > Import Registry File'
  6. Select downloaded registry file and import.
  7. Finish!

I hope it helps you. I also use some software that has Chinese font. Wine doesn't support some distro maybe.

AsukaMinato
  • 199
  • 1
  • 5
Cengiz ALCAN
  • 76
  • 1
  • 2
1

It is a problem with the locales in Wine rather than a font issue. I had the same problem with most popular Bulgarian dictionary for Windows (SA Dictionary). You should set correct value of the LANG variable after WINEPREFIX within the Exec= directive in the .desctop file that run your application. In my case this is LANG=bg_BG.UTF-8. Here is example how my .desctop looks like to work correctly:

user@host:~/Desktop$ cat Diction.desktop 

[Desktop Entry]
Name=Diction
Exec=env WINEPREFIX="/home/spas/.wine" LANG=bg_BG.UTF-8 wine C:\\\\windows\\\\command\\\\start.exe /Unix /home/spas/.wine/dosdevices/c:/users/Public/Desktop/Diction.lnk
Type=Application
StartupNotify=true
Path=/home/spas/.wine/dosdevices/c:/Program Files (x86)/SADiction
Icon=D7E1_Diction.0
StartupWMClass=diction.exe

Type locale to to find the current values of the locales in the terminal.

pa4080
  • 29,351
  • 10
  • 85
  • 161
  • LANG=en_US.UTF-8 LANGUAGE=en_US LC_CTYPE="en_US.UTF-8" LC_NUMERIC=zh_CN.UTF-8 LC_TIME=zh_CN.UTF-8 LC_COLLATE="en_US.UTF-8" LC_MONETARY=zh_CN.UTF-8 LC_MESSAGES="en_US.UTF-8" LC_PAPER=zh_CN.UTF-8 LC_NAME=zh_CN.UTF-8 LC_ADDRESS=zh_CN.UTF-8 LC_TELEPHONE=zh_CN.UTF-8 LC_MEASUREMENT=zh_CN.UTF-8 LC_IDENTIFICATION=zh_CN.UTF-8 LC_ALL= where will I find the .desctop file and how to edit that? can you please elaborate, thanks a lot – Jobayer Shajal Mar 27 '18 at 12:00
  • where will I find the .desctop file and how to edit that? can you please elaborate, thanks a lot – Jobayer Shajal Mar 27 '18 at 12:01
  • @JobayerShajal How do you start the application? Through the command line or by clicking on a icon that is on your desktop? – pa4080 Mar 27 '18 at 12:01
  • from a .exe icon located in a file in desktop, – Jobayer Shajal Mar 27 '18 at 12:08
  • clicking on .exe file icon@pacho – Jobayer Shajal Mar 27 '18 at 12:11
  • @JobayerShajal: Ok. 1) start `gesdit`; 2) In the `File` menu choose `Open`; 3) Navigate to your Desktop and select the icon. 4) Copy the content , pate it in https://paste.ubuntu.com/ , and provide the link, please. – pa4080 Mar 27 '18 at 12:15
  • it gives a lot of texts looks like aliens' secret words – Jobayer Shajal Mar 27 '18 at 12:22
  • https://expirebox.com/download/2ecc8f89830c915dea804553d7a25344.html – Jobayer Shajal Mar 27 '18 at 12:27
  • link to screenshot of total file – Jobayer Shajal Mar 27 '18 at 12:28
  • @JobayerShajal, I think I got it, you run directly the `.exe` and it is not installed within wine's folders. In this case try try these steps: 1) open terminal; 2) execute this command: `LANG=zh_CN.UTF-8 wine ~/Desktop/green/.exe` (change with the actual one)l you can just type `LANG=zh_CN.UTF-8 wine ` and drag and drop the file from Nautilus into the Terminal. – pa4080 Mar 27 '18 at 12:42
  • https://paste.ubuntu.com/p/PjpyjrYSJN/ – Jobayer Shajal Mar 27 '18 at 13:11
  • this is the out put – Jobayer Shajal Mar 27 '18 at 13:11
  • @JobayerShajal. Please try to go into the directory first `cd ~/Desktop/green/`, and then execute the command `LANG=zh_CN.UTF-8 wine 学宝客 户端.exe`. If this finally succeed I will rewrite my answer in a way how do create `.desktop` launcher for your application. – pa4080 Mar 27 '18 at 13:44
  • got the same output – Jobayer Shajal Mar 28 '18 at 02:49
0

I don't have wine env, but gut- feeling tells that you could try to install Chinese fonts in wine

/usr/share/wine/fonts

where the fonts is loaded from

j3ffyang
  • 187
  • 6
0

If you have a windows 10 iso image you can extract sources/install.wim from it and from this wim file you can extract all the true type fonts using wimextract tool

wimextract install.wim 1 /Windows/{Fonts/"*".{ttf,ttc},System32/Licenses/neutral/"*"/"*"/license.rtf} --dest-dir fonts

Now you can use wine explorer to copy/paste all the fonts into windows/Font directory.

vdegenne
  • 205
  • 1
  • 9