It is nice that the environment variables `LANG` & `LANGUAGE` can be used to override the system locale. But I think it would be even more user friendly to have a configuration option under preferences that would override both system & environment specified language.
It seems there are quite a few users who think there is no locale support or just aren't sure how to change languages. While "I don't have time to read the docs" generally isn't a good excuse, being able to configure the language from within the UI will lead to less confusion, especially for non-Posix system users.
If I get time, I may see if I can add the option myself & create a pull/merge request.
Some related threads: - #1757 - #2831 - #2619 - #2545 <- I think this one is an especially good reason for a configuration option - #1910
@AntumDeluge see [this](https://github.com/geany/geany/issues/1757#issuecomment-362868750). If you think you have a method to change languages within Geany please discuss it, otherwise the wrapper script/program used on the OSX version is the way to go.
I did skim over that conversation before. And re-reading it, I understand now why it would be difficult (or maybe impossible) since the UI language is managed by libraries not developed by Geany devs.
I still think a configurable option to override the value set at startup would be good for a more user-friendly UI. There may be some users that want to change languages on the fly (which currently could be done by creating multiple scripts or shortcuts). But I understand that implementing it may not be feasible.
But I understand that implementing it may not be feasible.
If I sound somewhat frustrated on those many other issues its because, whilst many people repeat "what a good idea, I want" nobody has actually described a way of doing it.
The MacOs [launcher](https://github.com/geany/geany-osx/tree/master/Launcher) approach at least allows easy(ish) setting locale at Geany startup, and although it is a program for MacOs (IIUC so it can be signed) it is probably fairly simple to script for windows, but despite all the "I want" posts nobody has bothered to actually _contribute_ even that for windows.
For Windows users, see current value of the LANG environment variable with PowerShell like so:
```powershell # User context / per user [System.Environment]::GetEnvironmentVariable('LANG','User')
# System context / all users [System.Environment]::GetEnvironmentVariable('LANG','Machine') ```
If no value is returned, it hasn't been set.
<hr>
And set it like so (in user context / per user, does not require admin):
```powershell [System.Environment]::SetEnvironmentVariable('LANG','en','User') ```
got a mix of ~10% Norwegian, the rest English.
Yes, not many of the messages have been translated in the Norwegian language file https://github.com/geany/geany/blob/master/po/nn.po and the last person who did any was back in 2012, so any contributors would help. Or maybe all Norwegian programmers speak English and don't need it.
Would be great with the ability to set the LANG environment variable in user context from Geany GUI, with a warning that it might impact other programs.
As has been said on other threads on the subject, setting it from the Geany GUI is too late, all the libraries that depend on it have already been loaded and initialized, some libraries may allow it to be changed, but that is not required to be supported except for some that POSIX says must, so it has to be set before the program starts and can't be changed from the GUI.
There was a contribution on another thread for how to set it for the Windows startup shortcuts which will (IIUC I don't use windows) only apply to this program.
@elextr It's not "too late". Set it in GUI, if changed offer to reload the application, or show a message saying Geany must be closed and reopened for changes to take effect.
@elextr It's not "too late". Set it in GUI, if changed offer to reload the application, or show a message saying Geany must be closed and reopened for changes to take effect.
Effectively this is the pre-run script/program as is used in the Macos build does, but with a GUI, and as I have said before "somebody" could contribute it for Windows.
With a Geany running another Geany there are potential problems of them sharing the user config and session files and there is currently no way of transferring modified buffers to the new Geany except saving to the underlying file. None of this is insurmountable, its a MMOP, but "somebody" has to do it.
github-comments@lists.geany.org