diff options
Diffstat (limited to 'src/body_layer.zig')
| -rw-r--r-- | src/body_layer.zig | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/body_layer.zig b/src/body_layer.zig index 04c84b62..ab8a888a 100644 --- a/src/body_layer.zig +++ b/src/body_layer.zig @@ -685,7 +685,7 @@ fn tagTintRange(pane: *const Pane, tag: []const u8, prefix_len: usize) ?struct { if (pane.prompt == .name) pane.input.own orelse file.path else file.path else if (pane.image) |state| blk: { // Image tags put renderer controls before the path. - start = prefix_len -| state.path.len; + start = std.mem.lastIndexOf(u8, tag[0..prefix_len], state.path) orelse return null; break :blk state.path; } else if (comptime pdf_enabled) blk: { break :blk if (pane.pdf) |state| state.path else return null; |
