module Graphics.Layout.Grid where
import Data.Text (Text)
import Graphics.Layout.Box
data Grid n = Grid {
rows :: [(Name, Either n Double)],
columns :: [(Name, Either n Double)],
gap :: Size n,
gridBox :: PaddedBox n
}
data GridItem n = GridItem {
startRow :: Int, endRow :: Int, startCol :: Int, endCol :: Int,
gridItemBox :: PaddedBox n
}
type Name = Text
{-sizeBoundGrid :: Grid Length -> [GridItem Length] -> Grid Length
sizeGrid :: PaddedBox Double -> Grid Length -> Grid Double
sizeGridItem :: Grid Length -> GridItem Length -> Grid Double
positionGrid :: Grid Double -> [GridItem Double] -> [Size]
layoutGrid :: PaddedBox Double -> Grid Length -> [GridItem Length] -> Bool ->
[(Grid Double, [(Size, GridItem Double)])]-}