From c052addd1dced4ca1ebc2dbb31749c7faa26ed0d Mon Sep 17 00:00:00 2001 From: Cyrus Rahman Date: Wed, 1 Mar 2017 21:20:44 -0700 Subject: [PATCH] wmaker: Do not place icons under the dock While I love the new maximizing functions, in the process of developing them the code to keep icons from under the dock was lost. I have created a patch to prevent this problem. --- src/placement.c | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/src/placement.c b/src/placement.c index 62fcb305..14fe226f 100644 --- a/src/placement.c +++ b/src/placement.c @@ -117,6 +117,16 @@ void PlaceIcon(WScreen *scr, int *x_ret, int *y_ret, int head) WMBagIterator iter; WArea area = wGetUsableAreaForHead(scr, head, NULL, False); + /* Do not place icons under the dock. */ + if (scr->dock) { + int offset = wPreferences.icon_size + DOCK_EXTRA_SPACE; + + if (scr->dock->on_right_side) + area.x2 -= offset; + else + area.x1 += offset; + } + /* Find out screen boundaries. */ /* Allows each head to have miniwindows */