Skip to content

Show a quickpick for changing display language - #69570

Merged
Rachel Macfarlane (RMacfarlane) merged 5 commits into
masterfrom
rmacfarlane/display-language
Mar 6, 2019
Merged

Show a quickpick for changing display language#69570
Rachel Macfarlane (RMacfarlane) merged 5 commits into
masterfrom
rmacfarlane/display-language

Conversation

@RMacfarlane

Copy link
Copy Markdown

While verifying issues I had to change my display language a couple of times, and I think the experience for it could be bit better.

Instead of opening the locale.json file, this PR uses the localization service to get the list of available languages and display it in a quick pick. The current language is selected by default, and the placeholder text explains that VS Code will restart on selection. When something is selected, the locale.json file is written to as before and VS Code gets restarted.

screen shot 2019-02-27 at 5 10 17 pm

When running out of sources I don't ever see the UI language change - I haven't dug into how nls gets loaded so I'm not sure if that's expected or not. But I do see that the locale.json file is updated correctly.

This fixes #22758

Let me know if you think this is a good change. Thanks!

@RMacfarlane Rachel Macfarlane (RMacfarlane) added the l10n-platform Localization platform issues (not wrong translations) label Feb 28, 2019
@dbaeumer

Copy link
Copy Markdown
Member

Rachel Macfarlane (@RMacfarlane) thanks a lot for the PR.

@dbaeumer

Copy link
Copy Markdown
Member

I looked over it and I have a suggestions: I think we should indicate whether the corresponding language pack is available locally. If not it might even be cool to install it. Otherwise the expierence might not be nice when selecting a LP that is not installed.

@RMacfarlane

Copy link
Copy Markdown
Author

Ah, thanks! I had misread the code for getLanguageIds. I've changed it now so that the quick pick is only populated with languages that are available locally, and there's an option at the bottom to install more languages that opens the extension's viewlet with a query for language packs.

@dbaeumer

Copy link
Copy Markdown
Member

Rachel Macfarlane (@RMacfarlane) have you updated the PR. I think I don't see the new code changes.

@RMacfarlane

Copy link
Copy Markdown
Author

Dirk Bäumer (@dbaeumer) it should be updated now, I just rebased against master

@dbaeumer

Copy link
Copy Markdown
Member

Rachel Macfarlane (@RMacfarlane) LGTM. Feel free to merge in.

@RMacfarlane

Copy link
Copy Markdown
Author

Dirk Bäumer (@dbaeumer) Thanks for reviewing! I pushed one more change to show a confirmation dialog before restarting, based on feedback when demoing to the Redmond team. I'll go ahead and merge since that addition is very simple.

@RMacfarlane
Rachel Macfarlane (RMacfarlane) deleted the rmacfarlane/display-language branch March 6, 2019 01:26
@github-actions github-actions Bot locked and limited conversation to collaborators Mar 27, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

l10n-platform Localization platform issues (not wrong translations)

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Suggestion: ability to restart when changing language

2 participants