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

Some characters not rendering correctly in translated sims on Safari #1458

Closed
Tracked by #841 ...
stemilymill opened this issue Oct 3, 2022 · 12 comments
Closed
Tracked by #841 ...

Comments

@stemilymill
Copy link

Please move/reassign as needed!

Found during phetsims/qa#838.

Seen on iPad safari and chrome, and Mac safari.

When testing Gravity and Orbits locale switching in-sim, I noticed that several locales were rendering with extraneous dotted circles throughout the text. I saw the same behavior in recent dev versions of equality explorer. In Gravity and Orbits 1.6.0-rc.1 the languages that do not render correctly are Bengali, Gujarati, Hindi, Khmer, Kannada, Marathi, Oriya, Tamil, Telugu, and Thai.

I also checked published sims with translations, and found the same problem in Gravity and Orbits as well as Number Play, Ratio and Proportion, and others. However, I did not see any incorrectly rendered characters in Build a Molecule.

Visuals

Gravity and Orbits not rendering correctly in Gutaraji
GaO text dotted circles safari:ipad

How it should look
GaO text no dotted circles

Please let me know if there is any other information needed~

https://phet-dev.colorado.edu/html/gravity-and-orbits/1.6.0-rc.1/phet/gravity-and-orbits_all_phet.html

@Nancy-Salpepi
Copy link

I also noticed that when using those locales in Gravity and Orbits 1.6.0-rc.1, there is a significant delay when switching to and from them in the preferences menu. There is also a delay with window resizing when changing iPad orientation if one of those locales is selected.

@samreid
Copy link
Member

samreid commented Oct 5, 2022

In discussion with @arouinfar and @marlitas, we hypothesize that this issue was introduced by the font change in phetsims/joist#645. Perhaps helvetica neue/helvetica don't have support for all the glyphs in these languages. We agreed that the sim title being off-centered is not a blocking problem, so if restoring this font corrects the problem we can do that for RC.2.

@samreid
Copy link
Member

samreid commented Oct 5, 2022

I observed that "Arial" has the same missing font problems on Safari Version 16.0 (17614.1.25.9.10, 17614). I noticed that https://developer.apple.com/fonts/system-fonts/ listed "Gujarati MT" as a preinstalled font, and when I tried it, it looked OK in Safari:

image

Arial, Lucida Grande and sans-serif all seem to be missing these glyphs.

@samreid
Copy link
Member

samreid commented Oct 5, 2022

Since this problem exists in Gravity and Orbits 1.5 and other published sims, it should not block publication of Gravity and Orbits 1.6. Once we have a solution, it can be cherry picked into sims as appropriate. @jonathanolson can you please advise?

What do you think about locale-specific font families? Or maybe locale + browser specific?

@jonathanolson
Copy link
Contributor

Locale-specific font families sounds potentially helpful, but is much trickier for dynamically changing the locale. If those fonts are missing the glyphs, are we able to provide Gujarati MT as a fallback?

@samreid
Copy link
Member

samreid commented Oct 6, 2022

I tried specifying a fallback by changing

 options.family = `${options.family}, sans-serif`;

to

 options.family = `${options.family}, "Gujarati MT"`;

And it had the same incorrect behavior.

@KatieWoe
Copy link

KatieWoe commented Oct 6, 2022

This still occurs in phetsims/qa#841

@Nancy-Salpepi
Copy link

this issue is also in phetsims/qa#844

@zepumph
Copy link
Member

zepumph commented Oct 27, 2022

PhET-iO team decided today that it is not currently blocking because it is in currently published sims.

The fix would likely require an MR to older sims too.

@Nancy-Salpepi
Copy link

Noting that this issue is still present in phetsims/qa#863 along with the slight delay when switching to those locales on the iPad and mac.

@zepumph
Copy link
Member

zepumph commented Feb 1, 2023

In phetsims/friction#330 (comment) @samreid showed that having the right font hooked up fixed the problem. Is this actually just a wontfix because we can assume people will have the fonts for their languages set up before using phetsims?

@monday-com-github monday-com-github bot changed the title Some characters not rendering correctly in translated sims on Safari Some characters not rendering correctly in translated sims on Safari Feb 21, 2024
@jonathanolson
Copy link
Contributor

This was handled and pushed out to maintenance, closing!

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

No branches or pull requests

7 participants