uikit

package module
v0.0.0-...-da4c08e Latest Latest
Warning

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

Go to latest
Published: Sep 13, 2026 License: MIT Imports: 15 Imported by: 1 module, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

README

go-uikit

A small immediate-mode UI kit for Ebiten games and apps: labels, buttons, checkboxes, text inputs, a text area, a dropdown select, and layout containers (stack, row-stack, grid), all sharing one rule — every proportion is derived from the font, so nothing needs to be tuned by hand.

▶ Try the live demo — the exact cmd/demo binary below, compiled to WebAssembly and running in your browser.

Contents

Design philosophy

  • All widgets share the same control height, derived from font metrics.
  • External layout can only control X/Y and width. Height is always computed by the theme (plus an optional error line for invalid fields).
  • No magic numbers: padding, radius, border width, gaps, etc. are all derived from the control height, not set individually per widget.

The result is that swapping uikit.NewTheme(font, fontPx) for a different font or size rescales the whole UI consistently, instead of a pile of independently-tuned constants drifting apart.

Installation

go get github.com/bstkhq/go-uikit

Requires Go 1.24+ and Ebiten v2.

Quick start

package main

import (
	"log"

	"github.com/bstkhq/go-uikit"
	"github.com/bstkhq/go-uikit/layout"
	"github.com/bstkhq/go-uikit/widget"
	"github.com/hajimehoshi/ebiten/v2"
)

type Game struct {
	ctx *uikit.Context
}

func NewGame() *Game {
	theme := uikit.DefaultTheme()

	root := layout.NewStack(theme)
	root.SetPadding(theme.SpaceM, theme.SpaceM)

	label := widget.NewLabel(theme, "Hello, go-uikit!")

	button := widget.NewButton(theme, "Click me")
	button.On(uikit.EventClick, func(uikit.Event) bool {
		label.SetText("Clicked!")
		return false
	}, false)

	root.Add(label, button)

	return &Game{ctx: uikit.NewContext(theme, root, nil)}
}

func (g *Game) Update() error                       { g.ctx.Update(); return nil }
func (g *Game) Draw(screen *ebiten.Image)            { g.ctx.Draw(screen) }
func (g *Game) Layout(w, h int) (int, int)           { return w, h }

func main() {
	ebiten.SetWindowSize(480, 320)
	ebiten.SetWindowTitle("go-uikit quick start")
	if err := ebiten.RunGame(NewGame()); err != nil {
		log.Fatal(err)
	}
}

Core concepts

