New controls, main view
This commit is contained in:
13
src/Library/TerminalUI/Models/Option.cs
Normal file
13
src/Library/TerminalUI/Models/Option.cs
Normal file
@@ -0,0 +1,13 @@
|
||||
namespace TerminalUI.Models;
|
||||
|
||||
public readonly ref struct Option<T>
|
||||
{
|
||||
public readonly T Value;
|
||||
public readonly bool IsSome;
|
||||
|
||||
public Option(T value, bool isSome)
|
||||
{
|
||||
Value = value;
|
||||
IsSome = isSome;
|
||||
}
|
||||
}
|
||||
7
src/Library/TerminalUI/Models/Orientation.cs
Normal file
7
src/Library/TerminalUI/Models/Orientation.cs
Normal file
@@ -0,0 +1,7 @@
|
||||
namespace TerminalUI.Models;
|
||||
|
||||
public enum Orientation
|
||||
{
|
||||
Horizontal,
|
||||
Vertical
|
||||
}
|
||||
@@ -1,3 +1,3 @@
|
||||
namespace TerminalUI.Models;
|
||||
|
||||
public record Size(int Width, int Height);
|
||||
public record struct Size(int Width, int Height);
|
||||
8
src/Library/TerminalUI/Models/TextAlignment.cs
Normal file
8
src/Library/TerminalUI/Models/TextAlignment.cs
Normal file
@@ -0,0 +1,8 @@
|
||||
namespace TerminalUI.Models;
|
||||
|
||||
public enum TextAlignment
|
||||
{
|
||||
Left,
|
||||
Center,
|
||||
Right
|
||||
}
|
||||
Reference in New Issue
Block a user