> ## Documentation Index
> Fetch the complete documentation index at: /docs/llms.txt
> Use this file to discover all available pages before exploring further.

> ## Agent Instructions
> Bach builds Windows installers from one bach.toml with the bach command: bach init, bach check, bach preview, bach build. Installs are per user and need no administrator rights by default. installer.scope = "machine" installs for every user after one Windows prompt. On Windows, run setup files with Start-Process -Wait -PassThru in PowerShell, and give signtool arguments that start with the word sign.

# [layout]: presets, window size, panels, spacing and motion

> Start from one of ten layouts for the Bach installer window, then set its size, a picture panel or banner, a floating card, tiles, spacing and animation.

The `[layout]` section sets how the installer window is sized, arranged and animated, on top of its [style](/docs/reference/config/style.md). Everything is optional; without `[layout]` the window is the classic column it always was. The quickest start is a preset, and every setting below changes it:

```toml bach.toml theme={"theme":{"light":"github-light","dark":"github-dark"}}
[layout]
preset = "showcase"               # the choices on the left, a rounded picture on the right
panel_image = "art/hero.jpg"
heading_size = 34                 # anything else you want different
```

[`bach layouts`](/docs/reference/cli/layouts) lists the presets, and `bach preview --layout NAME` shows one on your app without changing `bach.toml` ([`bach watch`](/docs/reference/cli/watch) reopens the window on every save). Texts are changed in [`[text]`](/docs/reference/config/text), and which options the window offers in [`[installer]`](/docs/reference/config/installer#options).

## Presets

| Preset | What it looks like | Best with |
| - | - | - |
| `classic` | One calm centred column. The default. | |
| `showcase` | The choices on the left, a large picture on the right, inset with rounded corners. | `panel_image` |
| `spotlight` | Key art down the left with the heading on it, the choices as tiles beside it. | `panel_image` |
| `hero` | A wide rounded picture on top with the heading on it, the choices as tiles below. | `panel_image` |
| `banner` | A picture across the top, edge to edge, with the heading on it; the choices below. | `panel_image` |
| `floating` | Everything on one card floating over the window's picture or colour. | `[style] background_image` |
| `editorial` | A picture edge to edge on the right, a large heading and plain rows on the left. | `panel_image` |
| `portrait` | A tall, narrow window: a large rounded picture with the heading on it, the choices below. | `panel_image` |
| `tiles` | A wide window with the install folder across the top and the options as tiles below. | |
| `minimal` | No card and no icons: the rows sit on the window, divided by hairlines. | |

A preset that is best with a picture still works without one: a panel without a picture shows the app's logo large on a tint of the accent.

## Window and panel

| Setting | Default | Meaning |
| - | - | - |
| `preset` | none | A built-in layout to start from (above). |
| `width` | `540`; `880` with a side panel; `600` with a banner | The window's width in points, 380 to 1400. |
| `height` | as tall as the choices need | The window's height in points, 340 to 1000. Taller than the width makes a portrait window; when the choices don't fit, the card scrolls. The window never grows past 85% of the screen. |
| `panel` | `"none"` | A panel at the `"left"` or `"right"` of the choices, or a banner across the `"top"`. |
| `panel_size` | 46% of the window (40% with the heading on it); `190` for a banner | The panel's width, or a banner's height, in points (120 to 800). The choices keep at least 300 points. |
| `panel_image` | none | A PNG or JPEG that fills the panel, cut to its shape around the middle (up to 8 MB). |
| `panel_inset` | `0` | Space around the panel in points, 0 to 48. With a radius the panel floats as a card. |
| `panel_radius` | `0` | The panel's corners in points, 0 to 48. |
| `header` | `"content"` | With a panel: the logo, heading and subtitle above the choices (`"content"`), or on the `"panel"`. On a picture they sit low over a shade and turn light, unless `[style] panel_text` says otherwise. |
| `content_width` | the room there is | The widest the choices and buttons get, in points (260 to 1200), centred in their room. |
| `surface` | `"plain"` | `"card"` puts the heading, choices and buttons on one card floating over the window's colour or picture. |

The panel's colour without a picture is `[style] panel` (by default a light tint of the accent), its text `[style] panel_text`.

## Text and spacing

| Setting | Default | Meaning |
| - | - | - |
| `align` | `"center"` (`"left"` with a panel) | How the logo, heading, subtitle and the footer line above the buttons align: `"left"`, `"center"` or `"right"`. |
| `logo` | `"above"` | The logo `"above"` the heading, or `"beside"` it on one line. |
| `padding` | `[44, 32, 24, 32]` | Space inside the window in points, 0 to 96: one number for every side, `[top and bottom, sides]`, or `[top, right, bottom, left]`. |
| `gap` | `28` (`0` with the heading on a side panel) | Points between the heading and the choices. |
| `heading_size` | `22` | The heading's size in points, 14 to 48. A long heading still steps down so it wraps calmly. |
| `text_size` | `14` | The text's size in points, 11 to 20. Descriptions are a point smaller, the footer line two. |

## Choices and buttons

| Setting | Default | Meaning |
| - | - | - |
| `rows` | `"joined"` | `"joined"`: one card with the rows divided by hairlines. `"separate"`: each row a card of its own. `"plain"`: no card, the rows straight on the window with hairlines between them. |
| `columns` | `1` | `2` lays separate rows out as tiles in two columns. The install folder keeps a line of its own, and tiles on one line are equally tall. |
| `row_padding` | `16` | Points inside each row, 6 to 32. |
| `icons` | `true` | Whether rows show their icon. |
| `dividers` | `true` | Whether joined and plain rows have hairlines between them. |
| `button_height` | `32` | Points, 24 to 56. |
| `buttons` | `"right"` | `"right"`, `"left"`, `"center"`, or `"stretch"` to share the whole width. |
| `primary` | `"last"` | The main button (Install, Remove, Open) `"last"` or `"first"`. Tab follows the order they are drawn in. |
| `footer` | `"beside"` | The footer line (publisher and version, or `[text] footer`): `"beside"` the buttons, `"above"` them, or `"hidden"`. With centred or stretched buttons it goes above them. |

## Motion

| Setting | Default | Meaning |
| - | - | - |
| `animation` | `"rise"` | How each page comes in: `"rise"` (fades in, rising a few points), `"fade"`, `"slide"` (in from the right), `"drop"` (from above) or `"none"`. |
| `animation_speed` | `1` | 0.25 to 4: 2 plays twice as fast, 0.5 half as fast. |

## Your own layout

Every setting works without a preset too. A banner with the heading on it, tiles in two columns and stretched buttons:

```toml bach.toml theme={"theme":{"light":"github-light","dark":"github-dark"}}
[layout]
panel = "top"
panel_size = 220
panel_image = "art/banner.jpg"
header = "panel"
align = "left"
width = 760
rows = "separate"
columns = 2
buttons = "stretch"
footer = "above"
animation = "drop"
```

## Check the result

`bach check` and `bach build` name the layout in their Look line:

```console theme={"theme":{"light":"github-light","dark":"github-dark"}}
$ bach check
  ...
  Look         bach style, follows Windows' light or dark, showcase layout (940 wide, panel at the right), panel picture
```

Every mistake names its setting and the values it takes, such as `layout.panel is "bottom"; use "none", "left", "right" or "top"`.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.