From 9d11d13085874c611fcefc12fc4890756bc5fdf9 Mon Sep 17 00:00:00 2001 From: Tim Culverhouse Date: Thu, 16 May 2024 07:00:41 -0500 Subject: [PATCH] window: remove deprecated code, add printSegment --- src/Window.zig | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/Window.zig b/src/Window.zig index 6249c95..54b3120 100644 --- a/src/Window.zig +++ b/src/Window.zig @@ -446,9 +446,9 @@ pub fn print(self: Window, segments: []const Segment, opts: PrintOptions) !Print return false; } -/// Deprecated. use print instead -pub fn wrap(self: Window, segments: []const Segment) !void { - _ = try self.print(segments, .{ .wrap = .word }); +/// print a single segment. This is just a shortcut for print(&.{segment}, opts) +pub fn printSegment(self: Window, segment: Segment, opts: PrintOptions) !PrintResult { + return self.print(&.{segment}, opts); } /// scrolls the window down one row (IE inserts a blank row at the bottom of the