Skip to content
ConsoleMonster
Class

LayoutFluent

ConsoleMonster.Layout

Namespace
ConsoleMonster.Layout
Assembly
ConsoleMonster
Modifiers
static

The fluent methods of Align, generated from its public properties: A property-named method sets a property and Add... adds to a collection, both returning the same instance.

Inheritance

  • object
  • LayoutFluent

Methods

public static ColumnFormat Alignment(ColumnFormat columnFormat, HorizontalAlignment value) #

Sets ColumnFormat.Alignment: Alignment of values inside the column; numbers default to right.

Parameters

columnFormat ConsoleMonster.Layout.ColumnFormat required
The instance.
value ConsoleMonster.Layout.HorizontalAlignment required
The value.

Returns

ColumnFormat The same instance.

Examples

// C# initializer or property                                            // C# fluent
new global::ConsoleMonster.Layout.ColumnFormat { Alignment = value };    Ui.ColumnFormat().Alignment(value);
AllowShrink 2 overloads
public static ColumnFormat AllowShrink(ColumnFormat columnFormat, bool value) #

Sets ColumnFormat.AllowShrink: When true, the column follows its current values and may shrink; defaults to false.

Parameters

columnFormat ConsoleMonster.Layout.ColumnFormat required
The instance.
value bool required
The value.

Returns

ColumnFormat The same instance.

Examples

// C# initializer or property                                              // C# fluent
new global::ConsoleMonster.Layout.ColumnFormat { AllowShrink = value };    Ui.ColumnFormat().AllowShrink(value);
public static ColumnFormat AllowShrink(ColumnFormat columnFormat) #

Sets ColumnFormat.AllowShrink to true.

Parameters

columnFormat ConsoleMonster.Layout.ColumnFormat required
The instance to configure.

Returns

ColumnFormat The same instance.
public static Panel Border(Panel panel, BoxStyle value) #

Sets Panel.Border: The border style (default rounded).

Parameters

panel ConsoleMonster.Layout.Panel required
The instance.
value ConsoleMonster.Glyphs.BoxStyle required
The value.

Returns

Panel The same instance.

Examples

// C# initializer or property                                  // C# fluent
new global::ConsoleMonster.Layout.Panel { Border = value };    Ui.Panel().Border(value);
public static Panel BorderRole(Panel panel, ThemeToken value) #

Sets Panel.BorderRole: The theme token for the border (default ThemeToken.Border).

Parameters

panel ConsoleMonster.Layout.Panel required
The instance.
value ConsoleMonster.Styling.ThemeToken required
The value.

Returns

Panel The same instance.

Examples

// C# initializer or property                                      // C# fluent
new global::ConsoleMonster.Layout.Panel { BorderRole = value };    Ui.Panel().BorderRole(value);
public static Padding Bottom(Padding padding, int value) #

Sets Padding.Bottom: Bottom rows.

Parameters

padding ConsoleMonster.Layout.Padding required
The instance.
value int required
The value.

Returns

Padding The same instance.

Examples

// C# initializer or property                                    // C# fluent
new global::ConsoleMonster.Layout.Padding { Bottom = value };    Ui.Padding().Bottom(value);
public static Panel Caption(Panel panel, string? value) #

Sets Panel.Caption: Text on the right of the bottom edge (markup), for example "+12 more".

Parameters

panel ConsoleMonster.Layout.Panel required
The instance.
value string? required
The value.

Returns

Panel The same instance.

Examples

// C# initializer or property                                   // C# fluent
new global::ConsoleMonster.Layout.Panel { Caption = value };    Ui.Panel().Caption(value);
public static Columns CollapseBelow(Columns columns, int value) #

Sets Columns.CollapseBelow: Width below which the columns stack vertically. -1 (default) uses the sum of the children's minimum widths (fractions without a minimum count as 16 cells).

Parameters

columns ConsoleMonster.Layout.Columns required
The instance.
value int required
The value.

Returns

Columns The same instance.

Examples

