Documentation ¶
Index ¶
- Constants
- func SetGLFWHints()
- type App
- type ButtonWidget
- func (widget *ButtonWidget) AttachWidget(wd Widget)
- func (widget *ButtonWidget) BaseWidget() *baseWidget
- func (widget *ButtonWidget) Buffer() *image.RGBA
- func (button *ButtonWidget) Click()
- func (widget *ButtonWidget) ComputedBox() *box
- func (widget *ButtonWidget) DetachWidget(wd Widget) Widget
- func (button *ButtonWidget) GetContent() string
- func (widget *ButtonWidget) GetHeight() float64
- func (widget *ButtonWidget) GetLeft() float64
- func (widget *ButtonWidget) GetRect() (float64, float64, float64, float64)
- func (widget *ButtonWidget) GetTop() float64
- func (widget *ButtonWidget) GetWidth() float64
- func (widget *ButtonWidget) IsPointInside(x, y float64) bool
- func (widget *ButtonWidget) NeedsRepaint() bool
- func (widget *ButtonWidget) RequestReflow()
- func (widget *ButtonWidget) RequestRepaint()
- func (button *ButtonWidget) SetBackgroundColor(backgroundColor string)
- func (widget *ButtonWidget) SetBuffer(buffer *image.RGBA)
- func (button *ButtonWidget) SetContent(content string)
- func (button *ButtonWidget) SetFontColor(fontColor string)
- func (button *ButtonWidget) SetFontSize(fontSize float64)
- func (button *ButtonWidget) SetHeight(height float64)
- func (widget *ButtonWidget) SetNeedsRepaint(value bool)
- func (button *ButtonWidget) SetPadding(padding float64)
- func (button *ButtonWidget) SetWidth(width float64)
- func (widget *ButtonWidget) SetWindow(window *Window)
- func (widget *ButtonWidget) Widgets() []Widget
- type CanvasWidget
- func (widget *CanvasWidget) AttachWidget(wd Widget)
- func (widget *CanvasWidget) BaseWidget() *baseWidget
- func (widget *CanvasWidget) Buffer() *image.RGBA
- func (widget *CanvasWidget) ComputedBox() *box
- func (widget *CanvasWidget) DetachWidget(wd Widget) Widget
- func (canvas *CanvasWidget) DisableScrolling()
- func (canvas *CanvasWidget) EnableScrolling()
- func (canvas *CanvasWidget) GetContext() *gg.Context
- func (widget *CanvasWidget) GetHeight() float64
- func (widget *CanvasWidget) GetLeft() float64
- func (canvas *CanvasWidget) GetOffset() int
- func (widget *CanvasWidget) GetRect() (float64, float64, float64, float64)
- func (widget *CanvasWidget) GetTop() float64
- func (widget *CanvasWidget) GetWidth() float64
- func (widget *CanvasWidget) IsPointInside(x, y float64) bool
- func (widget *CanvasWidget) NeedsRepaint() bool
- func (widget *CanvasWidget) RequestReflow()
- func (widget *CanvasWidget) RequestRepaint()
- func (widget *CanvasWidget) SetBuffer(buffer *image.RGBA)
- func (canvas *CanvasWidget) SetContext(ctx *gg.Context)
- func (cavas *CanvasWidget) SetDrawingRepaint(repaint bool)
- func (canvas *CanvasWidget) SetHeight(height float64)
- func (widget *CanvasWidget) SetNeedsRepaint(value bool)
- func (canvas *CanvasWidget) SetOffset(offset int)
- func (canvas *CanvasWidget) SetWidth(width float64)
- func (widget *CanvasWidget) SetWindow(window *Window)
- func (widget *CanvasWidget) Widgets() []Widget
- type Frame
- func (widget *Frame) AttachWidget(wd Widget)
- func (widget *Frame) BaseWidget() *baseWidget
- func (widget *Frame) Buffer() *image.RGBA
- func (widget *Frame) ComputedBox() *box
- func (widget *Frame) DetachWidget(wd Widget) Widget
- func (frame *Frame) GetHeight() float64
- func (widget *Frame) GetLeft() float64
- func (widget *Frame) GetRect() (float64, float64, float64, float64)
- func (widget *Frame) GetTop() float64
- func (widget *Frame) GetWidth() float64
- func (widget *Frame) IsPointInside(x, y float64) bool
- func (widget *Frame) NeedsRepaint() bool
- func (widget *Frame) RequestReflow()
- func (widget *Frame) RequestRepaint()
- func (frame *Frame) SetBackgroundColor(backgroundColor string)
- func (widget *Frame) SetBuffer(buffer *image.RGBA)
- func (frame *Frame) SetHeight(height float64)
- func (widget *Frame) SetNeedsRepaint(value bool)
- func (frame *Frame) SetWidth(width float64)
- func (widget *Frame) SetWindow(window *Window)
- func (widget *Frame) Widgets() []Widget
- type FrameOrientation
- type ImageWidget
- func (widget *ImageWidget) AttachWidget(wd Widget)
- func (widget *ImageWidget) BaseWidget() *baseWidget
- func (widget *ImageWidget) Buffer() *image.RGBA
- func (widget *ImageWidget) ComputedBox() *box
- func (widget *ImageWidget) DetachWidget(wd Widget) Widget
- func (widget *ImageWidget) GetHeight() float64
- func (widget *ImageWidget) GetLeft() float64
- func (widget *ImageWidget) GetRect() (float64, float64, float64, float64)
- func (widget *ImageWidget) GetTop() float64
- func (widget *ImageWidget) GetWidth() float64
- func (widget *ImageWidget) IsPointInside(x, y float64) bool
- func (widget *ImageWidget) NeedsRepaint() bool
- func (widget *ImageWidget) RequestReflow()
- func (widget *ImageWidget) RequestRepaint()
- func (widget *ImageWidget) SetBuffer(buffer *image.RGBA)
- func (label *ImageWidget) SetHeight(height float64)
- func (widget *ImageWidget) SetNeedsRepaint(value bool)
- func (label *ImageWidget) SetWidth(width float64)
- func (widget *ImageWidget) SetWindow(window *Window)
- func (widget *ImageWidget) Widgets() []Widget
- type InputWidget
- func (widget *InputWidget) AttachWidget(wd Widget)
- func (widget *InputWidget) BaseWidget() *baseWidget
- func (widget *InputWidget) Buffer() *image.RGBA
- func (widget *InputWidget) ComputedBox() *box
- func (widget *InputWidget) DetachWidget(wd Widget) Widget
- func (input *InputWidget) GetCursorPos() int
- func (widget *InputWidget) GetHeight() float64
- func (widget *InputWidget) GetLeft() float64
- func (widget *InputWidget) GetRect() (float64, float64, float64, float64)
- func (widget *InputWidget) GetTop() float64
- func (input *InputWidget) GetValue() string
- func (widget *InputWidget) GetWidth() float64
- func (widget *InputWidget) IsPointInside(x, y float64) bool
- func (widget *InputWidget) NeedsRepaint() bool
- func (widget *InputWidget) RequestReflow()
- func (widget *InputWidget) RequestRepaint()
- func (input *InputWidget) SetBackgroundColor(backgroundColor string)
- func (widget *InputWidget) SetBuffer(buffer *image.RGBA)
- func (input *InputWidget) SetFontColor(fontColor string)
- func (input *InputWidget) SetFontSize(fontSize float64)
- func (input *InputWidget) SetHeight(height float64)
- func (widget *InputWidget) SetNeedsRepaint(value bool)
- func (input *InputWidget) SetReturnCallback(returnCallback func())
- func (input *InputWidget) SetValue(value string)
- func (input *InputWidget) SetWidth(width float64)
- func (widget *InputWidget) SetWindow(window *Window)
- func (widget *InputWidget) Widgets() []Widget
- type LabelWidget
- func (widget *LabelWidget) AttachWidget(wd Widget)
- func (widget *LabelWidget) BaseWidget() *baseWidget
- func (widget *LabelWidget) Buffer() *image.RGBA
- func (widget *LabelWidget) ComputedBox() *box
- func (widget *LabelWidget) DetachWidget(wd Widget) Widget
- func (label *LabelWidget) GetContent() string
- func (widget *LabelWidget) GetHeight() float64
- func (widget *LabelWidget) GetLeft() float64
- func (widget *LabelWidget) GetRect() (float64, float64, float64, float64)
- func (widget *LabelWidget) GetTop() float64
- func (widget *LabelWidget) GetWidth() float64
- func (widget *LabelWidget) IsPointInside(x, y float64) bool
- func (widget *LabelWidget) NeedsRepaint() bool
- func (widget *LabelWidget) RequestReflow()
- func (widget *LabelWidget) RequestRepaint()
- func (label *LabelWidget) SetBackgroundColor(backgroundColor string)
- func (widget *LabelWidget) SetBuffer(buffer *image.RGBA)
- func (label *LabelWidget) SetContent(content string)
- func (label *LabelWidget) SetFontColor(fontColor string)
- func (label *LabelWidget) SetFontSize(fontSize float64)
- func (label *LabelWidget) SetHeight(height float64)
- func (widget *LabelWidget) SetNeedsRepaint(value bool)
- func (label *LabelWidget) SetWidth(width float64)
- func (widget *LabelWidget) SetWindow(window *Window)
- func (widget *LabelWidget) Widgets() []Widget
- type MustardKey
- type Overlay
- type ScrollBarOrientation
- type ScrollBarWidget
- func (widget *ScrollBarWidget) AttachWidget(wd Widget)
- func (widget *ScrollBarWidget) BaseWidget() *baseWidget
- func (widget *ScrollBarWidget) Buffer() *image.RGBA
- func (widget *ScrollBarWidget) ComputedBox() *box
- func (widget *ScrollBarWidget) DetachWidget(wd Widget) Widget
- func (widget *ScrollBarWidget) GetHeight() float64
- func (widget *ScrollBarWidget) GetLeft() float64
- func (widget *ScrollBarWidget) GetRect() (float64, float64, float64, float64)
- func (widget *ScrollBarWidget) GetTop() float64
- func (widget *ScrollBarWidget) GetWidth() float64
- func (widget *ScrollBarWidget) IsPointInside(x, y float64) bool
- func (widget *ScrollBarWidget) NeedsRepaint() bool
- func (widget *ScrollBarWidget) RequestReflow()
- func (widget *ScrollBarWidget) RequestRepaint()
- func (widget *ScrollBarWidget) SetBuffer(buffer *image.RGBA)
- func (scrollBar *ScrollBarWidget) SetHeight(height float64)
- func (widget *ScrollBarWidget) SetNeedsRepaint(value bool)
- func (scrollBar *ScrollBarWidget) SetScrollerOffset(scrollerOffset float64)
- func (scrollBar *ScrollBarWidget) SetScrollerSize(scrollerSize float64)
- func (scrollBar *ScrollBarWidget) SetThumbColor(thumbColor string)
- func (scrollBar *ScrollBarWidget) SetThumbSize(thumbSize float64)
- func (scrollBar *ScrollBarWidget) SetTrackColor(backgroundColor string)
- func (scrollBar *ScrollBarWidget) SetWidth(width float64)
- func (widget *ScrollBarWidget) SetWindow(window *Window)
- func (widget *ScrollBarWidget) Widgets() []Widget
- type TextWidget
- func (widget *TextWidget) AttachWidget(wd Widget)
- func (widget *TextWidget) BaseWidget() *baseWidget
- func (widget *TextWidget) Buffer() *image.RGBA
- func (widget *TextWidget) ComputedBox() *box
- func (widget *TextWidget) DetachWidget(wd Widget) Widget
- func (text *TextWidget) GetContent() string
- func (widget *TextWidget) GetHeight() float64
- func (widget *TextWidget) GetLeft() float64
- func (widget *TextWidget) GetRect() (float64, float64, float64, float64)
- func (widget *TextWidget) GetTop() float64
- func (widget *TextWidget) GetWidth() float64
- func (widget *TextWidget) IsPointInside(x, y float64) bool
- func (widget *TextWidget) NeedsRepaint() bool
- func (widget *TextWidget) RequestReflow()
- func (widget *TextWidget) RequestRepaint()
- func (text *TextWidget) SetBackgroundColor(backgroundColor string)
- func (widget *TextWidget) SetBuffer(buffer *image.RGBA)
- func (text *TextWidget) SetContent(content string)
- func (text *TextWidget) SetFontColor(fontColor string)
- func (text *TextWidget) SetFontSize(fontSize float64)
- func (text *TextWidget) SetHeight(height float64)
- func (widget *TextWidget) SetNeedsRepaint(value bool)
- func (text *TextWidget) SetWidth(width float64)
- func (widget *TextWidget) SetWindow(window *Window)
- func (widget *TextWidget) Widgets() []Widget
- type TreeWidget
- func (widget *TreeWidget) AddNode(childNode *TreeWidgetNode)
- func (widget *TreeWidget) AttachWidget(wd Widget)
- func (widget *TreeWidget) BaseWidget() *baseWidget
- func (widget *TreeWidget) Buffer() *image.RGBA
- func (tree *TreeWidget) Click()
- func (widget *TreeWidget) ComputedBox() *box
- func (widget *TreeWidget) DetachWidget(wd Widget) Widget
- func (widget *TreeWidget) GetHeight() float64
- func (widget *TreeWidget) GetLeft() float64
- func (widget *TreeWidget) GetRect() (float64, float64, float64, float64)
- func (widget *TreeWidget) GetTop() float64
- func (widget *TreeWidget) GetWidth() float64
- func (widget *TreeWidget) IsPointInside(x, y float64) bool
- func (widget *TreeWidget) NeedsRepaint() bool
- func (widget *TreeWidget) RemoveNodes()
- func (widget *TreeWidget) RequestReflow()
- func (widget *TreeWidget) RequestRepaint()
- func (tree *TreeWidget) SelectNode(node *TreeWidgetNode)
- func (tree *TreeWidget) SelectNodeByValue(value string)
- func (tree *TreeWidget) SetBackgroundColor(backgroundColor string)
- func (widget *TreeWidget) SetBuffer(buffer *image.RGBA)
- func (tree *TreeWidget) SetFontColor(fontColor string)
- func (tree *TreeWidget) SetFontSize(fontSize float64)
- func (tree *TreeWidget) SetHeight(height float64)
- func (widget *TreeWidget) SetNeedsRepaint(value bool)
- func (tree *TreeWidget) SetSelectCallback(selectCallback func(*TreeWidgetNode))
- func (tree *TreeWidget) SetWidth(width float64)
- func (widget *TreeWidget) SetWindow(window *Window)
- func (widget *TreeWidget) Widgets() []Widget
- type TreeWidgetNode
- type Widget
- type Window
- func (window *Window) AddContextMenuEntry(entryText string, action func())
- func (window *Window) AddOverlay(overlay *Overlay)
- func (window *Window) AddStaticOverlay(overlay *Overlay)
- func (window *Window) AttachClickEventListener(callback func(MustardKey))
- func (window *Window) AttachPointerPositionEventListener(callback func(pointerX, pointerY float64))
- func (window *Window) AttachScrollEventListener(callback func(direction int))
- func (window *Window) DeselectEntries()
- func (window *Window) DestroyContextMenu()
- func (window *Window) DrawContextMenu()
- func (window *Window) EnableContextMenus()
- func (window *Window) GetCursorPosition() (float64, float64)
- func (window *Window) GetSize() (int, int)
- func (window *Window) ProcessArrowKeys(arrowKey string)
- func (window *Window) ProcessButtonClick()
- func (window *Window) ProcessButtons()
- func (window *Window) ProcessContextMenu()
- func (window *Window) ProcessContextMenuClick()
- func (window *Window) ProcessInputActivation()
- func (window *Window) ProcessInputs()
- func (window *Window) ProcessPointerClick(button glfw.MouseButton)
- func (window *Window) ProcessPointerPosition()
- func (window *Window) ProcessReturnKey()
- func (window *Window) ProcessScroll(x, y float64)
- func (window *Window) ProcessTreeClick()
- func (window *Window) ProcessTrees()
- func (window *Window) RecreateContext()
- func (window *Window) RegisterButton(button *ButtonWidget, callback func())
- func (window *Window) RegisterInput(input *InputWidget)
- func (window *Window) RegisterTree(tree *TreeWidget)
- func (window *Window) RemoveOverlay(overlay *Overlay)
- func (window *Window) RemoveStaticOverlay(ref string)
- func (window *Window) RequestReflow()
- func (window *Window) SelectEntry(entry *menuEntry)
- func (window *Window) SetContextMenuOverlay(overlay *Overlay)
- func (window *Window) SetCursor(cursorType cursorType)
- func (window *Window) SetRootFrame(frame *Frame)
- func (window *Window) SetTitle(title string)
- func (window *Window) Show()
Constants ¶
const ( //DefaultCursor - Default arrow cursor DefaultCursor cursorType = iota //PointerCursor - Pointer cursor PointerCursor )
const ( PositionRelative widgetPosition = iota PositionAbsolute )
Variables ¶
This section is empty.
Functions ¶
func SetGLFWHints ¶
func SetGLFWHints()
Types ¶
type App ¶
type App struct {
// contains filtered or unexported fields
}
func CreateNewApp ¶
func (*App) DestroyWindow ¶
type ButtonWidget ¶
type ButtonWidget struct {
// contains filtered or unexported fields
}
func CreateButtonWidget ¶
func CreateButtonWidget(label string, asset []byte) *ButtonWidget
CreateButtonWidget - Creates and returns a new Button Widget
func (*ButtonWidget) AttachWidget ¶
func (widget *ButtonWidget) AttachWidget(wd Widget)
func (*ButtonWidget) BaseWidget ¶
func (widget *ButtonWidget) BaseWidget() *baseWidget
func (*ButtonWidget) Click ¶
func (button *ButtonWidget) Click()
func (*ButtonWidget) ComputedBox ¶
func (widget *ButtonWidget) ComputedBox() *box
func (*ButtonWidget) DetachWidget ¶
func (*ButtonWidget) GetContent ¶
func (button *ButtonWidget) GetContent() string
GetContent - Gets the button content
func (*ButtonWidget) IsPointInside ¶
func (*ButtonWidget) NeedsRepaint ¶
func (widget *ButtonWidget) NeedsRepaint() bool
func (*ButtonWidget) RequestReflow ¶
func (widget *ButtonWidget) RequestReflow()
func (*ButtonWidget) RequestRepaint ¶
func (widget *ButtonWidget) RequestRepaint()
func (*ButtonWidget) SetBackgroundColor ¶
func (button *ButtonWidget) SetBackgroundColor(backgroundColor string)
SetBackgroundColor - Sets the button background color
func (*ButtonWidget) SetContent ¶
func (button *ButtonWidget) SetContent(content string)
SetContent - Sets the button content
func (*ButtonWidget) SetFontColor ¶
func (button *ButtonWidget) SetFontColor(fontColor string)
SetFontColor - Sets the button font color
func (*ButtonWidget) SetFontSize ¶
func (button *ButtonWidget) SetFontSize(fontSize float64)
SetFontSize - Sets the button font size
func (*ButtonWidget) SetHeight ¶
func (button *ButtonWidget) SetHeight(height float64)
SetHeight - Sets the button height
func (*ButtonWidget) SetNeedsRepaint ¶
func (widget *ButtonWidget) SetNeedsRepaint(value bool)
func (*ButtonWidget) SetPadding ¶
func (button *ButtonWidget) SetPadding(padding float64)
SetFontSize - Sets the button font size
func (*ButtonWidget) SetWidth ¶
func (button *ButtonWidget) SetWidth(width float64)
SetWidth - Sets the button width
type CanvasWidget ¶
type CanvasWidget struct {
// contains filtered or unexported fields
}
func CreateCanvasWidget ¶
func CreateCanvasWidget(renderer func(*CanvasWidget)) *CanvasWidget
CreateImageWidget - Creates and returns a new Image Widget
func (*CanvasWidget) AttachWidget ¶
func (widget *CanvasWidget) AttachWidget(wd Widget)
func (*CanvasWidget) BaseWidget ¶
func (widget *CanvasWidget) BaseWidget() *baseWidget
func (*CanvasWidget) ComputedBox ¶
func (widget *CanvasWidget) ComputedBox() *box
func (*CanvasWidget) DetachWidget ¶
func (*CanvasWidget) DisableScrolling ¶
func (canvas *CanvasWidget) DisableScrolling()
func (*CanvasWidget) EnableScrolling ¶
func (canvas *CanvasWidget) EnableScrolling()
func (*CanvasWidget) GetContext ¶
func (canvas *CanvasWidget) GetContext() *gg.Context
func (*CanvasWidget) GetOffset ¶
func (canvas *CanvasWidget) GetOffset() int
func (*CanvasWidget) IsPointInside ¶
func (*CanvasWidget) NeedsRepaint ¶
func (widget *CanvasWidget) NeedsRepaint() bool
func (*CanvasWidget) RequestReflow ¶
func (widget *CanvasWidget) RequestReflow()
func (*CanvasWidget) RequestRepaint ¶
func (widget *CanvasWidget) RequestRepaint()
func (*CanvasWidget) SetContext ¶
func (canvas *CanvasWidget) SetContext(ctx *gg.Context)
func (*CanvasWidget) SetDrawingRepaint ¶
func (cavas *CanvasWidget) SetDrawingRepaint(repaint bool)
func (*CanvasWidget) SetHeight ¶
func (canvas *CanvasWidget) SetHeight(height float64)
SetHeight - Sets the label height
func (*CanvasWidget) SetNeedsRepaint ¶
func (widget *CanvasWidget) SetNeedsRepaint(value bool)
func (*CanvasWidget) SetOffset ¶
func (canvas *CanvasWidget) SetOffset(offset int)
func (*CanvasWidget) SetWidth ¶
func (canvas *CanvasWidget) SetWidth(width float64)
SetWidth - Sets the label width
type Frame ¶
type Frame struct {
// contains filtered or unexported fields
}
Frame - Layout frame type
func CreateFrame ¶
func CreateFrame(orientation FrameOrientation) *Frame
CreateFrame - Creates and returns a new Frame
func (*Frame) AttachWidget ¶
func (widget *Frame) AttachWidget(wd Widget)
func (*Frame) BaseWidget ¶
func (widget *Frame) BaseWidget() *baseWidget
func (*Frame) ComputedBox ¶
func (widget *Frame) ComputedBox() *box
func (*Frame) DetachWidget ¶
func (*Frame) IsPointInside ¶
func (*Frame) NeedsRepaint ¶
func (widget *Frame) NeedsRepaint() bool
func (*Frame) RequestReflow ¶
func (widget *Frame) RequestReflow()
func (*Frame) RequestRepaint ¶
func (widget *Frame) RequestRepaint()
func (*Frame) SetBackgroundColor ¶
SetBackgroundColor - Sets the frame background color
func (*Frame) SetNeedsRepaint ¶
func (widget *Frame) SetNeedsRepaint(value bool)
type FrameOrientation ¶
type FrameOrientation int
const ( //VerticalFrame - Vertical frame orientation VerticalFrame FrameOrientation = iota //HorizontalFrame - Horizontal frame orientation HorizontalFrame )
type ImageWidget ¶
type ImageWidget struct {
// contains filtered or unexported fields
}
func CreateImageWidget ¶
func CreateImageWidget(path []byte) *ImageWidget
CreateImageWidget - Creates and returns a new Image Widget
func (*ImageWidget) AttachWidget ¶
func (widget *ImageWidget) AttachWidget(wd Widget)
func (*ImageWidget) BaseWidget ¶
func (widget *ImageWidget) BaseWidget() *baseWidget
func (*ImageWidget) ComputedBox ¶
func (widget *ImageWidget) ComputedBox() *box
func (*ImageWidget) DetachWidget ¶
func (*ImageWidget) IsPointInside ¶
func (*ImageWidget) NeedsRepaint ¶
func (widget *ImageWidget) NeedsRepaint() bool
func (*ImageWidget) RequestReflow ¶
func (widget *ImageWidget) RequestReflow()
func (*ImageWidget) RequestRepaint ¶
func (widget *ImageWidget) RequestRepaint()
func (*ImageWidget) SetHeight ¶
func (label *ImageWidget) SetHeight(height float64)
SetHeight - Sets the label height
func (*ImageWidget) SetNeedsRepaint ¶
func (widget *ImageWidget) SetNeedsRepaint(value bool)
func (*ImageWidget) SetWidth ¶
func (label *ImageWidget) SetWidth(width float64)
SetWidth - Sets the label width
type InputWidget ¶
type InputWidget struct {
// contains filtered or unexported fields
}
func CreateInputWidget ¶
func CreateInputWidget() *InputWidget
CreateInputWidget - Creates and returns a new Input Widget
func (*InputWidget) AttachWidget ¶
func (widget *InputWidget) AttachWidget(wd Widget)
func (*InputWidget) BaseWidget ¶
func (widget *InputWidget) BaseWidget() *baseWidget
func (*InputWidget) ComputedBox ¶
func (widget *InputWidget) ComputedBox() *box
func (*InputWidget) DetachWidget ¶
func (*InputWidget) GetCursorPos ¶
func (input *InputWidget) GetCursorPos() int
func (*InputWidget) GetValue ¶
func (input *InputWidget) GetValue() string
SetFontColor - Sets the input font color
func (*InputWidget) IsPointInside ¶
func (*InputWidget) NeedsRepaint ¶
func (widget *InputWidget) NeedsRepaint() bool
func (*InputWidget) RequestReflow ¶
func (widget *InputWidget) RequestReflow()
func (*InputWidget) RequestRepaint ¶
func (widget *InputWidget) RequestRepaint()
func (*InputWidget) SetBackgroundColor ¶
func (input *InputWidget) SetBackgroundColor(backgroundColor string)
SetBackgroundColor - Sets the input background color
func (*InputWidget) SetFontColor ¶
func (input *InputWidget) SetFontColor(fontColor string)
SetFontColor - Sets the input font color
func (*InputWidget) SetFontSize ¶
func (input *InputWidget) SetFontSize(fontSize float64)
SetFontSize - Sets the input font size
func (*InputWidget) SetHeight ¶
func (input *InputWidget) SetHeight(height float64)
SetHeight - Sets the input height
func (*InputWidget) SetNeedsRepaint ¶
func (widget *InputWidget) SetNeedsRepaint(value bool)
func (*InputWidget) SetReturnCallback ¶
func (input *InputWidget) SetReturnCallback(returnCallback func())
func (*InputWidget) SetValue ¶
func (input *InputWidget) SetValue(value string)
SetFontColor - Sets the input font color
func (*InputWidget) SetWidth ¶
func (input *InputWidget) SetWidth(width float64)
SetWidth - Sets the input width
type LabelWidget ¶
type LabelWidget struct {
// contains filtered or unexported fields
}
func CreateLabelWidget ¶
func CreateLabelWidget(content string) *LabelWidget
CreateLabelWidget - Creates and returns a new Label Widget
func (*LabelWidget) AttachWidget ¶
func (widget *LabelWidget) AttachWidget(wd Widget)
func (*LabelWidget) BaseWidget ¶
func (widget *LabelWidget) BaseWidget() *baseWidget
func (*LabelWidget) ComputedBox ¶
func (widget *LabelWidget) ComputedBox() *box
func (*LabelWidget) DetachWidget ¶
func (*LabelWidget) GetContent ¶
func (label *LabelWidget) GetContent() string
GetContent - Gets the label content
func (*LabelWidget) IsPointInside ¶
func (*LabelWidget) NeedsRepaint ¶
func (widget *LabelWidget) NeedsRepaint() bool
func (*LabelWidget) RequestReflow ¶
func (widget *LabelWidget) RequestReflow()
func (*LabelWidget) RequestRepaint ¶
func (widget *LabelWidget) RequestRepaint()
func (*LabelWidget) SetBackgroundColor ¶
func (label *LabelWidget) SetBackgroundColor(backgroundColor string)
SetBackgroundColor - Sets the label background color
func (*LabelWidget) SetContent ¶
func (label *LabelWidget) SetContent(content string)
SetContent - Sets the label content
func (*LabelWidget) SetFontColor ¶
func (label *LabelWidget) SetFontColor(fontColor string)
SetFontColor - Sets the label font color
func (*LabelWidget) SetFontSize ¶
func (label *LabelWidget) SetFontSize(fontSize float64)
SetFontSize - Sets the label font size
func (*LabelWidget) SetHeight ¶
func (label *LabelWidget) SetHeight(height float64)
SetHeight - Sets the label height
func (*LabelWidget) SetNeedsRepaint ¶
func (widget *LabelWidget) SetNeedsRepaint(value bool)
func (*LabelWidget) SetWidth ¶
func (label *LabelWidget) SetWidth(width float64)
SetWidth - Sets the label width
type ScrollBarOrientation ¶
type ScrollBarOrientation int
const ( VerticalScrollBar ScrollBarOrientation = iota HorizontalScrollBar )
type ScrollBarWidget ¶
type ScrollBarWidget struct {
// contains filtered or unexported fields
}
func CreateScrollBarWidget ¶
func CreateScrollBarWidget(orientation ScrollBarOrientation) *ScrollBarWidget
CreateScrollBarWidget - Creates and returns a new ScrollBar Widget
func (*ScrollBarWidget) AttachWidget ¶
func (widget *ScrollBarWidget) AttachWidget(wd Widget)
func (*ScrollBarWidget) BaseWidget ¶
func (widget *ScrollBarWidget) BaseWidget() *baseWidget
func (*ScrollBarWidget) ComputedBox ¶
func (widget *ScrollBarWidget) ComputedBox() *box
func (*ScrollBarWidget) DetachWidget ¶
func (*ScrollBarWidget) IsPointInside ¶
func (*ScrollBarWidget) NeedsRepaint ¶
func (widget *ScrollBarWidget) NeedsRepaint() bool
func (*ScrollBarWidget) RequestReflow ¶
func (widget *ScrollBarWidget) RequestReflow()
func (*ScrollBarWidget) RequestRepaint ¶
func (widget *ScrollBarWidget) RequestRepaint()
func (*ScrollBarWidget) SetHeight ¶
func (scrollBar *ScrollBarWidget) SetHeight(height float64)
SetHeight - Sets the scrollBar height
func (*ScrollBarWidget) SetNeedsRepaint ¶
func (widget *ScrollBarWidget) SetNeedsRepaint(value bool)
func (*ScrollBarWidget) SetScrollerOffset ¶
func (scrollBar *ScrollBarWidget) SetScrollerOffset(scrollerOffset float64)
func (*ScrollBarWidget) SetScrollerSize ¶
func (scrollBar *ScrollBarWidget) SetScrollerSize(scrollerSize float64)
func (*ScrollBarWidget) SetThumbColor ¶
func (scrollBar *ScrollBarWidget) SetThumbColor(thumbColor string)
func (*ScrollBarWidget) SetThumbSize ¶
func (scrollBar *ScrollBarWidget) SetThumbSize(thumbSize float64)
func (*ScrollBarWidget) SetTrackColor ¶
func (scrollBar *ScrollBarWidget) SetTrackColor(backgroundColor string)
SetBackgroundColor - Sets the scrollBar background color
func (*ScrollBarWidget) SetWidth ¶
func (scrollBar *ScrollBarWidget) SetWidth(width float64)
SetWidth - Sets the scrollBar width
type TextWidget ¶
type TextWidget struct {
// contains filtered or unexported fields
}
func CreateTextWidget ¶
func CreateTextWidget(content string) *TextWidget
CreateTextWidget - Creates and returns a new Text Widget
func (*TextWidget) AttachWidget ¶
func (widget *TextWidget) AttachWidget(wd Widget)
func (*TextWidget) BaseWidget ¶
func (widget *TextWidget) BaseWidget() *baseWidget
func (*TextWidget) ComputedBox ¶
func (widget *TextWidget) ComputedBox() *box
func (*TextWidget) DetachWidget ¶
func (*TextWidget) GetContent ¶
func (text *TextWidget) GetContent() string
GetContent - Gets the text content
func (*TextWidget) IsPointInside ¶
func (*TextWidget) NeedsRepaint ¶
func (widget *TextWidget) NeedsRepaint() bool
func (*TextWidget) RequestReflow ¶
func (widget *TextWidget) RequestReflow()
func (*TextWidget) RequestRepaint ¶
func (widget *TextWidget) RequestRepaint()
func (*TextWidget) SetBackgroundColor ¶
func (text *TextWidget) SetBackgroundColor(backgroundColor string)
SetBackgroundColor - Sets the text background color
func (*TextWidget) SetContent ¶
func (text *TextWidget) SetContent(content string)
SetContent - Sets the text content
func (*TextWidget) SetFontColor ¶
func (text *TextWidget) SetFontColor(fontColor string)
SetFontColor - Sets the text font color
func (*TextWidget) SetFontSize ¶
func (text *TextWidget) SetFontSize(fontSize float64)
SetFontSize - Sets the text font size
func (*TextWidget) SetHeight ¶
func (text *TextWidget) SetHeight(height float64)
SetHeight - Sets the text height
func (*TextWidget) SetNeedsRepaint ¶
func (widget *TextWidget) SetNeedsRepaint(value bool)
func (*TextWidget) SetWidth ¶
func (text *TextWidget) SetWidth(width float64)
SetWidth - Sets the text width
type TreeWidget ¶
type TreeWidget struct {
// contains filtered or unexported fields
}
func CreateTreeWidget ¶
func CreateTreeWidget() *TreeWidget
CreateTreeWidget - Creates and returns a new Tree Widget
func (*TreeWidget) AddNode ¶
func (widget *TreeWidget) AddNode(childNode *TreeWidgetNode)
func (*TreeWidget) AttachWidget ¶
func (widget *TreeWidget) AttachWidget(wd Widget)
func (*TreeWidget) BaseWidget ¶
func (widget *TreeWidget) BaseWidget() *baseWidget
func (*TreeWidget) Click ¶
func (tree *TreeWidget) Click()
func (*TreeWidget) ComputedBox ¶
func (widget *TreeWidget) ComputedBox() *box
func (*TreeWidget) DetachWidget ¶
func (*TreeWidget) IsPointInside ¶
func (*TreeWidget) NeedsRepaint ¶
func (widget *TreeWidget) NeedsRepaint() bool
func (*TreeWidget) RemoveNodes ¶
func (widget *TreeWidget) RemoveNodes()
func (*TreeWidget) RequestReflow ¶
func (widget *TreeWidget) RequestReflow()
func (*TreeWidget) RequestRepaint ¶
func (widget *TreeWidget) RequestRepaint()
func (*TreeWidget) SelectNode ¶
func (tree *TreeWidget) SelectNode(node *TreeWidgetNode)
func (*TreeWidget) SelectNodeByValue ¶
func (tree *TreeWidget) SelectNodeByValue(value string)
func (*TreeWidget) SetBackgroundColor ¶
func (tree *TreeWidget) SetBackgroundColor(backgroundColor string)
SetBackgroundColor - Sets the tree background color
func (*TreeWidget) SetFontColor ¶
func (tree *TreeWidget) SetFontColor(fontColor string)
SetFontColor - Sets the tree font color
func (*TreeWidget) SetFontSize ¶
func (tree *TreeWidget) SetFontSize(fontSize float64)
SetFontSize - Sets the tree font size
func (*TreeWidget) SetHeight ¶
func (tree *TreeWidget) SetHeight(height float64)
SetHeight - Sets the tree height
func (*TreeWidget) SetNeedsRepaint ¶
func (widget *TreeWidget) SetNeedsRepaint(value bool)
func (*TreeWidget) SetSelectCallback ¶
func (tree *TreeWidget) SetSelectCallback(selectCallback func(*TreeWidgetNode))
func (*TreeWidget) SetWidth ¶
func (tree *TreeWidget) SetWidth(width float64)
SetWidth - Sets the tree width
type TreeWidgetNode ¶
type TreeWidgetNode struct { Key string Value string Parent *TreeWidgetNode Children []*TreeWidgetNode // contains filtered or unexported fields }
func CreateTreeWidgetNode ¶
func CreateTreeWidgetNode(key, value string) *TreeWidgetNode
func (*TreeWidgetNode) AddNode ¶
func (node *TreeWidgetNode) AddNode(childNode *TreeWidgetNode)
func (*TreeWidgetNode) Close ¶
func (node *TreeWidgetNode) Close()
func (*TreeWidgetNode) NextSibling ¶
func (node *TreeWidgetNode) NextSibling() *TreeWidgetNode
func (*TreeWidgetNode) Open ¶
func (node *TreeWidgetNode) Open()
func (*TreeWidgetNode) PreviousSibling ¶
func (node *TreeWidgetNode) PreviousSibling() *TreeWidgetNode
func (*TreeWidgetNode) Toggle ¶
func (node *TreeWidgetNode) Toggle()
type Window ¶
type Window struct {
// contains filtered or unexported fields
}
func CreateNewWindow ¶
func (*Window) AddContextMenuEntry ¶
func (*Window) AddOverlay ¶
func (*Window) AddStaticOverlay ¶
func (*Window) AttachClickEventListener ¶
func (window *Window) AttachClickEventListener(callback func(MustardKey))
func (*Window) AttachPointerPositionEventListener ¶
func (*Window) AttachScrollEventListener ¶
func (*Window) DeselectEntries ¶
func (window *Window) DeselectEntries()
func (*Window) DestroyContextMenu ¶
func (window *Window) DestroyContextMenu()
func (*Window) DrawContextMenu ¶
func (window *Window) DrawContextMenu()
func (*Window) EnableContextMenus ¶
func (window *Window) EnableContextMenus()
func (*Window) GetCursorPosition ¶
func (*Window) ProcessArrowKeys ¶
func (*Window) ProcessButtonClick ¶
func (window *Window) ProcessButtonClick()
func (*Window) ProcessButtons ¶
func (window *Window) ProcessButtons()
func (*Window) ProcessContextMenu ¶
func (window *Window) ProcessContextMenu()
func (*Window) ProcessContextMenuClick ¶
func (window *Window) ProcessContextMenuClick()
func (*Window) ProcessInputActivation ¶
func (window *Window) ProcessInputActivation()
func (*Window) ProcessInputs ¶
func (window *Window) ProcessInputs()
func (*Window) ProcessPointerClick ¶
func (window *Window) ProcessPointerClick(button glfw.MouseButton)
func (*Window) ProcessPointerPosition ¶
func (window *Window) ProcessPointerPosition()
func (*Window) ProcessReturnKey ¶
func (window *Window) ProcessReturnKey()
func (*Window) ProcessScroll ¶
func (*Window) ProcessTreeClick ¶
func (window *Window) ProcessTreeClick()
func (*Window) ProcessTrees ¶
func (window *Window) ProcessTrees()
func (*Window) RecreateContext ¶
func (window *Window) RecreateContext()
func (*Window) RegisterButton ¶
func (window *Window) RegisterButton(button *ButtonWidget, callback func())
func (*Window) RegisterInput ¶
func (window *Window) RegisterInput(input *InputWidget)
func (*Window) RegisterTree ¶
func (window *Window) RegisterTree(tree *TreeWidget)
func (*Window) RemoveOverlay ¶
func (*Window) RemoveStaticOverlay ¶
func (*Window) RequestReflow ¶
func (window *Window) RequestReflow()
func (*Window) SelectEntry ¶
func (window *Window) SelectEntry(entry *menuEntry)
func (*Window) SetContextMenuOverlay ¶
func (*Window) SetRootFrame ¶
SetRootFrame - Sets the window root frame