-
-
Notifications
You must be signed in to change notification settings - Fork 23.5k
Make editor language setting default to Auto #112317
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
base: master
Are you sure you want to change the base?
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Code looks good, having a dedicated "auto" make sense for me.
3c483e4 to
3d37a81
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There's one ramification: this needs to be documented in the migration guide. It technically breaks compatibility because interface/editor/editor_language is no longer reliable.
3d37a81 to
7daba1b
Compare
7daba1b to
ba6b7d2
Compare
Currently,
interface/editor/editor_languagedefaults to the system language. This creates the problem that it's technically impossible to pin a language, as the setting is not saved when being same as the default value.You can use the following steps to reproduce the problem.
Warning
Don't use Project Manager's quick settings dialog when testing the problem. It somehow saves all properties it sees on
EditorSettings, including those that are not meant to be saved :(LANG=esfor the first timefrinterface/editor/editor_language = "fr"setting is saved.LANG=esagainLANG=frLANG=esagaininterface/editor/editor_language = "fr"setting is removed in the third runThis PR adds a dedicated
Autooption as the default value.Tool scripts can use
EditorInterface.get_editor_language()to get the effective language instead of readinginterface/editor/editor_language.