mirror of
https://github.com/labwc/labwc.git
synced 2026-05-20 21:37:41 -04:00
output.c: use env var LABWC_TITLE to set nested labwc window title
Introduces an environment variable LABWC_TITLE, which, when set, will be used to set the title of a nested instance of labwc.
This commit is contained in:
parent
8473ea4b72
commit
7a53f294a8
1 changed files with 5 additions and 1 deletions
|
|
@ -606,7 +606,11 @@ handle_new_output(struct wl_listener *listener, void *data)
|
||||||
|
|
||||||
if (wlr_output_is_wl(wlr_output)) {
|
if (wlr_output_is_wl(wlr_output)) {
|
||||||
char title[64];
|
char title[64];
|
||||||
snprintf(title, sizeof(title), "%s - %s", "labwc", wlr_output->name);
|
if (getenv("LABWC_TITLE")) {
|
||||||
|
snprintf(title, sizeof(title), "%s", getenv("LABWC_TITLE"));
|
||||||
|
} else {
|
||||||
|
snprintf(title, sizeof(title), "%s - %s", "labwc", wlr_output->name);
|
||||||
|
}
|
||||||
wlr_wl_output_set_title(wlr_output, title);
|
wlr_wl_output_set_title(wlr_output, title);
|
||||||
wlr_wl_output_set_app_id(wlr_output, "labwc");
|
wlr_wl_output_set_app_id(wlr_output, "labwc");
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue