From 7a35e7c2175651b2901cc4050aff360b3c6441ec Mon Sep 17 00:00:00 2001 From: Francesco Abbate Date: Sun, 21 Feb 2021 09:43:47 +0100 Subject: [PATCH] Don't show partially hidden icons in toolbar --- data/plugins/toolbarview.lua | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/data/plugins/toolbarview.lua b/data/plugins/toolbarview.lua index 20b8ae87..60d348d3 100644 --- a/data/plugins/toolbarview.lua +++ b/data/plugins/toolbarview.lua @@ -57,7 +57,7 @@ function ToolbarView:each_item() if index <= #toolbar_commands then local dx = style.padding.x + (icon_w + toolbar_spacing) * (index - 1) local dy = style.padding.y - if dx >= self.size.x then return end + if dx + icon_w > self.size.x then return end return toolbar_commands[index], ox + dx, oy + dy, icon_w, icon_h end end