aboutsummaryrefslogtreecommitdiff
path: root/vendor/libghostty-vt/src/termio/Termio.zig
diff options
context:
space:
mode:
Diffstat (limited to 'vendor/libghostty-vt/src/termio/Termio.zig')
-rw-r--r--vendor/libghostty-vt/src/termio/Termio.zig26
1 files changed, 5 insertions, 21 deletions
diff --git a/vendor/libghostty-vt/src/termio/Termio.zig b/vendor/libghostty-vt/src/termio/Termio.zig
index 75ccb94b..1d1bfe25 100644
--- a/vendor/libghostty-vt/src/termio/Termio.zig
+++ b/vendor/libghostty-vt/src/termio/Termio.zig
@@ -255,21 +255,12 @@ pub fn init(self: *Termio, alloc: Allocator, opts: termio.Options) !void {
},
.palette = .init(opts.config.palette),
},
+ .kitty_image_storage_limit = opts.config.image_storage_limit,
+ .kitty_image_loading_limits = .all,
};
});
errdefer term.deinit(alloc);
- // Set the image size limits
- var it = term.screens.all.iterator();
- while (it.next()) |entry| {
- const screen: *terminalpkg.Screen = entry.value.*;
- try screen.kitty_images.setLimit(
- alloc,
- screen,
- opts.config.image_storage_limit,
- );
- }
-
// Set our default cursor style
term.screens.active.cursor.cursor_style = opts.config.cursor_style;
@@ -463,16 +454,9 @@ pub fn changeConfig(self: *Termio, td: *ThreadData, config: *DerivedConfig) !voi
break :cursor color.toTerminalRGB() orelse break :cursor null;
};
- // Set the image size limits
- var it = self.terminal.screens.all.iterator();
- while (it.next()) |entry| {
- const screen: *terminalpkg.Screen = entry.value.*;
- try screen.kitty_images.setLimit(
- self.alloc,
- screen,
- config.image_storage_limit,
- );
- }
+ // Set the image limits
+ try self.terminal.setKittyGraphicsSizeLimit(self.alloc, config.image_storage_limit);
+ self.terminal.setKittyGraphicsLoadingLimits(.all);
}
/// Resize the terminal.