From 1fc175627f3afe938be0b5daa6a864b281725fec Mon Sep 17 00:00:00 2001 From: Rudy Dellomas III Date: Tue, 23 Apr 2024 15:33:13 +1000 Subject: lua: Report viewport lines and bytes in one table This will break all plugins which currently use Win.viewport. --- lua/vis-std.lua | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'lua') diff --git a/lua/vis-std.lua b/lua/vis-std.lua index 5dd13eb..1fe93a9 100644 --- a/lua/vis-std.lua +++ b/lua/vis-std.lua @@ -54,7 +54,7 @@ vis.events.subscribe(vis.events.WIN_HIGHLIGHT, function(win) if not lexer then return end -- TODO: improve heuristic for initial style - local viewport = win.viewport + local viewport = win.viewport.bytes if not viewport then return end local horizon_max = win.horizon or 32768 local horizon = viewport.start < horizon_max and viewport.start or horizon_max -- cgit v1.2.3