monomer-1.6.0.1: A GUI library for writing native Haskell applications.
Copyright(c) 2018 Francisco Vallarino
LicenseBSD-3-Clause (see the LICENSE file)
Maintainerfjvallarino@gmail.com
Stabilityexperimental
Portabilitynon-portable
Safe HaskellSafe-Inferred
LanguageHaskell2010

Monomer.Widgets.Containers.Grid

Description

Layout container which distributes space evenly along the main axis. For the secondary axis children will receive as much space as available for the grid widget itself.

In the same way as with hstack and vstack, hgrid and vgrid can be combined to create more complex layouts.

The hgrid widget requests maxWidth * elements as its width, and the max height as its height. The inverse happens for vgrid.

hgrid [
    label "Third 1",
    label "Third 2",
    label "Third 3"
  ]
Synopsis

Configuration

data GridCfg Source #

Configuration options for grid:

Constructors

hgrid Source #

Arguments

:: Traversable t 
=> t (WidgetNode s e)

The list of items.

-> WidgetNode s e

The created grid.

Creates a grid of items with the same width.

hgrid_ Source #

Arguments

:: Traversable t 
=> [GridCfg]

The config options.

-> t (WidgetNode s e)

The list of items.

-> WidgetNode s e

The created grid.

Creates a grid of items with the same width. Accepts config.

vgrid Source #

Arguments

:: Traversable t 
=> t (WidgetNode s e)

The list of items.

-> WidgetNode s e

The created grid.

Creates a grid of items with the same height.

vgrid_ Source #

Arguments

:: Traversable t 
=> [GridCfg]

The config options.

-> t (WidgetNode s e)

The list of items.

-> WidgetNode s e

The created grid.

Creates a grid of items with the same height. Accepts config.