Add centered workspace thumbnails to overview

Render a tinted, scrollable workspace strip with live thumbnails, output-scaled font labels and a subtle selected-workspace outline. Keep the window grid background-free and support workspace selection without exiting overview.

Animate strip opacity independently with precise fade tolerances and continuous reversal, and expose toggle-overview through feresectl.
This commit is contained in:
Samuel Onoja committed 2026-09-26 15:13:13 +01:00
1 parent 0709484efb
commit b422448d88
11 files changed
+775 -52

No files matched your search

+12 -3
View File
@@ -48,8 +48,8 @@ fn parse_args(args: impl IntoIterator<Item = String>) -> Result<(String, Value),
json!({ "index": index })
}
"toggle-floating" | "toggle-fullscreen" | "toggle-maximized" | "toggle-layout"
| "cycle-column-width" | "center-column" | "consume" | "expel" | "close"
| "get-focused-window" | "get-workspaces" | "get-outputs" | "exit" => {
| "toggle-overview" | "cycle-column-width" | "center-column" | "consume" | "expel"
| "close" | "get-focused-window" | "get-workspaces" | "get-outputs" | "exit" => {
if !positional.is_empty() {
return Err(format!("{command} does not accept arguments"));
}
@@ -78,13 +78,22 @@ fn socket_path() -> Result<PathBuf, io::Error> {
}
fn usage() -> String {
"usage: feresectl <focus|move|resize> <direction>\n feresectl <workspace|move-to-workspace> <index>\n feresectl <toggle-floating|toggle-maximized|toggle-fullscreen|toggle-layout>\n feresectl <cycle-column-width|center-column|consume|expel|close|exit>\n feresectl <get-focused-window|get-workspaces|get-outputs>".to_owned()
"usage: feresectl <focus|move|resize> <direction>\n feresectl <workspace|move-to-workspace> <index>\n feresectl <toggle-floating|toggle-maximized|toggle-fullscreen|toggle-layout|toggle-overview>\n feresectl <cycle-column-width|center-column|consume|expel|close|exit>\n feresectl <get-focused-window|get-workspaces|get-outputs>".to_owned()
}
#[cfg(test)]
mod tests {
use super::*;
#[test]
fn overview_toggle_accepts_no_arguments() {
assert_eq!(
parse_args(["toggle-overview".into()]).unwrap(),
("toggle-overview".into(), json!({}))
);
assert!(parse_args(["toggle-overview".into(), "extra".into()]).is_err());
}
#[test]
fn parses_direction_and_workspace_commands() {
assert_eq!(