A renderable panel.
Constructors
public Panel(string text)
Initializes a new instance of the Panel class.
Parameters:
text (string)public Panel(IRenderable content)
Initializes a new instance of the Panel class.
Parameters:
content (IRenderable)Properties
Border
: BoxBorderGets or sets the box.
Expand
: boolGets or sets a value indicating whether or not the panel should fit the available space. If false, the panel width will be auto calculated. Defaults to false.
Header
: PanelHeaderGets or sets the header.
Height
: int?Gets or sets the height of the panel.
Padding
: Padding?Gets or sets the padding.
UseSafeBorder
: boolGets or sets a value indicating whether or not to use a "safe" border on legacy consoles that might not be able to render non-ASCII characters.
Width
: int?Gets or sets the width of the panel.
Extension Methods
Panel Header(this Panel panel, PanelHeader header)Sets the panel header.
Returns:
The same instance so that multiple calls can be chained.
Panel Header(this Panel panel, string text, Justify? alignment)Sets the panel header.
Returns:
The same instance so that multiple calls can be chained.
Panel HeaderAlignment(this Panel panel, Justify alignment)Sets the panel header alignment.
Returns:
The same instance so that multiple calls can be chained.