Non-ascii (ja) charactors aren't displayed properly in "Handle to grid intersection"

Bug #459914 reported by Masato HASHIMOTO on 2009-10-24
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Inkscape
Medium
OHTSUKA Yoshio

Bug Description

In Windows (Japanese), translated characters of string "Handle to grid intersection" (appeared during dragging control) isn't displayed properly, placeholder rectangles (we call "Tofu") are appeared. Translation is completed as for that and displayed properly in Linux.

Inkscape version: 0.47pre4
Windows version: XP, 7RC
Locale: ja
Repeatability: always

jazzynico (jazzynico) on 2009-10-24
tags: added: translation ui
jazzynico (jazzynico) wrote :

Confirmed on Vista.
Same issue with all snapping on-canvas messages.

Changed in inkscape:
importance: Undecided → Medium
status: New → Confirmed
jazzynico (jazzynico) wrote :

Still present in 0.48.3.1 and trunk revision 11251, on Windows XP (MS Gothic and MS Mincho installed) and Ubuntu 11.04 (IPA fonts).

jazzynico (jazzynico) wrote :

> ranslation is completed as for that and displayed properly in Linux.

@Masato HASHIMOTO - Does it still work for you on Gnu/Linux? I've tried to change the default applications font (on Ubuntu) with some IPA, UME and Sazanami fonts, but I still see the bug. Of course, I can't test with Hiragano...

Masato HASHIMOTO (hashimo) wrote :

I noticed that font used in the snap indicator seems to be always system wide default (fontconfig as for Linux) even though the default is overridden in other places (e.g. Desktop default).
I changed fontconfig setting, then ja's chars are gone and placeholders appeared.

BTW. You can call me Masato :)

OHTSUKA Yoshio (ohtsuka-yoshio) wrote :

This is a problem of cairo win32 backend.
Last version (1.15.2) of cairo still contains this problem. But
We can avoid this problem to set a font calling cairo_select_font_face() before calling cairo_text_path().

jazzynico (jazzynico) on 2016-08-24
Changed in inkscape:
assignee: nobody → OHTSUKA Yoshio (ohtsuka-yoshio)
milestone: none → 0.93
status: Confirmed → In Progress
jazzynico (jazzynico) wrote :

Thanks for the patch!

I can't test on Windows for now, but it doesn't fix the issue on Xubuntu 16.04, trunk rev. 15074.
Does it work on Windows? Since it's a different backend, the fix might be different for Windows and the other operating systems.

OHTSUKA Yoshio (ohtsuka-yoshio) wrote :

On Linux.

My Linux is Lubuntu 16.0.4.1 LTS installed Japanese and English language.
And I installed default inkscape binary(0.91 r13725) using "apt install inkscape".
libcairo2 is version 1.14.6.
The snapindicator does not have the problem. It displays translated japanese exactly.
It seems to me that your environment have some problem.

OHTSUKA Yoshio (ohtsuka-yoshio) wrote :

I could repro your garbage charactor on linux.

1. System Language is English (LANG=en_US.UTF-8)
2. Run inkscape.
3. Edit->Preference->Interface->Language, "System default" to "Japanese(ja)".
4. Restart inkspace.
5. Test snapindicator.

If System Language is Japanese (LANG=ja_JP.UTF-8), the problem is not occured.
We can confirm this using fc-match command.
1. LANG=en fc-match Sans
2. LANG=ja fc-match Sans

I didn't test, but
it seems to me that the simple solution for this problem on linux is
to adding a new line setenv("LANG", ui_language, 1) under a line of
setenv("LANGUAGE", ui_language, 1) at src/inkscape.cpp.

jazzynico (jazzynico) wrote :

Thanks for your investigations!
Setting the LANG env in inkscape.cpp fixes my issue on Xubuntu. I wonder if that same env would also help me test on Windows...
Tests in progress.

jazzynico (jazzynico) wrote :

Unfortunately I still can't test the patch on Windows. I guess there's something missing, due to the fact that it's a French version.
Anyway, since there's no obvious regression on Xubuntu 16.04, Windows XP and Windows 7, I'm going to commit the fix.

jazzynico (jazzynico) wrote :

Fix committed in lp:inkscape (rev. 15116) and lp:inkscape/0.92.x (rev. 15080).
A test version for the 0.92.x branch should be available for testing soon.

Thanks for your help!

Changed in inkscape:
milestone: 0.93 → 0.92
status: In Progress → Fix Committed
jazzynico (jazzynico) wrote :

A new test archive with the fix is available at ftp://download.tuxfamily.org/inkscape/win32/
@masato, would you be willing to test and confirm it's fixed, please?

I tested the r15080 win32 binary on Windows XP, 7 and 10.
The problem is fixed. Thanks!

Bryce Harrington (bryce) on 2017-01-10
Changed in inkscape:
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers