Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Area ¶
type Area struct {
// contains filtered or unexported fields
}
Area represents a text area.
It retains its state.
TODO: - Selection - Copy / paste - Undo / redo - Scrollbar and scroll with mouse wheel - auto grow with max height
func NewArea ¶
func NewArea(bounds rl.Rectangle, text string, opts AreaOptions) Area
NewArea returns a new, unfocused, text Area with the given bounds, text and text options
It works best with a monospaced font.
func (*Area) SetDisabled ¶
func (*Area) SetFocused ¶
SetFocused sets the focused state of the area
type AreaOptions ¶
type Options ¶
type Options struct {
// Font to use
Font rl.Font
// Font size
Size float32
// Text color
Color rl.Color
// Spacing between letters
Spacing float32
// Spacing between lines
LineSpacing float32
// Whether to print/draw debug info
Debug bool
// Horizontal alignment
Align Align
// Vertical alignment
VerticalAlign Align
// Whether to wrap text
Wrap Wrap
}
Click to show internal directories.
Click to hide internal directories.