diff --git a/Terminal.Gui/Terminal.Gui.csproj b/Terminal.Gui/Terminal.Gui.csproj index 9e3fd411c..b1043dd3e 100644 --- a/Terminal.Gui/Terminal.Gui.csproj +++ b/Terminal.Gui/Terminal.Gui.csproj @@ -15,16 +15,21 @@ 12 Terminal.Gui Terminal.Gui - true - $(DefineConstants);JETBRAINS_ANNOTATIONS;CONTRACTS_FULL - - + true + True portable - + $(DefineConstants);JETBRAINS_ANNOTATIONS;CONTRACTS_FULL + enable + True + true - TRACE;DEBUG_IDISPOSABLE - portable + True + $(DefineConstants);DEBUG_IDISPOSABLE + + + True + @@ -40,7 +45,6 @@ - @@ -48,16 +52,20 @@ + + + + + + + + + - - - - - @@ -87,13 +95,6 @@ Strings.Designer.cs - - - - - - - @@ -111,7 +112,7 @@ See: https://github.com/gui-cs/Terminal.Gui/releases - bin\Release\Terminal.Gui.xml + bin\$(Configuration)\Terminal.Gui.xml true true https://github.com/gui-cs/Terminal.Gui.git @@ -124,9 +125,6 @@ upstream true true - Miguel de Icaza, Tig Kindel (@tig), @BDisp - true - enable - + \ No newline at end of file diff --git a/Terminal.Gui/Text/TextAlignment.cs b/Terminal.Gui/Text/TextAlignment.cs new file mode 100644 index 000000000..44950cfd5 --- /dev/null +++ b/Terminal.Gui/Text/TextAlignment.cs @@ -0,0 +1,20 @@ +namespace Terminal.Gui; + +/// Text alignment enumeration, controls how text is displayed. +public enum TextAlignment +{ + /// The text will be left-aligned. + Left, + + /// The text will be right-aligned. + Right, + + /// The text will be centered horizontally. + Centered, + + /// + /// The text will be justified (spaces will be added to existing spaces such that the text fills the container + /// horizontally). + /// + Justified +} \ No newline at end of file diff --git a/Terminal.Gui/Text/TextDirection.cs b/Terminal.Gui/Text/TextDirection.cs new file mode 100644 index 000000000..18e889c8b --- /dev/null +++ b/Terminal.Gui/Text/TextDirection.cs @@ -0,0 +1,61 @@ +namespace Terminal.Gui; + +/// Text direction enumeration, controls how text is displayed. +/// +/// TextDirection [H] = Horizontal [V] = Vertical +/// +/// +/// +/// +/// +/// +/// +/// +/// +/// +/// +/// +/// +/// +/// +/// +/// +/// +/// +/// +/// +/// +/// +/// +/// +/// +/// +/// +///
TextDirection Description
LeftRight_TopBottom [H] Normal
TopBottom_LeftRight [V] Normal
RightLeft_TopBottom [H] Invert Text
TopBottom_RightLeft [V] Invert Lines
LeftRight_BottomTop [H] Invert Lines
BottomTop_LeftRight [V] Invert Text
RightLeft_BottomTop [H] Invert Text + Invert Lines
BottomTop_RightLeft [V] Invert Text + Invert Lines
+///
+public enum TextDirection +{ + /// Normal horizontal direction. HELLO
WORLD
+ LeftRight_TopBottom, + + /// Normal vertical direction. H W
E O
L R
L L
O D
+ TopBottom_LeftRight, + + /// This is a horizontal direction.
RTL OLLEH
DLROW
+ RightLeft_TopBottom, + + /// This is a vertical direction. W H
O E
R L
L L
D O
+ TopBottom_RightLeft, + + /// This is a horizontal direction. WORLD
HELLO
+ LeftRight_BottomTop, + + /// This is a vertical direction. O D
L L
L R
E O
H W
+ BottomTop_LeftRight, + + /// This is a horizontal direction. DLROW
OLLEH
+ RightLeft_BottomTop, + + /// This is a vertical direction. D O
L L
R L
O E
W H
+ BottomTop_RightLeft +} \ No newline at end of file diff --git a/Terminal.Gui/Text/TextFormatter.cs b/Terminal.Gui/Text/TextFormatter.cs index 9c6f0dc15..6168c53f0 100644 --- a/Terminal.Gui/Text/TextFormatter.cs +++ b/Terminal.Gui/Text/TextFormatter.cs @@ -1,103 +1,5 @@ namespace Terminal.Gui; -/// Text alignment enumeration, controls how text is displayed. -public enum TextAlignment -{ - /// The text will be left-aligned. - Left, - - /// The text will be right-aligned. - Right, - - /// The text will be centered horizontally. - Centered, - - /// - /// The text will be justified (spaces will be added to existing spaces such that the text fills the container - /// horizontally). - /// - Justified -} - -/// Vertical text alignment enumeration, controls how text is displayed. -public enum VerticalTextAlignment -{ - /// The text will be top-aligned. - Top, - - /// The text will be bottom-aligned. - Bottom, - - /// The text will centered vertically. - Middle, - - /// - /// The text will be justified (spaces will be added to existing spaces such that the text fills the container - /// vertically). - /// - Justified -} - -/// Text direction enumeration, controls how text is displayed. -/// -/// TextDirection [H] = Horizontal [V] = Vertical -/// -/// -/// -/// -/// -/// -/// -/// -/// -/// -/// -/// -/// -/// -/// -/// -/// -/// -/// -/// -/// -/// -/// -/// -/// -/// -/// -/// -///
TextDirection Description
LeftRight_TopBottom [H] Normal
TopBottom_LeftRight [V] Normal
RightLeft_TopBottom [H] Invert Text
TopBottom_RightLeft [V] Invert Lines
LeftRight_BottomTop [H] Invert Lines
BottomTop_LeftRight [V] Invert Text
RightLeft_BottomTop [H] Invert Text + Invert Lines
BottomTop_RightLeft [V] Invert Text + Invert Lines
-///
-public enum TextDirection -{ - /// Normal horizontal direction. HELLO
WORLD
- LeftRight_TopBottom, - - /// Normal vertical direction. H W
E O
L R
L L
O D
- TopBottom_LeftRight, - - /// This is a horizontal direction.
RTL OLLEH
DLROW
- RightLeft_TopBottom, - - /// This is a vertical direction. W H
O E
R L
L L
D O
- TopBottom_RightLeft, - - /// This is a horizontal direction. WORLD
HELLO
- LeftRight_BottomTop, - - /// This is a vertical direction. O D
L L
L R
E O
H W
- BottomTop_LeftRight, - - /// This is a horizontal direction. DLROW
OLLEH
- RightLeft_BottomTop, - - /// This is a vertical direction. D O
L L
R L
O E
W H
- BottomTop_RightLeft -} - /// /// Provides text formatting. Supports s, horizontal alignment, vertical alignment, /// multiple lines, and word-based line wrap. diff --git a/Terminal.Gui/Text/VerticalTextAlignment.cs b/Terminal.Gui/Text/VerticalTextAlignment.cs new file mode 100644 index 000000000..ef7788577 --- /dev/null +++ b/Terminal.Gui/Text/VerticalTextAlignment.cs @@ -0,0 +1,20 @@ +namespace Terminal.Gui; + +/// Vertical text alignment enumeration, controls how text is displayed. +public enum VerticalTextAlignment +{ + /// The text will be top-aligned. + Top, + + /// The text will be bottom-aligned. + Bottom, + + /// The text will centered vertically. + Middle, + + /// + /// The text will be justified (spaces will be added to existing spaces such that the text fills the container + /// vertically). + /// + Justified +} \ No newline at end of file diff --git a/Terminal.sln.DotSettings b/Terminal.sln.DotSettings index ddeb546f2..348be86b5 100644 --- a/Terminal.sln.DotSettings +++ b/Terminal.sln.DotSettings @@ -396,11 +396,19 @@ True True True + True + #FFCF9D32 + True + Suggestion + (?<=\W|^)(?<TAG>SUGGESTION:)(\W|$)(.*) + Question + (?<=\W|^)(?<TAG>BUG:|BUGBUG:)(\W|$)(.*) True + True #FFCF9D32 True Performance - (?<=\W|^)(?<TAG>PERF)(\W|$)(.*) + (?<=\W|^)(?<TAG>PERF:)(\W|$)(.*) Warning True True @@ -410,22 +418,26 @@ (?<=\W|^)(?<TAG>NOTE:)(\W|$)(.*) Normal True + True #FFCF9D32 True Question (?<=\W|^)(?<TAG>QUESTION:)(\W|$)(.*) Question + True + (?<=\W|^)(?<TAG>TODO:)(\W|$)(.*) True + True #FFCF9D32 True Unclear Intent - (?<=\W|^)(?<TAG>UNCLEAR|INTENT)(\W|$)(.*) + (?<=\W|^)(?<TAG>UNCLEAR:|INTENT:)(\W|$)(.*) Warning True #FFCF9D32 True Concurrency Issue - (?<=\W|^)(?<TAG>CONCURRENCY)(\W|$)(.*) + (?<=\W|^)(?<TAG>CONCURRENCY:)(\W|$)(.*) Warning True diff --git a/UnitTests/UnitTests.csproj b/UnitTests/UnitTests.csproj index ad71c4b17..a45843e53 100644 --- a/UnitTests/UnitTests.csproj +++ b/UnitTests/UnitTests.csproj @@ -1,11 +1,5 @@  - net8.0 - - - Preview - false - @@ -14,16 +8,29 @@ 2.0 2.0 - - TRACE + + net8.0 + 12 + false + + true + True + portable + $(DefineConstants);JETBRAINS_ANNOTATIONS;CONTRACTS_FULL + enable + True + true - TRACE;DEBUG_IDISPOSABLE + True + $(DefineConstants);DEBUG_IDISPOSABLE + + + True -