// C# initializer or property     // C# fluent
columns.CollapseBelow = value;    Ui.Columns().CollapseBelow(value);
public static LayoutGrid ColumnGap(LayoutGrid layoutGrid, int value) #

Sets LayoutGrid.ColumnGap: Blank columns between cells (default 1).

Parameters

layoutGrid ConsoleMonster.Layout.LayoutGrid required
The instance.
value int required
The value.

Returns

LayoutGrid The same instance.

Examples

// C# initializer or property    // C# fluent
layoutGrid.ColumnGap = value;    Ui.LayoutGrid().ColumnGap(value);
public static LayoutGrid Columns(LayoutGrid layoutGrid, int value) #

Sets LayoutGrid.Columns: The preferred number of columns.

Parameters

layoutGrid ConsoleMonster.Layout.LayoutGrid required
The instance.
value int required
The value.

Returns

LayoutGrid The same instance.

Examples

// C# initializer or property    // C# fluent
layoutGrid.Columns = value;      Ui.LayoutGrid().Columns(value);
Content 14 overloads
public static Align Content(Align align, IWidget content) #

Configures this container's content before session ownership.

Parameters

align ConsoleMonster.Layout.Align required
The instance.
content ConsoleMonster.Layout.IWidget required
The widget or nested content builder.

Returns

Align The same instance.
public static Align Content(Align align, Action<ContentBuilder> content) #

Configures this container's content before session ownership.

Parameters

align ConsoleMonster.Layout.Align required
The instance.
content System.Action<ConsoleMonster.Layout.ContentBuilder> required
The widget or nested content builder.

Returns

Align The same instance.
public static Columns Content(Columns columns, IWidget content) #

Configures this container's content before session ownership.

Parameters

columns ConsoleMonster.Layout.Columns required
The instance.
content ConsoleMonster.Layout.IWidget required
The widget or nested content builder.

Returns

Columns The same instance.
public static Columns Content(Columns columns, Action<ContentBuilder> content) #

Configures this container's content before session ownership.

Parameters

columns ConsoleMonster.Layout.Columns required
The instance.
content System.Action<ConsoleMonster.Layout.ContentBuilder> required
The widget or nested content builder.

Returns

Columns The same instance.
public static LayoutGrid Content(LayoutGrid layoutGrid, IWidget content) #

Configures this container's content before session ownership.

Parameters

layoutGrid ConsoleMonster.Layout.LayoutGrid required
The instance.
content ConsoleMonster.Layout.IWidget required
The widget or nested content builder.

Returns

LayoutGrid The same instance.
public static LayoutGrid Content(LayoutGrid layoutGrid, Action<ContentBuilder> content) #

Configures this container's content before session ownership.

Parameters

layoutGrid ConsoleMonster.Layout.LayoutGrid required
The instance.
content System.Action<ConsoleMonster.Layout.ContentBuilder> required
The widget or nested content builder.

Returns

LayoutGrid The same instance.
public static Padding Content(Padding padding, IWidget content) #

Configures this container's content before session ownership.

Parameters

padding ConsoleMonster.Layout.Padding required
The instance.
content ConsoleMonster.Layout.IWidget required
The widget or nested content builder.

Returns

Padding The same instance.
public static Padding Content(Padding padding, Action<ContentBuilder> content) #

Configures this container's content before session ownership.

Parameters

padding ConsoleMonster.Layout.Padding required
The instance.
content System.Action<ConsoleMonster.Layout.ContentBuilder> required
The widget or nested content builder.

Returns

Padding The same instance.
public static Panel Content(Panel panel, IWidget content) #

Configures this container's content before session ownership.

Parameters

panel ConsoleMonster.Layout.Panel required
The instance.
content ConsoleMonster.Layout.IWidget required
The widget or nested content builder.

Returns

Panel The same instance.
public static Panel Content(Panel panel, Action<ContentBuilder> content) #

Configures this container's content before session ownership.

Parameters

panel ConsoleMonster.Layout.Panel required
The instance.
content System.Action<ConsoleMonster.Layout.ContentBuilder> required
The widget or nested content builder.

Returns

