Kirigami is a rectangle-layout library for lua,
but mainly for use with love2d.
It is named after Japanese kirigami.
Kirigami was inspired by NLay by MikuAuahDark.
It works great with Inky!
Honestly, the best way to learn is just from doing.
Clone this repo and have a play around with the example in main.lua.
See API.md for a basic API reference.
Or just look through the source code :)
function love.draw()
local screen = kirigami.Region(0,0, love.graphics.getDimensions())
drawRegion(screen)
local header, main = screen:splitVertical(0.2, 0.8)
namedRegion("header", header)
local left, right = main:splitHorizontal(0.4, 0.6)
namedRegion("left", left)
local padded_right = right:pad(20) -- pad by 20 pixels
namedRegion("padded_right", padded_right)
end


