Pipelight fails to render CJK characters properly

Bug #1338122 reported by V字龍(Vdragon)
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Pipelight
Fix Released
Undecided
Unassigned
Wine
New
Undecided
Unassigned
Wine "Compholio" Edition
Fix Released
Undecided
Unassigned

Bug Description

All non-ASCII characters are rendered as "square symbol", it might be Wine font issue.
* The Distribution you are using
Ubuntu 14.04 i386

* The output of (as file attachment): pipelight-plugin --system-check
https://bugs.launchpad.net/pipelight/+bug/1338122/+attachment/4146163/+files/pipelight-plugin-system-check.output

* The output of: pipelight-plugin --list-enabled-all
silverlight5.1

* The URL of the website you have problems with (if it is available for the public)
https://booking.ambassador.com.tw/

* The console output when starting your browser via the command line (see https://answers.launchpad.net/pipelight/+faq/2517 )
https://bugs.launchpad.net/pipelight/+bug/1338122/+attachment/4146162/+files/pipelight.log

* The configuration file you are using (if you changed it)
N/A

* The desktop environment / window manager you are using (Unity, GNOME, Cinnamon, ....)
KDE

Workaround
-------------------
refer #4

Revision history for this message
V字龍(Vdragon) (vdragon) wrote :
Revision history for this message
V字龍(Vdragon) (vdragon) wrote :
description: updated
description: updated
Revision history for this message
V字龍(Vdragon) (vdragon) wrote :
description: updated
description: updated
Revision history for this message
Michael Müller (mqchael) wrote :

Hi,

there are basically two problems. The main issue is that Silverlight is using their own font system and expects the typical CJK fonts to be installed. The second issue is that the application does not specify the font directly and due to some bugs in Wine, Silverlight will always fallback to japanese fonts if they are available. The best solution I came up with, was to install the "Microsoft Yahei" font. It still misses some special punctuation characters like , or : but everything else was displayed correctly in the login menu. I do not recommend to install any japanese fonts like Meiryo otherwise Silverlight will always use this one.

You can use the following commands to install the font for the current user:

mkdir -p /tmp/chs-fonts/
cd /tmp/chs-fonts/
wget http://download.microsoft.com/download/c/7/e/c7e5397d-004f-468b-a441-dd0828dc1a17/VistaFont_CHS.EXE
cabextract VistaFont_CHS.EXE
mkdir -p ~/.fonts
cp *.ttf ~/.fonts/

Michael

Revision history for this message
V字龍(Vdragon) (vdragon) wrote :

Hi,
thanks for replying, the solution works perfectly for me.

I'll leave this bug report open until there's a better one describing this issue.

description: updated
Revision history for this message
Scott Ritchie (scottritchie) wrote :

Does Pipelight on Ubuntu incorporate the CJK font-substitution patches that are in the Ubuntu Wine package?

Revision history for this message
Michael Müller (mqchael) wrote :

Hi Scott,

I just tried the patch but it does not help. Silverlight uses their own font system and they only read all the font paths from the registry. Silverlight uses memory mapping to load the actual font and they check the name inside the file and if it does not match the one in the registry, the font is not being used. This makes font substitution impossible with Silverlight. The only way to use such a font is to change the name inside the file. We could for example change the name inside of WenQuanYi Micro Hei to Microsoft Yahei and Silverlight should accept it.

The only problem is that WenQuanYi Micro Hei is licensed under the GPL while wine now uses the LGPL and we therefore can not add such a file to Wine.

Michael

Revision history for this message
V字龍(Vdragon) (vdragon) wrote :

@Michael
Maybe we just make Microsoft Yahei font a dependency of Pipelight? If the font is not redistributable just listed them in the install instructions so that users can fix the problem themselves.

Revision history for this message
Scott Ritchie (scottritchie) wrote :

Regarding Licensing, making such a dependency is indeed not something upstream Wine can do, however it is something we as a distribution can do for our users. There is no license problem in having an LGPL package recommend a GPL package (in apt's terms). We could even include a symlink in /usr/share/wine/fonts if we wanted (would that work?)

Revision history for this message
Erich E. Hoover (ehoover) wrote :

Hi Scott, as long as it's in one of the font folders then Silverlight can find it - it's not necessary to put it in the Wine-specific folder. I'm not sure how critical it would be for the Wine you include in the official repositories (since Silverlight doesn't work anyway), but we could always put together a "ttf-mscorefonts-installer"-like package if you don't want to make one for inclusion in the official repo.

Revision history for this message
Michael Müller (mqchael) wrote :

Hi Scott,

we still could not use the GPL font without modifying it. It would therefore be necessary to create a new package, but I am not sure whether Ubuntu wants to ship the same font multiple times with different names in the font file. Another solution would be to create a new package similar to the corefont package which installs the original Microsoft font like Erich suggested.

@Erich: I think the mentioned Silverlight application should also work without our patches using firefox in a regular wine installation. It therefore also affects the regular wine version.

Michael

Revision history for this message
Erich E. Hoover (ehoover) wrote :

@Michael, really? There's a non-demo Silverlight app that doesn't run into the SIO_ADDRESS_LIST_CHANGE bug ( http://bugs.winehq.org/show_bug.cgi?id=32328 ) ??!?!?

Revision history for this message
Michael Müller (mqchael) wrote :

@Erich: I just confirmed that the silverlight application works using the current wine git version without any patches.

description: updated
Revision history for this message
Erich E. Hoover (ehoover) wrote :

@Michael: Great

@Scott: Would you like us to put together a package for this or would you like to include it in the main repo?

Revision history for this message
Scott Ritchie (scottritchie) wrote :

What is the licensing of Microsoft Yahei? Is it the same as other fonts in the corefonts-installer package?

Ideally it would be in the distribution proper. If the licensing is the same, I'd like to do that through the existing corefonts package as yet another font it grabs. We can keep our version of this package in the PPAs until the distro catches up.

Revision history for this message
Scott Ritchie (scottritchie) wrote :

After some checking it seems like the license is not acceptable (only licensed for use on Windows machines), so we will need to make a fake version of the font using a free one.

Changed in wine-compholio:
status: New → Fix Released
Revision history for this message
Michael Müller (mqchael) wrote :

A replacement font for Microsoft Yahei is now included in Wine compholio and the website should render properly. I therefore close the bug report as fixed for Pipelight.

Changed in pipelight:
status: New → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.