Panel The same instance.
public static Rows Content(Rows rows, IWidget content) #

Configures this container's content before session ownership.

Parameters

rows ConsoleMonster.Layout.Rows required
The instance.
content ConsoleMonster.Layout.IWidget required
The widget or nested content builder.

Returns

Rows The same instance.
public static Rows Content(Rows rows, Action<ContentBuilder> content) #

Configures this container's content before session ownership.

Parameters

rows ConsoleMonster.Layout.Rows required
The instance.
content System.Action<ConsoleMonster.Layout.ContentBuilder> required
The widget or nested content builder.

Returns

Rows The same instance.
public static Stack Content(Stack stack, IWidget content) #

Configures this container's content before session ownership.

Parameters

stack ConsoleMonster.Layout.Stack required
The instance.
content ConsoleMonster.Layout.IWidget required
The widget or nested content builder.

Returns

Stack The same instance.
public static Stack Content(Stack stack, Action<ContentBuilder> content) #

Configures this container's content before session ownership.

Parameters

stack ConsoleMonster.Layout.Stack required
The instance.
content System.Action<ConsoleMonster.Layout.ContentBuilder> required
The widget or nested content builder.

Returns

Stack The same instance.
Expand 2 overloads
public static Panel Expand(Panel panel, bool value) #

Sets Panel.Expand: Whether the panel takes the full available width (default true).

Parameters

panel ConsoleMonster.Layout.Panel required
The instance.
value bool required
The value.

Returns

Panel The same instance.

Examples

// C# initializer or property                                  // C# fluent
new global::ConsoleMonster.Layout.Panel { Expand = value };    Ui.Panel().Expand(value);
public static Panel Expand(Panel panel) #

Sets Panel.Expand to true.

Parameters

panel ConsoleMonster.Layout.Panel required
The instance to configure.

Returns

Panel The same instance.
FillHeight 2 overloads
public static LayoutGrid FillHeight(LayoutGrid layoutGrid, bool value) #

Sets LayoutGrid.FillHeight: Whether rows grow to fill spare height in a bounded region (default true).

Parameters

layoutGrid ConsoleMonster.Layout.LayoutGrid required
The instance.
value bool required
The value.

Returns

LayoutGrid The same instance.

Examples

// C# initializer or property     // C# fluent
layoutGrid.FillHeight = value;    Ui.LayoutGrid().FillHeight(value);
public static LayoutGrid FillHeight(LayoutGrid layoutGrid) #

Sets LayoutGrid.FillHeight to true.

Parameters

layoutGrid ConsoleMonster.Layout.LayoutGrid required
The instance to configure.

Returns

LayoutGrid The same instance.
Gap 3 overloads
public static Columns Gap(Columns columns, int value) #

Sets Columns.Gap: Blank columns between children (default 1).

Parameters

columns ConsoleMonster.Layout.Columns required
The instance.
value int required
The value.

Returns

Columns The same instance.

Examples

// C# initializer or property    // C# fluent
columns.Gap = value;             Ui.Columns().Gap(value);
public static Panel Gap(Panel panel, int value) #

Sets Panel.Gap: Blank rows between content children when the content is several widgets, as a report usually is (default 0).

Parameters

panel ConsoleMonster.Layout.Panel required
The instance.
value int required
The value.

Returns

Panel The same instance.

Examples

// C# initializer or property                               // C# fluent
new global::ConsoleMonster.Layout.Panel { Gap = value };    Ui.Panel().Gap(value);
public static Rows Gap(Rows rows, int value) #

Sets Rows.Gap: Blank rows between children.

Parameters

rows ConsoleMonster.Layout.Rows required
The instance.
value int required
The value.

Returns

Rows The same instance.

Examples

// C# initializer or property    // C# fluent
rows.Gap = value;                Ui.Rows().Gap(value);
public static Panel HeaderRight(Panel panel, string? value) #

Sets Panel.HeaderRight: Text on the right of the top edge (markup), for example a count or a clock.

Parameters

panel ConsoleMonster.Layout.Panel required
The instance.
value string? required
The value.

