|
|
@ -2,9 +2,6 @@ local BASE = (...):gsub('columns', '')
|
|
|
|
|
|
|
|
|
|
|
|
local Layout = require(BASE..'layout')
|
|
|
|
local Layout = require(BASE..'layout')
|
|
|
|
|
|
|
|
|
|
|
|
local Columns = setmetatable({}, Layout)
|
|
|
|
|
|
|
|
Columns.__index = Columns
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
-- Advance position to next column,
|
|
|
|
-- Advance position to next column,
|
|
|
|
-- given current position, widget dimensions and padding.
|
|
|
|
-- given current position, widget dimensions and padding.
|
|
|
@ -12,8 +9,8 @@ local function columnadvance(x,y, ww,wh, padding)
|
|
|
|
return x + ww + padding, y
|
|
|
|
return x + ww + padding, y
|
|
|
|
end
|
|
|
|
end
|
|
|
|
|
|
|
|
|
|
|
|
function Columns.new(args)
|
|
|
|
function Columns(args)
|
|
|
|
local self = setmetatable(Layout.new(args), Columns)
|
|
|
|
local self = Layout.new(args)
|
|
|
|
|
|
|
|
|
|
|
|
self.advance = columnadvance
|
|
|
|
self.advance = columnadvance
|
|
|
|
self.prev = 'left'
|
|
|
|
self.prev = 'left'
|
|
|
|