Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bad font for non latin users #2835

Closed
alexey-gamov opened this issue Apr 4, 2022 · 6 comments
Closed

Bad font for non latin users #2835

alexey-gamov opened this issue Apr 4, 2022 · 6 comments

Comments

@alexey-gamov
Copy link

alexey-gamov commented Apr 4, 2022

Fonts bug in MagicMirror

Platform: MagicMirrorOS on Raspberry Pi 2 .
MagicMirror² Version: 2.19.0

Description:

In this update fonts package was changed from roboto-fontface-bower to fontsource (2dcf55e).
CSS file roboto.css uses only latin subset for loading woff files. It is not fair = fonts must consist all world chars.

Way to fix:

Change roboto-latin-100-normal.woff2 to roboto-all-100-normal.woff2 and etc.

Expected Results: Fonts are still great with non US characters.
Actual Results: Fonts are ugly. Need to add custom @font-face from Google.

@khassel
Copy link
Collaborator

khassel commented Apr 4, 2022

It is not fair = fonts must consist all world chars.

that was not intentional

Can you provide a PR to fix this? Otherwise I will create one ...

@alexey-gamov
Copy link
Author

It is not fair = fonts must consist all world chars.

that was not intentional

Can you provide a PR to fix this? Otherwise I will create one ...

Last package was international :)
Unfortunately am not expert in node modules, it will be better if you can fix that issue..

@outlying
Copy link

outlying commented Apr 5, 2022

I confirm that, 2.19.0 update "broke" fonts in news module and greeting module (see ń character) probably in more places too
image

@MichMich
Copy link
Collaborator

MichMich commented Apr 6, 2022

Can anyone confirm the PR of @khassel solves the issue?

@ayuhito
Copy link

ayuhito commented Apr 11, 2022

Fontsource maintainer here. It may be better for you to reference the source CSS files itself so you can write the appropriate @font-face declarations instead to support international users. The unicode-range CSS selector is a key thing that @khassel’s PR is missing that prevents woff2 files from being used effectively.

Example CSS file.

That being said, since this is an offline Electron application (I’m just guessing), the current implementation with just the woff files containing all the subsets is completely fine. I’m not sure if we need to amend @khassel’s PR in that context. If it’s an online application, then I would recommend the woff2 approach.

Additionally when fontsource/fontsource#234 is implemented, I think that will help simplify your build process a lot more. Feel free to keep tabs on that issue!

@rejas
Copy link
Collaborator

rejas commented Apr 27, 2022

Can anyone confirm the PR of @khassel solves the issue?

I can confirm that with his PR the ń looks better (when used in the compliments module) Not sure if that solves it for ALL possible letters.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

6 participants