diff --git a/config.h b/config.h index 7354f64..5b2990b 100644 --- a/config.h +++ b/config.h @@ -128,7 +128,7 @@ binding keys[] = { // Only works for apps that use some form of their binary name as their class... { .mod = AnyModifier, .key = XK_F1, .act = action_find_or_start, .data = "konsole" }, { .mod = AnyModifier, .key = XK_F2, .act = action_find_or_start, .data = "chromium" }, - { .mod = AnyModifier, .key = XK_F3, .act = action_find_or_start, .data = "pcmanfm" }, + { .mod = AnyModifier, .key = XK_F3, .act = action_find_or_start, .data = "thunar" }, { .mod = AnyModifier, .key = XK_Menu, .act = action_command, .data = "xowl" }, }; diff --git a/event.c b/event.c index 178fffd..e4bee6d 100644 --- a/event.c +++ b/event.c @@ -179,6 +179,12 @@ void property_notify(XEvent *ev) XPropertyEvent *e = &ev->xproperty; client *c = window_build_client(e->window); + if (e->window == root && e->atom == atoms[WM_NAME]) + { + // root name appears in SPOT1 bar, for status etc + update_bars(); + } + else if (c && c->visible && c->manage) { client_update_border(c); diff --git a/setup.c b/setup.c index 63703f2..d986d61 100644 --- a/setup.c +++ b/setup.c @@ -150,7 +150,7 @@ void setup() } // become the window manager - XSelectInput(display, root, StructureNotifyMask | SubstructureRedirectMask | SubstructureNotifyMask); + XSelectInput(display, root, PropertyChangeMask | StructureNotifyMask | SubstructureRedirectMask | SubstructureNotifyMask); // ewmh support unsigned long pid = getpid(); diff --git a/spot.c b/spot.c index ce3892e..15c4796 100644 --- a/spot.c +++ b/spot.c @@ -32,6 +32,15 @@ void spot_update_bar(int spot, int mon) char title[SPOT_BUFF]; *title = 0; monitor *m = &monitors[mon]; + if (spot == SPOT1) + { + // Show X root window name in spot1 bar + // Use xsetroot -name for a custom status + char *tmp = NULL; + if (XFetchName(display, root, &tmp)) + len += snprintf(title+len, MAX(0, SPOT_BUFF-len), " %s ", tmp); + if (tmp) XFree(tmp); + } for_windows(i, o) if (o->manage && o->spot == spot && o->monitor == mon) { if (!c) c = o; diff --git a/xoat.1 b/xoat.1 index 3d0b782..446e999 100644 --- a/xoat.1 +++ b/xoat.1 @@ -1,4 +1,4 @@ -.TH XOAT 1 "" +.TH XOAT 1 "" .SH NAME .PP xoat - X11 Obstinate Asymmetric Tiler