Table of Contents

Class Header

Namespace
ConsoleAppVisuals.PassiveElements
Assembly
ConsoleAppVisuals.dll

The Header is a passive element that displays a header on the console.

public class Header : PassiveElement
Inheritance
Header
Inherited Members

Remarks

For more information, consider visiting the documentation available here.

Constructors

Header(string, string, string, int)

The Header is a passive element that displays a header on the console.

public Header(string leftText = "Header Left", string centerText = "Header Center", string rightText = "Header Right", int margin = 1)

Parameters

leftText string

The text on the left of the header.

centerText string

The text in the center of the header.

rightText string

The text on the right of the header.

margin int

The margin of the header.

Remarks

For more information, consider visiting the documentation available here.

Properties

Height

Gets the height of the header.

public override int Height { get; }

Property Value

int

Margin

Gets the margin of the header.

public int Margin { get; }

Property Value

int

MaxNumberOfThisElement

Gets the maximum number of this element.

public override int MaxNumberOfThisElement { get; }

Property Value

int

Placement

Gets the placement of the header.

public override Placement Placement { get; }

Property Value

Placement

Text

Gets the text of the header.

public (string, string, string) Text { get; }

Property Value

(string, string, string)

Width

Gets the width of the header.

public override int Width { get; }

Property Value

int

Methods

RenderElementActions()

Defines the actions to perform when the element is called to be rendered on the console.

[Visual]
protected override void RenderElementActions()

UpdateCenterText(string)

Updates the text in the center of the header.

public void UpdateCenterText(string centerText)

Parameters

centerText string

The new text in the center of the header.

Remarks

For more information, consider visiting the documentation available here.

UpdateLeftText(string)

Updates the text on the left of the header.

public void UpdateLeftText(string leftText)

Parameters

leftText string

The new text on the left of the header.

Remarks

For more information, consider visiting the documentation available here.

UpdateMargin(int)

Updates the margin of the header.

public void UpdateMargin(int margin)

Parameters

margin int

The new margin of the header.

Remarks

For more information, consider visiting the documentation available here.

UpdateRightText(string)

Updates the text on the right of the header.

public void UpdateRightText(string rightText)

Parameters

rightText string

The new text on the right of the header.

Remarks

For more information, consider visiting the documentation available here.