helium/hooks/setMinSize.lua
Elmārs Āboliņš f85b19c118 Documentation
2021-06-22 14:12:19 +03:00

8 lines
335 B
Lua

local path = string.sub(..., 1, string.len(...) - string.len(".hooks.setMinSize"))
local stack = require(path..'.core.stack')
--Sets the computed/minimum size of an element to be used with layout calculations and rendering
return function(w, h)
local currentStack = stack.getContext()
currentStack.element:setMinSize(w, h)
end