layout

package
v0.0.0-...-967bb3a Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 2, 2023 License: BSD-3-Clause Imports: 4 Imported by: 0

Documentation

Index

Constants

View Source
const (
	Horizontal = flat.LayoutAxisHorizontal
	Vertical   = flat.LayoutAxisVertical
)
View Source
const (
	SpaceEnd     = flat.LayoutSpacingEnd
	SpaceStart   = flat.LayoutSpacingStart
	SpaceSides   = flat.LayoutSpacingSides
	SpaceAround  = flat.LayoutSpacingAround
	SpaceBetween = flat.LayoutSpacingBetween
	SpaceEvenly  = flat.LayoutSpacingEvenly
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Alignment

type Alignment = flat.LayoutAlignment

type Axis

type Axis = flat.LayoutAxis

type Direction

type Direction flat.LayoutDirection

func (Direction) AddLayout

func (x Direction) AddLayout(b *flatbuffers.Builder, o *op.Ops, widget op.Ops) op.Ops

func (Direction) CreateLayout

func (x Direction) CreateLayout(b *flatbuffers.Builder, widget op.Ops) op.Op

type Flex

type Flex struct {
	Axis      Axis
	Spacing   Spacing
	Alignment Alignment
	WeightSum float32
}

func (Flex) AddLayout

func (x Flex) AddLayout(b *flatbuffers.Builder, o *op.Ops, children ...FlexChild) op.Ops

func (Flex) CreateLayout

func (x Flex) CreateLayout(b *flatbuffers.Builder, children ...FlexChild) op.Op

type FlexChild

type FlexChild struct {
	// contains filtered or unexported fields
}

func Flexed

func Flexed(weight float32, widget op.Ops) FlexChild

func Rigid

func Rigid(widget op.Ops) FlexChild

type Inset

type Inset struct {
	Top    unit.Value
	Bottom unit.Value
	Left   unit.Value
	Right  unit.Value
}

func UniformInset

func UniformInset(v unit.Value) Inset

func (Inset) AddLayout

func (x Inset) AddLayout(b *flatbuffers.Builder, o *op.Ops, widget op.Ops) op.Ops

func (Inset) CreateLayout

func (x Inset) CreateLayout(b *flatbuffers.Builder, widget op.Ops) op.Op

type Spacer

type Spacer struct {
	Width  unit.Value
	Height unit.Value
}

func (Spacer) AddLayout

func (x Spacer) AddLayout(b *flatbuffers.Builder, o *op.Ops) op.Ops

func (Spacer) CreateLayout

func (x Spacer) CreateLayout(b *flatbuffers.Builder) op.Op

type Spacing

type Spacing = flat.LayoutSpacing

type Stack

type Stack struct {
	Alignment Direction
}

func (Stack) AddLayout

func (x Stack) AddLayout(b *flatbuffers.Builder, o *op.Ops, children ...StackChild) op.Ops

func (Stack) CreateLayout

func (x Stack) CreateLayout(b *flatbuffers.Builder, children ...StackChild) op.Op

type StackChild

type StackChild struct {
	// contains filtered or unexported fields
}

func Expanded

func Expanded(widget op.Ops) StackChild

func Stacked

func Stacked(widget op.Ops) StackChild

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL