Ensure treeview is large enough to show toolbar

This commit is contained in:
Francesco Abbate committed 2021-02-27 19:39:56 +01:00
1 parent e861ea1d66
commit 4d320c1946
2 files changed
+11 -2

No files matched your search

+7
View File
@@ -64,6 +64,13 @@ function ToolbarView:each_item()
end
function ToolbarView:get_min_width()
local icon_w = style.icon_big_font:get_width("D")
local space = icon_w / 2
return 2 * style.padding.x + (icon_w + space) * #toolbar_commands - space
end
function ToolbarView:draw()
self:draw_background(style.background2)