aboutsummaryrefslogtreecommitdiff
path: root/src/FbTk
diff options
context:
space:
mode:
authorVladimir A. Pavlov <pv4@bk.ru>2012-10-22 15:39:35 (GMT)
committerMathias Gumz <akira at fluxbox dot org>2012-12-30 11:27:43 (GMT)
commit36489e4a17df27965ff14b7fd0a9482b4cf47882 (patch)
tree523ae56bd4f45633cc39cc21c682feb33229723a /src/FbTk
parent7a404e7fbca7894cdda76f7b0ddfed855a732424 (diff)
downloadfluxbox-36489e4a17df27965ff14b7fd0a9482b4cf47882.zip
fluxbox-36489e4a17df27965ff14b7fd0a9482b4cf47882.tar.bz2
Set WM_WINDOW_ROLE for fluxbox windows
Diffstat (limited to 'src/FbTk')
-rw-r--r--src/FbTk/FbWindow.cc7
-rw-r--r--src/FbTk/FbWindow.hh2
2 files changed, 9 insertions, 0 deletions
diff --git a/src/FbTk/FbWindow.cc b/src/FbTk/FbWindow.cc
index 8362733..257447f 100644
--- a/src/FbTk/FbWindow.cc
+++ b/src/FbTk/FbWindow.cc
@@ -265,6 +265,13 @@ void FbWindow::setName(const char *name) {
265 XStoreName(display(), m_window, name); 265 XStoreName(display(), m_window, name);
266} 266}
267 267
268void FbWindow::setWindowRole(const char *windowRole) {
269 XTextProperty tp;
270 XStringListToTextProperty(const_cast<char **>(&windowRole), 1, &tp);
271 XSetTextProperty(display(), m_window, &tp, XInternAtom(display(), "WM_WINDOW_ROLE", False));
272 XFree(tp.value);
273}
274
268void FbWindow::setEventMask(long mask) { 275void FbWindow::setEventMask(long mask) {
269 XSelectInput(display(), m_window, mask); 276 XSelectInput(display(), m_window, mask);
270} 277}
diff --git a/src/FbTk/FbWindow.hh b/src/FbTk/FbWindow.hh
index 9d335fa..3e1c05b 100644
--- a/src/FbTk/FbWindow.hh
+++ b/src/FbTk/FbWindow.hh
@@ -87,6 +87,8 @@ public:
87 virtual void setBorderWidth(unsigned int size); 87 virtual void setBorderWidth(unsigned int size);
88 /// set window name ("title") 88 /// set window name ("title")
89 void setName(const char *name); 89 void setName(const char *name);
90 /// set window role
91 void setWindowRole(const char *windowRole);
90 void setEventMask(long mask); 92 void setEventMask(long mask);
91 /// clear window with background pixmap or color 93 /// clear window with background pixmap or color
92 virtual void clear(); 94 virtual void clear();