diff --git a/src/x11window.cpp b/src/x11window.cpp index eb0e66152b..8783375df7 100644 --- a/src/x11window.cpp +++ b/src/x11window.cpp @@ -4509,11 +4509,10 @@ void X11Window::maximize(MaximizeMode mode) } } r.moveTopLeft(rules()->checkPosition(r.topLeft())); - // The above code tries to center align the window followed by setting top and bottom - // it's possible that we're in between two pixels - r.setX(Xcb::nativeFloor(r.x())); - r.setY(Xcb::nativeFloor(r.y())); } + // The above code tries to center align the window followed by setting top and bottom + // it's possible that we're in between two pixels + r = Xcb::nativeFloor(r); moveResize(r); if (options->electricBorderMaximize() && r.top() == clientArea.top()) {