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

Fixed missing textures with languages like Turkish #71

Merged
merged 1 commit into from
Sep 29, 2019

Conversation

rihi
Copy link
Collaborator

@rihi rihi commented Sep 28, 2019

There was a very weird issue, where when your pc language was set to Turkish you'd often end up with missing textures. For some reason, every texture name had all i characters converted to ? characters.

The source of the problem seems to be, that texture names are converted using String.toLowerCase(), which uses the standard locale. If this happens to be the Turkish locale, the I character is not converted to i, as you would expect from the English language, but to ı. This due to the Turkish language having 2 I characters. The "Dotted I" (U+0069) and the "Dotles I" (U+0131).
I changed the toLowerCase conversion to always use the Locale.ROOT locale instead of the standard one.

Fixes #51

This fixes cases where the default locale uses different uppercase characters as opposed to the standard english language. Example: Turkish locale uses the character 'İ' as an uppercase i.
@ata4 ata4 merged commit 5045de3 into ata4:master Sep 29, 2019
@ata4
Copy link
Owner

ata4 commented Sep 29, 2019

Thanks!

@rihi rihi deleted the turkish-locale-fix branch September 29, 2019 15:29
ata4 added a commit that referenced this pull request Dec 1, 2019
Fixed missing textures with languages like Turkish
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

Successfully merging this pull request may close these issues.

materials that have a i letter in it are replaced by ?
2 participants