all repos — fluxbox @ 6b92622d6e7431fc7891a56c9bea89bc80f8e91e

custom fork of the fluxbox windowmanager

window was growing when we received a configurerequest that changed width but not height
markt markt
commit

6b92622d6e7431fc7891a56c9bea89bc80f8e91e

parent

6fdda1a31d2417c23f5f222114d30ce6abec8b40

2 files changed, 9 insertions(+), 1 deletions(-)

jump to
M ChangeLogChangeLog

@@ -1,5 +1,9 @@

(Format: Year/Month/Day) Changes for 1.0rc3: +*07/02/10: + * Fixed a bug with resizing windows for clients when only the width is + specified (Mark) + Window.cc *07/02/09: * Introduced support for mouse buttons in the keys file (Mark) - Mouse buttons are bound to new `keys' Mouse1, Mouse2, etc.
M src/Window.ccsrc/Window.cc

@@ -2584,14 +2584,18 @@ frame().gravityTranslate(ignore, cy, client->gravity(), client->old_bw, false);

frame().setActiveGravity(client->gravity(), client->old_bw); } - if (cr.value_mask & CWWidth) + if (cr.value_mask & CWWidth) { cw = cr.width; + // we must set this now, or else window grows when height not specified + ch -= (frame().titlebarHeight() + frame().handleHeight()); + } if (cr.value_mask & CWHeight) ch = cr.height; // whether we should send ConfigureNotify to netizens // the request is for client window so we resize the frame to it first + // NOTE: this might not work correctly if client actually requests that size if (frame().width() != cw || frame().height() != ch) { if (frame().x() != cx || frame().y() != cy) frame().moveResizeForClient(cx, cy, cw, ch);