1
0
mirror of https://github.com/gryf/wmaker.git synced 2025-12-24 15:12:32 +01:00

wmaker: Use window placement settings on other workspaces.

Previously, if a window was placed on a workspace other than the current one,
the window placement settings (given by WindowPlacement) were ignored and
the window was drawn in the upper left hand corner.  This is Debian
bug #181735, https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=181735

Part of the bug report by Andrew Gorcester from the link above
is reproduced here:

"When placing a window in a non-active workspace (which usually happens
if the user asks for a program to be started when wmaker is launched,
and defines an initial workspace in the window's attributes dialog),
Windowmaker doesn't follow specified rules on window placement.

All windows of programs that don't manage their own window placement
(Gaim manages placement itself, for instance) are placed in the far
upper-left corner.  Usually windows originate from 64, 64, because the
clip occupies the upper-left corner by default."
This commit is contained in:
Doug Torrance
2016-01-18 20:52:17 -05:00
committed by Carlos R. Mafra
parent 9de5a27dbc
commit 65802d3402

View File

@@ -964,9 +964,8 @@ WWindow *wManageWindow(WScreen *scr, Window window)
wWindowConstrainSize(wwin, &width, &height);
/* do not ask for window placement if the window is
* transient, during startup, if the initial workspace is another one
* or if the window wants to start iconic.
* If geometry was saved, restore it. */
* transient, during startup, or if the window wants
* to start iconic. If geometry was saved, restore it. */
{
Bool dontBring = False;
@@ -975,7 +974,6 @@ WWindow *wManageWindow(WScreen *scr, Window window)
y = win_state->state->y;
} else if ((wwin->transient_for == None || wPreferences.window_placement != WPM_MANUAL)
&& !scr->flags.startup
&& workspace == scr->current_workspace
&& !wwin->flags.miniaturized
&& !wwin->flags.maximized && !(wwin->normal_hints->flags & (USPosition | PPosition))) {