Expand description
ToolBox — a vertical stack of collapsible sections, exactly one expanded at a time.
Semantic cousin of Qt’s QToolBox and the collapsible groups in
IntelliJ’s Settings dialog. Differs from Accordion
(single-item independent disclosure) and TabWidget
(horizontal tab bar with dormant panes) by combining vertical layout,
always-visible headers, and exclusive expansion in one widget.
Int UI visual language:
- flat, borderless headers (no corner radius)
- 1 dp accent indicator bar on the leading edge of the active header
- color-only emphasis (selected / hover / pressed surface roles)
- border IS the focus ring: 1 dp accent border appears on the focused header, no separate ring primitive
- content swaps are instant — Int UI’s house rule is to avoid
decorative animation for inline transitions; see
MotionTokens. Matches the existingTabWidgetprecedent where pane swaps have no transition.
ⓘ
let selected = ctx.signal(0_usize);
ToolBox::new(selected.clone())
.item("Outline", outline_widget)
.item("Properties", properties_widget)
.add(ToolBoxItem::new("Build", build_widget).enabled(false))Structs§
- ToolBox
- A vertical container of collapsible sections with exactly one expanded
at a time — the Int UI /
QToolBoxpattern. - Tool
BoxItem - One section of a
ToolBox. Construct withToolBoxItem::newand pass toToolBox::add, or use the convenienceToolBox::item/ToolBox::item_idbuilders directly when leading / trailing slots and tooltip are not needed.
Enums§
- Tool
BoxOrientation - Orientation of a
ToolBox: how its collapsible sections are arranged.