Table of Contents

Property Orientation

Namespace
Terminal.Gui.Views
Assembly
Terminal.Gui.dll

Orientation

The direction of the line.

public Orientation Orientation { get; set; }

Property Value

Orientation

Remarks

When orientation changes, the appropriate dimension is set to Length and the perpendicular dimension is set to 1.

For object initializers where dimensions are set before orientation:

new Line { Height = 9, Orientation = Orientation.Vertical }
Setting Height=9 updates Length to 9 (since default orientation is Horizontal and Height is perpendicular). Then when Orientation is set to Vertical, Height is set to Length (9) and Width is set to 1, resulting in the expected Width=1, Height=9.