FULE-0.3.1: Functional UI Layout Engine
Copyright(c) Paul Schnapp 2023
LicenseBSD3
MaintainerPaul Schnapp <paul.schnapp@gmail.com>
Safe HaskellSafe-Inferred
LanguageHaskell2010

FULE.Container

Description

A typeclass for creating containers of visual content.

Synopsis

Documentation

class Monad m => Container c k m where Source #

A typeclass for laying-out a container of type c that holds content of type k.

You'll need to have the FlexibleInstances and MultiParamTypeClasses language extensions enabled to use this and you may wish to have your instance use the {-# OVERLAPS #-} or {-# OVERLAPPING #-} pragmas.

Methods

minWidth :: c -> Proxy k -> m (Maybe Int) Source #

Get the minimum width required for display of the container c.

minHeight :: c -> Proxy k -> m (Maybe Int) Source #

Get the minimum height required for display of the container c.

addToLayout :: c -> Proxy k -> Bounds -> RenderGroup -> LayoutOp k m () Source #

Add the container c and its contents k to a LayoutDesign.

Instances

Instances details
Component k m => Container k k m Source # 
Instance details

Defined in FULE.Container

Methods

minWidth :: k -> Proxy k -> m (Maybe Int) Source #

minHeight :: k -> Proxy k -> m (Maybe Int) Source #

addToLayout :: k -> Proxy k -> Bounds -> RenderGroup -> LayoutOp k m () Source #

Container c k m => Container (Clipped c) k m Source # 
Instance details

Defined in FULE.Container.Clipped

Methods

minWidth :: Clipped c -> Proxy k -> m (Maybe Int) Source #

minHeight :: Clipped c -> Proxy k -> m (Maybe Int) Source #

addToLayout :: Clipped c -> Proxy k -> Bounds -> RenderGroup -> LayoutOp k m () Source #

Container c k m => Container (Padded c) k m Source # 
Instance details

Defined in FULE.Container.Padded

Methods

minWidth :: Padded c -> Proxy k -> m (Maybe Int) Source #

minHeight :: Padded c -> Proxy k -> m (Maybe Int) Source #

addToLayout :: Padded c -> Proxy k -> Bounds -> RenderGroup -> LayoutOp k m () Source #

Container c k m => Container (Positioned c) k m Source # 
Instance details

Defined in FULE.Container.Positioned

Container c k m => Container (Sized c) k m Source # 
Instance details

Defined in FULE.Container.Sized

Methods

minWidth :: Sized c -> Proxy k -> m (Maybe Int) Source #

minHeight :: Sized c -> Proxy k -> m (Maybe Int) Source #

addToLayout :: Sized c -> Proxy k -> Bounds -> RenderGroup -> LayoutOp k m () Source #

Container c k m => Container (Unreckoned c) k m Source # 
Instance details

Defined in FULE.Container.Unreckoned

Monad m => Container (ArrayedM m k) k m Source # 
Instance details

Defined in FULE.Container.Arrayed

Methods

minWidth :: ArrayedM m k -> Proxy k -> m (Maybe Int) Source #

minHeight :: ArrayedM m k -> Proxy k -> m (Maybe Int) Source #

addToLayout :: ArrayedM m k -> Proxy k -> Bounds -> RenderGroup -> LayoutOp k m () Source #

Monad m => Container (GridM m k) k m Source # 
Instance details

Defined in FULE.Container.Grid

Methods

minWidth :: GridM m k -> Proxy k -> m (Maybe Int) Source #

minHeight :: GridM m k -> Proxy k -> m (Maybe Int) Source #

addToLayout :: GridM m k -> Proxy k -> Bounds -> RenderGroup -> LayoutOp k m () Source #

Monad m => Container (ItemM m k) k m Source # 
Instance details

Defined in FULE.Container.Item

Methods

minWidth :: ItemM m k -> Proxy k -> m (Maybe Int) Source #

minHeight :: ItemM m k -> Proxy k -> m (Maybe Int) Source #

addToLayout :: ItemM m k -> Proxy k -> Bounds -> RenderGroup -> LayoutOp k m () Source #

Monad m => Container (LayeredM m k) k m Source # 
Instance details

Defined in FULE.Container.Layered

Methods

minWidth :: LayeredM m k -> Proxy k -> m (Maybe Int) Source #

minHeight :: LayeredM m k -> Proxy k -> m (Maybe Int) Source #

addToLayout :: LayeredM m k -> Proxy k -> Bounds -> RenderGroup -> LayoutOp k m () Source #

(Container s b m, Container u b m) => Container (Divided s b u) b m Source # 
Instance details

Defined in FULE.Container.Divided

Methods

minWidth :: Divided s b u -> Proxy b -> m (Maybe Int) Source #

minHeight :: Divided s b u -> Proxy b -> m (Maybe Int) Source #

addToLayout :: Divided s b u -> Proxy b -> Bounds -> RenderGroup -> LayoutOp b m () Source #