Closed togfoxy closed 3 years ago
Hi @togfoxy. There are two ways to do this as far as i can think of right now:
\n
occurences.First one would be costly as it will be calculated per frame. Second one will allow for more control and users can even use this to easily make buttons with higher height.
Fixed in 84fc55e4a7bfbd09482caad43c7a91196401156e
here's an example of how to use it:
local str = "dsadsadsadasdasdsadsa\ndasdsadasdsadsadsdsadas" --2 lines
function love.update(dt)
Slab.Update(dt)
Slab.BeginWindow("test", {Title = "Test"})
if Slab.Button(str, {
VLines = 2
}) then
end
Slab.EndWindow()
end
Wrapping button text across multiple lines then doing a corresponding auto-size would be handy.