Initialize workspace rect to the output's upon creation
The comment immediately following implied that this was the intended behaviour. Not doing so means that compound commands that both move a window to a new workspace as well as do something that depends on the workspace's geometry (e.g. 'move position center' or 'floating enable' on a tiled window) would use the workspace's calloc'd 0x0+0x0 geometry.
This commit is contained in:
@ -29,6 +29,7 @@ static void _workspace_apply_default_orientation(Con *ws) {
|
||||
if (config.default_orientation == NO_ORIENTATION) {
|
||||
Con *output = con_get_output(ws);
|
||||
ws->layout = (output->rect.height > output->rect.width) ? L_SPLITV : L_SPLITH;
|
||||
ws->rect = output->rect;
|
||||
DLOG("Auto orientation. Workspace size set to (%d,%d), setting layout to %d.\n",
|
||||
output->rect.width, output->rect.height, ws->layout);
|
||||
} else {
|
||||
|
Reference in New Issue
Block a user