package
0.0.23
Repository: https://github.com/cybriq/p9.git
Documentation: pkg.go.dev

# Functions

Exact returns the Constraints with the minimum and maximum size set to size.
Expanded returns a Stack child with the minimum constraints set to the largest Stacked child.
Flexed returns a Flex child forced to take up weight fraction of the space left over from Rigid children.
FPt converts an point to a f32.Point.
FRect converts a rectangle to a f32.Rectangle.
NewContext is a shorthand for Context{ Ops: ops, Now: e.Now, Queue: e.Queue, Config: e.Config, Constraints: Exact(e.Size), } NewContext calls ops.Reset and adjusts ops for e.Insets.
Rigid returns a Flex child with a maximal constraint of the remaining space.
Stacked returns a Stack child that is laid out with no minimum constraints and the maximum constraints passed to Stack.Layout.
UniformInset returns an Inset with a single inset applied to all edges.

# Constants

No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author
SpaceAround distributes space evenly between children, with half as much space at the start and end.
SpaceBetween distributes space evenly between children, leaving no space at the start and end.
SpaceEnd leaves space at the end.
SpaceEvenly distributes space evenly between children and at the start and end.
SpaceSides shares space between the start and end.
SpaceStart leaves space at the start.
No description provided by the author
No description provided by the author
No description provided by the author
No description provided by the author

# Structs

Constraints represent the minimum and maximum size of a widget.
Context carries the state needed by almost all layouts and widgets.
Dimensions are the resolved size and baseline for a widget.
Flex lays out child elements along an axis, according to alignment and weights.
FlexChild is the descriptor for a Flex child.
Inset adds space around a widget by decreasing its maximum constraints.
List displays a subsection of a potentially infinitely large underlying list.
Position is a List scroll offset represented as an offset from the top edge of a child element.
Spacer adds space between widgets.
Stack lays out child elements on top of each other, according to an alignment direction.
StackChild represents a child for a Stack layout.

# Type aliases

Alignment is the mutual alignment of a list of widgets.
Axis is the Horizontal or Vertical direction.
Direction is the alignment of widgets relative to a containing space.
ListElement is a function that computes the dimensions of a list element.
Spacing determine the spacing mode for a Flex.
Widget is a function scope for drawing, processing events and computing dimensions for a user interface element.