diff options
| author | Gabriel Schneider <[email protected]> | 2026-10-01 13:30:42 -0300 |
|---|---|---|
| committer | Gabriel Schneider <[email protected]> | 2026-10-01 13:44:34 -0300 |
| commit | bac1c62c1905a5ce11a6b630d556bc349041628b (patch) | |
| tree | ea3e154923ca5f36adb3e0e65920a17e464ca55f /src/image.zig | |
| parent | 7c84ebe66494c3b05dcd23f198b5c5f4189cb708 (diff) | |
| download | pardes-bac1c62c1905a5ce11a6b630d556bc349041628b.tar.gz pardes-bac1c62c1905a5ce11a6b630d556bc349041628b.zip | |
An image's or a terminal's tag says petscii:on when it is drawn as glyph art, as it always is with no graphics; Petscii on|off still chooses for when there are
The images and tagbottomimage goldens are re-recorded for the word.
Co-Authored-By: Claude Opus 5.5 <[email protected]>
Diffstat (limited to 'src/image.zig')
| -rw-r--r-- | src/image.zig | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/image.zig b/src/image.zig index 4a8bcdf4..72520ad6 100644 --- a/src/image.zig +++ b/src/image.zig @@ -919,13 +919,15 @@ pub fn toggleAscii(state: *State) void { /// Image renderer choices are pane-local, not global Config values. Keep them /// queryable where they apply: the live tag beside the image's path. -pub fn tagPrefix(arena: std.mem.Allocator, state: *const State) ![]u8 { +/// `glyphs`: whether the picture is drawn as glyph art, which a terminal +/// with no graphics does whatever `glyph_art` says. +pub fn tagPrefix(arena: std.mem.Allocator, state: *const State, glyphs: bool) ![]u8 { return std.fmt.allocPrint( arena, "{s} petscii:{s} palette:{s} ascii:{s} {s}", .{ config.tag_image, - if (state.glyph_art) "on" else "off", + if (glyphs) "on" else "off", @tagName(state.pmode), if (state.ascii) "on" else "off", state.path, |
