summaryrefslogtreecommitdiff
path: root/src/config.zig
diff options
context:
space:
mode:
Diffstat (limited to 'src/config.zig')
-rw-r--r--src/config.zig12
1 files changed, 11 insertions, 1 deletions
diff --git a/src/config.zig b/src/config.zig
index e0fcab48..b7662f1a 100644
--- a/src/config.zig
+++ b/src/config.zig
@@ -26,6 +26,7 @@ const undecided: []const u8 = "<undecided>";
// null means word/chord-only. Every enabled builtin must explicitly choose a path.
pub const leader_path = paths: {
+ @setEvalBranchQuota(10_000); // a check per builtin, and they grow
var table = std.EnumArray(Builtin, ?[]const u8).initDefault(@as(?[]const u8, undecided), .{
.Help = &[_]u8{leader_help},
.Hover = "lk",
@@ -75,6 +76,7 @@ pub const leader_path = paths: {
.Joincol = "cj",
.Placement = "cp",
.BootShell = null,
+ .LookWord = null,
.Debug = "td",
.Msg = null,
.Colors = "tc",
@@ -707,12 +709,17 @@ pub const Runtime = struct {
/// has typed into stands: `keep` leaves the shell, `replace` closes it
/// (exec.evictLonePristineTty).
boot_shell: BootShell = .keep,
+ /// A plain word looked at in a pane: `search`, acme's look3, selects its
+ /// next place in that pane, wrapping; `list`, what pardes did before,
+ /// lists every place in a +Search pane (look.zig, lookWord).
+ look_word: LookWord = .search,
pub const ShaderAnimation = enum { off, on, always };
pub const Placement = enum { acme, pardes };
pub const BootShell = enum { keep, replace };
+ pub const LookWord = enum { search, list };
/// A setting that is one of a few words, each an enum field of Runtime.
- pub const Choice = enum { placement, boot_shell };
+ pub const Choice = enum { placement, boot_shell, look_word };
/// shadow: a soft drop shadow. rim: a light hairline along the top of
/// the focused pane's tag rows. auto: a shadow on a light page; on a
@@ -963,6 +970,7 @@ pub const Runtime = struct {
.{ .word = "ShaderAnimation", .action = .shader_animation, .availability = .scene_shaders },
.{ .word = "Placement", .action = .{ .choice = .placement } },
.{ .word = "BootShell", .action = .{ .choice = .boot_shell } },
+ .{ .word = "LookWord", .action = .{ .choice = .look_word } },
};
pub fn find(name: []const u8) ?Setting {
@@ -1636,6 +1644,7 @@ pub const Runtime = struct {
.choice => |which| switch (which) {
.placement => "pardes",
.boot_shell => "replace",
+ .look_word => "list",
},
.lift => "rim",
.motion => "playful",
@@ -1694,6 +1703,7 @@ pub const Runtime = struct {
.choice => |which| switch (which) {
.placement => "Placement pardes\n",
.boot_shell => "BootShell replace\n",
+ .look_word => "LookWord list\n",
},
.lift => "Lift rim\n",
.motion => "Motion playful\n",