mirror of
https://github.com/labwc/labwc.git
synced 2025-10-29 05:40:24 -04:00
src/main.c: initialize locale after reading environments file
This makes the locale for client-menu items and workspace names follow the env var `LANG` defined in `~/.config/environments`.
This commit is contained in:
parent
edd674f96b
commit
2e00630d80
1 changed files with 8 additions and 5 deletions
13
src/main.c
13
src/main.c
|
|
@ -112,11 +112,6 @@ idle_callback(void *data)
|
|||
int
|
||||
main(int argc, char *argv[])
|
||||
{
|
||||
#if HAVE_NLS
|
||||
setlocale(LC_ALL, "");
|
||||
bindtextdomain(GETTEXT_PACKAGE, LOCALEDIR);
|
||||
textdomain(GETTEXT_PACKAGE);
|
||||
#endif
|
||||
char *startup_cmd = NULL;
|
||||
char *primary_client = NULL;
|
||||
enum wlr_log_importance verbosity = WLR_ERROR;
|
||||
|
|
@ -173,6 +168,14 @@ main(int argc, char *argv[])
|
|||
die_on_detecting_suid();
|
||||
|
||||
session_environment_init();
|
||||
|
||||
#if HAVE_NLS
|
||||
/* Initialize locale after setting env vars */
|
||||
setlocale(LC_ALL, "");
|
||||
bindtextdomain(GETTEXT_PACKAGE, LOCALEDIR);
|
||||
textdomain(GETTEXT_PACKAGE);
|
||||
#endif
|
||||
|
||||
rcxml_read(rc.config_file);
|
||||
|
||||
/*
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue