Merge luaML.love

This commit is contained in:
Kartik K. Agaram 2023-06-21 22:19:06 -07:00
commit 29acb39e0c
1 changed files with 2 additions and 2 deletions

View File

@ -24,7 +24,7 @@ compute_layout = function(node, x,y, nodes_to_render, preserve_screen_top_of_cur
else
node.w = 0
for i,s in ipairs(node.data) do
local width = love.graphics.getFont():getWidth(s)
local width = love.graphics.getFont():getWidth(s)/Viewport.zoom
if node.w < width then node.w = width end
end
end
@ -33,7 +33,7 @@ compute_layout = function(node, x,y, nodes_to_render, preserve_screen_top_of_cur
else
update_editor_box(node, preserve_screen_top_of_cursor_node)
end
node.h = box_height(node)
node.h = box_height(node)
table.insert(nodes_to_render, node)
for _,n in ipairs(pending_nodes) do
n.w = node.w