diff options
Diffstat (limited to 'plugins/minimap.lua')
-rw-r--r-- | plugins/minimap.lua | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/plugins/minimap.lua b/plugins/minimap.lua index c9e1c54..3f4a2a2 100644 --- a/plugins/minimap.lua +++ b/plugins/minimap.lua @@ -289,6 +289,13 @@ DocView.draw_scrollbar = function(self) end +local prev_update = DocView.update +DocView.update = function (self) + if not config.plugins.minimap.enabled then return prev_update(self) end + self.size.x = self.size.x - config.plugins.minimap.width * SCALE + return prev_update(self) +end + command.add(nil, { ["minimap:toggle-visibility"] = function() config.plugins.minimap.enabled = not config.plugins.minimap.enabled |