summaryrefslogtreecommitdiff
path: root/src/config.zig
diff options
context:
space:
mode:
authorGabriel Schneider <[email protected]>2026-10-21 21:42:33 -0300
committerGabriel Schneider <[email protected]>2026-10-22 10:03:15 -0300
commit3643635640e97eb2e43730d58fcc46214e21851e (patch)
treea096772d1709492a624bb90f06fdc98a60d142ac /src/config.zig
parent4e89db185fa4e3bfe4358d2da3b76fad0cc7e547 (diff)
downloadpardes-3643635640e97eb2e43730d58fcc46214e21851e.tar.gz
pardes-3643635640e97eb2e43730d58fcc46214e21851e.zip
Window mode: pick the pane to focus with an outline or a label
Diffstat (limited to 'src/config.zig')
-rw-r--r--src/config.zig14
1 files changed, 8 insertions, 6 deletions
diff --git a/src/config.zig b/src/config.zig
index f3cc0948..a92aabb6 100644
--- a/src/config.zig
+++ b/src/config.zig
@@ -119,10 +119,11 @@ pub const leader_path = paths: {
.Ascii = "ta",
.Dump = "sd",
.Restore = "sr",
- .Left = "wh",
- .Down = "wj",
- .Up = "wk",
- .Right = "wl",
+ .Left = null,
+ .Down = null,
+ .Up = null,
+ .Right = null,
+ .Window = "w",
.Back = "jo",
.Forward = "ji",
.Last = "jj",
@@ -212,7 +213,7 @@ pub const leader_path = paths: {
test "Space-k is unbound while Exit, Kill and other k chords remain available" {
try std.testing.expect(leader_path.get(.Kill) == null);
try std.testing.expectEqualStrings("q", leader_path.get(.Exit).?);
- try std.testing.expectEqualStrings("wk", leader_path.get(.Up).?);
+ try std.testing.expectEqualStrings("w", leader_path.get(.Window).?);
try std.testing.expectEqualStrings("lk", leader_path.get(.Hover).?);
try std.testing.expectEqualStrings("d", leader_path.get(.Del).?);
for (pardes.builtin_rows) |row| if (row.cmd == .Kill) {
@@ -264,7 +265,8 @@ pub const select_button: Mouse.Button = .left;
pub const look_cmd: Builtin = .Look;
pub const exec_cmd: Builtin = .Exec;
-// Ctrl-w remains available when a terminal owns printable keys.
+// Ctrl-w: window mode (layout.windowKey), as SPC w; on a header it
+// prefixes h/j/k/l, a move between the headers.
pub const window_prefix: []const Chord = &.{.{ .cp = 'w', .ctrl = true }};
pub const window_keys = [_]struct { letter: Chord, arrow: Chord, cmd: Builtin }{