]> Dogcows Code - chaz/openbox/commitdiff
i dont know what i fixed but here it is
authorDana Jansens <danakj@orodu.net>
Tue, 3 Dec 2002 05:38:40 +0000 (05:38 +0000)
committerDana Jansens <danakj@orodu.net>
Tue, 3 Dec 2002 05:38:40 +0000 (05:38 +0000)
src/frame.cc

index 40b9b9c635c7f1e57784ade090cda3b28db7397a..f1017d0ec5fc20a4a5996908083df22f8b8764c3 100644 (file)
@@ -121,21 +121,18 @@ void OBFrame::adjust()
   _decorations = _client->decorations();
   _decorations = 0xffffffff;
   
-  int width;   // the width of the client window and the border around it
+  int width;   // the width of the whole frame
   int bwidth;  // width to make borders
   int cbwidth; // width of the inner client border
   
   if (_decorations & OBClient::Decor_Border) {
     bwidth = _style->getBorderWidth();
     cbwidth = _style->getFrameWidth();
-    _size.left = _size.top = _size.bottom = _size.right =
-      _style->getFrameWidth();
-    width = _client->area().width() + _style->getFrameWidth() * 2;
-  } else {
+  } else
     bwidth = cbwidth = 0;
-    _size.left = _size.top = _size.bottom = _size.right = 0;
-    width = _client->area().width();
-  }
+  _size.left = _size.top = _size.bottom = _size.right = bwidth + cbwidth;
+  width = _client->area().width() + (bwidth + cbwidth) * 2;
+
   XSetWindowBorderWidth(otk::OBDisplay::display, _plate.getWindow(), cbwidth);
 
   XSetWindowBorderWidth(otk::OBDisplay::display, getWindow(), bwidth);
@@ -250,8 +247,8 @@ void OBFrame::adjust()
   resize(_size.left + _size.right + _client->area().width(),
          _size.top + _size.bottom + _client->area().height());
 
-  _plate.setGeometry(_size.left, _size.top, _client->area().width(),
-                     _client->area().height());
+  _plate.setGeometry(_size.left - cbwidth, _size.top - cbwidth,
+                     _client->area().width(), _client->area().height());
 
   // map/unmap all the windows
   if (_decorations & OBClient::Decor_Titlebar) {
This page took 0.023745 seconds and 4 git commands to generate.