diff options
| author | Carlos J. Torres <vlaadbrain@gmail.com> | 2013-11-22 10:45:48 -0500 |
|---|---|---|
| committer | Roberto E. Vargas Caballero <k0ga@shike2.com> | 2013-11-23 10:54:57 +0100 |
| commit | 4435e0ee6791136e641d58ce6cf00f8665fe3065 (patch) | |
| tree | 57158f1624abe8c0dec91320a586058cb7ef7973 | |
| parent | 7263820759aa914b27ab3097613bdf22432ed736 (diff) | |
| download | st-4435e0ee6791136e641d58ce6cf00f8665fe3065.tar.gz st-4435e0ee6791136e641d58ce6cf00f8665fe3065.zip | |
add _NET_WM_NAME
| -rw-r--r-- | st.c | 4 |
1 files changed, 3 insertions, 1 deletions
| @@ -239,7 +239,7 @@ typedef struct { | |||
| 239 | Colourmap cmap; | 239 | Colourmap cmap; |
| 240 | Window win; | 240 | Window win; |
| 241 | Drawable buf; | 241 | Drawable buf; |
| 242 | Atom xembed, wmdeletewin; | 242 | Atom xembed, wmdeletewin, netwmname; |
| 243 | XIM xim; | 243 | XIM xim; |
| 244 | XIC xic; | 244 | XIC xic; |
| 245 | Draw draw; | 245 | Draw draw; |
| @@ -3023,6 +3023,7 @@ xinit(void) { | |||
| 3023 | 3023 | ||
| 3024 | xw.xembed = XInternAtom(xw.dpy, "_XEMBED", False); | 3024 | xw.xembed = XInternAtom(xw.dpy, "_XEMBED", False); |
| 3025 | xw.wmdeletewin = XInternAtom(xw.dpy, "WM_DELETE_WINDOW", False); | 3025 | xw.wmdeletewin = XInternAtom(xw.dpy, "WM_DELETE_WINDOW", False); |
| 3026 | xw.netwmname = XInternAtom(xw.dpy, "_NET_WM_NAME", False); | ||
| 3026 | XSetWMProtocols(xw.dpy, xw.win, &xw.wmdeletewin, 1); | 3027 | XSetWMProtocols(xw.dpy, xw.win, &xw.wmdeletewin, 1); |
| 3027 | 3028 | ||
| 3028 | xresettitle(); | 3029 | xresettitle(); |
| @@ -3355,6 +3356,7 @@ xsettitle(char *p) { | |||
| 3355 | Xutf8TextListToTextProperty(xw.dpy, &p, 1, XUTF8StringStyle, | 3356 | Xutf8TextListToTextProperty(xw.dpy, &p, 1, XUTF8StringStyle, |
| 3356 | &prop); | 3357 | &prop); |
| 3357 | XSetWMName(xw.dpy, xw.win, &prop); | 3358 | XSetWMName(xw.dpy, xw.win, &prop); |
| 3359 | XSetTextProperty(xw.dpy, xw.win, &prop, xw.netwmname); | ||
| 3358 | XFree(prop.value); | 3360 | XFree(prop.value); |
| 3359 | } | 3361 | } |
| 3360 | 3362 | ||