Returns

Panel The same instance.

Examples

// C# initializer or property                                       // C# fluent
new global::ConsoleMonster.Layout.Panel { HeaderRight = value };    Ui.Panel().HeaderRight(value);
public static Panel Height(Panel panel, int? value) #

Sets Panel.Height: A fixed total height including borders, or null to fit the content.

Parameters

panel ConsoleMonster.Layout.Panel required
The instance.
value int? required
The value.

Returns

Panel The same instance.

Examples

// C# initializer or property                                  // C# fluent
new global::ConsoleMonster.Layout.Panel { Height = value };    Ui.Panel().Height(value);
public static Align Horizontal(Align align, HorizontalAlignment value) #

Sets Align.Horizontal: Horizontal placement.

Parameters

align ConsoleMonster.Layout.Align required
The instance.
value ConsoleMonster.Layout.HorizontalAlignment required
The value.

Returns

Align The same instance.

Examples

// C# initializer or property                                      // C# fluent
new global::ConsoleMonster.Layout.Align { Horizontal = value };    Ui.Align().Horizontal(value);
public static Padding Left(Padding padding, int value) #

Sets Padding.Left: Left cells.

Parameters

padding ConsoleMonster.Layout.Padding required
The instance.
value int required
The value.

Returns

Padding The same instance.

Examples

// C# initializer or property                                  // C# fluent
new global::ConsoleMonster.Layout.Padding { Left = value };    Ui.Padding().Left(value);
public static LayoutGrid MinColumnWidth(LayoutGrid layoutGrid, int value) #

Sets LayoutGrid.MinColumnWidth: The narrowest column before the grid reduces its column count (default 24).

Parameters

layoutGrid ConsoleMonster.Layout.LayoutGrid required
The instance.
value int required
The value.

Returns

LayoutGrid The same instance.

Examples

// C# initializer or property         // C# fluent
layoutGrid.MinColumnWidth = value;    Ui.LayoutGrid().MinColumnWidth(value);
public static ColumnFormat MinWidth(ColumnFormat columnFormat, int value) #

Sets ColumnFormat.MinWidth: Minimum width in cells (never negative).

Parameters

columnFormat ConsoleMonster.Layout.ColumnFormat required
The instance.
value int required
The value.

Returns

ColumnFormat The same instance.

Examples

// C# initializer or property                                           // C# fluent
new global::ConsoleMonster.Layout.ColumnFormat { MinWidth = value };    Ui.ColumnFormat().MinWidth(value);
public static Panel PaddingBottom(Panel panel, int value) #

Sets Panel.PaddingBottom: Rows between the content and the bottom border (default 0).

Parameters

panel ConsoleMonster.Layout.Panel required
The instance.
value int required
The value.

Returns

Panel The same instance.

Examples

// C# initializer or property                                         // C# fluent
new global::ConsoleMonster.Layout.Panel { PaddingBottom = value };    Ui.Panel().PaddingBottom(value);
public static Panel PaddingLeft(Panel panel, int value) #

Sets Panel.PaddingLeft: Cells between the left border and the content (default 1).

Parameters

panel ConsoleMonster.Layout.Panel required
The instance.
value int required
The value.

Returns

Panel The same instance.

Examples

// C# initializer or property                                       // C# fluent
new global::ConsoleMonster.Layout.Panel { PaddingLeft = value };    Ui.Panel().PaddingLeft(value);
public static Panel PaddingRight(Panel panel, int value) #

Sets Panel.PaddingRight: Cells between the content and the right border (default 1).

Parameters

panel ConsoleMonster.Layout.Panel required
The instance.
value int required
The value.

Returns

Panel The same instance.

Examples

// C# initializer or property                                        // C# fluent
new global::ConsoleMonster.Layout.Panel { PaddingRight = value };    Ui.Panel().PaddingRight(value);
public static Panel PaddingTop(Panel panel, int value) #

Sets Panel.PaddingTop: Rows between the top border and the content (default 0).

Parameters

panel ConsoleMonster.Layout.Panel required
The instance.
value int required
The value.