Type Role
uikit.Theme The single source of truth for proportions and colors. Built from a default font + pixel size via uikit.NewTheme(font, fontPx), or uikit.DefaultTheme() for a ready-made dark theme (Go Regular/Go Bold at 20px). Additional font variants live in the exported TextStyles map. All fields are exported, so you can restyle the returned *Theme without touching layout math.
uikit.Context Owns the widget tree, routes pointer/keyboard input, tracks focus, and drives per-frame Update/Draw. One per ebiten.Game. Created with uikit.NewContext(theme, root, ime).
uikit.Widget The interface every control implements: frame placement, hover/press/focus/enabled/visible state, Measure, Update, Draw, and event registration.
uikit.Layout A Widget that owns children (Add, SetChildren, Clear) and can draw overlays above them (used by Select's dropdown). Stack, RowStack and Grid all implement it — and since a Layout is itself a Widget, layouts nest freely.
uikit.Base Embedded by every widget/layout. Supplies the shared hover/press/focus/enabled/invalid bookkeeping, the standard surface/border/focus-ring/error drawing, and height computation from the theme.
uikit.EventDispatcher Embedded via Base. Backs On/Dispatch for every widget.

theme.Text() returns the default text renderer. Use theme.Renderer(uikit.TextBold) for a registered variant. Applications can add variants without changing Theme:

theme.TextStyles[uikit.TextStyle("italic")] = italicFont

All variants share theme.FontPx; components that need another size can adjust the renderer or use widget.Size.

Widgets

All constructors take *uikit.Theme first. All widgets embed uikit.Base and satisfy uikit.Widget.

Widget Constructor Notes
widget.Label NewLabel(theme, text) Wraps text to its width; SetText, or SetTextFunc(func() string) for a value that's recomputed every frame (handy for live stats). SetTextModifiers(...) applies one-off widget.Font/widget.Color/widget.Size overrides to the renderer.
widget.Button NewButton(theme, label) Fires EventClick on pointer click, and also on Enter/Space while focused. SetLabel to change text.
widget.Checkbox NewCheckbox(theme, label) SetChecked/Checked(); fires EventValueChange. Toggles on click or Space while focused.
widget.TextInput NewTextInput(theme, placeholder) Single-line text with caret, selection-free editing, and blinking cursor. Text()/SetText(), SetInputRuneLimit(n), Caret()/SetCaret(i). Set .IMEOptions to hint the on-screen keyboard type (see IME). Fires EventValueChange.
widget.TextArea NewTextArea(theme, placeholder) Multi-line variant; SetLines(n) sets the visible height in lines.
widget.Select NewSelect(theme, []widget.SelectOption) Dropdown with {Value any; Label string} options. SetOptions, Index()/SetIndex(i), Value(), Selected() (SelectOption, bool), SetPlaceholder, and MaxVisible (rows shown when open). The open list is drawn as an overlay, so it never shifts sibling widgets.
widget.Container NewContainer(theme) An empty themed box for custom content. SetHeight(px), then hook OnUpdate(ctx, contentRect) / OnDraw(ctx, dst) — dst is already a SubImage clipped to the padded content area.

Layouts

All layouts live in the layout package, implement uikit.Layout, and can be added to a Context or nested inside one another as regular widgets.

Layout Constructor Notes
layout.Stack NewStack(theme) Vertical list. SetPadding(x, y), SetGap(v). SetHeight(0) (default) sizes to content; SetHeight(px) fixes a viewport and enables scrolling/clipping.
layout.RowStack NewRowStack(theme, weights...) Rows of independently-weighted columns — e.g. NewRowStack(theme, 2, 1) gives every row a 2:1 split by default. Override a single row with SetRowPattern(rowIndex, weights...). SetGap(h, v), SetAlign(layout.AlignStart/AlignMiddle/AlignEnd) for vertical alignment within a row, and a BeforeUpdate hook to adjust children just before layout runs.
layout.Grid NewGrid(theme) Fixed column count (SetColumns(n), default 2), all cells equal width. SetGap(x, y), SetPadding(x, y), SetHeight(px) for scrolling.

Events

type EventType int
const (
	EventFocusGained
	EventFocusLost
	EventPointerDown
	EventPointerUp
	EventClick
	EventKeyDown
	EventKeyUp
	EventValueChange
)

Register handlers with widget.On(eventType, func(uikit.Event) bool { ... }, clear bool). Returning true stops the event from reaching any other handlers registered for that type on that widget; clear wipes previously-registered handlers of that type before adding the new one (useful when a handler closure needs to be replaced rather than appended).

Validation

Any widget can be marked invalid: widget.SetInvalid("message") / widget.ClearInvalid() / widget.IsInvalid() (bool, string). An invalid widget gets an error-colored border and an error line drawn below it, and its height grows to make room automatically — layouts don't need special-casing. See g.txtB and g.sel in demo/game.go for a required-field example wired to EventValueChange.

Scrolling

Stack, RowStack and Grid all embed uikit.Scroller. Give any of them a fixed height via SetHeight(px) and they become scrollable: mouse wheel, and press-drag on both desktop and touch, with a themed scrollbar that (by default, uikit.ScrollbarOnMove) only appears while scrolling.

Focus & keyboard navigation

Context.Update() handles Tab/Shift+Tab to cycle focus across visible, enabled, focusable widgets, and routes pointer clicks to focus the topmost hit widget. Widgets opt in via Focusable() bool (layouts return false; interactive controls return true).

Text input & IME (soft keyboards)

TextInput and TextArea implement uikit.IME, exposing an IMEOptions bitmask you set to hint the platform keyboard: keyboard kind (KeyboardText, KeyboardNumber, KeyboardEmail, KeyboardPhone, KeyboardURI, KeyboardPassword, KeyboardMultiline), the return-key action (ActionGo/ActionSearch/ActionSend/ActionNext/ActionDone), capitalization (CapsSentences/CapsWords/CapsAll), and flags like NoSuggestions/NoPersonalizedLearning.

On desktop these are mostly no-ops (real keyboard input works regardless); on mobile, wire a platform uikit.IMEBridge via Context.SetIMEBridge — see cmd/android for the Ebiten Mobile integration that shows/hides the Android keyboard and syncs IME composing text.

Building for other platforms

Desktop:

go run ./cmd/demo

WebAssembly — this is exactly how the live demo above was built, and is served straight from docs/ via GitHub Pages:

GOOS=js GOARCH=wasm go build -ldflags="-s -w" -trimpath -o docs/demo.wasm ./cmd/demo
cp "$(go env GOROOT)/lib/wasm/wasm_exec.js" docs/   # older Go: misc/wasm/wasm_exec.js
touch docs/.nojekyll                                # skip Jekyll processing on Pages

docs/index.html loads the glue script and does WebAssembly.instantiateStreaming(fetch("demo.wasm"), go.importObject).then(r => go.run(r.instance)), with a plain fallback for servers/browsers that don't stream-compile. Ebiten creates and manages its own <canvas> — no other markup is required. To publish: push docs/ to master and enable Settings → Pages → Deploy from a branch → master /docs on GitHub.

Android: see cmd/android/README.md for the Ebiten Mobile + apk-ebiten-builder toolchain, including the IME bridge wiring.

Examples in this repo

Path What it shows
cmd/demo (source in demo/game.go) Every widget and both Stack/Grid layouts together, with live focus/TPS/FPS labels, validation, and a custom Container. This is the binary behind the live WASM demo.
cmd/rowstack RowStack layout patterns — mixed column weights per row.
cmd/android / example/android Packaging the demo as an Android APK via Ebiten Mobile, with the IME bridge connected to the system keyboard.

License

MIT — see LICENSE.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Base

type Base struct {
	EventDispatcher

	HeightCalculator func() int
	// contains filtered or unexported fields
}

Base contains shared widget state.

func NewBase

func NewBase(cfg *WidgetBaseConfig) Base

func (*Base) ClearInvalid

func (b *Base) ClearInvalid()

func (*Base) Draw

func (c *Base) Draw(ctx *Context, dst *ebiten.Image) image.Rectangle

func (*Base) DrawBorder

func (c *Base) DrawBorder(ctx *Context, dst *ebiten.Image, r image.Rectangle)

func (*Base) DrawFocus

func (c *Base) DrawFocus(ctx *Context, dst *ebiten.Image, r image.Rectangle)

func (*Base) DrawInvalid

func (c *Base) DrawInvalid(ctx *Context, dst *ebiten.Image, r image.Rectangle)

func (*Base) DrawRoundedBorder

func (c *Base) DrawRoundedBorder(dst *ebiten.Image, r image.Rectangle, radius int, borderW int, col color.RGBA)

func (*Base) DrawRoundedRect

func (c *Base) DrawRoundedRect(dst *ebiten.Image, r image.Rectangle, radius int, col color.RGBA)

func (*Base) DrawSurface

func (c *Base) DrawSurface(ctx *Context, dst *ebiten.Image, r image.Rectangle)

func (*Base) ErrorRect

func (b *Base) ErrorRect() image.Rectangle

func (*Base) IsEnabled

func (b *Base) IsEnabled() bool

func (*Base) IsFocused

func (b *Base) IsFocused() bool

func (*Base) IsHovered

func (b *Base) IsHovered() bool

func (*Base) IsInvalid

func (b *Base) IsInvalid() (bool, string)

func (*Base) IsPressed

func (b *Base) IsPressed() bool

func (*Base) IsVisible

func (b *Base) IsVisible() bool

func (*Base) Measure

func (b *Base) Measure(extended bool) image.Rectangle

func (*Base) SetEnabled

func (b *Base) SetEnabled(v bool)

func (*Base) SetFocused

func (b *Base) SetFocused(v bool)

func (*Base) SetFrame

func (b *Base) SetFrame(x, y, w int)

SetFrame sets the widget position (x,y) and width (w). The final height is computed from the theme and the widget state (e.g. error line, variable-height controls).

func (*Base) SetHovered

func (b *Base) SetHovered(v bool)

func (*Base) SetInvalid

func (b *Base) SetInvalid(err string)

func (*Base) SetPressed

func (b *Base) SetPressed(v bool)

func (*Base) SetVisible

func (b *Base) SetVisible(v bool)

func (*Base) Theme

func (c *Base) Theme() *Theme

type Context

type Context struct {

	// PointerMapper receives a coordinate pair consistent with
	// Game.Layout and returns the corresponding offscreen position.
	//
	// This allows arbitrary pointer projections when the UI has to
	// be drawn to an offscreen first and then projected.
	PointerMapper func(image.Point) image.Point
	// contains filtered or unexported fields
}

Context holds shared state for all widgets.

func NewContext

func NewContext(theme *Theme, root Layout, ime IMEBridge) *Context

func (*Context) Add

func (c *Context) Add(w Widget)

func (*Context) Draw

func (c *Context) Draw(dst *ebiten.Image)

func (*Context) Focused

func (c *Context) Focused() Widget

func (*Context) IMEBridge

func (c *Context) IMEBridge() IMEBridge

func (*Context) Pointer

func (c *Context) Pointer() PointerStatus

func (*Context) Root

func (c *Context) Root() Layout

Root returns the root widget (typically a Layout).

func (*Context) SetFocus

func (c *Context) SetFocus(w Widget)

func (*Context) SetIMEBridge

func (c *Context) SetIMEBridge(b IMEBridge)

SetIMEBridge sets/updates the IME bridge at runtime. It also synchronizes the IME visibility with the currently focused widget.

func (*Context) Theme

func (c *Context) Theme() *Theme

func (*Context) Update

func (c *Context) Update()

type Event

type Event struct {
	Widget  Widget
	Type    EventType
	Pointer *PointerStatus
	Key     ebiten.Key
}

Event is a UI event routed to a widget.

type EventDispatcher

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

EventDispatcher is a small event router that stores handlers per EventType and dispatches incoming events to them in registration order.

func NewEventDispatcher

func NewEventDispatcher() EventDispatcher

NewEventDispatcher creates and returns a new EventDispatcher with no handlers registered.

func (*EventDispatcher) Dispatch

func (d *EventDispatcher) Dispatch(e Event)

Dispatch sends the given event to all handlers registered for its EventType.

Handlers are invoked sequentially in registration order. If a handler returns true, the event propagation stops immediately.

func (*EventDispatcher) On

func (d *EventDispatcher) On(t EventType, h EventHandler, clear bool)

On registers a new handler for the given event type.

Handlers are executed in the order they are registered. If clear is true, any previously registered handlers for the same type are removed before adding this one.

type EventHandler

type EventHandler func(Event) bool

EventHandler is a function invoked when an event is dispatched. If it returns true, the event is considered handled and propagation stops.

type EventType

type EventType int

EventType represents high-level UI events dispatched by the UI Context.

These events are intentionally kept generic so they can be used across widgets without depending on platform-specific details.

const (
	// EventNone is a zero/default value and should generally not be dispatched.
	EventNone EventType = iota
	// EventFocusGained is fired when a widget becomes the focused element.
	EventFocusGained
	// EventFocusLost is fired when a widget stops being the focused element.
	EventFocusLost
	// EventPointerDown is fired when a pointer (mouse/touch) is pressed down
	// over a widget. The event carries pointer coordinates in pixels.
	EventPointerDown
	// EventPointerUp is fired when a pointer (mouse/touch) is released.
	// The event carries pointer coordinates in pixels.
	EventPointerUp
	// EventClick is fired when a full click/tap gesture is detected
	// (typically PointerDown followed by PointerUp on the same widget).
	// The event carries pointer coordinates in pixels.
	EventClick
	// EventKeyDown is fired when a keyboard key is pressed while the widget
	// is focused. The event carries the key code (as int).
	EventKeyDown
	// EventKeyUp is fired when a keyboard key is released while the widget
	// is focused. The event carries the key code (as int).
	EventKeyUp
	// EventValueChange is fired when a widget's value changes due to user
	// interaction (e.g. text changed, checkbox toggled, slider moved, select
	// changed).
	EventValueChange
)

type Hittable

type Hittable interface {
	HitTest(ctx *Context, pos image.Point) bool
}

Hittable allows a widget to extend its clickable area beyond Base.ControlRect.

type IME

type IME interface {
	// IME returns the IME's input type and options. Changes to this value
	// only take effect when restarting the IME.
	IME() IMEOptions

	// IMESyncID must change when externally modifying text or cursor
	// position. This will restart the IME and flush composition.
	IMESyncID() uint64

	// IMEFlush is invoked before hiding or restarting the IME, and receives
	// any remaining composing text.
	IMEFlush(string)
}

IME marks widgets that should trigger IME when focused.

type IMEBridge

type IMEBridge interface {
	// Show restarts the IME input and makes it show up if not already visible.
	//
	// Android values can be derived with [IMEOptions.AndroidParameters]().
	Show(inputType, imeOptions int32)

	// Hide hides the IME if currently visible.
	Hide()

	// Composing returns the text in composition. This text is not yet
	// committed, so it might suddenly be dropped, completed or converted
	// (e.g. kana to kanji). Text should ideally be displayed underlined.
	Composing() string
}

IMEBridge is implemented on the Java side and registered from your mobile package.

type IMEOptions

type IMEOptions int32

IMEOptions control the IME input type and options. There are three parts that can be controlled: the keyboard type, the submit/action icon and capitalization. Options can be combined with bitwise ORs:

opts := KeyboardEmail // keyboard includes @ and .com more prominently
opts := KeyboardURI | ActionSearch // combine two options
opts := KeyboardText | CapSentences // add capitalization
opts := KeyboardText | ActionSend | CapsSentences // all options
const (
	// keyboard Types
	KeyboardRaw       IMEOptions = 0x000 // no configuration, most compatible with key events
	KeyboardText      IMEOptions = 0x100
	KeyboardMultiline IMEOptions = 0x200
	KeyboardNumber    IMEOptions = 0x300
	KeyboardPhone     IMEOptions = 0x400
	KeyboardEmail     IMEOptions = 0x500
	KeyboardURI       IMEOptions = 0x600
	KeyboardPassword  IMEOptions = 0x700

	// action type, typically affects the icon (defaults to return key)
	ActionGo     IMEOptions = 0x010
	ActionSearch IMEOptions = 0x020
	ActionSend   IMEOptions = 0x030
	ActionNext   IMEOptions = 0x040
	ActionDone   IMEOptions = 0x050

	// capitalization (defaults to none)
	CapsSentences IMEOptions = 0x001
	CapsWords     IMEOptions = 0x002
	CapsAll       IMEOptions = 0x003

	// NoSuggestions is intended only for KeyboardText,
	// and is ignored by most IMEs in practice.
	NoSuggestions IMEOptions = 0x1000

	// NoPersonalizedLearning enters an "incognito" mode, often
	// including icons or a color change to reflect it.
	NoPersonalizedLearning IMEOptions = 0x2000
)

IMEOptions constants.

func (IMEOptions) AndroidParameters

func (o IMEOptions) AndroidParameters() (int32, int32)

AndroidParameters returns the inputType and imeOptions to be sent to IMEBridge.Show().

type Layout

type Layout interface {
	Widget
	DrawOverlay(ctx *Context, dst *ebiten.Image)
	SetHeight(int)
	SetPadding(int, int)
	Children() []Widget
	SetChildren([]Widget)
	Add(...Widget)
	Clear()
}

Layout is a Widget that owns children.

type OverlayWidget

type OverlayWidget interface {
	OverlayActive() bool
	DrawOverlay(ctx *Context, dst *ebiten.Image)
}

OverlayWidget can draw an overlay above all other widgets (e.g. Select dropdown).

type PointerStatus

type PointerStatus struct {
	Position   image.Point
	IsDown     bool
	IsJustDown bool
	IsJustUp   bool
	IsTouch    bool
	TouchID    ebiten.TouchID
}

type ScrollbarMode

type ScrollbarMode int

ScrollbarMode controls when the scrollbar is rendered.

const (
	ScrollbarNever ScrollbarMode = iota
	ScrollbarAlways
	// ScrollbarOnMove shows the bar only while scrolling/dragging, and for a short
	// time after the last scroll input.
	ScrollbarOnMove
)

type Scroller

type Scroller struct {
	ScrollY int

	Scrollbar ScrollbarMode
	// contains filtered or unexported fields
}

Scroller is a small helper that manages vertical scrolling and a simple scrollbar. It is intentionally simple and relies on clipping via SubImage when drawing.

func NewScroller

func NewScroller() Scroller

func (*Scroller) Clamp

func (s *Scroller) Clamp(viewportH int, contentH int)

Clamp clamps ScrollY to the valid range for the given viewport height and content height.

func (*Scroller) DrawBar

func (s *Scroller) DrawBar(dst *ebiten.Image, theme *Theme, viewportW, viewportH, contentH int)

DrawBar draws a simple vertical scrollbar inside a clipped target (dst should already be a SubImage of the viewport). viewportW/H should match dst's size.

func (*Scroller) IsScrolling

func (s *Scroller) IsScrolling() bool

func (*Scroller) Update

func (s *Scroller) Update(ctx *Context, viewport image.Rectangle, contentH int)

Update updates scrolling using wheel + drag/touch, only if the pointer is inside viewport. contentH is the full scrollable content height in pixels.

type TextStyle

type TextStyle string

TextStyle identifies a font variant within a theme. Applications may define additional variants, such as "italic" or "narrow".

const (
	TextDefault TextStyle = "default"
	TextBold    TextStyle = "bold"
)

type TextStyles

type TextStyles map[TextStyle]*sfnt.Font

TextStyles maps font variants to their faces. Font size is shared by all variants through Theme.FontPx.

type Theme

type Theme struct {
	TextStyles TextStyles
	FontPx     int
	ControlH   int

	PadX int
	PadY int

	Radius       int
	BorderW      int
	FocusRingW   int
	FocusRingGap int

	SpaceS int
	SpaceM int
	SpaceL int

	CheckSize int // checkbox square size

	// Validation
	ErrorFontPx int
	ErrorGap    int

	// Colors
	TextColor           color.RGBA
	MutedTextColor      color.RGBA
	BackgroundColor     color.RGBA
	SurfaceColor        color.RGBA
	SurfaceHoverColor   color.RGBA
	SurfacePressedColor color.RGBA
	BorderColor         color.RGBA
	FocusColor          color.RGBA
	DisabledColor       color.RGBA
	ErrorTextColor      color.RGBA
	ErrorBorderColor    color.RGBA
	Scrollbar           color.RGBA
	CaretColor          color.RGBA

	// Scrollbar
	ScrollbarRadius int
	ScrollbarMinH   int
	ScrollbarW      int

	// Caret
	CaretWidthPx  int
	CaretBlink    time.Duration
	CaretMarginPx int
	// contains filtered or unexported fields
}

Theme is the single source of truth for widget proportions. Only the font and font size are inputs; everything else derives from them.

func DefaultTheme

func DefaultTheme() *Theme

func NewTheme

func NewTheme(font *sfnt.Font, fontPx int) *Theme

func (*Theme) ErrorText

func (t *Theme) ErrorText() *etxt.Renderer

func (*Theme) Renderer

func (t *Theme) Renderer(style TextStyle) *etxt.Renderer

Renderer returns the shared text renderer configured for style. Missing or nil variants fall back to TextDefault.

func (*Theme) Text

func (t *Theme) Text() *etxt.Renderer

Text returns the shared renderer configured with the default text style.

type ValidableWidget

type ValidableWidget interface {
	IsValidable() bool
	IsInvalid() (bool, string)
	SetInvalid(err string)
	ClearInvalid()
}

type Widget

type Widget interface {
	SetFrame(x, y, w int)

	IsHovered() bool
	SetHovered(bool)
	IsPressed() bool
	SetPressed(bool)
	IsFocused() bool
	SetFocused(bool)
	IsEnabled() bool
	SetEnabled(bool)
	IsVisible() bool
	SetVisible(bool)

	Focusable() bool

	Measure(bool) image.Rectangle
	Update(ctx *Context)
	Draw(ctx *Context, dst *ebiten.Image)

	On(t EventType, cb EventHandler, clear bool)
	Dispatch(e Event)
}

type WidgetBaseConfig

type WidgetBaseConfig struct {
	Theme       *Theme
	DrawSurface bool
	DrawBorder  bool
	DrawFocus   bool
	DrawInvalid bool
}

func NewWidgetBaseConfig

func NewWidgetBaseConfig(theme *Theme) *WidgetBaseConfig

Directories

Path Synopsis
cmd
demo command
rowstack command

Jump to

Keyboard shortcuts

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