tags 261114 patch fixed-upstream
thanks

mfk> Dmitry, this version does seem to fix the window placement bug.
mfk> Thank you soooo much for looking into it!
I've made a patch for correcting this bug. However I might overlook
smth. Please could You assemble version 1.0~rc3-3 with this patch and
tell me about results?

http://uvw.ru/debian/fluxbox/fluxbox-1.0/fluxbox_1.0~rc3-3.diff.gz
http://uvw.ru/debian/fluxbox/fluxbox-1.0/fluxbox_1.0~rc3-3.dsc
http://uvw.ru/debian/fluxbox/fluxbox-1.0/fluxbox_1.0~rc3.orig.tar.gz
--- fluxbox-1.0~rc3/src/ScreenPlacement.cc
+++ fluxbox-1.0~rc3/src/ScreenPlacement.cc
@@ -118,10 +123,11 @@
         win_h = win.height() + win.fbWindow().borderWidth()*2 + 
win.heightOffset();
 
     // make sure the window is inside our screen(head) area
-    if (place_x + win_w > head_right)
-        place_x = (head_right - win_w) / 2 + win.xOffset();
-    if (place_y + win_h > head_bot)
-        place_y = (head_bot - win_h) / 2 + win.yOffset();
+    if (place_x + win_w - win.xOffset() > head_right)
+        place_x = head_left + (head_right - head_left - win_w) / 2 +
+                  win.xOffset();
+    if (place_y + win_h - win.yOffset() > head_bot)
+        place_y = head_top + (head_bot - head_top - win_h) / 2 + win.yOffset();
 
     return true;
 }

Attachment: signature.asc
Description: Digital signature

Reply via email to