Helps you build and debug Guigui GUI components and interactions.
Copy the install command and let the AI configure it · recommended for beginners
Please install the "using-guigui" skill from askskill: 1. Download https://raw.githubusercontent.com/guigui-gui/guigui/main/.agents/skills/using-guigui/SKILL.md 2. Save it as ~/.claude/skills/using-guigui/SKILL.md 3. Reload skills and tell me it's ready
Use Guigui to build a UI with a title, text input, and submit button, and explain the layout relationships.
A Guigui component tree, LinearLayout layout plan, and button click handling approach.
In Guigui, I bound a text field to shared state, but changes do not show immediately. Analyze possible causes and suggest fixes.
An explanation of when state triggers rebuilds and the correct use of Env injection or event callbacks.
Implement a dynamic list in Guigui that supports add, remove, and item selection, and explain how dynamic children are handled.
Dynamic child list implementation guidance, event binding, and pointer/keyboard input handling.
Guigui is an immediate-mode-inspired GUI framework for Go on top of Ebitengine.
"Inspired" is the key word: widgets are retained Go structs that you own and
keep across ticks, but their child tree and presentation are reconstructed
by re-running Build whenever relevant state changes — the way Compose or
SwiftUI re-run a view function. You hold the state in struct fields; the
framework decides when to rebuild, lay out, and redraw.
Read this whole file before writing widget code; the lifecycle rules below are the part people get wrong.
Freshness. Verified against Guigui at commit
4ebb3fc7(2026-06-25). Guigui is alpha and its API may change — if anything here disagrees with the source, the source wins: trust*.goin the module root and the programs underexample/over this file, and update this skill when you find drift.
guigui.DefaultWidget and overrides the
methods it needs. DefaultWidget supplies no-op defaults for every method, so
override only what matters.&w.child. Do not allocate them in
a constructor; var w Foo must already be usable.Update,
at the app's TPS — 60×/sec by default, or whatever TPS is configured) settles
the tree: it may run Build (reconstruct the child tree), Layout
(position the children), and the Handle*Input methods an indeterminate
number of times, interleaved, until state stops changing — then calls Tick
exactly once. Rely only on these guarantees: within a pass Build precedes
Layout, and Tick runs once, last. Do not assume a fixed count of Build, Layout,
or input passes per tick, nor that an input handler runs only once before
Tick. Each frame (Ebitengine's Draw, at the display's refresh rate)
does Draw. Ticks and frames are not one-to-one — there may be more or
fewer frames than ticks — so put per-step logic in Tick, never in Draw.Build, Layout,
Tick, Draw, the Handle*Input methods, Env, …) yourself — you set fields
and register handlers, and the framework calls back. The one exception is
Measure: a parent or composite widget calls a child's Measure directly
to size it (it is what LinearLayout and the shared layout() helper do).package main
import (
"image"
"log"
"github.com/guigui-gui/guigui"
"github.com/guigui-gui/guigui/basicwidget"
)
type Root struct {
guigui.DefaultWidget
background basicwidget.Background
hello basicwidget.Text
}
func (r *Root) Build(context *guigui.Context, adder *guigui.ChildAdder) error {
adder.AddWidget(&r.background)
adder.AddWidget(&r.hello)
r.hello.SetValue("Hello, Guigui")
return nil
}
func (r *Root) Layout(context *guigui.Context, widgetBounds *guigui.WidgetBounds, layouter *guigui.ChildLayouter) {
layouter.LayoutWidget(&r.background, widgetBounds.Bounds())
layouter.LayoutWidget(&r.hello, widgetBounds.Bounds())
}
func main() {
if err := guigui.Run(&Root{}, &guigui.RunOptions{
Title: "Example",
WindowMinSize: image.Pt(480, 320),
}); err != nil {
log.Fatal(err)
}
}
guigui.Run(root, *RunOptions) starts the app. RunOptions carries Title,
WindowSize / WindowMinSize / WindowMaxSize, AppScale, and an optional
RunGameOptions passed through to Ebitengine.
Embed guigui.DefaultWidget, then override as needed:
| Method | Signature | Override when |
|---|---|---|
Build | Build(*Context, *ChildAdder) error | Almost always — declare and configure children. |
Layout | Layout(*Context, *WidgetBounds, *ChildLayouter) | You have children to position (i.e. almost always). |
…
Generate and serve ephemeral interactive UIs from natural language.
Handle UI changes, fixtures, screenshots, and visual testing in component explorer projects.
Build, design, and troubleshoot modern WinUI 3 desktop apps with C#.
Build and refine UI/UX with design exploration, frontend setup, and integration.
Lets AI understand and operate web interfaces through unified UI scene graphs.
Build Windows apps with WinUI 3 and the Windows App SDK.