-
Notifications
You must be signed in to change notification settings - Fork 6
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
Language choice can greatly change preference dialog size #843
Comments
Thanks @KatieWoe. I am not sure what is expected here. The Dialog fits the size of its contents. The contents are allowed to expand to support longer strings. Without dynamic locales this wouldn't be a problem. @arouinfar @kathy-phet should this behavior change? |
@jessegreenberg - I'm not sure why it doesn't just wrap in chinese, since it is a paragraph? |
Assigning to @jonathanolson in case he has any thoughts about what should happen with RichText |
In general, I am fine with the Preferences dialog changing in width in response to locale, so long as it remains within the dev bounds. Since the width is properly constrained here, we can probably leave it at that. However, in this specific case, we could probably add spaces after the period character I am fine with either approach. |
@arouinfar is this blocking Gravity and Orbits RC? @jonathanolson would this be easy to correct? |
@arouinfar said this doesn't block publication. |
I should have a fix for this relatively soon! |
…eak detection. Adding back directional marks into load-unbuilt-strings. Proper RichText line break handling. See phetsims/joist#843
…eak detection. Adding back directional marks into load-unbuilt-strings. Proper RichText line break handling. See phetsims/joist#843
…eak detection. Adding back directional marks into load-unbuilt-strings. Proper RichText line break handling. See phetsims/joist#843
…eak detection. Adding back directional marks into load-unbuilt-strings. Proper RichText line break handling. See phetsims/joist#843
…eak detection. Adding back directional marks into load-unbuilt-strings. Proper RichText line break handling. See phetsims/joist#843
…eak detection. Adding back directional marks into load-unbuilt-strings. Proper RichText line break handling. See phetsims/joist#843
…eak detection. Adding back directional marks into load-unbuilt-strings. Proper RichText line break handling. See phetsims/joist#843
…eak detection. Adding back directional marks into load-unbuilt-strings. Proper RichText line break handling. See phetsims/joist#843
…eak detection. Adding back directional marks into load-unbuilt-strings. Proper RichText line break handling. See phetsims/joist#843
…eak detection. Adding back directional marks into load-unbuilt-strings. Proper RichText line break handling. See phetsims/joist#843
…eak detection. Adding back directional marks into load-unbuilt-strings. Proper RichText line break handling. See phetsims/joist#843
…eak detection. Adding back directional marks into load-unbuilt-strings. Proper RichText line break handling. See phetsims/joist#843
…eak detection. Adding back directional marks into load-unbuilt-strings. Proper RichText line break handling. See phetsims/joist#843
…eak detection. Adding back directional marks into load-unbuilt-strings. Proper RichText line break handling. See phetsims/joist#843
…eak detection. Adding back directional marks into load-unbuilt-strings. Proper RichText line break handling. See phetsims/joist#843
…eak detection. Adding back directional marks into load-unbuilt-strings. Proper RichText line break handling. See phetsims/joist#843
…eak detection. Adding back directional marks into load-unbuilt-strings. Proper RichText line break handling. See phetsims/joist#843
…eak detection. Adding back directional marks into load-unbuilt-strings. Proper RichText line break handling. See phetsims/joist#843
…eak detection. Adding back directional marks into load-unbuilt-strings. Proper RichText line break handling. See phetsims/joist#843
…eak detection. Adding back directional marks into load-unbuilt-strings. Proper RichText line break handling. See phetsims/joist#843
…eak detection. Adding back directional marks into load-unbuilt-strings. Proper RichText line break handling. See phetsims/joist#843
…eak detection. Adding back directional marks into load-unbuilt-strings. Proper RichText line break handling. See phetsims/joist#843
…eak detection. Adding back directional marks into load-unbuilt-strings. Proper RichText line break handling. See phetsims/joist#843
…eak detection. Adding back directional marks into load-unbuilt-strings. Proper RichText line break handling. See phetsims/joist#843
…eak detection. Adding back directional marks into load-unbuilt-strings. Proper RichText line break handling. See phetsims/joist#843
…eak detection. Adding back directional marks into load-unbuilt-strings. Proper RichText line break handling. See phetsims/joist#843
…eak detection. Adding back directional marks into load-unbuilt-strings. Proper RichText line break handling. See phetsims/joist#843
…eak detection. Adding back directional marks into load-unbuilt-strings. Proper RichText line break handling. See phetsims/joist#843
…eak detection. Adding back directional marks into load-unbuilt-strings. Proper RichText line break handling. See phetsims/joist#843
…eak detection. Adding back directional marks into load-unbuilt-strings. Proper RichText line break handling. See phetsims/joist#843
Main commits in phetsims/chipper@4711345, phetsims/sherpa@e2b5b26, phetsims/scenery@f7a32b0, ee0da58 I added isLeftToRightProperty and some changes to GeneralPreferencesPanel to fix some i18n issues. I noticed that load-unbuilt-strings was NOT adding in directional marks into strings, and that was causing bugginess (I fixed that). RichText lineWrap will now wrap properly at unicode-decided points. This seems to work nicely for all locales that we have: and also does the RTL properly: |
@jessegreenberg would you be able to review? |
@pixelzoom, @jbphet and I were all hit by the API changes from this. Committed above. |
I reviewed the commits referenced in #843 (comment), changes make sense to me. The Preferences dialog is working really well, no longer resizes for different translations. RichText lineWrap is working great for all locales I have seen and the formatting for rtl languages works nicely. Very cool @jonathanolson, thanks! Closing. |
…eak detection. Adding back directional marks into load-unbuilt-strings. Proper RichText line break handling. See phetsims/joist#843
…eak detection. Adding back directional marks into load-unbuilt-strings. Proper RichText line break handling. See phetsims/joist#843
…eak detection. Adding back directional marks into load-unbuilt-strings. Proper RichText line break handling. See phetsims/joist#843
Test device
Dell
Operating System
Win 11
Browser
Chrome
Problem description
For phetsims/qa#830
One of the languages (Chinese Taiwan) changes the preference dialog box size quite a bit. It doesn't go out of bounds, so I'm not too worried, but it is different behavior. I think it's due to the translation of the first page of the dialog.
Visuals
Oddly sized dialog box:
Standard sized dialog box:
Troubleshooting information:
!!!!! DO NOT EDIT !!!!!
Name: Gravity and Orbits
URL: https://phet-dev.colorado.edu/html/gravity-and-orbits/1.6.0-dev.3/phet/gravity-and-orbits_all_phet.html
Version: 1.6.0-dev.3 2022-08-23 23:55:17 UTC
Features missing: applicationcache, applicationcache, touch
Flags: pixelRatioScaling
User Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/104.0.0.0 Safari/537.36
Language: en-US
Window: 1536x714
Pixel Ratio: 1.25/1
WebGL: WebGL 1.0 (OpenGL ES 2.0 Chromium)
GLSL: WebGL GLSL ES 1.0 (OpenGL ES GLSL ES 1.0 Chromium)
Vendor: WebKit (WebKit WebGL)
Vertex: attribs: 16 varying: 30 uniform: 4096
Texture: size: 16384 imageUnits: 16 (vertex: 16, combined: 32)
Max viewport: 32767x32767
OES_texture_float: true
Dependencies JSON: {}
The text was updated successfully, but these errors were encountered: