Skip to content

Add F1-F5 as default tab-switching shortcuts - #67

Draft
HoneyHazard wants to merge 1 commit into
tsowell:mainfrom
HoneyHazard:fkey-tab-shortcuts
Draft

Add F1-F5 as default tab-switching shortcuts#67
HoneyHazard wants to merge 1 commit into
tsowell:mainfrom
HoneyHazard:fkey-tab-shortcuts

Conversation

@HoneyHazard

@HoneyHazard HoneyHazard commented Aug 5, 2026

Copy link
Copy Markdown

⚠️ Full Disclosure: Drafted with AI assistance (Claude); reviewed by me briefly. I am neither a RUST developer nor pipewire expert. If I should stop making these PRs into your wonderful project, please let me know. ⚠️

That being said, I hope these can be helpful and useful additions that users could appreciate.


With 5 possible tabs (Playback/Recording/Output/Input/Configuration), cycling one at a time with H/L or Tab/Shift+Tab is slow if you want to jump straight to a specific one.

F4 pressed once, jumping straight from Playback to the Input Devices tab

This has been asked for before - #38, closed by the reporter themselves once they found the workaround, not because it was rejected. SelectTab(N) already exists and already works exactly for this, but has no default binding, so users have to know to add it themselves via the README's own "Use F-keys to select tabs" customization example.

Makes that the default instead:

  • F1-F5 bound to SelectTab(0..4).
  • SelectTab already silently no-ops on an out-of-range index (see Action::handle), so binding all 5 unconditionally is safe even with tabs configured to fewer than 5 entries - unused F-keys just do nothing rather than erroring.
  • Updated the README's keybinding table and its now-redundant "F-keys to select tabs" example, rewritten to show remapping F-keys to something else (e.g. Alt+1..5) for anyone whose terminal/WM intercepts function keys, since the original example no longer demonstrates anything you don't already get by default.

New default keybindings:

keybindings = [
 # Select a tab by position (Playback/Recording/Output/Input/Configuration,
 # or whatever order/subset `tabs` is set to)
 { key = { F = 1 }, action = { SelectTab = 0 } },
 { key = { F = 2 }, action = { SelectTab = 1 } },
 { key = { F = 3 }, action = { SelectTab = 2 } },
 { key = { F = 4 }, action = { SelectTab = 3 } },
 { key = { F = 5 }, action = { SelectTab = 4 } },
]

Like every other default binding, these are fully overridable/removable from the config file.

Tested:

  • cargo test: 145/145 passing, including a new test asserting all 5 F-key defaults resolve to the expected SelectTab index
  • cargo fmt --check / cargo clippy -- -D warnings / cargo doc (matching this repo's CI): all clean

Drafted with AI assistance (Claude); reviewed by me before opening. Left as a draft while I finish going through it - not requesting review yet.

With 5 possible tabs (Playback/Recording/Output/Input/Configuration),
cycling one at a time with H/L or Tab/Shift+Tab is slow if you want to
jump straight to a specific one. This has been asked for before
(tsowell#38 - closed by the reporter themselves once they found the
workaround, not because it was rejected): SelectTab(N) already exists
and already works exactly for this, but has no default binding, so
users have to know to add it themselves via the README's own
"Use F-keys to select tabs" customization example.

Makes that the default instead: F1-F5 bound to SelectTab(0..4).
SelectTab already silently no-ops on an out-of-range index (see
Action::handle), so binding all 5 unconditionally is safe even with
`tabs` configured to fewer than 5 entries - unused F-keys just do
nothing rather than erroring.

Updated the README's keybinding table and its now-redundant "F-keys to
select tabs" example, which is rewritten to show remapping F-keys to
something else (e.g. Alt+1..5) for anyone whose terminal/WM intercepts
function keys, since the original example no longer demonstrates
anything you don't already get by default.

Tested: cargo test (145/145, including a new test asserting all 5
F-key defaults resolve to the expected SelectTab index), cargo fmt
--check / cargo clippy -- -D warnings / cargo doc (matching wiremix's
CI) all clean.
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