Skip to content

feat: add column width preset cycling for scrolling layout#350

Open
qeude wants to merge 1 commit intoacsandmann:mainfrom
qeude:feat/column-width-presets
Open

feat: add column width preset cycling for scrolling layout#350
qeude wants to merge 1 commit intoacsandmann:mainfrom
qeude:feat/column-width-presets

Conversation

@qeude
Copy link
Copy Markdown

@qeude qeude commented May 5, 2026

This PR adds support for cycling the focused column through configurable width presets in the scrolling layout.

New commands

  • resize_window_preset_next
  • resize_window_preset_prev

New configuration

  • layout.scrolling.column_width_presets — a list of width fractions (0.01.0) to cycle through.

Behavior

When a window is fullscreen, the first preset is applied (or last when cycling backwards). Presets wrap around at the end of the list. The effective column width is updated via the existing width_offset mechanism, keeping changes local to the selected column.

Example

With column_width_ratio = 0.7 and presets = [0.33, 0.50, 0.66, 0.99]:

Next:

0.7 → 0.99 → 0.33 → 0.50 → 0.66 → 0.99

Previous:

0.7 → 0.66 → 0.50 → 0.33 → 0.99 → 0.66

Tests

Includes unit tests for forward/backward cycling, wrapping, and fullscreen exit behavior.

Adds resize_window_preset_next and resize_window_preset_prev commands

that cycle the focused column through configurable width presets.

New config option: layout.scrolling.column_width_presets
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant