Skip to content

Layouts

imawizard edited this page Jul 30, 2024 · 5 revisions

Tall

tall := TallLayout({
    ;; Default options:
    displayName: "Tall",
    masterCountMax: -1,
    flipped: false,
})

The default layout. Separates the screen into a primary and a secondary pane and places windows one below the other respectively in either pane.
masterCountMax limits the number of windows placed in the primary pane. If it's -1, the number is limited by mwm.Set("master-count") only (between 1 and 6).
flipped places the primary pane to the right instead of the left.

tall

Wide

wide := WideLayout({
    ;; Default options:
    displayName: "Wide",
    masterCountMax: -1,
})

Like TallLayout, but places the windows in either group side-by-side.
masterCountMax is the same as with TallLayout.
flipped places the primary pane at the bottom instead of the top.

wide

Fullscreen

fullscreen := FullscreenLayout({
    ;; Default options:
    displayName: "Fullscreen",
    nativeMaximize: false,
})

Shows only the active window, on top of all others.
If nativeMaximize is false the active window is resized to occupy the monitor's work area, otherwise the window is not resized but maximized.

Floating

floating := FloatingLayout({
    ;; Default options:
    displayName: "Floating",
})

Disables automatic tiling/positioning.

Columns

columns := ColumnLayout({
    ;; Default options:
    displayName: "Columns",
})

Shows all windows side-by-side, equivalent to WideLayout with zero windows in the primary pane.

wide-4

Rows

rows := RowLayout({
    ;; Default options:
    displayName: "Rows",
})

Shows all windows as rows, one below the other, equivalent to TallLayout with zero windows in the primary pane.

Three-Columns

threecolumn := ThreeColumnLayout({
    ;; Default options:
    displayName: "Three-Columns",
    positioning: ["mid", "left", "right"],
    masterSizeFactor: 1.0,
    masterCountMax: -1,
    showEmptyTertiary: true,
})

The windows in the secondary pane are split in half, resulting in three groups. positioning specifies where to place each group in the order: 1. primary pane, 2. first half of secondary pane, 3. second half.
masterSizeFactor changes the size of the primary pane through usableWidth * workspace.masterSize * layout.masterSizeFactor
masterCountMax is the same as with TallLayout.
showEmptyTertiary keeps the space for the possibly empty tertiary pane, otherwise the secondary pane gets stretched if there are no tertiary windows.

Two-Panes

twopane := TwoPaneLayout({
    ;; Default options:
    displayName: "Two-Panes",
    flipped: false,
})

TwoPaneLayout always shows one window in the primary pane and the rest overlapped in the secondary pane.
flipped places the primary pane to the right instead of the left.

Spiral

spiral := SpiralLayout({
    ;; Default options:
    displayName: "Spiral",
    masterCountMax: -1,
    ratio: 1.0,
})

masterCountMax is the same as with TallLayout.
ratio specifies the factor for sizing subsequent windows. Possible values are e.g. 1.0 or 1.618 (golden ratio).

Clone this wiki locally