style

package
v0.1.0 Latest Latest
Warning

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

Go to latest
Published: Oct 9, 2020 License: MIT Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var Black = color.RGBA{0, 0, 0, 255}

Functions

This section is empty.

Types

type CheckboxControl

type CheckboxControl struct {
	gui.RawItem
	// contains filtered or unexported fields
}

CheckboxControl is a checkbox to be used as a canvas.Control

func NewCheckBox

func NewCheckBox(label string, active bool, color color.RGBA) *CheckboxControl

func (*CheckboxControl) Ack

func (*CheckboxControl) Color

func (c *CheckboxControl) Color() color.RGBA

func (*CheckboxControl) Disable

func (c *CheckboxControl) Disable()

func (*CheckboxControl) Draw

func (c *CheckboxControl) Draw(gtx *layout.Context, th *material.Theme) error

func (*CheckboxControl) Enable

func (c *CheckboxControl) Enable()

func (*CheckboxControl) IsActive

func (c *CheckboxControl) IsActive() bool

func (*CheckboxControl) Label

func (c *CheckboxControl) Label() string

func (*CheckboxControl) Set

func (c *CheckboxControl) Set(active bool)

func (*CheckboxControl) Trigger

func (c *CheckboxControl) Trigger() canvas.EventReceiver

type CheckboxControlGroup

type CheckboxControlGroup struct {
	CheckboxControl
	// contains filtered or unexported fields
}

func NewCheckboxControlGroup

func NewCheckboxControlGroup(active bool, control ...canvas.Control) *CheckboxControlGroup

type Input

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

func NewInput

func NewInput() *Input

func (*Input) Ack

func (i *Input) Ack() canvas.EventEmitter

func (*Input) Draw

func (i *Input) Draw(gtx *layout.Context, th *material.Theme) error

func (*Input) IsActive

func (i *Input) IsActive() bool

func (*Input) Set

func (i *Input) Set(active bool)

func (*Input) Trigger

func (i *Input) Trigger() canvas.EventReceiver

type Label

type Label struct {
	Properties
	// contains filtered or unexported fields
}

func NewLabel

func NewLabel(center f32.Point, text string) Label

func (Label) Draw

func (l Label) Draw(gtx *layout.Context, th *material.Theme) error

func (*Label) Position

func (l *Label) Position(position f32.Point)

Position adjusts the label position

func (*Label) Text

func (l *Label) Text(text string)

Text adjusts the labels text

type Properties

type Properties struct {
	color.RGBA
}

func (*Properties) Color

func (p *Properties) Color(rgba color.RGBA) *Properties

type Rect

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

func NewRect

func NewRect(rect *f32.Rectangle) *Rect

func (Rect) Draw

func (r Rect) Draw(gtx *layout.Context, th *material.Theme) error

Jump to

Keyboard shortcuts

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