Master Layout

Master Layout

The master layout makes one (or more) window(s) be the “master”, taking (by default) the left part of the screen, and tiles the rest on the right. You can change the orientation on a per-workspace basis if you want to use anything other than the default left/right split.

master1

Config

category name master

namedescriptiontypedefault
allow_small_splitenable adding additional master windows in a horizontal split styleboolfalse
special_scale_factorthe scale of the special workspace windows. [0.0 - 1.0]float1
mfactthe size as a percentage of the master window, for example mfact = 0.70 would mean 70% of the screen will be the master window, and 30% the slave [0.0 - 1.0]floatvalue0.55
new_statusmaster: new window becomes master; slave: new windows are added to slave stack; inherit: inherit from focused windowstringslave
new_on_topwhether a newly open window should be on the top of the stackboolfalse
new_on_activebefore, after: place new window relative to the focused window; none: place new window according to the value of new_on_top.stringnone
orientationdefault placement of the master area, can be left, right, top, bottom or centerstringleft
inherit_fullscreeninherit fullscreen status when cycling/swapping to another window (e.g. monocle layout)booltrue
always_center_masterwhen using orientation=center, keep the master window centered, even when it is the only window in the workspace.boolfalse
smart_resizingif enabled, resizing direction will be determined by the mouse’s position on the window (nearest to which corner). Else, it is based on the window’s tiling position.booltrue
drop_at_cursorwhen enabled, dragging and dropping windows will put them at the cursor position. Otherwise, when dropped at the stack side, they will go to the top/bottom of the stack depending on new_on_top.booltrue

Dispatchers

layoutmsg commands:

commanddescriptionparams
swapwithmasterswaps the current window with master. If the current window is the master, swaps it with the first child.either master (new focus is the new master window), child (new focus is the new child) or auto (which is the default, keeps the focus of the previously focused window)
focusmasterfocuses the master window.either master (focus stays at master, even if it was selected before) or auto (which is the default, if the current window is the master, focuses the first child.)
cyclenextfocuses the next window respecting the layoutnone
cycleprevfocuses the previous window respecting the layoutnone
swapnextswaps the focused window with the next window respecting the layoutnone
swapprevswaps the focused window with the previous window respecting the layoutnone
addmasteradds a master to the master side. That will be the active window, if it’s not a master, or the first non-master window.none
removemasterremoves a master from the master side. That will be the active window, if it’s a master, or the last master window.none
orientationleftsets the orientation for the current workspace to left (master area left, slave windows to the right, vertically stacked)none
orientationrightsets the orientation for the current workspace to right (master area right, slave windows to the left, vertically stacked)none
orientationtopsets the orientation for the current workspace to top (master area top, slave windows to the bottom, horizontally stacked)none
orientationbottomsets the orientation for the current workspace to bottom (master area bottom, slave windows to the top, horizontally stacked)none
orientationcentersets the orientation for the current workspace to center (master area center, slave windows alternate to the left and right, vertically stacked)none
orientationnextcycle to the next orientation for the current workspace (clockwise)none
orientationprevcycle to the previous orientation for the current workspace (counter-clockwise)none
orientationcyclecycle to the next orientation from the provided list, for the current workspaceallowed values: left, top, right, bottom, or center. The values have to be separated by a space. If left empty, it will work like orientationnext
mfactchange mfact, the master split ratiothe new split ratio, a relative float delta (e.g -0.2 or +0.2) or exact followed by a the exact float value between 0.0 and 1.0
rollnextrotate the next window in stack to be the master, while keeping the focus on masternone
rollprevrotate the previous window in stack to be the master, while keeping the focus on masternone

Parameters for the commands are separated by a single space.

ℹ️

Example usage:

bind = MOD, KEY, layoutmsg, cyclenext
# behaves like xmonads promote feature (https://hackage.haskell.org/package/xmonad-contrib-0.17.1/docs/XMonad-Actions-Promote.html)
bind = MOD, KEY, layoutmsg, swapwithmaster master

Workspace Rules

layoutopt rules:

ruledescriptiontype
orientation:[o]Sets the orientation of a workspace. For available orientations, see Config->orientationstring

Example usage:

workspace = 2, layoutopt:orientation:top