Table of Contents

Method Layout

Namespace
Terminal.Gui.ViewBase
Assembly
Terminal.Gui.dll

Layout(Size)

Resolves the view's declarative layout and then lays out its subviews within the specified content size.

public bool Layout(Size contentSize)

Parameters

contentSize Size

Returns

bool

falseIf the view could not be laid out (typically because a dependencies was not ready).

Remarks

See the View Layout Deep Dive for more information: https://gui-cs.github.io/Terminal.Gui/docs/layout.html

This method turns responsive Pos and Dim expressions into an absolute Frame, then recursively lays out SubViews.

This method is intended to be called by the layout engine to prepare the view for layout and is exposed as a public API primarily for testing purposes.

Layout()

Resolves the view's declarative layout and then lays out its subviews using the content size of either the SuperView or Screen.

public bool Layout()

Returns

bool

falseIf the view could not be laid out (typically because dependency was not ready).

Remarks

See the View Layout Deep Dive for more information: https://gui-cs.github.io/Terminal.Gui/docs/layout.html

To force a responsive layout pass after changing X, Y, Width, or Height, call this overload.

This method is intended to be called by the layout engine to prepare the view for layout and is exposed as a public API primarily for testing purposes.