Versions in this module Expand all Collapse all v0 v0.1.2 Jan 25, 2021 v0.1.1 Jan 25, 2021 Changes in this version + const AxisBoth + const AxisHorizontal + const AxisNone + const AxisVertical + func RunWindow(s screen.Screen, root node.Node, opts *RunWindowOptions) error + func WithLayoutData(n node.Node, layoutData interface{}) node.Node + type Axis uint8 + func (a Axis) Horizontal() bool + func (a Axis) Vertical() bool + type Flow struct + Axis Axis + func NewFlow(a Axis, children ...node.Node) *Flow + func (w *Flow) Layout(t *theme.Theme) + func (w *Flow) Measure(t *theme.Theme, widthHint, heightHint int) + type FlowLayoutData struct + AlongWeight int + ExpandAcross bool + ExpandAlong bool + ShrinkAcross bool + ShrinkAlong bool + type Image struct + Src image.Image + SrcRect image.Rectangle + func NewImage(src image.Image, srcRect image.Rectangle) *Image + func (w *Image) Measure(t *theme.Theme, widthHint, heightHint int) + func (w *Image) PaintBase(ctx *node.PaintBaseContext, origin image.Point) error + type Label struct + Text string + ThemeColor theme.Color + func NewLabel(text string) *Label + func (w *Label) Measure(t *theme.Theme, widthHint, heightHint int) + func (w *Label) PaintBase(ctx *node.PaintBaseContext, origin image.Point) error + type Padder struct + Axis Axis + Margin unit.Value + func NewPadder(a Axis, margin unit.Value, inner node.Node) *Padder + func (w *Padder) Layout(t *theme.Theme) + func (w *Padder) Measure(t *theme.Theme, widthHint, heightHint int) + type RunWindowOptions struct + NewWindowOptions screen.NewWindowOptions + Theme theme.Theme + type Sheet struct + func NewSheet(inner node.Node) *Sheet + func (w *Sheet) OnChildMarked(child node.Node, newMarks node.Marks) + func (w *Sheet) OnLifecycleEvent(e lifecycle.Event) + func (w *Sheet) Paint(ctx *node.PaintContext, origin image.Point) (retErr error) + func (w *Sheet) PaintBase(ctx *node.PaintBaseContext, origin image.Point) error + type Sizer struct + NaturalHeight unit.Value + NaturalWidth unit.Value + func NewSizer(naturalWidth, naturalHeight unit.Value, inner node.Node) *Sizer + func (w *Sizer) Measure(t *theme.Theme, widthHint, heightHint int) + type Space struct + func NewSpace() *Space + type Text struct + func NewText(text string) *Text + func (w *Text) Layout(t *theme.Theme) + func (w *Text) Measure(t *theme.Theme, widthHint, heightHint int) + func (w *Text) Paint(ctx *node.PaintContext, origin image.Point) error + func (w *Text) PaintBase(ctx *node.PaintBaseContext, origin image.Point) error + type Uniform struct + ThemeColor theme.Color + func NewUniform(c theme.Color, inner node.Node) *Uniform + func (w *Uniform) PaintBase(ctx *node.PaintBaseContext, origin image.Point) error