Bug 2281392

Summary: Missing characters in some locales (e.g. Czech locale cs_CZ.utf8)
Product: [Fedora] Fedora Reporter: Jaroslav Škarvada <jskarvad>
Component: prusa-slicerAssignee: Jason Tibbitts <j>
Status: NEW --- QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: medium Docs Contact:
Priority: unspecified    
Version: 41CC: jpazdziora, jstanek, j, mhroncok, spotrh
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Attachments:
Description Flags
Missing characters in the tip box.
none
Quick and dirty downstream fix
none
Quick and dirty downstream fix none

Description Jaroslav Škarvada 2024-05-18 11:29:51 UTC
Most of the texts are missing several characters.

Reproducible: Always

Steps to Reproduce:
1. set locale to cs_CZ.utf8
2. prusa-slicer
3. Observe UI
Actual Results:  
Most of the texts are missing several characters (see attached screenshot)

Expected Results:  
All texts are OK

Comment 1 Jaroslav Škarvada 2024-05-18 11:33:34 UTC
It seems it's all tooltips and tips, i.e. the overlay boxes, maybe other things as well. Missing are Czech letters like "čžšě...", probably non UTF font is used for rendering.

Comment 2 Jaroslav Škarvada 2024-05-18 11:34:24 UTC
I guess the same problem will be with other locales that have non ASCII characters.

Comment 3 Jaroslav Škarvada 2024-05-18 11:35:59 UTC
Created attachment 2033834 [details]
Missing characters in the tip box.

Comment 4 Jaroslav Škarvada 2024-05-18 11:41:09 UTC
Created attachment 2033835 [details]
Missing characters in the tip box.

Comment 5 Jaroslav Škarvada 2024-05-18 11:45:12 UTC
The same problem hit with the measurement dialog and probably all other "overlay" dialogs/boxes are affected.

Comment 6 Jan Pazdziora (Red Hat) 2024-05-18 13:25:57 UTC
I confirm the issue on prusa-slicer-2.7.4-1.fc40.x86_64 with

$ LC_ALL=cs_CZ.utf8 prusa-slicer

Jaroslav, would you remember if with previous versions the same dialogs were fine? IOW, is this a regression?

Comment 7 Miro Hrončok 2024-05-18 14:55:10 UTC
This has been a problem for a very long time.

I can confirm this happens at least in prusa-slicer-2.5.2-2.fc39.x86_64

Comment 8 Jaroslav Škarvada 2024-05-19 19:29:30 UTC
I don't know when they introduced it, I haven't used this slicer much. I guess in tips/tooltips this was very minor problem, but now when they are adding more useful overlay dialogs (like the measurement tool in 2.6) it's more annoying.

Comment 9 Jaroslav Škarvada 2024-05-20 00:16:59 UTC
Created attachment 2034031 [details]
Quick and dirty downstream fix

It seems you are not bundling the google font "NotoSans-Regular.ttf" into "/usr/share/PrusaSlicer/fonts". Attached is quick and dirty downstream fix that uses system font. You will also need to add the following into spec:

Requires: google-noto-sans-fonts

Comment 10 Jaroslav Škarvada 2024-05-20 00:23:57 UTC
And for the CJK font also:

Requires: google-noto-sans-cjk-fonts

Comment 11 Jaroslav Škarvada 2024-05-20 00:28:48 UTC
For the CJK fonts the path is:
/usr/share/fonts/google-noto-sans-cjk-fonts/

I will alter the patch.

Comment 12 Jaroslav Škarvada 2024-05-20 00:41:42 UTC
Created attachment 2034034 [details]
Quick and dirty downstream fix

Also add to spec:

Requires: google-noto-sans-fonts
Requires: google-noto-sans-cjk-fonts

Maybe you could use "Recommends:".

Maybe you could omit the explicit CJK fonts dep, it's additional cca. 81 MB with probably no use for non APAC users and APAC users would probably already have it.

Comment 13 Jaroslav Škarvada 2024-05-20 00:48:27 UTC
Changing version to f39, because the patch is the same and it's also affected. But I will be OK with the rawhide only fix.

Comment 14 Jaroslav Škarvada 2024-05-20 01:05:43 UTC
You could also create font symlinks from /usr/share/PrusaSlicer/fonts to system fonts.

Comment 15 Miro Hrončok 2024-08-07 12:34:48 UTC
This does "fix" the problem for me:

sudo ln -s /usr/share/fonts/google-noto /usr/share/PrusaSlicer/fonts
sudo dnf install google-noto-sans-fonts

We could package that symbolic link. The only problem is we might hit https://docs.fedoraproject.org/en-US/packaging-guidelines/Directory_Replacement/ in case the fonts will ever be bundled.

I belive we should link the actual files.

Comment 16 Aoife Moloney 2024-11-13 12:30:49 UTC
This message is a reminder that Fedora Linux 39 is nearing its end of life.
Fedora will stop maintaining and issuing updates for Fedora Linux 39 on 2024-11-26.
It is Fedora's policy to close all bug reports from releases that are no longer
maintained. At that time this bug will be closed as EOL if it remains open with a
'version' of '39'.

Package Maintainer: If you wish for this bug to remain open because you
plan to fix it in a currently maintained version, change the 'version' 
to a later Fedora Linux version. Note that the version field may be hidden.
Click the "Show advanced fields" button if you do not see it.

Thank you for reporting this issue and we are sorry that we were not 
able to fix it before Fedora Linux 39 is end of life. If you would still like 
to see this bug fixed and are able to reproduce it against a later version 
of Fedora Linux, you are encouraged to change the 'version' to a later version
prior to this bug being closed.