Skip to content
ConsoleMonster

API Reference

Class

RowsBuilderBase`1

Namespace ConsoleMonster.Building
Assembly ConsoleMonster
Modifiers abstract

Base of the fluent vertical-layout builders (RowsBuilder, DashboardBuilder). Every method returns the builder; out parameters hand back the typed widgets so callers can create live handles from them after the session starts.

Inheritance

  • Object
  • RowsBuilderBase`1

Type Parameters

TSelf
The concrete builder type returned by every method.

Methods

public TSelf Add(IWidget widget, LayoutSize? size = null) #
Returns: TSelf

Adds a widget sized to its content.

Parameters

widget ConsoleMonster.Layout.IWidget requiredposition: 0
The widget.
size ConsoleMonster.Layout.LayoutSize? = null optionalposition: 1
Its height specification (default auto).

Returns

This builder.

public TSelf Add<T>(T widget, out T added, LayoutSize? size = null) #
Returns: TSelf

Adds a widget and returns it typed.

Type Parameters

T
The widget type.

Parameters

widget T requiredposition: 0
The widget.
added T requiredposition: 1
The same widget, typed.
size ConsoleMonster.Layout.LayoutSize? = null optionalposition: 2
Its height specification.

Returns

This builder.

public Rows Build() #
Returns: Rows

Builds the layout.

Returns

The rows container.

public TSelf Columns(Action<ColumnsBuilder> configure, LayoutSize? size = null) #
Returns: TSelf

Adds a row of columns.

Parameters

configure System.Action<ConsoleMonster.Building.ColumnsBuilder> requiredposition: 0
Configures the columns.
size ConsoleMonster.Layout.LayoutSize? = null optionalposition: 1
Its height specification (default auto).

Returns

This builder.

public TSelf Gap(Int32 gap) #
Returns: TSelf

Blank rows between children.

Parameters

gap System.Int32 requiredposition: 0
The gap.

Returns

This builder.

public TSelf Panel(String title, IWidget content, Boolean fill = false, String? caption = null) #
Returns: TSelf

Adds any content inside a titled panel.

Parameters

title System.String requiredposition: 0
The panel title (markup).
content ConsoleMonster.Layout.IWidget requiredposition: 1
The content.
fill System.Boolean = false optionalposition: 2
Whether the panel takes the remaining height in a live frame.
caption System.String? = null optionalposition: 3
Text on the right of the top edge.

Returns

This builder.

public TSelf Panel<T>(String title, T widget, out T added, Boolean fill = false, String? caption = null) #
Returns: TSelf

Adds a widget inside a titled panel.

Type Parameters

T
The widget type.

Parameters

title System.String requiredposition: 0
The panel title (markup).
widget T requiredposition: 1
The content.
added T requiredposition: 2
The content, typed.
fill System.Boolean = false optionalposition: 3
Whether the panel takes the remaining height in a live frame.
caption System.String? = null optionalposition: 4
Text on the right of the top edge.

Returns

This builder.

public TSelf Region(String title, String name, IWidget? content = null, Boolean fill = false, String? caption = null) #
Returns: TSelf

Adds a panel whose content can be replaced while the session runs: the panel frame stays and the content is a Slot named name (see LiveSession.Region).

Parameters

title System.String requiredposition: 0
The panel title.
name System.String requiredposition: 1
The region name.
content ConsoleMonster.Layout.IWidget? = null optionalposition: 2
The first content, or null for an empty region.
fill System.Boolean = false optionalposition: 3
Whether the panel takes the remaining height.
caption System.String? = null optionalposition: 4
A caption in the bottom border, or null.

Returns

This builder.