aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/Ewmh.cc24
-rw-r--r--src/FbTk/FbWindow.cc7
-rw-r--r--src/FbTk/FbWindow.hh3
3 files changed, 18 insertions, 16 deletions
diff --git a/src/Ewmh.cc b/src/Ewmh.cc
index 257b432..067b445 100644
--- a/src/Ewmh.cc
+++ b/src/Ewmh.cc
@@ -810,14 +810,14 @@ bool Ewmh::checkClientMessage(const XClientMessageEvent &ce,
810 if (!screen) 810 if (!screen)
811 return true; 811 return true;
812 FbWinFrameTheme &theme = screen->winFrameTheme(); 812 FbWinFrameTheme &theme = screen->winFrameTheme();
813 unsigned int bw = theme.border(true).width();
813 long title_h = theme.titleHeight() || 814 long title_h = theme.titleHeight() ||
814 theme.font().height() + 2*theme.bevelWidth() + 2; 815 theme.font().height() + 2*theme.bevelWidth() + 2 + 2*bw;
815 title_h += theme.border(true).width(); 816 long handle_h = theme.handleWidth() + 2*bw;
816 long handle_h = theme.handleWidth() + theme.border(true).width();
817 long extents[4]; 817 long extents[4];
818 // our frames currently don't protrude from left/right 818 // our frames currently don't protrude from left/right
819 extents[0] = 0; 819 extents[0] = bw;
820 extents[1] = 0; 820 extents[1] = bw;
821 extents[2] = title_h; 821 extents[2] = title_h;
822 extents[3] = handle_h; 822 extents[3] = handle_h;
823 823
@@ -1195,16 +1195,18 @@ void Ewmh::updateFrameExtents(FluxboxWindow &win) {
1195 protrudes from the client window, on left, right, top, bottom 1195 protrudes from the client window, on left, right, top, bottom
1196 (it is independent of window position). 1196 (it is independent of window position).
1197 */ 1197 */
1198 long extents[4];
1199 // our frames currently don't protrude from left/right
1200 extents[0] = 0;
1201 extents[1] = 0;
1202 extents[2] = win.frame().titlebarHeight();
1203 extents[3] = win.frame().handleHeight();
1204 1198
1205 FluxboxWindow::ClientList::iterator it = win.clientList().begin(); 1199 FluxboxWindow::ClientList::iterator it = win.clientList().begin();
1206 FluxboxWindow::ClientList::iterator it_end = win.clientList().end(); 1200 FluxboxWindow::ClientList::iterator it_end = win.clientList().end();
1207 for (; it != it_end; ++it) { 1201 for (; it != it_end; ++it) {
1202 long extents[4];
1203 // our frames currently don't protrude from left/right
1204 int bw = win.frame().window().borderWidth() - (*it)->old_bw;
1205 extents[0] = bw;
1206 extents[1] = bw;
1207 extents[2] = win.frame().titlebarHeight() + bw;
1208 extents[3] = win.frame().handleHeight() + bw;
1209
1208 (*it)->changeProperty(m_net_frame_extents, 1210 (*it)->changeProperty(m_net_frame_extents,
1209 XA_CARDINAL, 32, PropModeReplace, 1211 XA_CARDINAL, 32, PropModeReplace,
1210 (unsigned char *)extents, 4); 1212 (unsigned char *)extents, 4);
diff --git a/src/FbTk/FbWindow.cc b/src/FbTk/FbWindow.cc
index 12492d9..12b16d9 100644
--- a/src/FbTk/FbWindow.cc
+++ b/src/FbTk/FbWindow.cc
@@ -633,7 +633,8 @@ void FbWindow::create(Window parent, int x, int y,
633 633
634 634
635void FbWindow::sendConfigureNotify(int x, int y, 635void FbWindow::sendConfigureNotify(int x, int y,
636 unsigned int width, unsigned int height) { 636 unsigned int width, unsigned int height,
637 unsigned int bw) {
637 Display *disp = FbTk::App::instance()->display(); 638 Display *disp = FbTk::App::instance()->display();
638 XEvent event; 639 XEvent event;
639 event.type = ConfigureNotify; 640 event.type = ConfigureNotify;
@@ -645,9 +646,7 @@ void FbWindow::sendConfigureNotify(int x, int y,
645 event.xconfigure.y = y; 646 event.xconfigure.y = y;
646 event.xconfigure.width = width; 647 event.xconfigure.width = width;
647 event.xconfigure.height = height; 648 event.xconfigure.height = height;
648 //!! TODO 649 event.xconfigure.border_width = bw;
649 event.xconfigure.border_width = 1;
650 //!! TODO
651 event.xconfigure.above = None; 650 event.xconfigure.above = None;
652 event.xconfigure.override_redirect = false; 651 event.xconfigure.override_redirect = false;
653 652
diff --git a/src/FbTk/FbWindow.hh b/src/FbTk/FbWindow.hh
index f266ec3..ae3526c 100644
--- a/src/FbTk/FbWindow.hh
+++ b/src/FbTk/FbWindow.hh
@@ -195,7 +195,8 @@ public:
195 void setOpaque(unsigned char alpha); 195 void setOpaque(unsigned char alpha);
196 196
197 void setRenderer(FbWindowRenderer &renderer) { m_renderer = &renderer; } 197 void setRenderer(FbWindowRenderer &renderer) { m_renderer = &renderer; }
198 void sendConfigureNotify(int x, int y, unsigned int width, unsigned int height); 198 void sendConfigureNotify(int x, int y, unsigned int width,
199 unsigned int height, unsigned int bw = 0);
199 200
200 /// forces full background change, recalcing of alpha values if necessary 201 /// forces full background change, recalcing of alpha values if necessary
201 void updateBackground(bool only_if_alpha); 202 void updateBackground(bool only_if_alpha);