Returns

Panel The same instance.

Examples

// C# initializer or property                                      // C# fluent
new global::ConsoleMonster.Layout.Panel { PaddingTop = value };    Ui.Panel().PaddingTop(value);
public static ColumnFormat ReserveDigits(ColumnFormat columnFormat, int value) #

Sets ColumnFormat.ReserveDigits: Digits reserved for numeric values, for example 4 to keep room for 9999 from the first frame. Zero (the default) reserves only what the widget knows (its totals) or has already displayed.

Parameters

columnFormat ConsoleMonster.Layout.ColumnFormat required
The instance.
value int required
The value.

Returns

ColumnFormat The same instance.

Examples

// C# initializer or property                                                // C# fluent
new global::ConsoleMonster.Layout.ColumnFormat { ReserveDigits = value };    Ui.ColumnFormat().ReserveDigits(value);
public static Padding Right(Padding padding, int value) #

Sets Padding.Right: Right cells.

Parameters

padding ConsoleMonster.Layout.Padding required
The instance.
value int required
The value.

Returns

Padding The same instance.

Examples

// C# initializer or property                                   // C# fluent
new global::ConsoleMonster.Layout.Padding { Right = value };    Ui.Padding().Right(value);
public static LayoutGrid RowGap(LayoutGrid layoutGrid, int value) #

Sets LayoutGrid.RowGap: Blank rows between grid rows (default 0).

Parameters

layoutGrid ConsoleMonster.Layout.LayoutGrid required
The instance.
value int required
The value.

Returns

LayoutGrid The same instance.

Examples

// C# initializer or property    // C# fluent
layoutGrid.RowGap = value;       Ui.LayoutGrid().RowGap(value);
public static Panel Status(Panel panel, StatusKind? value) #

Sets Panel.Status: Optional status colour and title glyph for a verdict.

Parameters

panel ConsoleMonster.Layout.Panel required
The instance.
value ConsoleMonster.Styling.StatusKind? required
The value.

Returns

Panel The same instance.

Examples

// C# initializer or property                                  // C# fluent
new global::ConsoleMonster.Layout.Panel { Status = value };    Ui.Panel().Status(value);
public static Panel Title(Panel panel, string? value) #

Sets Panel.Title: The title shown in the top edge (markup).

Parameters

panel ConsoleMonster.Layout.Panel required
The instance.
value string? required
The value.

Returns

Panel The same instance.

Examples

// C# initializer or property                                 // C# fluent
new global::ConsoleMonster.Layout.Panel { Title = value };    Ui.Panel().Title(value);
public static Padding Top(Padding padding, int value) #

Sets Padding.Top: Top rows.

Parameters

padding ConsoleMonster.Layout.Padding required
The instance.
value int required
The value.

Returns

Padding The same instance.

Examples

// C# initializer or property                                 // C# fluent
new global::ConsoleMonster.Layout.Padding { Top = value };    Ui.Padding().Top(value);
Verdict 2 overloads
public static Panel Verdict(Panel panel, bool value) #

Sets Panel.Verdict: Uses a double border and a centred title for a verdict.

Parameters

panel ConsoleMonster.Layout.Panel required
The instance.
value bool required
The value.

Returns

Panel The same instance.

Examples

// C# initializer or property                                   // C# fluent
new global::ConsoleMonster.Layout.Panel { Verdict = value };    Ui.Panel().Verdict(value);
public static Panel Verdict(Panel panel) #

Sets Panel.Verdict to true.

Parameters

panel ConsoleMonster.Layout.Panel required
The instance to configure.

Returns

Panel The same instance.
public static Align Vertical(Align align, VerticalAlignment value) #

Sets Align.Vertical: Vertical placement.

Parameters

align ConsoleMonster.Layout.Align required
The instance.
value ConsoleMonster.Layout.VerticalAlignment required
The value.

Returns

Align The same instance.

Examples

// C# initializer or property                                    // C# fluent
new global::ConsoleMonster.Layout.Align { Vertical = value };    Ui.Align().Vertical(value);