Workspaces
Pin workspaces to specific monitors with sweets.workspace.
sweets.workspace(number, { ... }) pins a workspace to a monitor. Workspace
rules are optional. If a workspace has no monitor rule, it follows the current
output as before.
sweets.workspace(1, { monitor = "DP-4" })
sweets.workspace(2, { monitor = "DP-2" })
sweets.workspace(3, { monitor = "DP-1" })Options
| Key | Type | Default | Description |
|---|---|---|---|
monitor | string | current | Output name that owns the workspace |
number is 1–10. When a pinned monitor is connected, switching to that
workspace selects the owning monitor and shows the workspace there. Moving a
window to a pinned workspace moves it to that monitor's copy of the workspace.
If the configured monitor is disconnected, Sweets falls back to the current
output so the workspace remains reachable. A pin behaves the same in both
workspace_mode values; it just fixes that workspace's home monitor.
Limiting the number of workspaces
Sweets always has ten workspaces internally. To use fewer, set
workspace_count in
sweets.general; workspaces above the limit become unreachable and are hidden
from status bars. Pinning a workspace above the limit has no effect while the
limit is in place.