functions

FormRow
Edited: Sunday 25 January 2026

FormRow

Category: Layouts
File: layouts.go
Package: ui

Signature

1func FormRow(children ...layout.FlexChild) W

Description

FormRow creates a horizontal layout with vertical centering for form elements.
Identical to ColumnsVCentered, specifically named for form field layouts.

Example:

row := FormRow(
    Rigid(Label("Name:")),
    Flexed(1, TextInput(editor, "Enter name")),
)

Convention for laying out form labels next to input fields.

Examples

FormRow

1{
2	editor := LineEditor()
3	row := FormRow(
4		Rigid(Label("Name:")),
5		Flexed(1, TextInput(&editor, "Enter name")),
6	)
7	_ = row
8}

Example Output


This documentation is auto-generated. To update, run make docs

Backlinks