summaryrefslogtreecommitdiff
path: root/core/Band.zig
diff options
context:
space:
mode:
Diffstat (limited to 'core/Band.zig')
-rw-r--r--core/Band.zig9
1 files changed, 7 insertions, 2 deletions
diff --git a/core/Band.zig b/core/Band.zig
index 8ee5c9f0..0424315a 100644
--- a/core/Band.zig
+++ b/core/Band.zig
@@ -40,6 +40,9 @@ pub const Row = struct {
on: bool = false,
/// Its first `key` bytes are a key: the key ink, bold.
key: u8 = 0,
+ /// Its first `kind` bytes are a symbol's kind mark (`t`, `f`, `m`):
+ /// the keyword's ink (UX DESIGN N4).
+ kind: u8 = 0,
/// Its first `chord` bytes are a chord (Help's `SPC h t`): the key ink
/// at the text's weight.
chord: u8 = 0,
@@ -53,8 +56,9 @@ pub const Row = struct {
index: u16 = 0,
/// Marked in a picker's list: `•` before it.
mark: bool = false,
- /// Its first `pre` bytes are a place (`file:line`, `@p3`): the name's
- /// tint; the `faint` bytes after them dimmed (a path's directory).
+ /// Its first `pre` bytes are a place (`file:line`, `@p3`) or a kind
+ /// mark: the name's tint; the `faint` bytes after them dimmed (a path's
+ /// directory, a symbol's qualifier).
pre: u16 = 0,
faint: u16 = 0,
/// Said at the row's right end in the dim ink, two cells off its text
@@ -644,6 +648,7 @@ fn cutRow(arena: std.mem.Allocator, tab: u16, row: Row, room: u16) !Row {
fit.text = try std.mem.concat(arena, u8, &.{ row.text[0..cut], if (room > 0) "…" else "" });
for (row.marks) |m| if (m < cut) try marks.append(arena, m);
fit.key = @intCast(@min(row.key, cut));
+ fit.kind = @intCast(@min(row.kind, cut));
fit.pre = @intCast(@min(row.pre, cut));
fit.faint = @intCast(@min(row.faint, cut -| fit.pre));
}