From f3697a99f4fdcde1cf50c2a39266a9dacd2af37b Mon Sep 17 00:00:00 2001 From: Tig Date: Wed, 26 Feb 2025 15:24:58 -0700 Subject: [PATCH 1/2] Fixes #3839, #3922 - CM Glyphs not working (#3923) * fixed * Moved Glyphs to ThemeScope * Removed test code --- .../Configuration/ConfigurationManager.cs | 9 +- Terminal.Gui/Configuration/Scope.cs | 1 + .../Configuration/SourceGenerationContext.cs | 2 +- Terminal.Gui/Drawing/Glyphs.cs | 332 +++++---- Terminal.Gui/Drawing/LineCanvas/LineStyle.cs | 6 +- Terminal.Gui/Resources/config.json | 287 ++++---- Terminal.Gui/Views/CheckBox.cs | 6 +- .../Scenarios/CharacterMap/CharacterMap.cs | 2 +- UICatalog/Scenarios/Clipping.cs | 2 +- UICatalog/Scenarios/DynamicMenuBar.cs | 12 +- UICatalog/Scenarios/DynamicStatusBar.cs | 4 +- UICatalog/Scenarios/GraphViewExample.cs | 4 +- UICatalog/Scenarios/LineViewExample.cs | 4 +- UICatalog/Scenarios/ShadowStyles.cs | 2 +- UICatalog/Scenarios/SimpleDialog.cs | 2 +- UICatalog/Scenarios/Sliders.cs | 16 +- UICatalog/Scenarios/Snake.cs | 4 +- UICatalog/Scenarios/TableEditor.cs | 8 +- UICatalog/Scenarios/Unicode.cs | 10 +- UnitTests/Application/ApplicationTests.cs | 13 +- .../Configuration/ConfigurationMangerTests.cs | 91 ++- UnitTests/Configuration/GlyphTests.cs | 50 ++ .../Configuration/RuneJsonConverterTests.cs | 2 +- UnitTests/Dialogs/DialogTests.cs | 152 ++-- UnitTests/Dialogs/MessageBoxTests.cs | 4 +- UnitTests/Dialogs/WizardTests.cs | 86 +-- UnitTests/Drawing/GlyphTests.cs | 29 - UnitTests/Text/TextFormatterTests.cs | 2 +- UnitTests/View/Layout/Pos.AnchorEndTests.cs | 2 +- UnitTests/Views/ButtonTests.cs | 20 +- UnitTests/Views/CheckBoxTests.cs | 32 +- UnitTests/Views/GraphViewTests.cs | 10 +- UnitTests/Views/MenuBarTests.cs | 8 +- UnitTests/Views/ProgressBarTests.cs | 652 +++++++++--------- UnitTests/Views/RadioGroupTests.cs | 8 +- UnitTests/Views/TreeTableSourceTests.cs | 12 +- 36 files changed, 984 insertions(+), 902 deletions(-) create mode 100644 UnitTests/Configuration/GlyphTests.cs delete mode 100644 UnitTests/Drawing/GlyphTests.cs diff --git a/Terminal.Gui/Configuration/ConfigurationManager.cs b/Terminal.Gui/Configuration/ConfigurationManager.cs index 473f1bf651..48bf2fd58d 100644 --- a/Terminal.Gui/Configuration/ConfigurationManager.cs +++ b/Terminal.Gui/Configuration/ConfigurationManager.cs @@ -110,14 +110,6 @@ public static class ConfigurationManager [JsonPropertyName ("AppSettings")] public static AppScope? AppSettings { get; set; } - /// - /// The set of glyphs used to draw checkboxes, lines, borders, etc...See also - /// . - /// - [SerializableConfigurationProperty (Scope = typeof (SettingsScope), OmitClassName = true)] - [JsonPropertyName ("Glyphs")] - public static GlyphDefinitions Glyphs { get; set; } = new (); - /// /// Gets and sets the locations where will look for config files. The value is /// . @@ -301,6 +293,7 @@ public static void Load (bool reset = false) public static void OnApplied () { Debug.WriteLine ("ConfigurationManager.OnApplied()"); + Applied?.Invoke (null, new ()); // TODO: Refactor ConfigurationManager to not use an event handler for this. diff --git a/Terminal.Gui/Configuration/Scope.cs b/Terminal.Gui/Configuration/Scope.cs index 718c5d5124..5b28a1b8f8 100644 --- a/Terminal.Gui/Configuration/Scope.cs +++ b/Terminal.Gui/Configuration/Scope.cs @@ -1,4 +1,5 @@ #nullable enable +using System.Diagnostics; using System.Reflection; namespace Terminal.Gui; diff --git a/Terminal.Gui/Configuration/SourceGenerationContext.cs b/Terminal.Gui/Configuration/SourceGenerationContext.cs index 5d2388bcfe..c624cf839f 100644 --- a/Terminal.Gui/Configuration/SourceGenerationContext.cs +++ b/Terminal.Gui/Configuration/SourceGenerationContext.cs @@ -10,7 +10,7 @@ namespace Terminal.Gui; [JsonSerializable (typeof (AppScope))] [JsonSerializable (typeof (SettingsScope))] [JsonSerializable (typeof (Key))] -[JsonSerializable (typeof (GlyphDefinitions))] +[JsonSerializable (typeof (Glyphs))] [JsonSerializable (typeof (Alignment))] [JsonSerializable (typeof (AlignmentModes))] [JsonSerializable (typeof (LineStyle))] diff --git a/Terminal.Gui/Drawing/Glyphs.cs b/Terminal.Gui/Drawing/Glyphs.cs index f3a0334bf4..de9d80378a 100644 --- a/Terminal.Gui/Drawing/Glyphs.cs +++ b/Terminal.Gui/Drawing/Glyphs.cs @@ -18,7 +18,7 @@ /// - A decimal number (e.g. 97 for "a") /// /// -public class GlyphDefinitions +public class Glyphs { // IMPORTANT: If you change these, make sure to update the ./Resources/config.json file as // IMPORTANT: it is the source of truth for the default glyphs at runtime. @@ -26,466 +26,504 @@ public class GlyphDefinitions // IMPORTANT: in ./UnitTests/bin/Debug/netX.0/config.json /// File icon. Defaults to ☰ (Trigram For Heaven) - public Rune File { get; set; } = (Rune)'☰'; + [SerializableConfigurationProperty (Scope = typeof (ThemeScope))] + public static Rune File { get; set; } = (Rune)'☰'; /// Folder icon. Defaults to ꤉ (Kayah Li Digit Nine) - public Rune Folder { get; set; } = (Rune)'꤉'; + [SerializableConfigurationProperty (Scope = typeof (ThemeScope))] + public static Rune Folder { get; set; } = (Rune)'꤉'; /// Horizontal Ellipsis - … U+2026 - public Rune HorizontalEllipsis { get; set; } = (Rune)'…'; + [SerializableConfigurationProperty (Scope = typeof (ThemeScope))] + public static Rune HorizontalEllipsis { get; set; } = (Rune)'…'; /// Vertical Four Dots - ⁞ U+205e - public Rune VerticalFourDots { get; set; } = (Rune)'⁞'; + [SerializableConfigurationProperty (Scope = typeof (ThemeScope))] + public static Rune VerticalFourDots { get; set; } = (Rune)'⁞'; #region ----------------- Single Glyphs ----------------- /// Checked indicator (e.g. for and ). - public Rune CheckStateChecked { get; set; } = (Rune)'☑'; + [SerializableConfigurationProperty (Scope = typeof (ThemeScope))] + public static Rune CheckStateChecked { get; set; } = (Rune)'☑'; /// Not Checked indicator (e.g. for and ). - public Rune CheckStateUnChecked { get; set; } = (Rune)'☐'; + [SerializableConfigurationProperty (Scope = typeof (ThemeScope))] + public static Rune CheckStateUnChecked { get; set; } = (Rune)'☐'; /// Null Checked indicator (e.g. for and ). - public Rune CheckStateNone { get; set; } = (Rune)'☒'; + [SerializableConfigurationProperty (Scope = typeof (ThemeScope))] + public static Rune CheckStateNone { get; set; } = (Rune)'☒'; /// Selected indicator (e.g. for and ). - public Rune Selected { get; set; } = (Rune)'◉'; + [SerializableConfigurationProperty (Scope = typeof (ThemeScope))] + public static Rune Selected { get; set; } = (Rune)'◉'; /// Not Selected indicator (e.g. for and ). - public Rune UnSelected { get; set; } = (Rune)'○'; + [SerializableConfigurationProperty (Scope = typeof (ThemeScope))] + public static Rune UnSelected { get; set; } = (Rune)'○'; /// Horizontal arrow. - public Rune RightArrow { get; set; } = (Rune)'►'; + [SerializableConfigurationProperty (Scope = typeof (ThemeScope))] + public static Rune RightArrow { get; set; } = (Rune)'►'; /// Left arrow. - public Rune LeftArrow { get; set; } = (Rune)'◄'; + [SerializableConfigurationProperty (Scope = typeof (ThemeScope))] + public static Rune LeftArrow { get; set; } = (Rune)'◄'; /// Down arrow. - public Rune DownArrow { get; set; } = (Rune)'▼'; + [SerializableConfigurationProperty (Scope = typeof (ThemeScope))] + public static Rune DownArrow { get; set; } = (Rune)'▼'; /// Vertical arrow. - public Rune UpArrow { get; set; } = (Rune)'▲'; + [SerializableConfigurationProperty (Scope = typeof (ThemeScope))] + public static Rune UpArrow { get; set; } = (Rune)'▲'; /// Left default indicator (e.g. for . - public Rune LeftDefaultIndicator { get; set; } = (Rune)'►'; + [SerializableConfigurationProperty (Scope = typeof (ThemeScope))] + public static Rune LeftDefaultIndicator { get; set; } = (Rune)'►'; /// Horizontal default indicator (e.g. for . - public Rune RightDefaultIndicator { get; set; } = (Rune)'◄'; + [SerializableConfigurationProperty (Scope = typeof (ThemeScope))] + public static Rune RightDefaultIndicator { get; set; } = (Rune)'◄'; /// Left Bracket (e.g. for . Default is (U+005B) - [. - public Rune LeftBracket { get; set; } = (Rune)'⟦'; + [SerializableConfigurationProperty (Scope = typeof (ThemeScope))] + public static Rune LeftBracket { get; set; } = (Rune)'⟦'; /// Horizontal Bracket (e.g. for . Default is (U+005D) - ]. - public Rune RightBracket { get; set; } = (Rune)'⟧'; + [SerializableConfigurationProperty (Scope = typeof (ThemeScope))] + public static Rune RightBracket { get; set; } = (Rune)'⟧'; /// Half block meter segment (e.g. for ). - public Rune BlocksMeterSegment { get; set; } = (Rune)'▌'; + [SerializableConfigurationProperty (Scope = typeof (ThemeScope))] + public static Rune BlocksMeterSegment { get; set; } = (Rune)'▌'; /// Continuous block meter segment (e.g. for ). - public Rune ContinuousMeterSegment { get; set; } = (Rune)'█'; + [SerializableConfigurationProperty (Scope = typeof (ThemeScope))] + public static Rune ContinuousMeterSegment { get; set; } = (Rune)'█'; /// Stipple pattern (e.g. for ). Default is Light Shade (U+2591) - ░. - public Rune Stipple { get; set; } = (Rune)'░'; + [SerializableConfigurationProperty (Scope = typeof (ThemeScope))] + public static Rune Stipple { get; set; } = (Rune)'░'; /// Diamond. Default is Lozenge (U+25CA) - ◊. - public Rune Diamond { get; set; } = (Rune)'◊'; + [SerializableConfigurationProperty (Scope = typeof (ThemeScope))] + public static Rune Diamond { get; set; } = (Rune)'◊'; /// Close. Default is Heavy Ballot X (U+2718) - ✘. - public Rune Close { get; set; } = (Rune)'✘'; + [SerializableConfigurationProperty (Scope = typeof (ThemeScope))] + public static Rune Close { get; set; } = (Rune)'✘'; /// Minimize. Default is Lower Horizontal Shadowed White Circle (U+274F) - ❏. - public Rune Minimize { get; set; } = (Rune)'❏'; + [SerializableConfigurationProperty (Scope = typeof (ThemeScope))] + public static Rune Minimize { get; set; } = (Rune)'❏'; /// Maximize. Default is Upper Horizontal Shadowed White Circle (U+273D) - ✽. - public Rune Maximize { get; set; } = (Rune)'✽'; + [SerializableConfigurationProperty (Scope = typeof (ThemeScope))] + public static Rune Maximize { get; set; } = (Rune)'✽'; /// Dot. Default is (U+2219) - ∙. - public Rune Dot { get; set; } = (Rune)'∙'; + [SerializableConfigurationProperty (Scope = typeof (ThemeScope))] + public static Rune Dot { get; set; } = (Rune)'∙'; /// Dotted Square - ⬚ U+02b1a┝ - public Rune DottedSquare { get; set; } = (Rune)'⬚'; + [SerializableConfigurationProperty (Scope = typeof (ThemeScope))] + public static Rune DottedSquare { get; set; } = (Rune)'⬚'; /// Black Circle . Default is (U+025cf) - ●. - public Rune BlackCircle { get; set; } = (Rune)'●'; // Black Circle - ● U+025cf + [SerializableConfigurationProperty (Scope = typeof (ThemeScope))] + public static Rune BlackCircle { get; set; } = (Rune)'●'; // Black Circle - ● U+025cf /// Expand (e.g. for . - public Rune Expand { get; set; } = (Rune)'+'; + [SerializableConfigurationProperty (Scope = typeof (ThemeScope))] + public static Rune Expand { get; set; } = (Rune)'+'; /// Expand (e.g. for . - public Rune Collapse { get; set; } = (Rune)'-'; + [SerializableConfigurationProperty (Scope = typeof (ThemeScope))] + public static Rune Collapse { get; set; } = (Rune)'-'; /// Identical To (U+226) - public Rune IdenticalTo { get; set; } = (Rune)'≡'; + [SerializableConfigurationProperty (Scope = typeof (ThemeScope))] + public static Rune IdenticalTo { get; set; } = (Rune)'≡'; /// Move indicator. Default is Lozenge (U+25CA) - ◊. - public Rune Move { get; set; } = (Rune)'◊'; + [SerializableConfigurationProperty (Scope = typeof (ThemeScope))] + public static Rune Move { get; set; } = (Rune)'◊'; /// Size Horizontally indicator. Default is ┥Left Right Arrow - ↔ U+02194 - public Rune SizeHorizontal { get; set; } = (Rune)'↔'; + [SerializableConfigurationProperty (Scope = typeof (ThemeScope))] + public static Rune SizeHorizontal { get; set; } = (Rune)'↔'; /// Size Vertical indicator. Default Up Down Arrow - ↕ U+02195 - public Rune SizeVertical { get; set; } = (Rune)'↕'; + [SerializableConfigurationProperty (Scope = typeof (ThemeScope))] + public static Rune SizeVertical { get; set; } = (Rune)'↕'; /// Size Top Left indicator. North West Arrow - ↖ U+02196 - public Rune SizeTopLeft { get; set; } = (Rune)'↖'; + [SerializableConfigurationProperty (Scope = typeof (ThemeScope))] + public static Rune SizeTopLeft { get; set; } = (Rune)'↖'; /// Size Top Right indicator. North East Arrow - ↗ U+02197 - public Rune SizeTopRight { get; set; } = (Rune)'↗'; + [SerializableConfigurationProperty (Scope = typeof (ThemeScope))] + public static Rune SizeTopRight { get; set; } = (Rune)'↗'; /// Size Bottom Right indicator. South East Arrow - ↘ U+02198 - public Rune SizeBottomRight { get; set; } = (Rune)'↘'; + [SerializableConfigurationProperty (Scope = typeof (ThemeScope))] + public static Rune SizeBottomRight { get; set; } = (Rune)'↘'; /// Size Bottom Left indicator. South West Arrow - ↙ U+02199 - public Rune SizeBottomLeft { get; set; } = (Rune)'↙'; + [SerializableConfigurationProperty (Scope = typeof (ThemeScope))] + public static Rune SizeBottomLeft { get; set; } = (Rune)'↙'; /// Apple (non-BMP). Because snek. And because it's an example of a non-BMP surrogate pair. See Issue #2610. - public Rune Apple { get; set; } = "🍎".ToRunes () [0]; // nonBMP + [SerializableConfigurationProperty (Scope = typeof (ThemeScope))] + public static Rune Apple { get; set; } = "🍎".ToRunes () [0]; // nonBMP /// Apple (BMP). Because snek. See Issue #2610. - public Rune AppleBMP { get; set; } = (Rune)'❦'; - - ///// - ///// A nonprintable (low surrogate) that should fail to ctor. - ///// - //public Rune InvalidGlyph { get; set; } = (Rune)'\ud83d'; + [SerializableConfigurationProperty (Scope = typeof (ThemeScope))] + public static Rune AppleBMP { get; set; } = (Rune)'❦'; #endregion #region ----------------- Lines ----------------- /// Box Drawings Horizontal Line - Light (U+2500) - ─ - public Rune HLine { get; set; } = (Rune)'─'; + [SerializableConfigurationProperty (Scope = typeof (ThemeScope))] + public static Rune HLine { get; set; } = (Rune)'─'; /// Box Drawings Vertical Line - Light (U+2502) - │ - public Rune VLine { get; set; } = (Rune)'│'; + [SerializableConfigurationProperty (Scope = typeof (ThemeScope))] + public static Rune VLine { get; set; } = (Rune)'│'; /// Box Drawings Double Horizontal (U+2550) - ═ - public Rune HLineDbl { get; set; } = (Rune)'═'; + [SerializableConfigurationProperty (Scope = typeof (ThemeScope))] + public static Rune HLineDbl { get; set; } = (Rune)'═'; /// Box Drawings Double Vertical (U+2551) - ║ - public Rune VLineDbl { get; set; } = (Rune)'║'; + [SerializableConfigurationProperty(Scope = typeof(ThemeScope))] public static Rune VLineDbl { get; set; } = (Rune)'║'; /// Box Drawings Heavy Double Dash Horizontal (U+254D) - ╍ - public Rune HLineHvDa2 { get; set; } = (Rune)'╍'; + [SerializableConfigurationProperty(Scope = typeof(ThemeScope))] public static Rune HLineHvDa2 { get; set; } = (Rune)'╍'; /// Box Drawings Heavy Triple Dash Vertical (U+2507) - ┇ - public Rune VLineHvDa3 { get; set; } = (Rune)'┇'; + [SerializableConfigurationProperty (Scope = typeof (ThemeScope))] + public static Rune VLineHvDa3 { get; set; } = (Rune)'┇'; /// Box Drawings Heavy Triple Dash Horizontal (U+2505) - ┅ - public Rune HLineHvDa3 { get; set; } = (Rune)'┅'; + [SerializableConfigurationProperty(Scope = typeof(ThemeScope))] public static Rune HLineHvDa3 { get; set; } = (Rune)'┅'; /// Box Drawings Heavy Quadruple Dash Horizontal (U+2509) - ┉ - public Rune HLineHvDa4 { get; set; } = (Rune)'┉'; + [SerializableConfigurationProperty(Scope = typeof(ThemeScope))] public static Rune HLineHvDa4 { get; set; } = (Rune)'┉'; /// Box Drawings Heavy Double Dash Vertical (U+254F) - ╏ - public Rune VLineHvDa2 { get; set; } = (Rune)'╏'; + [SerializableConfigurationProperty(Scope = typeof(ThemeScope))] public static Rune VLineHvDa2 { get; set; } = (Rune)'╏'; /// Box Drawings Heavy Quadruple Dash Vertical (U+250B) - ┋ - public Rune VLineHvDa4 { get; set; } = (Rune)'┋'; + [SerializableConfigurationProperty(Scope = typeof(ThemeScope))] public static Rune VLineHvDa4 { get; set; } = (Rune)'┋'; /// Box Drawings Light Double Dash Horizontal (U+254C) - ╌ - public Rune HLineDa2 { get; set; } = (Rune)'╌'; + [SerializableConfigurationProperty(Scope = typeof(ThemeScope))] public static Rune HLineDa2 { get; set; } = (Rune)'╌'; /// Box Drawings Light Triple Dash Vertical (U+2506) - ┆ - public Rune VLineDa3 { get; set; } = (Rune)'┆'; + [SerializableConfigurationProperty(Scope = typeof(ThemeScope))] public static Rune VLineDa3 { get; set; } = (Rune)'┆'; /// Box Drawings Light Triple Dash Horizontal (U+2504) - ┄ - public Rune HLineDa3 { get; set; } = (Rune)'┄'; + [SerializableConfigurationProperty(Scope = typeof(ThemeScope))] public static Rune HLineDa3 { get; set; } = (Rune)'┄'; /// Box Drawings Light Quadruple Dash Horizontal (U+2508) - ┈ - public Rune HLineDa4 { get; set; } = (Rune)'┈'; + [SerializableConfigurationProperty(Scope = typeof(ThemeScope))] public static Rune HLineDa4 { get; set; } = (Rune)'┈'; /// Box Drawings Light Double Dash Vertical (U+254E) - ╎ - public Rune VLineDa2 { get; set; } = (Rune)'╎'; + [SerializableConfigurationProperty(Scope = typeof(ThemeScope))] public static Rune VLineDa2 { get; set; } = (Rune)'╎'; /// Box Drawings Light Quadruple Dash Vertical (U+250A) - ┊ - public Rune VLineDa4 { get; set; } = (Rune)'┊'; + [SerializableConfigurationProperty(Scope = typeof(ThemeScope))] public static Rune VLineDa4 { get; set; } = (Rune)'┊'; /// Box Drawings Heavy Horizontal (U+2501) - ━ - public Rune HLineHv { get; set; } = (Rune)'━'; + [SerializableConfigurationProperty(Scope = typeof(ThemeScope))] public static Rune HLineHv { get; set; } = (Rune)'━'; /// Box Drawings Heavy Vertical (U+2503) - ┃ - public Rune VLineHv { get; set; } = (Rune)'┃'; + [SerializableConfigurationProperty(Scope = typeof(ThemeScope))] public static Rune VLineHv { get; set; } = (Rune)'┃'; /// Box Drawings Light Left (U+2574) - ╴ - public Rune HalfLeftLine { get; set; } = (Rune)'╴'; + [SerializableConfigurationProperty(Scope = typeof(ThemeScope))] public static Rune HalfLeftLine { get; set; } = (Rune)'╴'; /// Box Drawings Light Vertical (U+2575) - ╵ - public Rune HalfTopLine { get; set; } = (Rune)'╵'; + [SerializableConfigurationProperty(Scope = typeof(ThemeScope))] public static Rune HalfTopLine { get; set; } = (Rune)'╵'; /// Box Drawings Light Horizontal (U+2576) - ╶ - public Rune HalfRightLine { get; set; } = (Rune)'╶'; + [SerializableConfigurationProperty(Scope = typeof(ThemeScope))] public static Rune HalfRightLine { get; set; } = (Rune)'╶'; /// Box Drawings Light Down (U+2577) - ╷ - public Rune HalfBottomLine { get; set; } = (Rune)'╷'; + [SerializableConfigurationProperty(Scope = typeof(ThemeScope))] public static Rune HalfBottomLine { get; set; } = (Rune)'╷'; /// Box Drawings Heavy Left (U+2578) - ╸ - public Rune HalfLeftLineHv { get; set; } = (Rune)'╸'; + [SerializableConfigurationProperty(Scope = typeof(ThemeScope))] public static Rune HalfLeftLineHv { get; set; } = (Rune)'╸'; /// Box Drawings Heavy Vertical (U+2579) - ╹ - public Rune HalfTopLineHv { get; set; } = (Rune)'╹'; + [SerializableConfigurationProperty(Scope = typeof(ThemeScope))] public static Rune HalfTopLineHv { get; set; } = (Rune)'╹'; /// Box Drawings Heavy Horizontal (U+257A) - ╺ - public Rune HalfRightLineHv { get; set; } = (Rune)'╺'; + [SerializableConfigurationProperty(Scope = typeof(ThemeScope))] public static Rune HalfRightLineHv { get; set; } = (Rune)'╺'; /// Box Drawings Light Vertical and Horizontal (U+257B) - ╻ - public Rune HalfBottomLineLt { get; set; } = (Rune)'╻'; + [SerializableConfigurationProperty(Scope = typeof(ThemeScope))] public static Rune HalfBottomLineLt { get; set; } = (Rune)'╻'; /// Box Drawings Light Horizontal and Heavy Horizontal (U+257C) - ╼ - public Rune RightSideLineLtHv { get; set; } = (Rune)'╼'; + [SerializableConfigurationProperty(Scope = typeof(ThemeScope))] public static Rune RightSideLineLtHv { get; set; } = (Rune)'╼'; /// Box Drawings Light Vertical and Heavy Horizontal (U+257D) - ╽ - public Rune BottomSideLineLtHv { get; set; } = (Rune)'╽'; + [SerializableConfigurationProperty(Scope = typeof(ThemeScope))] public static Rune BottomSideLineLtHv { get; set; } = (Rune)'╽'; /// Box Drawings Heavy Left and Light Horizontal (U+257E) - ╾ - public Rune LeftSideLineHvLt { get; set; } = (Rune)'╾'; + [SerializableConfigurationProperty(Scope = typeof(ThemeScope))] public static Rune LeftSideLineHvLt { get; set; } = (Rune)'╾'; /// Box Drawings Heavy Vertical and Light Horizontal (U+257F) - ╿ - public Rune TopSideLineHvLt { get; set; } = (Rune)'╿'; + [SerializableConfigurationProperty(Scope = typeof(ThemeScope))] public static Rune TopSideLineHvLt { get; set; } = (Rune)'╿'; #endregion #region ----------------- Upper Left Corners ----------------- /// Box Drawings Upper Left Corner - Light Vertical and Light Horizontal (U+250C) - ┌ - public Rune ULCorner { get; set; } = (Rune)'┌'; + [SerializableConfigurationProperty(Scope = typeof(ThemeScope))] public static Rune ULCorner { get; set; } = (Rune)'┌'; /// Box Drawings Upper Left Corner - Double (U+2554) - ╔ - public Rune ULCornerDbl { get; set; } = (Rune)'╔'; + [SerializableConfigurationProperty(Scope = typeof(ThemeScope))] public static Rune ULCornerDbl { get; set; } = (Rune)'╔'; /// Box Drawings Upper Left Corner - Light Arc Down and Horizontal (U+256D) - ╭ - public Rune ULCornerR { get; set; } = (Rune)'╭'; + [SerializableConfigurationProperty(Scope = typeof(ThemeScope))] public static Rune ULCornerR { get; set; } = (Rune)'╭'; /// Box Drawings Heavy Down and Horizontal (U+250F) - ┏ - public Rune ULCornerHv { get; set; } = (Rune)'┏'; + [SerializableConfigurationProperty(Scope = typeof(ThemeScope))] public static Rune ULCornerHv { get; set; } = (Rune)'┏'; /// Box Drawings Down Heavy and Horizontal Light (U+251E) - ┎ - public Rune ULCornerHvLt { get; set; } = (Rune)'┎'; + [SerializableConfigurationProperty(Scope = typeof(ThemeScope))] public static Rune ULCornerHvLt { get; set; } = (Rune)'┎'; /// Box Drawings Down Light and Horizontal Heavy (U+250D) - ┎ - public Rune ULCornerLtHv { get; set; } = (Rune)'┍'; + [SerializableConfigurationProperty(Scope = typeof(ThemeScope))] public static Rune ULCornerLtHv { get; set; } = (Rune)'┍'; /// Box Drawings Double Down and Single Horizontal (U+2553) - ╓ - public Rune ULCornerDblSingle { get; set; } = (Rune)'╓'; + [SerializableConfigurationProperty(Scope = typeof(ThemeScope))] public static Rune ULCornerDblSingle { get; set; } = (Rune)'╓'; /// Box Drawings Single Down and Double Horizontal (U+2552) - ╒ - public Rune ULCornerSingleDbl { get; set; } = (Rune)'╒'; + [SerializableConfigurationProperty(Scope = typeof(ThemeScope))] public static Rune ULCornerSingleDbl { get; set; } = (Rune)'╒'; #endregion #region ----------------- Lower Left Corners ----------------- /// Box Drawings Lower Left Corner - Light Vertical and Light Horizontal (U+2514) - └ - public Rune LLCorner { get; set; } = (Rune)'└'; + [SerializableConfigurationProperty(Scope = typeof(ThemeScope))] public static Rune LLCorner { get; set; } = (Rune)'└'; /// Box Drawings Heavy Vertical and Horizontal (U+2517) - ┗ - public Rune LLCornerHv { get; set; } = (Rune)'┗'; + [SerializableConfigurationProperty(Scope = typeof(ThemeScope))] public static Rune LLCornerHv { get; set; } = (Rune)'┗'; /// Box Drawings Heavy Vertical and Horizontal Light (U+2516) - ┖ - public Rune LLCornerHvLt { get; set; } = (Rune)'┖'; + [SerializableConfigurationProperty(Scope = typeof(ThemeScope))] public static Rune LLCornerHvLt { get; set; } = (Rune)'┖'; /// Box Drawings Vertical Light and Horizontal Heavy (U+2511) - ┕ - public Rune LLCornerLtHv { get; set; } = (Rune)'┕'; + [SerializableConfigurationProperty(Scope = typeof(ThemeScope))] public static Rune LLCornerLtHv { get; set; } = (Rune)'┕'; /// Box Drawings Double Vertical and Double Left (U+255A) - ╚ - public Rune LLCornerDbl { get; set; } = (Rune)'╚'; + [SerializableConfigurationProperty(Scope = typeof(ThemeScope))] public static Rune LLCornerDbl { get; set; } = (Rune)'╚'; /// Box Drawings Single Vertical and Double Left (U+2558) - ╘ - public Rune LLCornerSingleDbl { get; set; } = (Rune)'╘'; + [SerializableConfigurationProperty(Scope = typeof(ThemeScope))] public static Rune LLCornerSingleDbl { get; set; } = (Rune)'╘'; /// Box Drawings Double Down and Single Left (U+2559) - ╙ - public Rune LLCornerDblSingle { get; set; } = (Rune)'╙'; + [SerializableConfigurationProperty(Scope = typeof(ThemeScope))] public static Rune LLCornerDblSingle { get; set; } = (Rune)'╙'; /// Box Drawings Upper Left Corner - Light Arc Down and Left (U+2570) - ╰ - public Rune LLCornerR { get; set; } = (Rune)'╰'; + [SerializableConfigurationProperty(Scope = typeof(ThemeScope))] public static Rune LLCornerR { get; set; } = (Rune)'╰'; #endregion #region ----------------- Upper Right Corners ----------------- /// Box Drawings Upper Horizontal Corner - Light Vertical and Light Horizontal (U+2510) - ┐ - public Rune URCorner { get; set; } = (Rune)'┐'; + [SerializableConfigurationProperty(Scope = typeof(ThemeScope))] public static Rune URCorner { get; set; } = (Rune)'┐'; /// Box Drawings Upper Horizontal Corner - Double Vertical and Double Horizontal (U+2557) - ╗ - public Rune URCornerDbl { get; set; } = (Rune)'╗'; + [SerializableConfigurationProperty(Scope = typeof(ThemeScope))] public static Rune URCornerDbl { get; set; } = (Rune)'╗'; /// Box Drawings Upper Horizontal Corner - Light Arc Vertical and Horizontal (U+256E) - ╮ - public Rune URCornerR { get; set; } = (Rune)'╮'; + [SerializableConfigurationProperty(Scope = typeof(ThemeScope))] public static Rune URCornerR { get; set; } = (Rune)'╮'; /// Box Drawings Heavy Down and Left (U+2513) - ┓ - public Rune URCornerHv { get; set; } = (Rune)'┓'; + [SerializableConfigurationProperty(Scope = typeof(ThemeScope))] public static Rune URCornerHv { get; set; } = (Rune)'┓'; /// Box Drawings Heavy Vertical and Left Down Light (U+2511) - ┑ - public Rune URCornerHvLt { get; set; } = (Rune)'┑'; + [SerializableConfigurationProperty(Scope = typeof(ThemeScope))] public static Rune URCornerHvLt { get; set; } = (Rune)'┑'; /// Box Drawings Down Light and Horizontal Heavy (U+2514) - ┒ - public Rune URCornerLtHv { get; set; } = (Rune)'┒'; + [SerializableConfigurationProperty(Scope = typeof(ThemeScope))] public static Rune URCornerLtHv { get; set; } = (Rune)'┒'; /// Box Drawings Double Vertical and Single Left (U+2556) - ╖ - public Rune URCornerDblSingle { get; set; } = (Rune)'╖'; + [SerializableConfigurationProperty(Scope = typeof(ThemeScope))] public static Rune URCornerDblSingle { get; set; } = (Rune)'╖'; /// Box Drawings Single Vertical and Double Left (U+2555) - ╕ - public Rune URCornerSingleDbl { get; set; } = (Rune)'╕'; + [SerializableConfigurationProperty(Scope = typeof(ThemeScope))] public static Rune URCornerSingleDbl { get; set; } = (Rune)'╕'; #endregion #region ----------------- Lower Right Corners ----------------- /// Box Drawings Lower Right Corner - Light (U+2518) - ┘ - public Rune LRCorner { get; set; } = (Rune)'┘'; + [SerializableConfigurationProperty(Scope = typeof(ThemeScope))] public static Rune LRCorner { get; set; } = (Rune)'┘'; /// Box Drawings Lower Right Corner - Double (U+255D) - ╝ - public Rune LRCornerDbl { get; set; } = (Rune)'╝'; + [SerializableConfigurationProperty(Scope = typeof(ThemeScope))] public static Rune LRCornerDbl { get; set; } = (Rune)'╝'; /// Box Drawings Lower Right Corner - Rounded (U+256F) - ╯ - public Rune LRCornerR { get; set; } = (Rune)'╯'; + [SerializableConfigurationProperty(Scope = typeof(ThemeScope))] public static Rune LRCornerR { get; set; } = (Rune)'╯'; /// Box Drawings Lower Right Corner - Heavy (U+251B) - ┛ - public Rune LRCornerHv { get; set; } = (Rune)'┛'; + [SerializableConfigurationProperty(Scope = typeof(ThemeScope))] public static Rune LRCornerHv { get; set; } = (Rune)'┛'; /// Box Drawings Lower Right Corner - Double Vertical and Single Horizontal (U+255C) - ╜ - public Rune LRCornerDblSingle { get; set; } = (Rune)'╜'; + [SerializableConfigurationProperty(Scope = typeof(ThemeScope))] public static Rune LRCornerDblSingle { get; set; } = (Rune)'╜'; /// Box Drawings Lower Right Corner - Single Vertical and Double Horizontal (U+255B) - ╛ - public Rune LRCornerSingleDbl { get; set; } = (Rune)'╛'; + [SerializableConfigurationProperty(Scope = typeof(ThemeScope))] public static Rune LRCornerSingleDbl { get; set; } = (Rune)'╛'; /// Box Drawings Lower Right Corner - Light Vertical and Heavy Horizontal (U+2519) - ┙ - public Rune LRCornerLtHv { get; set; } = (Rune)'┙'; + [SerializableConfigurationProperty(Scope = typeof(ThemeScope))] public static Rune LRCornerLtHv { get; set; } = (Rune)'┙'; /// Box Drawings Lower Right Corner - Heavy Vertical and Light Horizontal (U+251A) - ┚ - public Rune LRCornerHvLt { get; set; } = (Rune)'┚'; + [SerializableConfigurationProperty(Scope = typeof(ThemeScope))] public static Rune LRCornerHvLt { get; set; } = (Rune)'┚'; #endregion #region ----------------- Tees ----------------- /// Box Drawings Left Tee - Single Vertical and Single Horizontal (U+251C) - ├ - public Rune LeftTee { get; set; } = (Rune)'├'; + [SerializableConfigurationProperty(Scope = typeof(ThemeScope))] public static Rune LeftTee { get; set; } = (Rune)'├'; /// Box Drawings Left Tee - Single Vertical and Double Horizontal (U+255E) - ╞ - public Rune LeftTeeDblH { get; set; } = (Rune)'╞'; + [SerializableConfigurationProperty(Scope = typeof(ThemeScope))] public static Rune LeftTeeDblH { get; set; } = (Rune)'╞'; /// Box Drawings Left Tee - Double Vertical and Single Horizontal (U+255F) - ╟ - public Rune LeftTeeDblV { get; set; } = (Rune)'╟'; + [SerializableConfigurationProperty(Scope = typeof(ThemeScope))] public static Rune LeftTeeDblV { get; set; } = (Rune)'╟'; /// Box Drawings Left Tee - Double Vertical and Double Horizontal (U+2560) - ╠ - public Rune LeftTeeDbl { get; set; } = (Rune)'╠'; + [SerializableConfigurationProperty(Scope = typeof(ThemeScope))] public static Rune LeftTeeDbl { get; set; } = (Rune)'╠'; /// Box Drawings Left Tee - Heavy Horizontal and Light Vertical (U+2523) - ┝ - public Rune LeftTeeHvH { get; set; } = (Rune)'┝'; + [SerializableConfigurationProperty(Scope = typeof(ThemeScope))] public static Rune LeftTeeHvH { get; set; } = (Rune)'┝'; /// Box Drawings Left Tee - Light Horizontal and Heavy Vertical (U+252B) - ┠ - public Rune LeftTeeHvV { get; set; } = (Rune)'┠'; + [SerializableConfigurationProperty(Scope = typeof(ThemeScope))] public static Rune LeftTeeHvV { get; set; } = (Rune)'┠'; /// Box Drawings Left Tee - Heavy Vertical and Heavy Horizontal (U+2527) - ┣ - public Rune LeftTeeHvDblH { get; set; } = (Rune)'┣'; + [SerializableConfigurationProperty(Scope = typeof(ThemeScope))] public static Rune LeftTeeHvDblH { get; set; } = (Rune)'┣'; /// Box Drawings Right Tee - Single Vertical and Single Horizontal (U+2524) - ┤ - public Rune RightTee { get; set; } = (Rune)'┤'; + [SerializableConfigurationProperty(Scope = typeof(ThemeScope))] public static Rune RightTee { get; set; } = (Rune)'┤'; /// Box Drawings Right Tee - Single Vertical and Double Horizontal (U+2561) - ╡ - public Rune RightTeeDblH { get; set; } = (Rune)'╡'; + [SerializableConfigurationProperty(Scope = typeof(ThemeScope))] public static Rune RightTeeDblH { get; set; } = (Rune)'╡'; /// Box Drawings Right Tee - Double Vertical and Single Horizontal (U+2562) - ╢ - public Rune RightTeeDblV { get; set; } = (Rune)'╢'; + [SerializableConfigurationProperty(Scope = typeof(ThemeScope))] public static Rune RightTeeDblV { get; set; } = (Rune)'╢'; /// Box Drawings Right Tee - Double Vertical and Double Horizontal (U+2563) - ╣ - public Rune RightTeeDbl { get; set; } = (Rune)'╣'; + [SerializableConfigurationProperty(Scope = typeof(ThemeScope))] public static Rune RightTeeDbl { get; set; } = (Rune)'╣'; /// Box Drawings Right Tee - Heavy Horizontal and Light Vertical (U+2528) - ┥ - public Rune RightTeeHvH { get; set; } = (Rune)'┥'; + [SerializableConfigurationProperty(Scope = typeof(ThemeScope))] public static Rune RightTeeHvH { get; set; } = (Rune)'┥'; /// Box Drawings Right Tee - Light Horizontal and Heavy Vertical (U+2530) - ┨ - public Rune RightTeeHvV { get; set; } = (Rune)'┨'; + [SerializableConfigurationProperty(Scope = typeof(ThemeScope))] public static Rune RightTeeHvV { get; set; } = (Rune)'┨'; /// Box Drawings Right Tee - Heavy Vertical and Heavy Horizontal (U+252C) - ┫ - public Rune RightTeeHvDblH { get; set; } = (Rune)'┫'; + [SerializableConfigurationProperty(Scope = typeof(ThemeScope))] public static Rune RightTeeHvDblH { get; set; } = (Rune)'┫'; /// Box Drawings Top Tee - Single Vertical and Single Horizontal (U+252C) - ┬ - public Rune TopTee { get; set; } = (Rune)'┬'; + [SerializableConfigurationProperty(Scope = typeof(ThemeScope))] public static Rune TopTee { get; set; } = (Rune)'┬'; /// Box Drawings Top Tee - Single Vertical and Double Horizontal (U+2564) - ╤ - public Rune TopTeeDblH { get; set; } = (Rune)'╤'; + [SerializableConfigurationProperty(Scope = typeof(ThemeScope))] public static Rune TopTeeDblH { get; set; } = (Rune)'╤'; /// Box Drawings Top Tee - Double Vertical and Single Horizontal (U+2565) - ╥ - public Rune TopTeeDblV { get; set; } = (Rune)'╥'; + [SerializableConfigurationProperty(Scope = typeof(ThemeScope))] public static Rune TopTeeDblV { get; set; } = (Rune)'╥'; /// Box Drawings Top Tee - Double Vertical and Double Horizontal (U+2566) - ╦ - public Rune TopTeeDbl { get; set; } = (Rune)'╦'; + [SerializableConfigurationProperty(Scope = typeof(ThemeScope))] public static Rune TopTeeDbl { get; set; } = (Rune)'╦'; /// Box Drawings Top Tee - Heavy Horizontal and Light Vertical (U+252F) - ┯ - public Rune TopTeeHvH { get; set; } = (Rune)'┯'; + [SerializableConfigurationProperty(Scope = typeof(ThemeScope))] public static Rune TopTeeHvH { get; set; } = (Rune)'┯'; /// Box Drawings Top Tee - Light Horizontal and Heavy Vertical (U+2537) - ┰ - public Rune TopTeeHvV { get; set; } = (Rune)'┰'; + [SerializableConfigurationProperty(Scope = typeof(ThemeScope))] public static Rune TopTeeHvV { get; set; } = (Rune)'┰'; /// Box Drawings Top Tee - Heavy Vertical and Heavy Horizontal (U+2533) - ┳ - public Rune TopTeeHvDblH { get; set; } = (Rune)'┳'; + [SerializableConfigurationProperty(Scope = typeof(ThemeScope))] public static Rune TopTeeHvDblH { get; set; } = (Rune)'┳'; /// Box Drawings Bottom Tee - Single Vertical and Single Horizontal (U+2534) - ┴ - public Rune BottomTee { get; set; } = (Rune)'┴'; + [SerializableConfigurationProperty(Scope = typeof(ThemeScope))] public static Rune BottomTee { get; set; } = (Rune)'┴'; /// Box Drawings Bottom Tee - Single Vertical and Double Horizontal (U+2567) - ╧ - public Rune BottomTeeDblH { get; set; } = (Rune)'╧'; + [SerializableConfigurationProperty(Scope = typeof(ThemeScope))] public static Rune BottomTeeDblH { get; set; } = (Rune)'╧'; /// Box Drawings Bottom Tee - Double Vertical and Single Horizontal (U+2568) - ╨ - public Rune BottomTeeDblV { get; set; } = (Rune)'╨'; + [SerializableConfigurationProperty(Scope = typeof(ThemeScope))] public static Rune BottomTeeDblV { get; set; } = (Rune)'╨'; /// Box Drawings Bottom Tee - Double Vertical and Double Horizontal (U+2569) - ╩ - public Rune BottomTeeDbl { get; set; } = (Rune)'╩'; + [SerializableConfigurationProperty(Scope = typeof(ThemeScope))] public static Rune BottomTeeDbl { get; set; } = (Rune)'╩'; /// Box Drawings Bottom Tee - Heavy Horizontal and Light Vertical (U+2535) - ┷ - public Rune BottomTeeHvH { get; set; } = (Rune)'┷'; + [SerializableConfigurationProperty(Scope = typeof(ThemeScope))] public static Rune BottomTeeHvH { get; set; } = (Rune)'┷'; /// Box Drawings Bottom Tee - Light Horizontal and Heavy Vertical (U+253D) - ┸ - public Rune BottomTeeHvV { get; set; } = (Rune)'┸'; + [SerializableConfigurationProperty(Scope = typeof(ThemeScope))] public static Rune BottomTeeHvV { get; set; } = (Rune)'┸'; /// Box Drawings Bottom Tee - Heavy Vertical and Heavy Horizontal (U+2539) - ┻ - public Rune BottomTeeHvDblH { get; set; } = (Rune)'┻'; + [SerializableConfigurationProperty(Scope = typeof(ThemeScope))] public static Rune BottomTeeHvDblH { get; set; } = (Rune)'┻'; #endregion #region ----------------- Crosses ----------------- /// Box Drawings Cross - Single Vertical and Single Horizontal (U+253C) - ┼ - public Rune Cross { get; set; } = (Rune)'┼'; + [SerializableConfigurationProperty(Scope = typeof(ThemeScope))] public static Rune Cross { get; set; } = (Rune)'┼'; /// Box Drawings Cross - Single Vertical and Double Horizontal (U+256A) - ╪ - public Rune CrossDblH { get; set; } = (Rune)'╪'; + [SerializableConfigurationProperty(Scope = typeof(ThemeScope))] public static Rune CrossDblH { get; set; } = (Rune)'╪'; /// Box Drawings Cross - Double Vertical and Single Horizontal (U+256B) - ╫ - public Rune CrossDblV { get; set; } = (Rune)'╫'; + [SerializableConfigurationProperty(Scope = typeof(ThemeScope))] public static Rune CrossDblV { get; set; } = (Rune)'╫'; /// Box Drawings Cross - Double Vertical and Double Horizontal (U+256C) - ╬ - public Rune CrossDbl { get; set; } = (Rune)'╬'; + [SerializableConfigurationProperty(Scope = typeof(ThemeScope))] public static Rune CrossDbl { get; set; } = (Rune)'╬'; /// Box Drawings Cross - Heavy Horizontal and Light Vertical (U+253F) - ┿ - public Rune CrossHvH { get; set; } = (Rune)'┿'; + [SerializableConfigurationProperty(Scope = typeof(ThemeScope))] public static Rune CrossHvH { get; set; } = (Rune)'┿'; /// Box Drawings Cross - Light Horizontal and Heavy Vertical (U+2541) - ╂ - public Rune CrossHvV { get; set; } = (Rune)'╂'; + [SerializableConfigurationProperty(Scope = typeof(ThemeScope))] public static Rune CrossHvV { get; set; } = (Rune)'╂'; /// Box Drawings Cross - Heavy Vertical and Heavy Horizontal (U+254B) - ╋ - public Rune CrossHv { get; set; } = (Rune)'╋'; + [SerializableConfigurationProperty(Scope = typeof(ThemeScope))] public static Rune CrossHv { get; set; } = (Rune)'╋'; #endregion #region ----------------- ShadowStyle ----------------- /// Shadow - Vertical Start - Left Half Block - ▌ U+0258c - public Rune ShadowVerticalStart { get; set; } = (Rune)'▖'; // Half: '\u2596' ▖; + [SerializableConfigurationProperty(Scope = typeof(ThemeScope))] public static Rune ShadowVerticalStart { get; set; } = (Rune)'▖'; // Half: '\u2596' ▖; /// Shadow - Vertical - Left Half Block - ▌ U+0258c - public Rune ShadowVertical { get; set; } = (Rune)'▌'; + [SerializableConfigurationProperty(Scope = typeof(ThemeScope))] public static Rune ShadowVertical { get; set; } = (Rune)'▌'; /// Shadow - Horizontal Start - Upper Half Block - ▀ U+02580 - public Rune ShadowHorizontalStart { get; set; } = (Rune)'▝'; // Half: ▝ U+0259d; + [SerializableConfigurationProperty(Scope = typeof(ThemeScope))] public static Rune ShadowHorizontalStart { get; set; } = (Rune)'▝'; // Half: ▝ U+0259d; /// Shadow - Horizontal - Upper Half Block - ▀ U+02580 - public Rune ShadowHorizontal { get; set; } = (Rune)'▀'; + [SerializableConfigurationProperty(Scope = typeof(ThemeScope))] public static Rune ShadowHorizontal { get; set; } = (Rune)'▀'; /// Shadow - Horizontal End - Quadrant Upper Left - ▘ U+02598 - public Rune ShadowHorizontalEnd { get; set; } = (Rune)'▘'; + [SerializableConfigurationProperty(Scope = typeof(ThemeScope))] public static Rune ShadowHorizontalEnd { get; set; } = (Rune)'▘'; #endregion } diff --git a/Terminal.Gui/Drawing/LineCanvas/LineStyle.cs b/Terminal.Gui/Drawing/LineCanvas/LineStyle.cs index a696bc9435..fb56fccfd0 100644 --- a/Terminal.Gui/Drawing/LineCanvas/LineStyle.cs +++ b/Terminal.Gui/Drawing/LineCanvas/LineStyle.cs @@ -10,7 +10,7 @@ public enum LineStyle /// No border is drawn. None, - /// The border is drawn using thin line CM.Glyphs. + /// The border is drawn using thin line Glyphs. Single, /// The border is drawn using thin line glyphs with dashed (double and triple) straight lines. @@ -19,10 +19,10 @@ public enum LineStyle /// The border is drawn using thin line glyphs with short dashed (triple and quadruple) straight lines. Dotted, - /// The border is drawn using thin double line CM.Glyphs. + /// The border is drawn using thin double line Glyphs. Double, - /// The border is drawn using heavy line CM.Glyphs. + /// The border is drawn using heavy line Glyphs. Heavy, /// The border is drawn using heavy line glyphs with dashed (double and triple) straight lines. diff --git a/Terminal.Gui/Resources/config.json b/Terminal.Gui/Resources/config.json index ca6ab6a842..31752d43b2 100644 --- a/Terminal.Gui/Resources/config.json +++ b/Terminal.Gui/Resources/config.json @@ -38,150 +38,6 @@ "FileDialogStyle.DefaultUseColors": false, "FileDialogStyle.DefaultUseUnicodeCharacters": false, - // --------------- Glyphs --------------- - "Glyphs": { - "File": "☰", - "Folder": "꤉", - "HorizontalEllipsis": "…", - "VerticalFourDots": "⁞", - "CheckStateChecked": "☑", - "CheckStateUnChecked": "☐", - "CheckStateNone": "☒", - "Selected": "◉", - "UnSelected": "○", - "RightArrow": "►", - "LeftArrow": "◄", - "DownArrow": "▼", - "UpArrow": "▲", - "LeftDefaultIndicator": "►", - "RightDefaultIndicator": "◄", - "LeftBracket": "⟦", - "RightBracket": "⟧", - "BlocksMeterSegment": "▌", - "ContinuousMeterSegment": "█", - "Stipple": "░", - "Diamond": "◊", - "Close": "✘", - "Minimize": "❏", - "Maximize": "✽", - "Dot": "∙", - "BlackCircle": "●", - "Expand": "+", - "Collapse": "-", - "IdenticalTo": "≡", - "Move": "◊", - "SizeHorizontal": "↔", - "SizeVertical": "↕", - "SizeTopLeft": "↖", - "SizeTopRight": "↗", - "SizeBottomRight": "↘", - "SizeBottomLeft": "↙", - "Apple": "\uD83C\uDF4E", - "AppleBMP": "❦", - "HLine": "─", - "VLine": "│", - "HLineDbl": "═", - "VLineDbl": "║", - "HLineHvDa2": "╍", - "VLineHvDa3": "┇", - "HLineHvDa3": "┅", - "HLineHvDa4": "┉", - "VLineHvDa2": "╏", - "VLineHvDa4": "┋", - "HLineDa2": "╌", - "VLineDa3": "┆", - "HLineDa3": "┄", - "HLineDa4": "┈", - "VLineDa2": "╎", - "VLineDa4": "┊", - "HLineHv": "━", - "VLineHv": "┃", - "HalfLeftLine": "╴", - "HalfTopLine": "╵", - "HalfRightLine": "╶", - "HalfBottomLine": "╷", - "HalfLeftLineHv": "╸", - "HalfTopLineHv": "╹", - "HalfRightLineHv": "╺", - "HalfBottomLineLt": "╻", - "RightSideLineLtHv": "╼", - "BottomSideLineLtHv": "╽", - "LeftSideLineHvLt": "╾", - "TopSideLineHvLt": "╿", - "ULCorner": "┌", - "ULCornerDbl": "╔", - "ULCornerR": "╭", - "ULCornerHv": "┏", - "ULCornerHvLt": "┎", - "ULCornerLtHv": "┍", - "ULCornerDblSingle": "╓", - "ULCornerSingleDbl": "╒", - "LLCorner": "└", - "LLCornerHv": "┗", - "LLCornerHvLt": "┖", - "LLCornerLtHv": "┕", - "LLCornerDbl": "╚", - "LLCornerSingleDbl": "╘", - "LLCornerDblSingle": "╙", - "LLCornerR": "╰", - "URCorner": "┐", - "URCornerDbl": "╗", - "URCornerR": "╮", - "URCornerHv": "┓", - "URCornerHvLt": "┑", - "URCornerLtHv": "┒", - "URCornerDblSingle": "╖", - "URCornerSingleDbl": "╕", - "LRCorner": "┘", - "LRCornerDbl": "╝", - "LRCornerR": "╯", - "LRCornerHv": "┛", - "LRCornerDblSingle": "╜", - "LRCornerSingleDbl": "╛", - "LRCornerLtHv": "┙", - "LRCornerHvLt": "┚", - "LeftTee": "├", - "LeftTeeDblH": "╞", - "LeftTeeDblV": "╟", - "LeftTeeDbl": "╠", - "LeftTeeHvH": "┝", - "LeftTeeHvV": "┠", - "LeftTeeHvDblH": "┣", - "RightTee": "┤", - "RightTeeDblH": "╡", - "RightTeeDblV": "╢", - "RightTeeDbl": "╣", - "RightTeeHvH": "┥", - "RightTeeHvV": "┨", - "RightTeeHvDblH": "┫", - "TopTee": "┬", - "TopTeeDblH": "╤", - "TopTeeDblV": "╥", - "TopTeeDbl": "╦", - "TopTeeHvH": "┯", - "TopTeeHvV": "┰", - "TopTeeHvDblH": "┳", - "BottomTee": "┴", - "BottomTeeDblH": "╧", - "BottomTeeDblV": "╨", - "BottomTeeDbl": "╩", - "BottomTeeHvH": "┷", - "BottomTeeHvV": "┸", - "BottomTeeHvDblH": "┻", - "Cross": "┼", - "CrossDblH": "╪", - "CrossDblV": "╫", - "CrossDbl": "╬", - "CrossHvH": "┿", - "CrossHvV": "╂", - "CrossHv": "╋", - "ShadowVerticalStart": "▖", - "ShadowVertical": "▌", - "ShadowHorizontalStart": "▝", - "ShadowHorizontal": "▀", - "ShadowHorizontalEnd": "▘" - }, - // --------------- Themes ----------------- "Theme": "Default", "Themes": [ @@ -317,7 +173,148 @@ } } } - ] + ], + "Glyphs.Apple": "\uD83C\uDF4E", + "Glyphs.AppleBMP": "❦", + "Glyphs.BlackCircle": "●", + "Glyphs.BlocksMeterSegment": "▌", + "Glyphs.BottomSideLineLtHv": "╽", + "Glyphs.BottomTee": "┴", + "Glyphs.BottomTeeDbl": "╩", + "Glyphs.BottomTeeDblH": "╧", + "Glyphs.BottomTeeDblV": "╨", + "Glyphs.BottomTeeHvDblH": "┻", + "Glyphs.BottomTeeHvH": "┷", + "Glyphs.BottomTeeHvV": "┸", + "Glyphs.CheckStateChecked": "☑", + "Glyphs.CheckStateNone": "☒", + "Glyphs.CheckStateUnChecked": "☐", + "Glyphs.Close": "✘", + "Glyphs.Collapse": "-", + "Glyphs.ContinuousMeterSegment": "█", + "Glyphs.Cross": "┼", + "Glyphs.CrossDbl": "╬", + "Glyphs.CrossDblH": "╪", + "Glyphs.CrossDblV": "╫", + "Glyphs.CrossHv": "╋", + "Glyphs.CrossHvH": "┿", + "Glyphs.CrossHvV": "╂", + "Glyphs.Diamond": "◊", + "Glyphs.Dot": "∙", + "Glyphs.DottedSquare": "⬚", + "Glyphs.DownArrow": "▼", + "Glyphs.Expand": "+", + "Glyphs.File": "☰", + "Glyphs.Folder": "꤉", + "Glyphs.HalfBottomLine": "╷", + "Glyphs.HalfBottomLineLt": "╻", + "Glyphs.HalfLeftLine": "╴", + "Glyphs.HalfLeftLineHv": "╸", + "Glyphs.HalfRightLine": "╶", + "Glyphs.HalfRightLineHv": "╺", + "Glyphs.HalfTopLine": "╵", + "Glyphs.HalfTopLineHv": "╹", + "Glyphs.HLine": "─", + "Glyphs.HLineDa2": "╌", + "Glyphs.HLineDa3": "┄", + "Glyphs.HLineDa4": "┈", + "Glyphs.HLineDbl": "═", + "Glyphs.HLineHv": "━", + "Glyphs.HLineHvDa2": "╍", + "Glyphs.HLineHvDa3": "┅", + "Glyphs.HLineHvDa4": "┉", + "Glyphs.HorizontalEllipsis": "…", + "Glyphs.IdenticalTo": "≡", + "Glyphs.LeftArrow": "◄", + "Glyphs.LeftBracket": "⟦", + "Glyphs.LeftDefaultIndicator": "►", + "Glyphs.LeftSideLineHvLt": "╾", + "Glyphs.LeftTee": "├", + "Glyphs.LeftTeeDbl": "╠", + "Glyphs.LeftTeeDblH": "╞", + "Glyphs.LeftTeeDblV": "╟", + "Glyphs.LeftTeeHvDblH": "┣", + "Glyphs.LeftTeeHvH": "┝", + "Glyphs.LeftTeeHvV": "┠", + "Glyphs.LLCorner": "└", + "Glyphs.LLCornerDbl": "╚", + "Glyphs.LLCornerDblSingle": "╙", + "Glyphs.LLCornerHv": "┗", + "Glyphs.LLCornerHvLt": "┖", + "Glyphs.LLCornerLtHv": "┕", + "Glyphs.LLCornerR": "╰", + "Glyphs.LLCornerSingleDbl": "╘", + "Glyphs.LRCorner": "┘", + "Glyphs.LRCornerDbl": "╝", + "Glyphs.LRCornerDblSingle": "╜", + "Glyphs.LRCornerHv": "┛", + "Glyphs.LRCornerHvLt": "┚", + "Glyphs.LRCornerLtHv": "┙", + "Glyphs.LRCornerR": "╯", + "Glyphs.LRCornerSingleDbl": "╛", + "Glyphs.Maximize": "✽", + "Glyphs.Minimize": "❏", + "Glyphs.Move": "◊", + "Glyphs.RightArrow": "►", + "Glyphs.RightBracket": "⟧", + "Glyphs.RightDefaultIndicator": "◄", + "Glyphs.RightSideLineLtHv": "╼", + "Glyphs.RightTee": "┤", + "Glyphs.RightTeeDbl": "╣", + "Glyphs.RightTeeDblH": "╡", + "Glyphs.RightTeeDblV": "╢", + "Glyphs.RightTeeHvDblH": "┫", + "Glyphs.RightTeeHvH": "┥", + "Glyphs.RightTeeHvV": "┨", + "Glyphs.Selected": "◉", + "Glyphs.ShadowHorizontal": "▀", + "Glyphs.ShadowHorizontalEnd": "▘", + "Glyphs.ShadowHorizontalStart": "▝", + "Glyphs.ShadowVertical": "▌", + "Glyphs.ShadowVerticalStart": "▖", + "Glyphs.SizeBottomLeft": "↙", + "Glyphs.SizeBottomRight": "↘", + "Glyphs.SizeHorizontal": "↔", + "Glyphs.SizeTopLeft": "↖", + "Glyphs.SizeTopRight": "↗", + "Glyphs.SizeVertical": "↕", + "Glyphs.Stipple": "░", + "Glyphs.TopSideLineHvLt": "╿", + "Glyphs.TopTee": "┬", + "Glyphs.TopTeeDbl": "╦", + "Glyphs.TopTeeDblH": "╤", + "Glyphs.TopTeeDblV": "╥", + "Glyphs.TopTeeHvDblH": "┳", + "Glyphs.TopTeeHvH": "┯", + "Glyphs.TopTeeHvV": "┰", + "Glyphs.ULCorner": "┌", + "Glyphs.ULCornerDbl": "╔", + "Glyphs.ULCornerDblSingle": "╓", + "Glyphs.ULCornerHv": "┏", + "Glyphs.ULCornerHvLt": "┎", + "Glyphs.ULCornerLtHv": "┍", + "Glyphs.ULCornerR": "╭", + "Glyphs.ULCornerSingleDbl": "╒", + "Glyphs.UnSelected": "○", + "Glyphs.UpArrow": "▲", + "Glyphs.URCorner": "┐", + "Glyphs.URCornerDbl": "╗", + "Glyphs.URCornerDblSingle": "╖", + "Glyphs.URCornerHv": "┓", + "Glyphs.URCornerHvLt": "┑", + "Glyphs.URCornerLtHv": "┒", + "Glyphs.URCornerR": "╮", + "Glyphs.URCornerSingleDbl": "╕", + "Glyphs.VerticalFourDots": "⁞", + "Glyphs.VLine": "│", + "Glyphs.VLineDa2": "╎", + "Glyphs.VLineDa3": "┆", + "Glyphs.VLineDa4": "┊", + "Glyphs.VLineDbl": "║", + "Glyphs.VLineHv": "┃", + "Glyphs.VLineHvDa2": "╏", + "Glyphs.VLineHvDa3": "┇", + "Glyphs.VLineHvDa4": "┋" } }, { diff --git a/Terminal.Gui/Views/CheckBox.cs b/Terminal.Gui/Views/CheckBox.cs index 6b7c7ad190..cec31d4f9c 100644 --- a/Terminal.Gui/Views/CheckBox.cs +++ b/Terminal.Gui/Views/CheckBox.cs @@ -114,15 +114,15 @@ public bool AllowCheckStateNone /// /// If is and , the /// - /// will display the ConfigurationManager.Glyphs.CheckStateNone character (☒). + /// will display the Glyphs.CheckStateNone character (☒). /// /// /// If , the - /// will display the ConfigurationManager.Glyphs.CheckStateUnChecked character (☐). + /// will display the Glyphs.CheckStateUnChecked character (☐). /// /// /// If , the - /// will display the ConfigurationManager.Glyphs.CheckStateChecked character (☑). + /// will display the Glyphs.CheckStateChecked character (☑). /// /// public CheckState CheckedState diff --git a/UICatalog/Scenarios/CharacterMap/CharacterMap.cs b/UICatalog/Scenarios/CharacterMap/CharacterMap.cs index b6c7c11175..efea9e28a2 100644 --- a/UICatalog/Scenarios/CharacterMap/CharacterMap.cs +++ b/UICatalog/Scenarios/CharacterMap/CharacterMap.cs @@ -270,7 +270,7 @@ private EnumerableTableSource CreateCategoryTable (int sortByColum var startSort = string.Empty; var endSort = string.Empty; - string sortIndicator = descending ? CM.Glyphs.DownArrow.ToString () : CM.Glyphs.UpArrow.ToString (); + string sortIndicator = descending ? Glyphs.DownArrow.ToString () : Glyphs.UpArrow.ToString (); switch (sortByColumn) { diff --git a/UICatalog/Scenarios/Clipping.cs b/UICatalog/Scenarios/Clipping.cs index 621bfc8604..57a2b01725 100644 --- a/UICatalog/Scenarios/Clipping.cs +++ b/UICatalog/Scenarios/Clipping.cs @@ -25,7 +25,7 @@ public override void Main () app.DrawingContent += (s, e) => { - app!.FillRect (app!.Viewport, CM.Glyphs.Dot); + app!.FillRect (app!.Viewport, Glyphs.Dot); e.Cancel = true; }; diff --git a/UICatalog/Scenarios/DynamicMenuBar.cs b/UICatalog/Scenarios/DynamicMenuBar.cs index 60408929bb..987ee97868 100644 --- a/UICatalog/Scenarios/DynamicMenuBar.cs +++ b/UICatalog/Scenarios/DynamicMenuBar.cs @@ -567,10 +567,10 @@ public DynamicMenuBarSample () var btnAddMenuBar = new Button { Y = 1, Text = "Add a MenuBar" }; frmMenu.Add (btnAddMenuBar); - var btnMenuBarUp = new Button { X = Pos.Center (), Text = CM.Glyphs.UpArrow.ToString () }; + var btnMenuBarUp = new Button { X = Pos.Center (), Text = Glyphs.UpArrow.ToString () }; frmMenu.Add (btnMenuBarUp); - var btnMenuBarDown = new Button { X = Pos.Center (), Y = Pos.Bottom (btnMenuBarUp), Text = CM.Glyphs.DownArrow.ToString () }; + var btnMenuBarDown = new Button { X = Pos.Center (), Y = Pos.Bottom (btnMenuBarUp), Text = Glyphs.DownArrow.ToString () }; frmMenu.Add (btnMenuBarDown); var btnRemoveMenuBar = new Button { Y = 1, Text = "Remove a MenuBar" }; @@ -580,7 +580,7 @@ public DynamicMenuBarSample () var btnPrevious = new Button { - X = Pos.Left (btnAddMenuBar), Y = Pos.Top (btnAddMenuBar) + 2, Text = CM.Glyphs.LeftArrow.ToString () + X = Pos.Left (btnAddMenuBar), Y = Pos.Top (btnAddMenuBar) + 2, Text = Glyphs.LeftArrow.ToString () }; frmMenu.Add (btnPrevious); @@ -588,7 +588,7 @@ public DynamicMenuBarSample () btnAdd.X = Pos.AnchorEnd (); frmMenu.Add (btnAdd); - var btnNext = new Button { X = Pos.X (btnAdd), Y = Pos.Top (btnPrevious), Text = CM.Glyphs.RightArrow.ToString () }; + var btnNext = new Button { X = Pos.X (btnAdd), Y = Pos.Top (btnPrevious), Text = Glyphs.RightArrow.ToString () }; frmMenu.Add (btnNext); var lblMenuBar = new Label @@ -648,10 +648,10 @@ public DynamicMenuBarSample () var btnRemove = new Button { X = Pos.Left (btnAdd), Y = Pos.Top (btnAdd) + 1, Text = "Remove" }; frmMenu.Add (btnRemove); - var btnUp = new Button { X = Pos.Right (_lstMenus) + 2, Y = Pos.Top (btnRemove) + 2, Text = CM.Glyphs.UpArrow.ToString () }; + var btnUp = new Button { X = Pos.Right (_lstMenus) + 2, Y = Pos.Top (btnRemove) + 2, Text = Glyphs.UpArrow.ToString () }; frmMenu.Add (btnUp); - var btnDown = new Button { X = Pos.Right (_lstMenus) + 2, Y = Pos.Top (btnUp) + 1, Text = CM.Glyphs.DownArrow.ToString () }; + var btnDown = new Button { X = Pos.Right (_lstMenus) + 2, Y = Pos.Top (btnUp) + 1, Text = Glyphs.DownArrow.ToString () }; frmMenu.Add (btnDown); Add (frmMenu); diff --git a/UICatalog/Scenarios/DynamicStatusBar.cs b/UICatalog/Scenarios/DynamicStatusBar.cs index ce377c3de7..4e1cd157a3 100644 --- a/UICatalog/Scenarios/DynamicStatusBar.cs +++ b/UICatalog/Scenarios/DynamicStatusBar.cs @@ -293,10 +293,10 @@ public DynamicStatusBarSample () var _btnRemove = new Button { X = Pos.Left (_btnAdd), Y = Pos.Top (_btnAdd) + 1, Text = "Remove" }; _frmStatusBar.Add (_btnRemove); - var _btnUp = new Button { X = Pos.Right (_lstItems) + 2, Y = Pos.Top (_btnRemove) + 2, Text = CM.Glyphs.UpArrow.ToString () }; + var _btnUp = new Button { X = Pos.Right (_lstItems) + 2, Y = Pos.Top (_btnRemove) + 2, Text = Glyphs.UpArrow.ToString () }; _frmStatusBar.Add (_btnUp); - var _btnDown = new Button { X = Pos.Right (_lstItems) + 2, Y = Pos.Top (_btnUp) + 1, Text = CM.Glyphs.DownArrow.ToString () }; + var _btnDown = new Button { X = Pos.Right (_lstItems) + 2, Y = Pos.Top (_btnUp) + 1, Text = Glyphs.DownArrow.ToString () }; _frmStatusBar.Add (_btnDown); Add (_frmStatusBar); diff --git a/UICatalog/Scenarios/GraphViewExample.cs b/UICatalog/Scenarios/GraphViewExample.cs index f66463664a..bb62e1cf04 100644 --- a/UICatalog/Scenarios/GraphViewExample.cs +++ b/UICatalog/Scenarios/GraphViewExample.cs @@ -251,7 +251,7 @@ private void MultiBarGraph () var series = new MultiBarSeries (3, 1, 0.25f, new [] { magenta, cyan, red }); - Rune stiple = CM.Glyphs.Stipple; + Rune stiple = Glyphs.Stipple; series.AddBars ("'96", stiple, 5900, 9000, 14000); series.AddBars ("'97", stiple, 6100, 9200, 14800); @@ -817,7 +817,7 @@ private void SetupPopulationPyramid () _graphView.AxisY.ShowLabelsEvery = 0; _graphView.AxisY.Minimum = 0; - var stiple = new GraphCellToRender (CM.Glyphs.Stipple); + var stiple = new GraphCellToRender (Glyphs.Stipple); // Bars in 2 directions diff --git a/UICatalog/Scenarios/LineViewExample.cs b/UICatalog/Scenarios/LineViewExample.cs index ff3a6b82a5..9113ccc5b8 100644 --- a/UICatalog/Scenarios/LineViewExample.cs +++ b/UICatalog/Scenarios/LineViewExample.cs @@ -45,7 +45,7 @@ public override void Main () // creates a horizontal line var arrowLine = new LineView { - Y = 8, Width = 10, StartingAnchor = CM.Glyphs.LeftTee, EndingAnchor = (Rune)'>' + Y = 8, Width = 10, StartingAnchor = Glyphs.LeftTee, EndingAnchor = (Rune)'>' }; appWindow.Add (arrowLine); @@ -62,7 +62,7 @@ public override void Main () // creates a horizontal line var verticalArrow = new LineView (Orientation.Vertical) { - X = 27, StartingAnchor = CM.Glyphs.TopTee, EndingAnchor = (Rune)'V' + X = 27, StartingAnchor = Glyphs.TopTee, EndingAnchor = (Rune)'V' }; appWindow.Add (verticalArrow); diff --git a/UICatalog/Scenarios/ShadowStyles.cs b/UICatalog/Scenarios/ShadowStyles.cs index b9919fbcd4..7552c9937a 100644 --- a/UICatalog/Scenarios/ShadowStyles.cs +++ b/UICatalog/Scenarios/ShadowStyles.cs @@ -45,7 +45,7 @@ public override void Main () app.DrawingContent += (s, e) => { - app!.FillRect (app!.Viewport, CM.Glyphs.Dot); + app!.FillRect (app!.Viewport, Glyphs.Dot); e.Cancel = true; }; diff --git a/UICatalog/Scenarios/SimpleDialog.cs b/UICatalog/Scenarios/SimpleDialog.cs index 6719079361..cf3a60a8cd 100644 --- a/UICatalog/Scenarios/SimpleDialog.cs +++ b/UICatalog/Scenarios/SimpleDialog.cs @@ -21,7 +21,7 @@ public override void Main () appWindow.DrawingText += (s, e) => { - appWindow!.FillRect (appWindow!.Viewport, CM.Glyphs.Dot); + appWindow!.FillRect (appWindow!.Viewport, Glyphs.Dot); e.Cancel = true; }; diff --git a/UICatalog/Scenarios/Sliders.cs b/UICatalog/Scenarios/Sliders.cs index 7645d1753a..819246da50 100644 --- a/UICatalog/Scenarios/Sliders.cs +++ b/UICatalog/Scenarios/Sliders.cs @@ -90,17 +90,17 @@ public void MakeSliders (View v, List options) { if (single.Orientation == Orientation.Horizontal) { - single.Style.SpaceChar = new Cell { Rune = CM.Glyphs.HLine }; - single.Style.OptionChar = new Cell { Rune = CM.Glyphs.HLine }; + single.Style.SpaceChar = new Cell { Rune = Glyphs.HLine }; + single.Style.OptionChar = new Cell { Rune = Glyphs.HLine }; } else { - single.Style.SpaceChar = new Cell { Rune = CM.Glyphs.VLine }; - single.Style.OptionChar = new Cell { Rune = CM.Glyphs.VLine }; + single.Style.SpaceChar = new Cell { Rune = Glyphs.VLine }; + single.Style.OptionChar = new Cell { Rune = Glyphs.VLine }; } }; - single.Style.SetChar = new Cell { Rune = CM.Glyphs.ContinuousMeterSegment }; - single.Style.DragChar = new Cell { Rune = CM.Glyphs.ContinuousMeterSegment }; + single.Style.SetChar = new Cell { Rune = Glyphs.ContinuousMeterSegment }; + single.Style.DragChar = new Cell { Rune = Glyphs.ContinuousMeterSegment }; v.Add (single); @@ -264,7 +264,7 @@ public override void Main () { s.Orientation = Orientation.Horizontal; - s.Style.SpaceChar = new Cell { Rune = CM.Glyphs.HLine }; + s.Style.SpaceChar = new Cell { Rune = Glyphs.HLine }; if (prev == null) { @@ -282,7 +282,7 @@ public override void Main () { s.Orientation = Orientation.Vertical; - s.Style.SpaceChar = new Cell { Rune = CM.Glyphs.VLine }; + s.Style.SpaceChar = new Cell { Rune = Glyphs.VLine }; if (prev == null) { diff --git a/UICatalog/Scenarios/Snake.cs b/UICatalog/Scenarios/Snake.cs index 9bcd8a1983..1896c7dae8 100644 --- a/UICatalog/Scenarios/Snake.cs +++ b/UICatalog/Scenarios/Snake.cs @@ -292,11 +292,11 @@ private class SnakeView : View public SnakeView (SnakeState state) { - _appleRune = CM.Glyphs.Apple; + _appleRune = Glyphs.Apple; if (!Driver.IsRuneSupported (_appleRune)) { - _appleRune = CM.Glyphs.AppleBMP; + _appleRune = Glyphs.AppleBMP; } State = state; diff --git a/UICatalog/Scenarios/TableEditor.cs b/UICatalog/Scenarios/TableEditor.cs index 22bafcfe1a..a85d30ecc7 100644 --- a/UICatalog/Scenarios/TableEditor.cs +++ b/UICatalog/Scenarios/TableEditor.cs @@ -1278,14 +1278,14 @@ private void SortColumn (int clickedCol, string sort, bool isAsc) // add a new one if this the one that is being sorted if (col.Ordinal == clickedCol) { - col.ColumnName += isAsc ? CM.Glyphs.UpArrow : CM.Glyphs.DownArrow; + col.ColumnName += isAsc ? Glyphs.UpArrow : Glyphs.DownArrow; } } _tableView.Update (); } - private string StripArrows (string columnName) { return columnName.Replace ($"{CM.Glyphs.DownArrow}", "").Replace ($"{CM.Glyphs.UpArrow}", ""); } + private string StripArrows (string columnName) { return columnName.Replace ($"{Glyphs.DownArrow}", "").Replace ($"{Glyphs.UpArrow}", ""); } private void TableViewKeyPress (object sender, Key e) { @@ -1528,8 +1528,8 @@ private int ToTableCol (int col) private string TrimArrows (string columnName) { return columnName.TrimEnd ( - (char)CM.Glyphs.UpArrow.Value, - (char)CM.Glyphs.DownArrow.Value + (char)Glyphs.UpArrow.Value, + (char)Glyphs.DownArrow.Value ); } diff --git a/UICatalog/Scenarios/Unicode.cs b/UICatalog/Scenarios/Unicode.cs index 156e78e112..f494c071c7 100644 --- a/UICatalog/Scenarios/Unicode.cs +++ b/UICatalog/Scenarios/Unicode.cs @@ -17,15 +17,15 @@ public override void Main () var gitString = $"gui.cs 糊 (hú) { - CM.Glyphs.IdenticalTo + Glyphs.IdenticalTo } { - CM.Glyphs.DownArrow + Glyphs.DownArrow }18 { - CM.Glyphs.UpArrow + Glyphs.UpArrow }10 { - CM.Glyphs.VerticalFourDots + Glyphs.VerticalFourDots }1 { - CM.Glyphs.HorizontalEllipsis + Glyphs.HorizontalEllipsis }"; // Init diff --git a/UnitTests/Application/ApplicationTests.cs b/UnitTests/Application/ApplicationTests.cs index e3528e3764..3ad3db9c29 100644 --- a/UnitTests/Application/ApplicationTests.cs +++ b/UnitTests/Application/ApplicationTests.cs @@ -1,4 +1,5 @@ -using Xunit.Abstractions; +using System.Diagnostics; +using Xunit.Abstractions; using static Terminal.Gui.ConfigurationManager; // Alias Console to MockConsole so we don't accidentally use Console @@ -201,6 +202,10 @@ public void End_And_Shutdown_Should_Not_Dispose_ApplicationTop () [Fact] public void Init_Begin_End_Cleans_Up () { + // Start stopwatch + Stopwatch stopwatch = new Stopwatch (); + stopwatch.Start (); + Init (); // Begin will cause Run() to be called, which will call Begin(). Thus will block the tests @@ -237,6 +242,12 @@ public void Init_Begin_End_Cleans_Up () Assert.Null (Application.Top); Assert.Null (Application.MainLoop); Assert.Null (Application.Driver); + + // Stop stopwatch + stopwatch.Stop (); + + _output.WriteLine ($"Load took {stopwatch.ElapsedMilliseconds} ms"); + } [Theory] diff --git a/UnitTests/Configuration/ConfigurationMangerTests.cs b/UnitTests/Configuration/ConfigurationMangerTests.cs index 00b6445f8d..0ab76e4c2d 100644 --- a/UnitTests/Configuration/ConfigurationMangerTests.cs +++ b/UnitTests/Configuration/ConfigurationMangerTests.cs @@ -208,6 +208,27 @@ void ConfigurationManager_Updated (object sender, ConfigurationManagerEventArgs Reset (); } + [Fact] + public void Load_Performance_Check () + { + Locations = ConfigLocations.All; + Reset (); + + // Start stopwatch + Stopwatch stopwatch = new Stopwatch (); + stopwatch.Start (); + + // Act + Load (true); + Apply(); + + // Stop stopwatch + stopwatch.Stop (); + + // Assert + _output.WriteLine ($"Load took {stopwatch.ElapsedMilliseconds} ms"); + } + [Fact] public void Load_Loads_Custom_Json () @@ -236,41 +257,41 @@ public void Load_Loads_Custom_Json () Reset (); } - [Fact] - [AutoInitShutdown] - public void LoadConfigurationFromAllSources_ShouldLoadSettingsFromAllSources () - { - //var _configFilename = "config.json"; - //// Arrange - //// Create a mock of the configuration files in all sources - //// Home directory - //string homeDir = Path.Combine (Environment.GetFolderPath (Environment.SpecialFolder.UserProfile), ".tui"); - //if (!Directory.Exists (homeDir)) { - // Directory.CreateDirectory (homeDir); - //} - //string globalConfigFile = Path.Combine (homeDir, _configFilename); - //string appSpecificConfigFile = Path.Combine (homeDir, "appname.config.json"); - //File.WriteAllText (globalConfigFile, "{\"Settings\": {\"TestSetting\":\"Global\"}}"); - //File.WriteAllText (appSpecificConfigFile, "{\"Settings\": {\"TestSetting\":\"AppSpecific\"}}"); - - //// App directory - //string appDir = Directory.GetCurrentDirectory (); - //string appDirGlobalConfigFile = Path.Combine (appDir, _configFilename); - //string appDirAppSpecificConfigFile = Path.Combine (appDir, "appname.config.json"); - //File.WriteAllText (appDirGlobalConfigFile, "{\"Settings\": {\"TestSetting\":\"GlobalAppDir\"}}"); - //File.WriteAllText (appDirAppSpecificConfigFile, "{\"Settings\": {\"TestSetting\":\"AppSpecificAppDir\"}}"); - - //// App resources - //// ... - - //// Act - //ConfigurationManager.Locations = ConfigurationManager.ConfigLocation.All; - //ConfigurationManager.Load (); - - //// Assert - //// Check that the settings from the highest precedence source are loaded - //Assert.Equal ("AppSpecific", ConfigurationManager.Config.Settings.TestSetting); - } + //[Fact] + //[AutoInitShutdown] + //public void LoadConfigurationFromAllSources_ShouldLoadSettingsFromAllSources () + //{ + // //var _configFilename = "config.json"; + // //// Arrange + // //// Create a mock of the configuration files in all sources + // //// Home directory + // //string homeDir = Path.Combine (Environment.GetFolderPath (Environment.SpecialFolder.UserProfile), ".tui"); + // //if (!Directory.Exists (homeDir)) { + // // Directory.CreateDirectory (homeDir); + // //} + // //string globalConfigFile = Path.Combine (homeDir, _configFilename); + // //string appSpecificConfigFile = Path.Combine (homeDir, "appname.config.json"); + // //File.WriteAllText (globalConfigFile, "{\"Settings\": {\"TestSetting\":\"Global\"}}"); + // //File.WriteAllText (appSpecificConfigFile, "{\"Settings\": {\"TestSetting\":\"AppSpecific\"}}"); + + // //// App directory + // //string appDir = Directory.GetCurrentDirectory (); + // //string appDirGlobalConfigFile = Path.Combine (appDir, _configFilename); + // //string appDirAppSpecificConfigFile = Path.Combine (appDir, "appname.config.json"); + // //File.WriteAllText (appDirGlobalConfigFile, "{\"Settings\": {\"TestSetting\":\"GlobalAppDir\"}}"); + // //File.WriteAllText (appDirAppSpecificConfigFile, "{\"Settings\": {\"TestSetting\":\"AppSpecificAppDir\"}}"); + + // //// App resources + // //// ... + + // //// Act + // //ConfigurationManager.Locations = ConfigurationManager.ConfigLocation.All; + // //ConfigurationManager.Load (); + + // //// Assert + // //// Check that the settings from the highest precedence source are loaded + // //Assert.Equal ("AppSpecific", ConfigurationManager.Config.Settings.TestSetting); + //} [Fact] diff --git a/UnitTests/Configuration/GlyphTests.cs b/UnitTests/Configuration/GlyphTests.cs new file mode 100644 index 0000000000..59a4b9d0e5 --- /dev/null +++ b/UnitTests/Configuration/GlyphTests.cs @@ -0,0 +1,50 @@ +using System.Reflection; +using System.Text; +using System.Text.Json; +using static Terminal.Gui.ConfigurationManager; + +namespace Terminal.Gui.ConfigurationTests; + +public class GlyphTests +{ + [Fact] + public void Overrides_Defaults () + { + // arrange + Locations = ConfigLocations.Default; + Load (true); + + Assert.Equal ((Rune)'⟦', Glyphs.LeftBracket); + + var glyph = (Rune)Themes ["Default"] ["Glyphs.LeftBracket"].PropertyValue; + Assert.Equal ((Rune)'⟦', glyph); + + ThrowOnJsonErrors = true; + + // act + var json = """ + { + "Themes": [ + { + "Default": + { + "Glyphs.LeftBracket": "[" + } + } + ] + } + """; + + Settings!.Update (json, "Overrides_Defaults", ConfigLocations.Runtime); + Apply(); + + // assert + glyph = glyph = (Rune)Themes ["Default"] ["Glyphs.LeftBracket"].PropertyValue; + Assert.Equal ((Rune)'[', glyph); + Assert.Equal((Rune)'[', Glyphs.LeftBracket); + + // clean up + Locations = ConfigLocations.All; + } + +} diff --git a/UnitTests/Configuration/RuneJsonConverterTests.cs b/UnitTests/Configuration/RuneJsonConverterTests.cs index c0a56a5bfd..b8c98498ce 100644 --- a/UnitTests/Configuration/RuneJsonConverterTests.cs +++ b/UnitTests/Configuration/RuneJsonConverterTests.cs @@ -3,7 +3,7 @@ namespace Terminal.Gui.ConfigurationTests; -public class RunJsonConverterTests +public class RuneJsonConverterTests { [Theory] [InlineData ("aa")] diff --git a/UnitTests/Dialogs/DialogTests.cs b/UnitTests/Dialogs/DialogTests.cs index 9320b84039..9009b41d36 100644 --- a/UnitTests/Dialogs/DialogTests.cs +++ b/UnitTests/Dialogs/DialogTests.cs @@ -18,12 +18,12 @@ public void Add_Button_Works () var title = "1234"; var btn1Text = "yes"; - var btn1 = $"{CM.Glyphs.LeftBracket} {btn1Text} {CM.Glyphs.RightBracket}"; + var btn1 = $"{Glyphs.LeftBracket} {btn1Text} {Glyphs.RightBracket}"; var btn2Text = "no"; - var btn2 = $"{CM.Glyphs.LeftBracket} {btn2Text} {CM.Glyphs.RightBracket}"; + var btn2 = $"{Glyphs.LeftBracket} {btn2Text} {Glyphs.RightBracket}"; // We test with one button first, but do this to get the width right for 2 - int width = $@"{CM.Glyphs.VLine} {btn1} {btn2} {CM.Glyphs.VLine}".Length; + int width = $@"{Glyphs.VLine} {btn1} {btn2} {Glyphs.VLine}".Length; d.SetBufferSize (width, 1); // Override CM @@ -45,14 +45,14 @@ public void Add_Button_Works () // Create with no top or bottom border to simplify testing button layout (no need to account for title etc..) dlg.Border.Thickness = new (1, 0, 1, 0); runstate = Begin (dlg); - var buttonRow = $"{CM.Glyphs.VLine} {btn1} {CM.Glyphs.VLine}"; + var buttonRow = $"{Glyphs.VLine} {btn1} {Glyphs.VLine}"; RunIteration (ref runstate); TestHelpers.AssertDriverContentsWithFrameAre ($"{buttonRow}", _output); // Now add a second button - buttonRow = $"{CM.Glyphs.VLine} {btn1} {btn2} {CM.Glyphs.VLine}"; + buttonRow = $"{Glyphs.VLine} {btn1} {btn2} {Glyphs.VLine}"; dlg.AddButton (new () { Text = btn2Text }); RunIteration (ref runstate); @@ -76,11 +76,11 @@ public void Add_Button_Works () RunIteration (ref runstate); - buttonRow = $"{CM.Glyphs.VLine}{btn1} {CM.Glyphs.VLine}"; + buttonRow = $"{Glyphs.VLine}{btn1} {Glyphs.VLine}"; TestHelpers.AssertDriverContentsWithFrameAre ($"{buttonRow}", _output); // Now add a second button - buttonRow = $"{CM.Glyphs.VLine}{btn1} {btn2}{CM.Glyphs.VLine}"; + buttonRow = $"{Glyphs.VLine}{btn1} {btn2}{Glyphs.VLine}"; dlg.AddButton (new () { Text = btn2Text }); RunIteration (ref runstate); TestHelpers.AssertDriverContentsWithFrameAre ($"{buttonRow}", _output); @@ -103,11 +103,11 @@ public void Add_Button_Works () RunIteration (ref runstate); - buttonRow = $"{CM.Glyphs.VLine}{new (' ', width - btn1.Length - 2)}{btn1}{CM.Glyphs.VLine}"; + buttonRow = $"{Glyphs.VLine}{new (' ', width - btn1.Length - 2)}{btn1}{Glyphs.VLine}"; TestHelpers.AssertDriverContentsWithFrameAre ($"{buttonRow}", _output); // Now add a second button - buttonRow = $"{CM.Glyphs.VLine} {btn1} {btn2}{CM.Glyphs.VLine}"; + buttonRow = $"{Glyphs.VLine} {btn1} {btn2}{Glyphs.VLine}"; dlg.AddButton (new () { Text = btn2Text }); RunIteration (ref runstate); @@ -130,11 +130,11 @@ public void Add_Button_Works () runstate = Begin (dlg); RunIteration (ref runstate); - buttonRow = $"{CM.Glyphs.VLine}{btn1}{new (' ', width - btn1.Length - 2)}{CM.Glyphs.VLine}"; + buttonRow = $"{Glyphs.VLine}{btn1}{new (' ', width - btn1.Length - 2)}{Glyphs.VLine}"; TestHelpers.AssertDriverContentsWithFrameAre ($"{buttonRow}", _output); // Now add a second button - buttonRow = $"{CM.Glyphs.VLine}{btn1} {btn2} {CM.Glyphs.VLine}"; + buttonRow = $"{Glyphs.VLine}{btn1} {btn2} {Glyphs.VLine}"; dlg.AddButton (new () { Text = btn2Text }); RunIteration (ref runstate); @@ -157,15 +157,15 @@ public void ButtonAlignment_Four () // E.g "|[ yes ][ no ][ maybe ]|" var btn1Text = "yes"; - var btn1 = $"{CM.Glyphs.LeftBracket} {btn1Text} {CM.Glyphs.RightBracket}"; + var btn1 = $"{Glyphs.LeftBracket} {btn1Text} {Glyphs.RightBracket}"; var btn2Text = "no"; - var btn2 = $"{CM.Glyphs.LeftBracket} {btn2Text} {CM.Glyphs.RightBracket}"; + var btn2 = $"{Glyphs.LeftBracket} {btn2Text} {Glyphs.RightBracket}"; var btn3Text = "maybe"; - var btn3 = $"{CM.Glyphs.LeftBracket} {btn3Text} {CM.Glyphs.RightBracket}"; + var btn3 = $"{Glyphs.LeftBracket} {btn3Text} {Glyphs.RightBracket}"; var btn4Text = "never"; - var btn4 = $"{CM.Glyphs.LeftBracket} {btn4Text} {CM.Glyphs.RightBracket}"; + var btn4 = $"{Glyphs.LeftBracket} {btn4Text} {Glyphs.RightBracket}"; - var buttonRow = $"{CM.Glyphs.VLine} {btn1} {btn2} {btn3} {btn4} {CM.Glyphs.VLine}"; + var buttonRow = $"{Glyphs.VLine} {btn1} {btn2} {btn3} {btn4} {Glyphs.VLine}"; int width = buttonRow.Length; d.SetBufferSize (buttonRow.Length, 3); @@ -184,7 +184,7 @@ public void ButtonAlignment_Four () dlg.Dispose (); // Justify - buttonRow = $"{CM.Glyphs.VLine}{btn1} {btn2} {btn3} {btn4}{CM.Glyphs.VLine}"; + buttonRow = $"{Glyphs.VLine}{btn1} {btn2} {btn3} {btn4}{Glyphs.VLine}"; Assert.Equal (width, buttonRow.Length); (runstate, dlg) = BeginButtonTestDialog ( @@ -201,7 +201,7 @@ public void ButtonAlignment_Four () dlg.Dispose (); // Right - buttonRow = $"{CM.Glyphs.VLine} {btn1} {btn2} {btn3} {btn4}{CM.Glyphs.VLine}"; + buttonRow = $"{Glyphs.VLine} {btn1} {btn2} {btn3} {btn4}{Glyphs.VLine}"; Assert.Equal (width, buttonRow.Length); (runstate, dlg) = BeginButtonTestDialog ( @@ -218,7 +218,7 @@ public void ButtonAlignment_Four () dlg.Dispose (); // Left - buttonRow = $"{CM.Glyphs.VLine}{btn1} {btn2} {btn3} {btn4} {CM.Glyphs.VLine}"; + buttonRow = $"{Glyphs.VLine}{btn1} {btn2} {btn3} {btn4} {Glyphs.VLine}"; Assert.Equal (width, buttonRow.Length); (runstate, dlg) = BeginButtonTestDialog ( @@ -249,13 +249,13 @@ public void ButtonAlignment_Four_On_Too_Small_Width () // E.g "|[ yes ][ no ][ maybe ][ never ]|" var btn1Text = "yes"; - var btn1 = $"{CM.Glyphs.LeftBracket} {btn1Text} {CM.Glyphs.RightBracket}"; + var btn1 = $"{Glyphs.LeftBracket} {btn1Text} {Glyphs.RightBracket}"; var btn2Text = "no"; - var btn2 = $"{CM.Glyphs.LeftBracket} {btn2Text} {CM.Glyphs.RightBracket}"; + var btn2 = $"{Glyphs.LeftBracket} {btn2Text} {Glyphs.RightBracket}"; var btn3Text = "maybe"; - var btn3 = $"{CM.Glyphs.LeftBracket} {btn3Text} {CM.Glyphs.RightBracket}"; + var btn3 = $"{Glyphs.LeftBracket} {btn3Text} {Glyphs.RightBracket}"; var btn4Text = "never"; - var btn4 = $"{CM.Glyphs.LeftBracket} {btn4Text} {CM.Glyphs.RightBracket}"; + var btn4 = $"{Glyphs.LeftBracket} {btn4Text} {Glyphs.RightBracket}"; var buttonRow = string.Empty; var width = 30; @@ -263,7 +263,7 @@ public void ButtonAlignment_Four_On_Too_Small_Width () // Default - Center buttonRow = - $"{CM.Glyphs.VLine} yes {CM.Glyphs.RightBracket}{btn2}{btn3}{CM.Glyphs.LeftBracket} never{CM.Glyphs.VLine}"; + $"{Glyphs.VLine} yes {Glyphs.RightBracket}{btn2}{btn3}{Glyphs.LeftBracket} never{Glyphs.VLine}"; (runstate, Dialog dlg) = BeginButtonTestDialog ( title, @@ -281,7 +281,7 @@ public void ButtonAlignment_Four_On_Too_Small_Width () // Justify buttonRow = - $"{CM.Glyphs.VLine}{CM.Glyphs.LeftBracket} yes {CM.Glyphs.LeftBracket} no {CM.Glyphs.LeftBracket} maybe {CM.Glyphs.LeftBracket} never {CM.Glyphs.RightBracket}{CM.Glyphs.VLine}"; + $"{Glyphs.VLine}{Glyphs.LeftBracket} yes {Glyphs.LeftBracket} no {Glyphs.LeftBracket} maybe {Glyphs.LeftBracket} never {Glyphs.RightBracket}{Glyphs.VLine}"; (runstate, dlg) = BeginButtonTestDialog ( title, @@ -297,7 +297,7 @@ public void ButtonAlignment_Four_On_Too_Small_Width () dlg.Dispose (); // Right - buttonRow = $"{CM.Glyphs.VLine}es {CM.Glyphs.RightBracket}{btn2}{btn3}{btn4}{CM.Glyphs.VLine}"; + buttonRow = $"{Glyphs.VLine}es {Glyphs.RightBracket}{btn2}{btn3}{btn4}{Glyphs.VLine}"; Assert.Equal (width, buttonRow.Length); (runstate, dlg) = BeginButtonTestDialog ( @@ -314,7 +314,7 @@ public void ButtonAlignment_Four_On_Too_Small_Width () dlg.Dispose (); // Left - buttonRow = $"{CM.Glyphs.VLine}{btn1}{btn2}{btn3}{CM.Glyphs.LeftBracket} neve{CM.Glyphs.VLine}"; + buttonRow = $"{Glyphs.VLine}{btn1}{btn2}{btn3}{Glyphs.LeftBracket} neve{Glyphs.VLine}"; (runstate, dlg) = BeginButtonTestDialog ( title, @@ -344,17 +344,17 @@ public void ButtonAlignment_Four_WideOdd () // E.g "|[ yes ][ no ][ maybe ]|" var btn1Text = "really long button 1"; - var btn1 = $"{CM.Glyphs.LeftBracket} {btn1Text} {CM.Glyphs.RightBracket}"; + var btn1 = $"{Glyphs.LeftBracket} {btn1Text} {Glyphs.RightBracket}"; var btn2Text = "really long button 2"; - var btn2 = $"{CM.Glyphs.LeftBracket} {btn2Text} {CM.Glyphs.RightBracket}"; + var btn2 = $"{Glyphs.LeftBracket} {btn2Text} {Glyphs.RightBracket}"; var btn3Text = "really long button 3"; - var btn3 = $"{CM.Glyphs.LeftBracket} {btn3Text} {CM.Glyphs.RightBracket}"; + var btn3 = $"{Glyphs.LeftBracket} {btn3Text} {Glyphs.RightBracket}"; var btn4Text = "really long button 44"; // 44 is intentional to make length different than rest - var btn4 = $"{CM.Glyphs.LeftBracket} {btn4Text} {CM.Glyphs.RightBracket}"; + var btn4 = $"{Glyphs.LeftBracket} {btn4Text} {Glyphs.RightBracket}"; // Note extra spaces to make dialog even wider // 123456 1234567 - var buttonRow = $"{CM.Glyphs.VLine} {btn1} {btn2} {btn3} {btn4} {CM.Glyphs.VLine}"; + var buttonRow = $"{Glyphs.VLine} {btn1} {btn2} {btn3} {btn4} {Glyphs.VLine}"; int width = buttonRow.Length; d.SetBufferSize (buttonRow.Length, 1); @@ -373,7 +373,7 @@ public void ButtonAlignment_Four_WideOdd () dlg.Dispose (); // Justify - buttonRow = $"{CM.Glyphs.VLine}{btn1} {btn2} {btn3} {btn4}{CM.Glyphs.VLine}"; + buttonRow = $"{Glyphs.VLine}{btn1} {btn2} {btn3} {btn4}{Glyphs.VLine}"; Assert.Equal (width, buttonRow.Length); (runstate, dlg) = BeginButtonTestDialog ( @@ -390,7 +390,7 @@ public void ButtonAlignment_Four_WideOdd () dlg.Dispose (); // Right - buttonRow = $"{CM.Glyphs.VLine} {btn1} {btn2} {btn3} {btn4}{CM.Glyphs.VLine}"; + buttonRow = $"{Glyphs.VLine} {btn1} {btn2} {btn3} {btn4}{Glyphs.VLine}"; Assert.Equal (width, buttonRow.Length); (runstate, dlg) = BeginButtonTestDialog ( @@ -407,7 +407,7 @@ public void ButtonAlignment_Four_WideOdd () dlg.Dispose (); // Left - buttonRow = $"{CM.Glyphs.VLine}{btn1} {btn2} {btn3} {btn4} {CM.Glyphs.VLine}"; + buttonRow = $"{Glyphs.VLine}{btn1} {btn2} {btn3} {btn4} {Glyphs.VLine}"; Assert.Equal (width, buttonRow.Length); (runstate, dlg) = BeginButtonTestDialog ( @@ -438,19 +438,19 @@ public void ButtonAlignment_Four_Wider () // E.g "|[ yes ][ no ][ maybe ]|" var btn1Text = "yes"; - var btn1 = $"{CM.Glyphs.LeftBracket} {btn1Text} {CM.Glyphs.RightBracket}"; + var btn1 = $"{Glyphs.LeftBracket} {btn1Text} {Glyphs.RightBracket}"; var btn2Text = "no"; - var btn2 = $"{CM.Glyphs.LeftBracket} {btn2Text} {CM.Glyphs.RightBracket}"; + var btn2 = $"{Glyphs.LeftBracket} {btn2Text} {Glyphs.RightBracket}"; var btn3Text = "你你你你你"; // This is a wide char - var btn3 = $"{CM.Glyphs.LeftBracket} {btn3Text} {CM.Glyphs.RightBracket}"; + var btn3 = $"{Glyphs.LeftBracket} {btn3Text} {Glyphs.RightBracket}"; // Requires a Nerd Font var btn4Text = "\uE36E\uE36F\uE370\uE371\uE372\uE373"; - var btn4 = $"{CM.Glyphs.LeftBracket} {btn4Text} {CM.Glyphs.RightBracket}"; + var btn4 = $"{Glyphs.LeftBracket} {btn4Text} {Glyphs.RightBracket}"; // Note extra spaces to make dialog even wider // 123456 123456 - var buttonRow = $"{CM.Glyphs.VLine} {btn1} {btn2} {btn3} {btn4} {CM.Glyphs.VLine}"; + var buttonRow = $"{Glyphs.VLine} {btn1} {btn2} {btn3} {btn4} {Glyphs.VLine}"; int width = buttonRow.GetColumns (); d.SetBufferSize (width, 3); @@ -469,7 +469,7 @@ public void ButtonAlignment_Four_Wider () dlg.Dispose (); // Justify - buttonRow = $"{CM.Glyphs.VLine}{btn1} {btn2} {btn3} {btn4}{CM.Glyphs.VLine}"; + buttonRow = $"{Glyphs.VLine}{btn1} {btn2} {btn3} {btn4}{Glyphs.VLine}"; Assert.Equal (width, buttonRow.GetColumns ()); (runstate, dlg) = BeginButtonTestDialog ( @@ -486,7 +486,7 @@ public void ButtonAlignment_Four_Wider () dlg.Dispose (); // Right - buttonRow = $"{CM.Glyphs.VLine} {btn1} {btn2} {btn3} {btn4}{CM.Glyphs.VLine}"; + buttonRow = $"{Glyphs.VLine} {btn1} {btn2} {btn3} {btn4}{Glyphs.VLine}"; Assert.Equal (width, buttonRow.GetColumns ()); (runstate, dlg) = BeginButtonTestDialog ( @@ -503,7 +503,7 @@ public void ButtonAlignment_Four_Wider () dlg.Dispose (); // Left - buttonRow = $"{CM.Glyphs.VLine}{btn1} {btn2} {btn3} {btn4} {CM.Glyphs.VLine}"; + buttonRow = $"{Glyphs.VLine}{btn1} {btn2} {btn3} {btn4} {Glyphs.VLine}"; Assert.Equal (width, buttonRow.GetColumns ()); (runstate, dlg) = BeginButtonTestDialog ( @@ -535,7 +535,7 @@ public void ButtonAlignment_One () var btnText = "ok"; var buttonRow = - $"{CM.Glyphs.VLine} {CM.Glyphs.LeftBracket} {btnText} {CM.Glyphs.RightBracket} {CM.Glyphs.VLine}"; + $"{Glyphs.VLine} {Glyphs.LeftBracket} {btnText} {Glyphs.RightBracket} {Glyphs.VLine}"; int width = buttonRow.Length; d.SetBufferSize (width, 1); @@ -554,7 +554,7 @@ public void ButtonAlignment_One () // Justify buttonRow = - $"{CM.Glyphs.VLine}{CM.Glyphs.LeftBracket} {btnText} {CM.Glyphs.RightBracket} {CM.Glyphs.VLine}"; + $"{Glyphs.VLine}{Glyphs.LeftBracket} {btnText} {Glyphs.RightBracket} {Glyphs.VLine}"; Assert.Equal (width, buttonRow.Length); (runstate, dlg) = BeginButtonTestDialog ( @@ -569,7 +569,7 @@ public void ButtonAlignment_One () // Right buttonRow = - $"{CM.Glyphs.VLine} {CM.Glyphs.LeftBracket} {btnText} {CM.Glyphs.RightBracket}{CM.Glyphs.VLine}"; + $"{Glyphs.VLine} {Glyphs.LeftBracket} {btnText} {Glyphs.RightBracket}{Glyphs.VLine}"; Assert.Equal (width, buttonRow.Length); (runstate, dlg) = BeginButtonTestDialog ( @@ -584,7 +584,7 @@ public void ButtonAlignment_One () // Left buttonRow = - $"{CM.Glyphs.VLine}{CM.Glyphs.LeftBracket} {btnText} {CM.Glyphs.RightBracket} {CM.Glyphs.VLine}"; + $"{Glyphs.VLine}{Glyphs.LeftBracket} {btnText} {Glyphs.RightBracket} {Glyphs.VLine}"; Assert.Equal (width, buttonRow.Length); (runstate, dlg) = BeginButtonTestDialog ( @@ -599,7 +599,7 @@ public void ButtonAlignment_One () // Wider buttonRow = - $"{CM.Glyphs.VLine} {CM.Glyphs.LeftBracket} {btnText} {CM.Glyphs.RightBracket} {CM.Glyphs.VLine}"; + $"{Glyphs.VLine} {Glyphs.LeftBracket} {btnText} {Glyphs.RightBracket} {Glyphs.VLine}"; width = buttonRow.Length; d.SetBufferSize (width, 1); @@ -616,7 +616,7 @@ public void ButtonAlignment_One () // Justify buttonRow = - $"{CM.Glyphs.VLine}{CM.Glyphs.LeftBracket} {btnText} {CM.Glyphs.RightBracket} {CM.Glyphs.VLine}"; + $"{Glyphs.VLine}{Glyphs.LeftBracket} {btnText} {Glyphs.RightBracket} {Glyphs.VLine}"; Assert.Equal (width, buttonRow.Length); (runstate, dlg) = BeginButtonTestDialog ( @@ -631,7 +631,7 @@ public void ButtonAlignment_One () // Right buttonRow = - $"{CM.Glyphs.VLine} {CM.Glyphs.LeftBracket} {btnText} {CM.Glyphs.RightBracket}{CM.Glyphs.VLine}"; + $"{Glyphs.VLine} {Glyphs.LeftBracket} {btnText} {Glyphs.RightBracket}{Glyphs.VLine}"; Assert.Equal (width, buttonRow.Length); (runstate, dlg) = BeginButtonTestDialog ( @@ -646,7 +646,7 @@ public void ButtonAlignment_One () // Left buttonRow = - $"{CM.Glyphs.VLine}{CM.Glyphs.LeftBracket} {btnText} {CM.Glyphs.RightBracket} {CM.Glyphs.VLine}"; + $"{Glyphs.VLine}{Glyphs.LeftBracket} {btnText} {Glyphs.RightBracket} {Glyphs.VLine}"; Assert.Equal (width, buttonRow.Length); (runstate, dlg) = BeginButtonTestDialog ( @@ -674,13 +674,13 @@ public void ButtonAlignment_Three () // E.g "|[ yes ][ no ][ maybe ]|" var btn1Text = "yes"; - var btn1 = $"{CM.Glyphs.LeftBracket} {btn1Text} {CM.Glyphs.RightBracket}"; + var btn1 = $"{Glyphs.LeftBracket} {btn1Text} {Glyphs.RightBracket}"; var btn2Text = "no"; - var btn2 = $"{CM.Glyphs.LeftBracket} {btn2Text} {CM.Glyphs.RightBracket}"; + var btn2 = $"{Glyphs.LeftBracket} {btn2Text} {Glyphs.RightBracket}"; var btn3Text = "maybe"; - var btn3 = $"{CM.Glyphs.LeftBracket} {btn3Text} {CM.Glyphs.RightBracket}"; + var btn3 = $"{Glyphs.LeftBracket} {btn3Text} {Glyphs.RightBracket}"; - var buttonRow = $@"{CM.Glyphs.VLine} {btn1} {btn2} {btn3} {CM.Glyphs.VLine}"; + var buttonRow = $@"{Glyphs.VLine} {btn1} {btn2} {btn3} {Glyphs.VLine}"; int width = buttonRow.Length; d.SetBufferSize (buttonRow.Length, 3); @@ -698,7 +698,7 @@ public void ButtonAlignment_Three () dlg.Dispose (); // Justify - buttonRow = $@"{CM.Glyphs.VLine}{btn1} {btn2} {btn3}{CM.Glyphs.VLine}"; + buttonRow = $@"{Glyphs.VLine}{btn1} {btn2} {btn3}{Glyphs.VLine}"; Assert.Equal (width, buttonRow.Length); (runstate, dlg) = BeginButtonTestDialog ( @@ -714,7 +714,7 @@ public void ButtonAlignment_Three () dlg.Dispose (); // Right - buttonRow = $@"{CM.Glyphs.VLine} {btn1} {btn2} {btn3}{CM.Glyphs.VLine}"; + buttonRow = $@"{Glyphs.VLine} {btn1} {btn2} {btn3}{Glyphs.VLine}"; Assert.Equal (width, buttonRow.Length); (runstate, dlg) = BeginButtonTestDialog ( @@ -730,7 +730,7 @@ public void ButtonAlignment_Three () dlg.Dispose (); // Left - buttonRow = $@"{CM.Glyphs.VLine}{btn1} {btn2} {btn3} {CM.Glyphs.VLine}"; + buttonRow = $@"{Glyphs.VLine}{btn1} {btn2} {btn3} {Glyphs.VLine}"; Assert.Equal (width, buttonRow.Length); (runstate, dlg) = BeginButtonTestDialog ( @@ -760,11 +760,11 @@ public void ButtonAlignment_Two () // E.g "|[ yes ][ no ]|" var btn1Text = "yes"; - var btn1 = $"{CM.Glyphs.LeftBracket} {btn1Text} {CM.Glyphs.RightBracket}"; + var btn1 = $"{Glyphs.LeftBracket} {btn1Text} {Glyphs.RightBracket}"; var btn2Text = "no"; - var btn2 = $"{CM.Glyphs.LeftBracket} {btn2Text} {CM.Glyphs.RightBracket}"; + var btn2 = $"{Glyphs.LeftBracket} {btn2Text} {Glyphs.RightBracket}"; - var buttonRow = $@"{CM.Glyphs.VLine} {btn1} {btn2} {CM.Glyphs.VLine}"; + var buttonRow = $@"{Glyphs.VLine} {btn1} {btn2} {Glyphs.VLine}"; int width = buttonRow.Length; d.SetBufferSize (buttonRow.Length, 3); @@ -781,7 +781,7 @@ public void ButtonAlignment_Two () dlg.Dispose (); // Justify - buttonRow = $@"{CM.Glyphs.VLine}{btn1} {btn2}{CM.Glyphs.VLine}"; + buttonRow = $@"{Glyphs.VLine}{btn1} {btn2}{Glyphs.VLine}"; Assert.Equal (width, buttonRow.Length); (runstate, dlg) = BeginButtonTestDialog ( @@ -796,7 +796,7 @@ public void ButtonAlignment_Two () dlg.Dispose (); // Right - buttonRow = $@"{CM.Glyphs.VLine} {btn1} {btn2}{CM.Glyphs.VLine}"; + buttonRow = $@"{Glyphs.VLine} {btn1} {btn2}{Glyphs.VLine}"; Assert.Equal (width, buttonRow.Length); (runstate, dlg) = BeginButtonTestDialog ( @@ -811,7 +811,7 @@ public void ButtonAlignment_Two () dlg.Dispose (); // Left - buttonRow = $@"{CM.Glyphs.VLine}{btn1} {btn2} {CM.Glyphs.VLine}"; + buttonRow = $@"{Glyphs.VLine}{btn1} {btn2} {Glyphs.VLine}"; Assert.Equal (width, buttonRow.Length); (runstate, dlg) = BeginButtonTestDialog ( @@ -841,11 +841,11 @@ public void ButtonAlignment_Two_Hidden () // E.g "|[ yes ][ no ]|" var btn1Text = "yes"; - var btn1 = $"{CM.Glyphs.LeftBracket} {btn1Text} {CM.Glyphs.RightBracket}"; + var btn1 = $"{Glyphs.LeftBracket} {btn1Text} {Glyphs.RightBracket}"; var btn2Text = "no"; - var btn2 = $"{CM.Glyphs.LeftBracket} {btn2Text} {CM.Glyphs.RightBracket}"; + var btn2 = $"{Glyphs.LeftBracket} {btn2Text} {Glyphs.RightBracket}"; - var buttonRow = $@"{CM.Glyphs.VLine} {btn1} {btn2} {CM.Glyphs.VLine}"; + var buttonRow = $@"{Glyphs.VLine} {btn1} {btn2} {Glyphs.VLine}"; int width = buttonRow.Length; d.SetBufferSize (buttonRow.Length, 3); @@ -859,7 +859,7 @@ public void ButtonAlignment_Two_Hidden () (runstate, dlg) = BeginButtonTestDialog (title, width, Alignment.Center, button1, button2); button1.Visible = false; RunIteration (ref runstate, firstIteration); - buttonRow = $@"{CM.Glyphs.VLine} {btn2} {CM.Glyphs.VLine}"; + buttonRow = $@"{Glyphs.VLine} {btn2} {Glyphs.VLine}"; TestHelpers.AssertDriverContentsWithFrameAre ($"{buttonRow}", _output); End (runstate); dlg.Dispose (); @@ -871,7 +871,7 @@ public void ButtonAlignment_Two_Hidden () (runstate, dlg) = BeginButtonTestDialog (title, width, Alignment.Fill, button1, button2); button1.Visible = false; RunIteration (ref runstate, firstIteration); - buttonRow = $@"{CM.Glyphs.VLine} {btn2}{CM.Glyphs.VLine}"; + buttonRow = $@"{Glyphs.VLine} {btn2}{Glyphs.VLine}"; TestHelpers.AssertDriverContentsWithFrameAre ($"{buttonRow}", _output); End (runstate); dlg.Dispose (); @@ -894,7 +894,7 @@ public void ButtonAlignment_Two_Hidden () (runstate, dlg) = BeginButtonTestDialog (title, width, Alignment.Start, button1, button2); button1.Visible = false; RunIteration (ref runstate, firstIteration); - buttonRow = $@"{CM.Glyphs.VLine} {btn2} {CM.Glyphs.VLine}"; + buttonRow = $@"{Glyphs.VLine} {btn2} {Glyphs.VLine}"; TestHelpers.AssertDriverContentsWithFrameAre ($"{buttonRow}", _output); End (runstate); dlg.Dispose (); @@ -924,7 +924,7 @@ public void Dialog_In_Window_With_Size_One_Button_Aligns () RequestStop (); } }; - var btn = $"{CM.Glyphs.LeftBracket} Ok {CM.Glyphs.RightBracket}"; + var btn = $"{Glyphs.LeftBracket} Ok {Glyphs.RightBracket}"; win.Loaded += (s, a) => { @@ -1096,7 +1096,7 @@ public void Dialog_Opened_From_Another_Dialog () }; var btn = - $"{CM.Glyphs.LeftBracket}{CM.Glyphs.LeftDefaultIndicator} Ok {CM.Glyphs.RightDefaultIndicator}{CM.Glyphs.RightBracket}"; + $"{Glyphs.LeftBracket}{Glyphs.LeftDefaultIndicator} Ok {Glyphs.RightDefaultIndicator}{Glyphs.RightBracket}"; int iterations = -1; @@ -1127,7 +1127,7 @@ public void Dialog_Opened_From_Another_Dialog () │ │ │ │ │ │ - │{CM.Glyphs.LeftBracket} Show Sub {CM.Glyphs.RightBracket} {CM.Glyphs.LeftBracket} Close {CM.Glyphs.RightBracket} │ + │{Glyphs.LeftBracket} Show Sub {Glyphs.RightBracket} {Glyphs.LeftBracket} Close {Glyphs.RightBracket} │ └───────────────────────┘"; TestHelpers.AssertDriverContentsWithFrameAre (expected, _output); @@ -1145,7 +1145,7 @@ public void Dialog_Opened_From_Another_Dialog () │ │ │ │ │ │ {btn} │ │ │ └──────────────────┘ │ - │{CM.Glyphs.LeftBracket} Show Sub {CM.Glyphs.RightBracket} {CM.Glyphs.LeftBracket} Close {CM.Glyphs.RightBracket} │ + │{Glyphs.LeftBracket} Show Sub {Glyphs.RightBracket} {Glyphs.LeftBracket} Close {Glyphs.RightBracket} │ └───────────────────────┘", _output ); @@ -1266,7 +1266,7 @@ public void One_Button_Works () var btnText = "ok"; var buttonRow = - $"{CM.Glyphs.VLine} {CM.Glyphs.LeftBracket} {btnText} {CM.Glyphs.RightBracket} {CM.Glyphs.VLine}"; + $"{Glyphs.VLine} {Glyphs.LeftBracket} {btnText} {Glyphs.RightBracket} {Glyphs.VLine}"; int width = buttonRow.Length; d.SetBufferSize (buttonRow.Length, 10); @@ -1326,7 +1326,7 @@ public void Zero_Buttons_Works () var title = "1234"; - var buttonRow = $"{CM.Glyphs.VLine} {CM.Glyphs.VLine}"; + var buttonRow = $"{Glyphs.VLine} {Glyphs.VLine}"; int width = buttonRow.Length; d.SetBufferSize (buttonRow.Length, 3); diff --git a/UnitTests/Dialogs/MessageBoxTests.cs b/UnitTests/Dialogs/MessageBoxTests.cs index 6d7176b039..ff7fd728ac 100644 --- a/UnitTests/Dialogs/MessageBoxTests.cs +++ b/UnitTests/Dialogs/MessageBoxTests.cs @@ -192,7 +192,7 @@ public void Message_With_Spaces_WrapMessage_False () ((FakeDriver)Application.Driver!).SetBufferSize (20, 10); var btn = - $"{CM.Glyphs.LeftBracket}{CM.Glyphs.LeftDefaultIndicator} btn {CM.Glyphs.RightDefaultIndicator}{CM.Glyphs.RightBracket}"; + $"{Glyphs.LeftBracket}{Glyphs.LeftDefaultIndicator} btn {Glyphs.RightDefaultIndicator}{Glyphs.RightBracket}"; // Override CM MessageBox.DefaultButtonAlignment = Alignment.End; @@ -264,7 +264,7 @@ public void Message_With_Spaces_WrapMessage_True () ((FakeDriver)Application.Driver!).SetBufferSize (20, 10); var btn = - $"{CM.Glyphs.LeftBracket}{CM.Glyphs.LeftDefaultIndicator} btn {CM.Glyphs.RightDefaultIndicator}{CM.Glyphs.RightBracket}"; + $"{Glyphs.LeftBracket}{Glyphs.LeftDefaultIndicator} btn {Glyphs.RightDefaultIndicator}{Glyphs.RightBracket}"; // Override CM MessageBox.DefaultButtonAlignment = Alignment.End; diff --git a/UnitTests/Dialogs/WizardTests.cs b/UnitTests/Dialogs/WizardTests.cs index accd381398..66fbfc8f99 100644 --- a/UnitTests/Dialogs/WizardTests.cs +++ b/UnitTests/Dialogs/WizardTests.cs @@ -401,44 +401,44 @@ public void OneStepWizard_Shows () d.SetBufferSize (width, height); // var btnBackText = "Back"; - var btnBack = string.Empty; // $"{CM.Glyphs.LeftBracket} {btnBackText} {CM.Glyphs.RightBracket}"; + var btnBack = string.Empty; // $"{Glyphs.LeftBracket} {btnBackText} {Glyphs.RightBracket}"; var btnNextText = "Finish"; // "Next"; var btnNext = $"{ - CM.Glyphs.LeftBracket + Glyphs.LeftBracket }{ - CM.Glyphs.LeftDefaultIndicator + Glyphs.LeftDefaultIndicator } { btnNextText } { - CM.Glyphs.RightDefaultIndicator + Glyphs.RightDefaultIndicator }{ - CM.Glyphs.RightBracket + Glyphs.RightBracket }"; var topRow = $"{ - CM.Glyphs.ULCornerDbl + Glyphs.ULCornerDbl }╡{ title } - { stepTitle }╞{ - new (CM.Glyphs.HLineDbl.ToString () [0], width - title.Length - stepTitle.Length - 7) + new (Glyphs.HLineDbl.ToString () [0], width - title.Length - stepTitle.Length - 7) }{ - CM.Glyphs.URCornerDbl + Glyphs.URCornerDbl }"; - var row2 = $"{CM.Glyphs.VLineDbl}{new (' ', width - 2)}{CM.Glyphs.VLineDbl}"; + var row2 = $"{Glyphs.VLineDbl}{new (' ', width - 2)}{Glyphs.VLineDbl}"; string row3 = row2; string row4 = row3; var separatorRow = - $"{CM.Glyphs.VLineDbl}{new (CM.Glyphs.HLine.ToString () [0], width - 2)}{CM.Glyphs.VLineDbl}"; + $"{Glyphs.VLineDbl}{new (Glyphs.HLine.ToString () [0], width - 2)}{Glyphs.VLineDbl}"; var buttonRow = $"{ - CM.Glyphs.VLineDbl + Glyphs.VLineDbl }{ btnBack }{ @@ -446,16 +446,16 @@ public void OneStepWizard_Shows () }{ btnNext }{ - CM.Glyphs.VLineDbl + Glyphs.VLineDbl }"; var bottomRow = $"{ - CM.Glyphs.LLCornerDbl + Glyphs.LLCornerDbl }{ - new (CM.Glyphs.HLineDbl.ToString () [0], width - 2) + new (Glyphs.HLineDbl.ToString () [0], width - 2) }{ - CM.Glyphs.LRCornerDbl + Glyphs.LRCornerDbl }"; var wizard = new Wizard { Title = title, Width = width, Height = height }; @@ -494,45 +494,45 @@ public void Setting_Title_Works () var btnNext = $"{ - CM.Glyphs.LeftBracket + Glyphs.LeftBracket }{ - CM.Glyphs.LeftDefaultIndicator + Glyphs.LeftDefaultIndicator } { btnNextText } { - CM.Glyphs.RightDefaultIndicator + Glyphs.RightDefaultIndicator }{ - CM.Glyphs.RightBracket + Glyphs.RightBracket }"; var topRow = $"{ - CM.Glyphs.ULCornerDbl + Glyphs.ULCornerDbl }╡{ title }{ stepTitle }╞{ - new (CM.Glyphs.HLineDbl.ToString () [0], width - title.Length - stepTitle.Length - 4) + new (Glyphs.HLineDbl.ToString () [0], width - title.Length - stepTitle.Length - 4) }{ - CM.Glyphs.URCornerDbl + Glyphs.URCornerDbl }"; var separatorRow = - $"{CM.Glyphs.VLineDbl}{new (CM.Glyphs.HLine.ToString () [0], width - 2)}{CM.Glyphs.VLineDbl}"; + $"{Glyphs.VLineDbl}{new (Glyphs.HLine.ToString () [0], width - 2)}{Glyphs.VLineDbl}"; // Once this is fixed, revert to commented out line: https://github.com/gui-cs/Terminal.Gui/issues/1791 var buttonRow = - $"{CM.Glyphs.VLineDbl}{new (' ', width - btnNext.Length - 2)}{btnNext}{CM.Glyphs.VLineDbl}"; + $"{Glyphs.VLineDbl}{new (' ', width - btnNext.Length - 2)}{btnNext}{Glyphs.VLineDbl}"; - //var buttonRow = $"{CM.Glyphs.VDLine}{new String (' ', width - btnNext.Length - 2)}{btnNext}{CM.Glyphs.VDLine}"; + //var buttonRow = $"{Glyphs.VDLine}{new String (' ', width - btnNext.Length - 2)}{btnNext}{Glyphs.VDLine}"; var bottomRow = $"{ - CM.Glyphs.LLCornerDbl + Glyphs.LLCornerDbl }{ - new (CM.Glyphs.HLineDbl.ToString () [0], width - 2) + new (Glyphs.HLineDbl.ToString () [0], width - 2) }{ - CM.Glyphs.LRCornerDbl + Glyphs.LRCornerDbl }"; var wizard = new Wizard { Title = title, Width = width, Height = height }; @@ -655,43 +655,43 @@ public void ZeroStepWizard_Shows () d.SetBufferSize (width, height); var btnBackText = "Back"; - var btnBack = $"{CM.Glyphs.LeftBracket} {btnBackText} {CM.Glyphs.RightBracket}"; + var btnBack = $"{Glyphs.LeftBracket} {btnBackText} {Glyphs.RightBracket}"; var btnNextText = "Finish"; var btnNext = $"{ - CM.Glyphs.LeftBracket + Glyphs.LeftBracket }{ - CM.Glyphs.LeftDefaultIndicator + Glyphs.LeftDefaultIndicator } { btnNextText } { - CM.Glyphs.RightDefaultIndicator + Glyphs.RightDefaultIndicator }{ - CM.Glyphs.RightBracket + Glyphs.RightBracket }"; var topRow = $"{ - CM.Glyphs.ULCornerDbl + Glyphs.ULCornerDbl }╡{ title }{ stepTitle }╞{ - new (CM.Glyphs.HLineDbl.ToString () [0], width - title.Length - stepTitle.Length - 4) + new (Glyphs.HLineDbl.ToString () [0], width - title.Length - stepTitle.Length - 4) }{ - CM.Glyphs.URCornerDbl + Glyphs.URCornerDbl }"; - var row2 = $"{CM.Glyphs.VLineDbl}{new (' ', width - 2)}{CM.Glyphs.VLineDbl}"; + var row2 = $"{Glyphs.VLineDbl}{new (' ', width - 2)}{Glyphs.VLineDbl}"; string row3 = row2; var separatorRow = - $"{CM.Glyphs.VLineDbl}{new (CM.Glyphs.HLine.ToString () [0], width - 2)}{CM.Glyphs.VLineDbl}"; + $"{Glyphs.VLineDbl}{new (Glyphs.HLine.ToString () [0], width - 2)}{Glyphs.VLineDbl}"; var buttonRow = $"{ - CM.Glyphs.VLineDbl + Glyphs.VLineDbl }{ btnBack }{ @@ -699,16 +699,16 @@ public void ZeroStepWizard_Shows () }{ btnNext }{ - CM.Glyphs.VLineDbl + Glyphs.VLineDbl }"; var bottomRow = $"{ - CM.Glyphs.LLCornerDbl + Glyphs.LLCornerDbl }{ - new (CM.Glyphs.HLineDbl.ToString () [0], width - 2) + new (Glyphs.HLineDbl.ToString () [0], width - 2) }{ - CM.Glyphs.LRCornerDbl + Glyphs.LRCornerDbl }"; var wizard = new Wizard { Title = title, Width = width, Height = height }; diff --git a/UnitTests/Drawing/GlyphTests.cs b/UnitTests/Drawing/GlyphTests.cs deleted file mode 100644 index c3b1488621..0000000000 --- a/UnitTests/Drawing/GlyphTests.cs +++ /dev/null @@ -1,29 +0,0 @@ -using System.Reflection; -using System.Text; -using System.Text.Json; - -namespace Terminal.Gui.DrawingTests; - -public class GlyphTests -{ - [Fact] - public void Default_GlyphDefinitions_Deserialize () - { - var defs = new GlyphDefinitions (); - - // enumerate all properties in GlyphDefinitions - foreach (PropertyInfo prop in typeof (GlyphDefinitions).GetProperties ()) - { - if (prop.PropertyType == typeof (Rune)) - { - // Act - var rune = (Rune)prop.GetValue (defs); - string json = JsonSerializer.Serialize (rune, ConfigurationManager._serializerOptions); - var deserialized = JsonSerializer.Deserialize (json, ConfigurationManager._serializerOptions); - - // Assert - Assert.Equal (((Rune)prop.GetValue (defs)).Value, deserialized.Value); - } - } - } -} diff --git a/UnitTests/Text/TextFormatterTests.cs b/UnitTests/Text/TextFormatterTests.cs index 5435d02044..986775079d 100644 --- a/UnitTests/Text/TextFormatterTests.cs +++ b/UnitTests/Text/TextFormatterTests.cs @@ -235,7 +235,7 @@ public void ClipAndJustify_Valid_Right (string text, string justifiedText, int m } public static IEnumerable CMGlyphs => - new List { new object [] { $"{CM.Glyphs.LeftBracket} Say Hello 你 {CM.Glyphs.RightBracket}", 16, 15 } }; + new List { new object [] { $"{Glyphs.LeftBracket} Say Hello 你 {Glyphs.RightBracket}", 16, 15 } }; [SetupFakeDriver] [Theory] diff --git a/UnitTests/View/Layout/Pos.AnchorEndTests.cs b/UnitTests/View/Layout/Pos.AnchorEndTests.cs index 9359dbff4d..f69faca9f7 100644 --- a/UnitTests/View/Layout/Pos.AnchorEndTests.cs +++ b/UnitTests/View/Layout/Pos.AnchorEndTests.cs @@ -180,7 +180,7 @@ public void PosAnchorEnd_View_And_Button () // Override CM Button.DefaultShadow = ShadowStyle.None; - var b = $"{CM.Glyphs.LeftBracket} Ok {CM.Glyphs.RightBracket}"; + var b = $"{Glyphs.LeftBracket} Ok {Glyphs.RightBracket}"; var frame = new FrameView { Width = 18, Height = 3 }; Assert.Equal (16, frame.Viewport.Width); diff --git a/UnitTests/Views/ButtonTests.cs b/UnitTests/Views/ButtonTests.cs index cf663d887a..dc7dcb5ce9 100644 --- a/UnitTests/Views/ButtonTests.cs +++ b/UnitTests/Views/ButtonTests.cs @@ -15,7 +15,7 @@ public void Text_Mirrors_Title () Assert.Equal ("Hello", view.TitleTextFormatter.Text); Assert.Equal ("Hello", view.Text); - Assert.Equal ($"{CM.Glyphs.LeftBracket} Hello {CM.Glyphs.RightBracket}", view.TextFormatter.Text); + Assert.Equal ($"{Glyphs.LeftBracket} Hello {Glyphs.RightBracket}", view.TextFormatter.Text); view.Dispose (); } @@ -25,7 +25,7 @@ public void Title_Mirrors_Text () var view = new Button (); view.Text = "Hello"; Assert.Equal ("Hello", view.Text); - Assert.Equal ($"{CM.Glyphs.LeftBracket} Hello {CM.Glyphs.RightBracket}", view.TextFormatter.Text); + Assert.Equal ($"{Glyphs.LeftBracket} Hello {Glyphs.RightBracket}", view.TextFormatter.Text); Assert.Equal ("Hello", view.Title); Assert.Equal ("Hello", view.TitleTextFormatter.Text); @@ -158,14 +158,14 @@ public void Constructors_Defaults () btn.EndInit (); btn.SetRelativeLayout (new (100, 100)); - Assert.Equal ($"{CM.Glyphs.LeftBracket} {CM.Glyphs.RightBracket}", btn.TextFormatter.Text); + Assert.Equal ($"{Glyphs.LeftBracket} {Glyphs.RightBracket}", btn.TextFormatter.Text); Assert.False (btn.IsDefault); Assert.Equal (Alignment.Center, btn.TextAlignment); Assert.Equal ('_', btn.HotKeySpecifier.Value); Assert.True (btn.CanFocus); Assert.Equal (new (0, 0, 4, 1), btn.Viewport); Assert.Equal (new (0, 0, 4, 1), btn.Frame); - Assert.Equal ($"{CM.Glyphs.LeftBracket} {CM.Glyphs.RightBracket}", btn.TextFormatter.Text); + Assert.Equal ($"{Glyphs.LeftBracket} {Glyphs.RightBracket}", btn.TextFormatter.Text); Assert.False (btn.IsDefault); Assert.Equal (Alignment.Center, btn.TextAlignment); Assert.Equal ('_', btn.HotKeySpecifier.Value); @@ -179,7 +179,7 @@ public void Constructors_Defaults () btn.Draw (); var expected = @$" -{CM.Glyphs.LeftBracket} {CM.Glyphs.RightBracket} +{Glyphs.LeftBracket} {Glyphs.RightBracket} "; TestHelpers.AssertDriverContentsWithFrameAre (expected, output); btn.Dispose (); @@ -197,7 +197,7 @@ public void Constructors_Defaults () Assert.Equal ("_Test", btn.Text); Assert.Equal ( - $"{CM.Glyphs.LeftBracket}{CM.Glyphs.LeftDefaultIndicator} Test {CM.Glyphs.RightDefaultIndicator}{CM.Glyphs.RightBracket}", + $"{Glyphs.LeftBracket}{Glyphs.LeftDefaultIndicator} Test {Glyphs.RightDefaultIndicator}{Glyphs.RightBracket}", btn.TextFormatter.Format () ); Assert.True (btn.IsDefault); @@ -224,7 +224,7 @@ public void Constructors_Defaults () Assert.Equal (Key.A, btn.HotKey); Assert.Equal ( - $"{CM.Glyphs.LeftBracket}{CM.Glyphs.LeftDefaultIndicator} abc {CM.Glyphs.RightDefaultIndicator}{CM.Glyphs.RightBracket}", + $"{Glyphs.LeftBracket}{Glyphs.LeftDefaultIndicator} abc {Glyphs.RightDefaultIndicator}{Glyphs.RightBracket}", btn.TextFormatter.Format () ); Assert.True (btn.IsDefault); @@ -236,7 +236,7 @@ public void Constructors_Defaults () btn.Draw (); expected = @$" - {CM.Glyphs.LeftBracket}{CM.Glyphs.LeftDefaultIndicator} abc {CM.Glyphs.RightDefaultIndicator}{CM.Glyphs.RightBracket} + {Glyphs.LeftBracket}{Glyphs.LeftDefaultIndicator} abc {Glyphs.RightDefaultIndicator}{Glyphs.RightBracket} "; TestHelpers.AssertDriverContentsWithFrameAre (expected, output); @@ -576,9 +576,9 @@ public void Update_Parameterless_Only_On_Or_After_Initialize () Assert.True (btn.IsInitialized); Assert.Equal ("Say Hello 你", btn.Text); - Assert.Equal ($"{CM.Glyphs.LeftBracket} {btn.Text} {CM.Glyphs.RightBracket}", btn.TextFormatter.Text); + Assert.Equal ($"{Glyphs.LeftBracket} {btn.Text} {Glyphs.RightBracket}", btn.TextFormatter.Text); Assert.Equal (new (0, 0, 16, 1), btn.Viewport); - var btnTxt = $"{CM.Glyphs.LeftBracket} {btn.Text} {CM.Glyphs.RightBracket}"; + var btnTxt = $"{Glyphs.LeftBracket} {btn.Text} {Glyphs.RightBracket}"; var expected = @$" ┌────────────────────────────┐ diff --git a/UnitTests/Views/CheckBoxTests.cs b/UnitTests/Views/CheckBoxTests.cs index a64c2e7912..511cf3be4f 100644 --- a/UnitTests/Views/CheckBoxTests.cs +++ b/UnitTests/Views/CheckBoxTests.cs @@ -79,7 +79,7 @@ public void Text_Mirrors_Title () Assert.Equal ("Hello", view.TitleTextFormatter.Text); Assert.Equal ("Hello", view.Text); - Assert.Equal ($"{CM.Glyphs.CheckStateUnChecked} Hello", view.TextFormatter.Text); + Assert.Equal ($"{Glyphs.CheckStateUnChecked} Hello", view.TextFormatter.Text); } [Fact] @@ -88,7 +88,7 @@ public void Title_Mirrors_Text () var view = new CheckBox (); view.Text = "Hello"; Assert.Equal ("Hello", view.Text); - Assert.Equal ($"{CM.Glyphs.CheckStateUnChecked} Hello", view.TextFormatter.Text); + Assert.Equal ($"{Glyphs.CheckStateUnChecked} Hello", view.TextFormatter.Text); Assert.Equal ("Hello", view.Title); Assert.Equal ("Hello", view.TitleTextFormatter.Text); @@ -104,7 +104,7 @@ public void Constructors_Defaults () Assert.Equal (CheckState.UnChecked, ckb.CheckedState); Assert.False (ckb.AllowCheckStateNone); Assert.Equal (string.Empty, ckb.Text); - Assert.Equal ($"{CM.Glyphs.CheckStateUnChecked} ", ckb.TextFormatter.Text); + Assert.Equal ($"{Glyphs.CheckStateUnChecked} ", ckb.TextFormatter.Text); Assert.True (ckb.CanFocus); Assert.Equal (new (0, 0, 2, 1), ckb.Frame); @@ -115,7 +115,7 @@ public void Constructors_Defaults () Assert.Equal (CheckState.Checked, ckb.CheckedState); Assert.False (ckb.AllowCheckStateNone); Assert.Equal ("Test", ckb.Text); - Assert.Equal ($"{CM.Glyphs.CheckStateChecked} Test", ckb.TextFormatter.Text); + Assert.Equal ($"{Glyphs.CheckStateChecked} Test", ckb.TextFormatter.Text); Assert.True (ckb.CanFocus); Assert.Equal (new (0, 0, 6, 1), ckb.Frame); @@ -126,7 +126,7 @@ public void Constructors_Defaults () Assert.Equal (CheckState.UnChecked, ckb.CheckedState); Assert.False (ckb.AllowCheckStateNone); Assert.Equal ("Test", ckb.Text); - Assert.Equal ($"{CM.Glyphs.CheckStateUnChecked} Test", ckb.TextFormatter.Text); + Assert.Equal ($"{Glyphs.CheckStateUnChecked} Test", ckb.TextFormatter.Text); Assert.True (ckb.CanFocus); Assert.Equal (new (1, 2, 6, 1), ckb.Frame); @@ -137,7 +137,7 @@ public void Constructors_Defaults () Assert.Equal (CheckState.Checked, ckb.CheckedState); Assert.False (ckb.AllowCheckStateNone); Assert.Equal ("Test", ckb.Text); - Assert.Equal ($"{CM.Glyphs.CheckStateChecked} Test", ckb.TextFormatter.Text); + Assert.Equal ($"{Glyphs.CheckStateChecked} Test", ckb.TextFormatter.Text); Assert.True (ckb.CanFocus); Assert.Equal (new (3, 4, 6, 1), ckb.Frame); } @@ -359,7 +359,7 @@ public void TextAlignment_Centered () var expected = @$" ┌┤Test Demo 你├──────────────┐ │ │ -│ {CM.Glyphs.CheckStateUnChecked} Check this out 你 │ +│ {Glyphs.CheckStateUnChecked} Check this out 你 │ │ │ └────────────────────────────┘ "; @@ -373,7 +373,7 @@ public void TextAlignment_Centered () expected = @$" ┌┤Test Demo 你├──────────────┐ │ │ -│ {CM.Glyphs.CheckStateChecked} Check this out 你 │ +│ {Glyphs.CheckStateChecked} Check this out 你 │ │ │ └────────────────────────────┘ "; @@ -420,8 +420,8 @@ public void TextAlignment_Justified () var expected = @$" ┌┤Test Demo 你├──────────────┐ │ │ -│ {CM.Glyphs.CheckStateUnChecked} Check first out 你 │ -│ {CM.Glyphs.CheckStateUnChecked} Check second out 你 │ +│ {Glyphs.CheckStateUnChecked} Check first out 你 │ +│ {Glyphs.CheckStateUnChecked} Check second out 你 │ │ │ └────────────────────────────┘ "; @@ -443,8 +443,8 @@ public void TextAlignment_Justified () expected = @$" ┌┤Test Demo 你├──────────────┐ │ │ -│ {CM.Glyphs.CheckStateChecked} Check first out 你 │ -│ {CM.Glyphs.CheckStateChecked} Check second out 你 │ +│ {Glyphs.CheckStateChecked} Check first out 你 │ +│ {Glyphs.CheckStateChecked} Check second out 你 │ │ │ └────────────────────────────┘ "; @@ -480,7 +480,7 @@ public void TextAlignment_Left () var expected = @$" ┌┤Test Demo 你├──────────────┐ │ │ -│ {CM.Glyphs.CheckStateUnChecked} Check this out 你 │ +│ {Glyphs.CheckStateUnChecked} Check this out 你 │ │ │ └────────────────────────────┘ "; @@ -494,7 +494,7 @@ public void TextAlignment_Left () expected = @$" ┌┤Test Demo 你├──────────────┐ │ │ -│ {CM.Glyphs.CheckStateChecked} Check this out 你 │ +│ {Glyphs.CheckStateChecked} Check this out 你 │ │ │ └────────────────────────────┘ "; @@ -531,7 +531,7 @@ public void TextAlignment_Right () var expected = @$" ┌┤Test Demo 你├──────────────┐ │ │ -│ Check this out 你 {CM.Glyphs.CheckStateUnChecked} │ +│ Check this out 你 {Glyphs.CheckStateUnChecked} │ │ │ └────────────────────────────┘ "; @@ -545,7 +545,7 @@ public void TextAlignment_Right () expected = @$" ┌┤Test Demo 你├──────────────┐ │ │ -│ Check this out 你 {CM.Glyphs.CheckStateChecked} │ +│ Check this out 你 {Glyphs.CheckStateChecked} │ │ │ └────────────────────────────┘ "; diff --git a/UnitTests/Views/GraphViewTests.cs b/UnitTests/Views/GraphViewTests.cs index c44f26ea33..4a7fe4a066 100644 --- a/UnitTests/Views/GraphViewTests.cs +++ b/UnitTests/Views/GraphViewTests.cs @@ -1118,7 +1118,7 @@ public void TestTextAnnotation_EmptyText (string whitespace) var expected = @$" │ - ┤ {CM.Glyphs.Dot} + ┤ {Glyphs.Dot} ┤ 0┼┬┬┬┬┬┬┬┬ 0 5"; @@ -1593,9 +1593,9 @@ public void XAxisLabels_With_MarginLeft () │ 2┤ │ - 1┤{CM.Glyphs.Dot} + 1┤{Glyphs.Dot} │ - 0┼┬┬┬┬{CM.Glyphs.Dot}┬ + 0┼┬┬┬┬{Glyphs.Dot}┬ 0 5 "; @@ -1630,9 +1630,9 @@ public void YAxisLabels_With_MarginBottom () var expected = @$" │ -1┤{CM.Glyphs.Dot} +1┤{Glyphs.Dot} │ -0┼┬┬┬┬{CM.Glyphs.Dot}┬┬┬ +0┼┬┬┬┬{Glyphs.Dot}┬┬┬ 0 5 "; diff --git a/UnitTests/Views/MenuBarTests.cs b/UnitTests/Views/MenuBarTests.cs index 34fac896e8..133f0175fa 100644 --- a/UnitTests/Views/MenuBarTests.cs +++ b/UnitTests/Views/MenuBarTests.cs @@ -107,7 +107,7 @@ public void AllowNullChecked_Get_Set () @$" Nullable Checked ┌──────────────────────┐ -│ {CM.Glyphs.CheckStateNone} Check this out 你 │ +│ {Glyphs.CheckStateNone} Check this out 你 │ └──────────────────────┘", output ); @@ -3771,11 +3771,11 @@ public class ExpectedMenuBar : MenuBar public string ExpectedBottomRow (int i) { - return $"{CM.Glyphs.LLCorner}{new (CM.Glyphs.HLine.ToString () [0], Menus [i].Children [0].TitleLength + 3)}{CM.Glyphs.LRCorner} \n"; + return $"{Glyphs.LLCorner}{new (Glyphs.HLine.ToString () [0], Menus [i].Children [0].TitleLength + 3)}{Glyphs.LRCorner} \n"; } // The 3 spaces at end are a result of Menu.cs line 1062 where `pos` is calculated (` + spacesAfterTitle`) - public string ExpectedMenuItemRow (int i) { return $"{CM.Glyphs.VLine} {Menus [i].Children [0].Title} {CM.Glyphs.VLine} \n"; } + public string ExpectedMenuItemRow (int i) { return $"{Glyphs.VLine} {Menus [i].Children [0].Title} {Glyphs.VLine} \n"; } // The full expected string for an open sub menu public string ExpectedSubMenuOpen (int i) @@ -3800,7 +3800,7 @@ public string ExpectedSubMenuOpen (int i) // 1 space before the Title and 2 spaces after the Title/Check/Help public string ExpectedTopRow (int i) { - return $"{CM.Glyphs.ULCorner}{new (CM.Glyphs.HLine.ToString () [0], Menus [i].Children [0].TitleLength + 3)}{CM.Glyphs.URCorner} \n"; + return $"{Glyphs.ULCorner}{new (Glyphs.HLine.ToString () [0], Menus [i].Children [0].TitleLength + 3)}{Glyphs.URCorner} \n"; } // Each MenuBar title has a 1 space pad on each side diff --git a/UnitTests/Views/ProgressBarTests.cs b/UnitTests/Views/ProgressBarTests.cs index 927085f742..d5c163a76b 100644 --- a/UnitTests/Views/ProgressBarTests.cs +++ b/UnitTests/Views/ProgressBarTests.cs @@ -18,7 +18,7 @@ public void Default_Constructor () Assert.Equal (1, pb.Frame.Height); Assert.Equal (ProgressBarStyle.Blocks, pb.ProgressBarStyle); Assert.Equal (ProgressBarFormat.Simple, pb.ProgressBarFormat); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, pb.SegmentCharacter); + Assert.Equal (Glyphs.BlocksMeterSegment, pb.SegmentCharacter); } [Fact] @@ -41,7 +41,7 @@ public void Fraction_Redraw () if (i == 0) { - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 0].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 0].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 1].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 2].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 3].Rune); @@ -50,8 +50,8 @@ public void Fraction_Redraw () } else if (i == 1) { - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 0].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 1].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 0].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 1].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 2].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 3].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 4].Rune); @@ -59,38 +59,38 @@ public void Fraction_Redraw () } else if (i == 2) { - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 0].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 1].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 2].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 0].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 1].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 2].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 3].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 4].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 5].Rune); } else if (i == 3) { - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 0].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 1].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 2].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 3].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 0].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 1].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 2].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 3].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 4].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 5].Rune); } else if (i == 4) { - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 0].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 1].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 2].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 3].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 4].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 0].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 1].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 2].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 3].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 4].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 5].Rune); } else if (i == 5) { - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 0].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 1].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 2].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 3].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 4].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 0].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 1].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 2].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 3].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 4].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 5].Rune); } } @@ -148,16 +148,16 @@ public void ProgressBarStyle_Setter () var pb = new ProgressBar (); pb.ProgressBarStyle = ProgressBarStyle.Blocks; - Assert.Equal (CM.Glyphs.BlocksMeterSegment, pb.SegmentCharacter); + Assert.Equal (Glyphs.BlocksMeterSegment, pb.SegmentCharacter); pb.ProgressBarStyle = ProgressBarStyle.Continuous; - Assert.Equal (CM.Glyphs.ContinuousMeterSegment, pb.SegmentCharacter); + Assert.Equal (Glyphs.ContinuousMeterSegment, pb.SegmentCharacter); pb.ProgressBarStyle = ProgressBarStyle.MarqueeBlocks; - Assert.Equal (CM.Glyphs.BlocksMeterSegment, pb.SegmentCharacter); + Assert.Equal (Glyphs.BlocksMeterSegment, pb.SegmentCharacter); pb.ProgressBarStyle = ProgressBarStyle.MarqueeContinuous; - Assert.Equal (CM.Glyphs.ContinuousMeterSegment, pb.SegmentCharacter); + Assert.Equal (Glyphs.ContinuousMeterSegment, pb.SegmentCharacter); } [Fact] @@ -183,7 +183,7 @@ public void Pulse_Redraw_BidirectionalMarquee_False () if (i == 0) { - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 0].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 0].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 1].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 2].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 3].Rune); @@ -201,8 +201,8 @@ public void Pulse_Redraw_BidirectionalMarquee_False () } else if (i == 1) { - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 0].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 1].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 0].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 1].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 2].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 3].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 4].Rune); @@ -219,9 +219,9 @@ public void Pulse_Redraw_BidirectionalMarquee_False () } else if (i == 2) { - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 0].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 1].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 2].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 0].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 1].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 2].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 3].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 4].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 5].Rune); @@ -237,10 +237,10 @@ public void Pulse_Redraw_BidirectionalMarquee_False () } else if (i == 3) { - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 0].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 1].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 2].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 3].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 0].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 1].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 2].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 3].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 4].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 5].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 6].Rune); @@ -255,11 +255,11 @@ public void Pulse_Redraw_BidirectionalMarquee_False () } else if (i == 4) { - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 0].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 1].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 2].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 3].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 4].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 0].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 1].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 2].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 3].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 4].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 5].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 6].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 7].Rune); @@ -274,11 +274,11 @@ public void Pulse_Redraw_BidirectionalMarquee_False () else if (i == 5) { Assert.Equal ((Rune)' ', driver.Contents [0, 0].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 1].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 2].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 3].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 4].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 5].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 1].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 2].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 3].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 4].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 5].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 6].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 7].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 8].Rune); @@ -293,11 +293,11 @@ public void Pulse_Redraw_BidirectionalMarquee_False () { Assert.Equal ((Rune)' ', driver.Contents [0, 0].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 1].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 2].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 3].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 4].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 5].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 6].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 2].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 3].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 4].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 5].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 6].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 7].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 8].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 9].Rune); @@ -312,11 +312,11 @@ public void Pulse_Redraw_BidirectionalMarquee_False () Assert.Equal ((Rune)' ', driver.Contents [0, 0].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 1].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 2].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 3].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 4].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 5].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 6].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 7].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 3].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 4].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 5].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 6].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 7].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 8].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 9].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 10].Rune); @@ -331,11 +331,11 @@ public void Pulse_Redraw_BidirectionalMarquee_False () Assert.Equal ((Rune)' ', driver.Contents [0, 1].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 2].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 3].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 4].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 5].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 6].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 7].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 8].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 4].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 5].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 6].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 7].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 8].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 9].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 10].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 11].Rune); @@ -350,11 +350,11 @@ public void Pulse_Redraw_BidirectionalMarquee_False () Assert.Equal ((Rune)' ', driver.Contents [0, 2].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 3].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 4].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 5].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 6].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 7].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 8].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 9].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 5].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 6].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 7].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 8].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 9].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 10].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 11].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 12].Rune); @@ -369,11 +369,11 @@ public void Pulse_Redraw_BidirectionalMarquee_False () Assert.Equal ((Rune)' ', driver.Contents [0, 3].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 4].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 5].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 6].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 7].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 8].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 9].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 10].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 6].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 7].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 8].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 9].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 10].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 11].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 12].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 13].Rune); @@ -388,11 +388,11 @@ public void Pulse_Redraw_BidirectionalMarquee_False () Assert.Equal ((Rune)' ', driver.Contents [0, 4].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 5].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 6].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 7].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 8].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 9].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 10].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 11].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 7].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 8].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 9].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 10].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 11].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 12].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 13].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 14].Rune); @@ -407,11 +407,11 @@ public void Pulse_Redraw_BidirectionalMarquee_False () Assert.Equal ((Rune)' ', driver.Contents [0, 5].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 6].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 7].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 8].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 9].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 10].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 11].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 12].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 8].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 9].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 10].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 11].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 12].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 13].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 14].Rune); } @@ -426,11 +426,11 @@ public void Pulse_Redraw_BidirectionalMarquee_False () Assert.Equal ((Rune)' ', driver.Contents [0, 6].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 7].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 8].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 9].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 10].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 11].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 12].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 13].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 9].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 10].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 11].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 12].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 13].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 14].Rune); } else if (i == 14) @@ -445,11 +445,11 @@ public void Pulse_Redraw_BidirectionalMarquee_False () Assert.Equal ((Rune)' ', driver.Contents [0, 7].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 8].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 9].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 10].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 11].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 12].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 13].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 14].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 10].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 11].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 12].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 13].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 14].Rune); } else if (i == 15) { @@ -464,10 +464,10 @@ public void Pulse_Redraw_BidirectionalMarquee_False () Assert.Equal ((Rune)' ', driver.Contents [0, 8].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 9].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 10].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 11].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 12].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 13].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 14].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 11].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 12].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 13].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 14].Rune); } else if (i == 16) { @@ -483,9 +483,9 @@ public void Pulse_Redraw_BidirectionalMarquee_False () Assert.Equal ((Rune)' ', driver.Contents [0, 9].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 10].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 11].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 12].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 13].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 14].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 12].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 13].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 14].Rune); } else if (i == 17) { @@ -502,8 +502,8 @@ public void Pulse_Redraw_BidirectionalMarquee_False () Assert.Equal ((Rune)' ', driver.Contents [0, 10].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 11].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 12].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 13].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 14].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 13].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 14].Rune); } else if (i == 18) { @@ -521,11 +521,11 @@ public void Pulse_Redraw_BidirectionalMarquee_False () Assert.Equal ((Rune)' ', driver.Contents [0, 11].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 12].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 13].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 14].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 14].Rune); } else if (i == 19) { - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 0].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 0].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 1].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 2].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 3].Rune); @@ -543,8 +543,8 @@ public void Pulse_Redraw_BidirectionalMarquee_False () } else if (i == 20) { - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 0].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 1].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 0].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 1].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 2].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 3].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 4].Rune); @@ -561,9 +561,9 @@ public void Pulse_Redraw_BidirectionalMarquee_False () } else if (i == 21) { - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 0].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 1].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 2].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 0].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 1].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 2].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 3].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 4].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 5].Rune); @@ -579,10 +579,10 @@ public void Pulse_Redraw_BidirectionalMarquee_False () } else if (i == 22) { - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 0].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 1].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 2].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 3].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 0].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 1].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 2].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 3].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 4].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 5].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 6].Rune); @@ -597,11 +597,11 @@ public void Pulse_Redraw_BidirectionalMarquee_False () } else if (i == 23) { - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 0].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 1].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 2].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 3].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 4].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 0].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 1].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 2].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 3].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 4].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 5].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 6].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 7].Rune); @@ -616,11 +616,11 @@ public void Pulse_Redraw_BidirectionalMarquee_False () else if (i == 24) { Assert.Equal ((Rune)' ', driver.Contents [0, 0].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 1].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 2].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 3].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 4].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 5].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 1].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 2].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 3].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 4].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 5].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 6].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 7].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 8].Rune); @@ -635,11 +635,11 @@ public void Pulse_Redraw_BidirectionalMarquee_False () { Assert.Equal ((Rune)' ', driver.Contents [0, 0].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 1].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 2].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 3].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 4].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 5].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 6].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 2].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 3].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 4].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 5].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 6].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 7].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 8].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 9].Rune); @@ -654,11 +654,11 @@ public void Pulse_Redraw_BidirectionalMarquee_False () Assert.Equal ((Rune)' ', driver.Contents [0, 0].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 1].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 2].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 3].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 4].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 5].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 6].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 7].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 3].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 4].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 5].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 6].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 7].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 8].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 9].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 10].Rune); @@ -673,11 +673,11 @@ public void Pulse_Redraw_BidirectionalMarquee_False () Assert.Equal ((Rune)' ', driver.Contents [0, 1].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 2].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 3].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 4].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 5].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 6].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 7].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 8].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 4].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 5].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 6].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 7].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 8].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 9].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 10].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 11].Rune); @@ -692,11 +692,11 @@ public void Pulse_Redraw_BidirectionalMarquee_False () Assert.Equal ((Rune)' ', driver.Contents [0, 2].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 3].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 4].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 5].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 6].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 7].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 8].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 9].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 5].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 6].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 7].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 8].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 9].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 10].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 11].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 12].Rune); @@ -711,11 +711,11 @@ public void Pulse_Redraw_BidirectionalMarquee_False () Assert.Equal ((Rune)' ', driver.Contents [0, 3].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 4].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 5].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 6].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 7].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 8].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 9].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 10].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 6].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 7].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 8].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 9].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 10].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 11].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 12].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 13].Rune); @@ -730,11 +730,11 @@ public void Pulse_Redraw_BidirectionalMarquee_False () Assert.Equal ((Rune)' ', driver.Contents [0, 4].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 5].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 6].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 7].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 8].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 9].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 10].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 11].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 7].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 8].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 9].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 10].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 11].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 12].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 13].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 14].Rune); @@ -749,11 +749,11 @@ public void Pulse_Redraw_BidirectionalMarquee_False () Assert.Equal ((Rune)' ', driver.Contents [0, 5].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 6].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 7].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 8].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 9].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 10].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 11].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 12].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 8].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 9].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 10].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 11].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 12].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 13].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 14].Rune); } @@ -768,11 +768,11 @@ public void Pulse_Redraw_BidirectionalMarquee_False () Assert.Equal ((Rune)' ', driver.Contents [0, 6].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 7].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 8].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 9].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 10].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 11].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 12].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 13].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 9].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 10].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 11].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 12].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 13].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 14].Rune); } else if (i == 33) @@ -787,11 +787,11 @@ public void Pulse_Redraw_BidirectionalMarquee_False () Assert.Equal ((Rune)' ', driver.Contents [0, 7].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 8].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 9].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 10].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 11].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 12].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 13].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 14].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 10].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 11].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 12].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 13].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 14].Rune); } else if (i == 34) { @@ -806,10 +806,10 @@ public void Pulse_Redraw_BidirectionalMarquee_False () Assert.Equal ((Rune)' ', driver.Contents [0, 8].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 9].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 10].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 11].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 12].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 13].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 14].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 11].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 12].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 13].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 14].Rune); } else if (i == 35) { @@ -825,9 +825,9 @@ public void Pulse_Redraw_BidirectionalMarquee_False () Assert.Equal ((Rune)' ', driver.Contents [0, 9].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 10].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 11].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 12].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 13].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 14].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 12].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 13].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 14].Rune); } else if (i == 36) { @@ -844,8 +844,8 @@ public void Pulse_Redraw_BidirectionalMarquee_False () Assert.Equal ((Rune)' ', driver.Contents [0, 10].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 11].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 12].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 13].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 14].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 13].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 14].Rune); } else if (i == 37) { @@ -863,7 +863,7 @@ public void Pulse_Redraw_BidirectionalMarquee_False () Assert.Equal ((Rune)' ', driver.Contents [0, 11].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 12].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 13].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 14].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 14].Rune); } } } @@ -888,7 +888,7 @@ public void Pulse_Redraw_BidirectionalMarquee_True_Default () if (i == 0) { - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 0].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 0].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 1].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 2].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 3].Rune); @@ -906,8 +906,8 @@ public void Pulse_Redraw_BidirectionalMarquee_True_Default () } else if (i == 1) { - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 0].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 1].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 0].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 1].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 2].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 3].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 4].Rune); @@ -924,9 +924,9 @@ public void Pulse_Redraw_BidirectionalMarquee_True_Default () } else if (i == 2) { - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 0].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 1].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 2].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 0].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 1].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 2].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 3].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 4].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 5].Rune); @@ -942,10 +942,10 @@ public void Pulse_Redraw_BidirectionalMarquee_True_Default () } else if (i == 3) { - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 0].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 1].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 2].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 3].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 0].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 1].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 2].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 3].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 4].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 5].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 6].Rune); @@ -960,11 +960,11 @@ public void Pulse_Redraw_BidirectionalMarquee_True_Default () } else if (i == 4) { - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 0].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 1].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 2].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 3].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 4].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 0].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 1].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 2].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 3].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 4].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 5].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 6].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 7].Rune); @@ -979,11 +979,11 @@ public void Pulse_Redraw_BidirectionalMarquee_True_Default () else if (i == 5) { Assert.Equal ((Rune)' ', driver.Contents [0, 0].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 1].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 2].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 3].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 4].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 5].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 1].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 2].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 3].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 4].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 5].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 6].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 7].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 8].Rune); @@ -998,11 +998,11 @@ public void Pulse_Redraw_BidirectionalMarquee_True_Default () { Assert.Equal ((Rune)' ', driver.Contents [0, 0].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 1].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 2].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 3].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 4].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 5].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 6].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 2].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 3].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 4].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 5].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 6].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 7].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 8].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 9].Rune); @@ -1017,11 +1017,11 @@ public void Pulse_Redraw_BidirectionalMarquee_True_Default () Assert.Equal ((Rune)' ', driver.Contents [0, 0].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 1].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 2].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 3].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 4].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 5].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 6].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 7].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 3].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 4].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 5].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 6].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 7].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 8].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 9].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 10].Rune); @@ -1036,11 +1036,11 @@ public void Pulse_Redraw_BidirectionalMarquee_True_Default () Assert.Equal ((Rune)' ', driver.Contents [0, 1].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 2].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 3].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 4].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 5].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 6].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 7].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 8].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 4].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 5].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 6].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 7].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 8].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 9].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 10].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 11].Rune); @@ -1055,11 +1055,11 @@ public void Pulse_Redraw_BidirectionalMarquee_True_Default () Assert.Equal ((Rune)' ', driver.Contents [0, 2].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 3].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 4].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 5].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 6].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 7].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 8].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 9].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 5].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 6].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 7].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 8].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 9].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 10].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 11].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 12].Rune); @@ -1074,11 +1074,11 @@ public void Pulse_Redraw_BidirectionalMarquee_True_Default () Assert.Equal ((Rune)' ', driver.Contents [0, 3].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 4].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 5].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 6].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 7].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 8].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 9].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 10].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 6].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 7].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 8].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 9].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 10].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 11].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 12].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 13].Rune); @@ -1093,11 +1093,11 @@ public void Pulse_Redraw_BidirectionalMarquee_True_Default () Assert.Equal ((Rune)' ', driver.Contents [0, 4].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 5].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 6].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 7].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 8].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 9].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 10].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 11].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 7].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 8].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 9].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 10].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 11].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 12].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 13].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 14].Rune); @@ -1112,11 +1112,11 @@ public void Pulse_Redraw_BidirectionalMarquee_True_Default () Assert.Equal ((Rune)' ', driver.Contents [0, 5].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 6].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 7].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 8].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 9].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 10].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 11].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 12].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 8].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 9].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 10].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 11].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 12].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 13].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 14].Rune); } @@ -1131,11 +1131,11 @@ public void Pulse_Redraw_BidirectionalMarquee_True_Default () Assert.Equal ((Rune)' ', driver.Contents [0, 6].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 7].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 8].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 9].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 10].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 11].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 12].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 13].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 9].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 10].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 11].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 12].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 13].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 14].Rune); } else if (i == 14) @@ -1150,11 +1150,11 @@ public void Pulse_Redraw_BidirectionalMarquee_True_Default () Assert.Equal ((Rune)' ', driver.Contents [0, 7].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 8].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 9].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 10].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 11].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 12].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 13].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 14].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 10].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 11].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 12].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 13].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 14].Rune); } else if (i == 15) { @@ -1169,10 +1169,10 @@ public void Pulse_Redraw_BidirectionalMarquee_True_Default () Assert.Equal ((Rune)' ', driver.Contents [0, 8].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 9].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 10].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 11].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 12].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 13].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 14].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 11].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 12].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 13].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 14].Rune); } else if (i == 16) { @@ -1188,9 +1188,9 @@ public void Pulse_Redraw_BidirectionalMarquee_True_Default () Assert.Equal ((Rune)' ', driver.Contents [0, 9].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 10].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 11].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 12].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 13].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 14].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 12].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 13].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 14].Rune); } else if (i == 17) { @@ -1207,8 +1207,8 @@ public void Pulse_Redraw_BidirectionalMarquee_True_Default () Assert.Equal ((Rune)' ', driver.Contents [0, 10].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 11].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 12].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 13].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 14].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 13].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 14].Rune); } else if (i == 18) { @@ -1226,7 +1226,7 @@ public void Pulse_Redraw_BidirectionalMarquee_True_Default () Assert.Equal ((Rune)' ', driver.Contents [0, 11].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 12].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 13].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 14].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 14].Rune); } else if (i == 19) { @@ -1243,8 +1243,8 @@ public void Pulse_Redraw_BidirectionalMarquee_True_Default () Assert.Equal ((Rune)' ', driver.Contents [0, 10].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 11].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 12].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 13].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 14].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 13].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 14].Rune); } else if (i == 20) { @@ -1260,9 +1260,9 @@ public void Pulse_Redraw_BidirectionalMarquee_True_Default () Assert.Equal ((Rune)' ', driver.Contents [0, 9].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 10].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 11].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 12].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 13].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 14].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 12].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 13].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 14].Rune); } else if (i == 21) { @@ -1277,10 +1277,10 @@ public void Pulse_Redraw_BidirectionalMarquee_True_Default () Assert.Equal ((Rune)' ', driver.Contents [0, 8].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 9].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 10].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 11].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 12].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 13].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 14].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 11].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 12].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 13].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 14].Rune); } else if (i == 22) { @@ -1294,11 +1294,11 @@ public void Pulse_Redraw_BidirectionalMarquee_True_Default () Assert.Equal ((Rune)' ', driver.Contents [0, 7].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 8].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 9].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 10].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 11].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 12].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 13].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 14].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 10].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 11].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 12].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 13].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 14].Rune); } else if (i == 23) { @@ -1311,11 +1311,11 @@ public void Pulse_Redraw_BidirectionalMarquee_True_Default () Assert.Equal ((Rune)' ', driver.Contents [0, 6].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 7].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 8].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 9].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 10].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 11].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 12].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 13].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 9].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 10].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 11].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 12].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 13].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 14].Rune); } else if (i == 24) @@ -1328,11 +1328,11 @@ public void Pulse_Redraw_BidirectionalMarquee_True_Default () Assert.Equal ((Rune)' ', driver.Contents [0, 5].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 6].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 7].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 8].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 9].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 10].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 11].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 12].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 8].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 9].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 10].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 11].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 12].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 13].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 14].Rune); } @@ -1345,11 +1345,11 @@ public void Pulse_Redraw_BidirectionalMarquee_True_Default () Assert.Equal ((Rune)' ', driver.Contents [0, 4].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 5].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 6].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 7].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 8].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 9].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 10].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 11].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 7].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 8].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 9].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 10].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 11].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 12].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 13].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 14].Rune); @@ -1362,11 +1362,11 @@ public void Pulse_Redraw_BidirectionalMarquee_True_Default () Assert.Equal ((Rune)' ', driver.Contents [0, 3].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 4].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 5].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 6].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 7].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 8].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 9].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 10].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 6].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 7].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 8].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 9].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 10].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 11].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 12].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 13].Rune); @@ -1379,11 +1379,11 @@ public void Pulse_Redraw_BidirectionalMarquee_True_Default () Assert.Equal ((Rune)' ', driver.Contents [0, 2].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 3].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 4].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 5].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 6].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 7].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 8].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 9].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 5].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 6].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 7].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 8].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 9].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 10].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 11].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 12].Rune); @@ -1396,11 +1396,11 @@ public void Pulse_Redraw_BidirectionalMarquee_True_Default () Assert.Equal ((Rune)' ', driver.Contents [0, 1].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 2].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 3].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 4].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 5].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 6].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 7].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 8].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 4].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 5].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 6].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 7].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 8].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 9].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 10].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 11].Rune); @@ -1413,11 +1413,11 @@ public void Pulse_Redraw_BidirectionalMarquee_True_Default () Assert.Equal ((Rune)' ', driver.Contents [0, 0].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 1].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 2].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 3].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 4].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 5].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 6].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 7].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 3].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 4].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 5].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 6].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 7].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 8].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 9].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 10].Rune); @@ -1430,11 +1430,11 @@ public void Pulse_Redraw_BidirectionalMarquee_True_Default () { Assert.Equal ((Rune)' ', driver.Contents [0, 0].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 1].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 2].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 3].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 4].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 5].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 6].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 2].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 3].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 4].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 5].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 6].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 7].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 8].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 9].Rune); @@ -1447,11 +1447,11 @@ public void Pulse_Redraw_BidirectionalMarquee_True_Default () else if (i == 31) { Assert.Equal ((Rune)' ', driver.Contents [0, 0].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 1].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 2].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 3].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 4].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 5].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 1].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 2].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 3].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 4].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 5].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 6].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 7].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 8].Rune); @@ -1464,11 +1464,11 @@ public void Pulse_Redraw_BidirectionalMarquee_True_Default () } else if (i == 32) { - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 0].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 1].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 2].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 3].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 4].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 0].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 1].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 2].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 3].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 4].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 5].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 6].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 7].Rune); @@ -1482,10 +1482,10 @@ public void Pulse_Redraw_BidirectionalMarquee_True_Default () } else if (i == 33) { - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 0].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 1].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 2].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 3].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 0].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 1].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 2].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 3].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 4].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 5].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 6].Rune); @@ -1500,9 +1500,9 @@ public void Pulse_Redraw_BidirectionalMarquee_True_Default () } else if (i == 34) { - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 0].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 1].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 2].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 0].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 1].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 2].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 3].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 4].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 5].Rune); @@ -1518,8 +1518,8 @@ public void Pulse_Redraw_BidirectionalMarquee_True_Default () } else if (i == 35) { - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 0].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 1].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 0].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 1].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 2].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 3].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 4].Rune); @@ -1536,7 +1536,7 @@ public void Pulse_Redraw_BidirectionalMarquee_True_Default () } else if (i == 36) { - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 0].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 0].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 1].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 2].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 3].Rune); @@ -1554,8 +1554,8 @@ public void Pulse_Redraw_BidirectionalMarquee_True_Default () } else if (i == 37) { - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 0].Rune); - Assert.Equal (CM.Glyphs.BlocksMeterSegment, driver.Contents [0, 1].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 0].Rune); + Assert.Equal (Glyphs.BlocksMeterSegment, driver.Contents [0, 1].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 2].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 3].Rune); Assert.Equal ((Rune)' ', driver.Contents [0, 4].Rune); diff --git a/UnitTests/Views/RadioGroupTests.cs b/UnitTests/Views/RadioGroupTests.cs index 4276ca71f6..8eb95cb716 100644 --- a/UnitTests/Views/RadioGroupTests.cs +++ b/UnitTests/Views/RadioGroupTests.cs @@ -543,8 +543,8 @@ public void Orientation_Width_Height_Vertical_Horizontal_Space () var expected = @$" ┌────────────────────────────┐ -│{CM.Glyphs.Selected} Test │ -│{CM.Glyphs.UnSelected} New Test 你 │ +│{Glyphs.Selected} Test │ +│{Glyphs.UnSelected} New Test 你 │ │ │ └────────────────────────────┘ "; @@ -564,7 +564,7 @@ public void Orientation_Width_Height_Vertical_Horizontal_Space () expected = @$" ┌────────────────────────────┐ -│{CM.Glyphs.Selected} Test {CM.Glyphs.UnSelected} New Test 你 │ +│{Glyphs.Selected} Test {Glyphs.UnSelected} New Test 你 │ │ │ │ │ └────────────────────────────┘ @@ -585,7 +585,7 @@ public void Orientation_Width_Height_Vertical_Horizontal_Space () expected = @$" ┌────────────────────────────┐ -│{CM.Glyphs.Selected} Test {CM.Glyphs.UnSelected} New Test 你 │ +│{Glyphs.Selected} Test {Glyphs.UnSelected} New Test 你 │ │ │ │ │ └────────────────────────────┘ diff --git a/UnitTests/Views/TreeTableSourceTests.cs b/UnitTests/Views/TreeTableSourceTests.cs index bf8945f610..d235690284 100644 --- a/UnitTests/Views/TreeTableSourceTests.cs +++ b/UnitTests/Views/TreeTableSourceTests.cs @@ -13,16 +13,16 @@ public TreeTableSourceTests (ITestOutputHelper output) { _output = output; - _origChecked = ConfigurationManager.Glyphs.CheckStateChecked; - _origUnchecked = ConfigurationManager.Glyphs.CheckStateUnChecked; - ConfigurationManager.Glyphs.CheckStateChecked = new Rune ('☑'); - ConfigurationManager.Glyphs.CheckStateUnChecked = new Rune ('☐'); + _origChecked = Glyphs.CheckStateChecked; + _origUnchecked = Glyphs.CheckStateUnChecked; + Glyphs.CheckStateChecked = new Rune ('☑'); + Glyphs.CheckStateUnChecked = new Rune ('☐'); } public void Dispose () { - ConfigurationManager.Glyphs.CheckStateChecked = _origChecked; - ConfigurationManager.Glyphs.CheckStateUnChecked = _origUnchecked; + Glyphs.CheckStateChecked = _origChecked; + Glyphs.CheckStateUnChecked = _origUnchecked; } [Fact] From aff7e2c6d58bda2ca723ca134a23c0ab075c125e Mon Sep 17 00:00:00 2001 From: Tig Date: Thu, 27 Feb 2025 08:09:36 -0700 Subject: [PATCH 2/2] Fixed nav (#3926) --- Terminal.Gui/Views/Wizard/Wizard.cs | 89 +++++++++++++------------ Terminal.Gui/Views/Wizard/WizardStep.cs | 29 ++------ UICatalog/Scenarios/Wizards.cs | 4 +- 3 files changed, 54 insertions(+), 68 deletions(-) diff --git a/Terminal.Gui/Views/Wizard/Wizard.cs b/Terminal.Gui/Views/Wizard/Wizard.cs index 254aece7a2..2155c7cc14 100644 --- a/Terminal.Gui/Views/Wizard/Wizard.cs +++ b/Terminal.Gui/Views/Wizard/Wizard.cs @@ -1,4 +1,5 @@ -using Terminal.Gui.Resources; +#nullable enable +using Terminal.Gui.Resources; namespace Terminal.Gui; @@ -52,7 +53,7 @@ namespace Terminal.Gui; public class Wizard : Dialog { private readonly LinkedList _steps = new (); - private WizardStep _currentStep; + private WizardStep? _currentStep; private bool _finishedPressed; private string _wizardTitle = string.Empty; @@ -81,12 +82,12 @@ public Wizard () //// Add a horiz separator var separator = new LineView (Orientation.Horizontal) { Y = Pos.Top (BackButton) - 1 }; - Add (separator); + base.Add (separator); AddButton (BackButton); AddButton (NextFinishButton); - BackButton.Accepting += BackBtn_Clicked; - NextFinishButton.Accepting += NextfinishBtn_Clicked; + BackButton.Accepting += BackBtn_Accepting; + NextFinishButton.Accepting += NextFinishBtn_Accepting; Loaded += Wizard_Loaded; Closing += Wizard_Closing; @@ -103,7 +104,7 @@ public Wizard () public Button BackButton { get; } /// Gets or sets the currently active . - public WizardStep CurrentStep + public WizardStep? CurrentStep { get => _currentStep; set => GoToStep (value); @@ -197,7 +198,7 @@ public void AddStep (WizardStep newStep) /// is true) Wizard from closing, cancel the event by setting /// to true before returning from the event handler. /// - public event EventHandler Cancelled; + public event EventHandler? Cancelled; /// /// Raised when the Next/Finish button in the is clicked. The Next/Finish button is always @@ -205,15 +206,15 @@ public void AddStep (WizardStep newStep) /// raised if the is the last Step in the Wizard flow (otherwise the /// event is raised). /// - public event EventHandler Finished; + public event EventHandler? Finished; /// Returns the first enabled step in the Wizard /// The last enabled step - public WizardStep GetFirstStep () { return _steps.FirstOrDefault (s => s.Enabled); } + public WizardStep? GetFirstStep () { return _steps.FirstOrDefault (s => s.Enabled); } /// Returns the last enabled step in the Wizard /// The last enabled step - public WizardStep GetLastStep () { return _steps.LastOrDefault (s => s.Enabled); } + public WizardStep? GetLastStep () { return _steps.LastOrDefault (s => s.Enabled); } /// /// Returns the next enabled after the current step. Takes into account steps which are @@ -223,9 +224,9 @@ public void AddStep (WizardStep newStep) /// The next step after the current step, if there is one; otherwise returns null, which indicates either /// there are no enabled steps or the current step is the last enabled step. /// - public WizardStep GetNextStep () + public WizardStep? GetNextStep () { - LinkedListNode step = null; + LinkedListNode? step = null; if (CurrentStep is null) { @@ -265,9 +266,9 @@ public WizardStep GetNextStep () /// The first step ahead of the current step, if there is one; otherwise returns null, which indicates /// either there are no enabled steps or the current step is the first enabled step. /// - public WizardStep GetPreviousStep () + public WizardStep? GetPreviousStep () { - LinkedListNode step = null; + LinkedListNode? step = null; if (CurrentStep is null) { @@ -303,36 +304,42 @@ public WizardStep GetPreviousStep () /// Causes the wizard to move to the previous enabled step (or first step if is not set). /// If there is no previous step, does nothing. /// - public void GoBack () + /// if the transition to the step succeeded. if the step was not found or the operation was cancelled. + public bool GoBack () { - WizardStep previous = GetPreviousStep (); + WizardStep? previous = GetPreviousStep (); if (previous is { }) { - GoToStep (previous); + return GoToStep (previous); } + + return false; } /// /// Causes the wizard to move to the next enabled step (or last step if is not set). If /// there is no previous step, does nothing. /// - public void GoNext () + /// if the transition to the step succeeded. if the step was not found or the operation was cancelled. + public bool GoNext () { - WizardStep nextStep = GetNextStep (); + WizardStep? nextStep = GetNextStep (); if (nextStep is { }) { - GoToStep (nextStep); + return GoToStep (nextStep); } + + return false; } /// Changes to the specified . /// The step to go to. - /// True if the transition to the step succeeded. False if the step was not found or the operation was cancelled. - public bool GoToStep (WizardStep newStep) + /// if the transition to the step succeeded. if the step was not found or the operation was cancelled. + public bool GoToStep (WizardStep? newStep) { - if (OnStepChanging (_currentStep, newStep) || (newStep is { } && !newStep.Enabled)) + if (OnStepChanging (_currentStep, newStep) || newStep is { Enabled: false }) { return false; } @@ -344,20 +351,17 @@ public bool GoToStep (WizardStep newStep) step.ShowHide (); } - WizardStep oldStep = _currentStep; + WizardStep? oldStep = _currentStep; _currentStep = newStep; UpdateButtonsAndTitle (); // Set focus on the contentview - if (newStep is { }) - { - newStep.Subviews.ToArray () [0].SetFocus (); - } + newStep?.Subviews.ToArray () [0].SetFocus (); if (OnStepChanged (oldStep, _currentStep)) { - // For correctness we do this, but it's meaningless because there's nothing to cancel + // For correctness, we do this, but it's meaningless because there's nothing to cancel return false; } @@ -368,7 +372,7 @@ public bool GoToStep (WizardStep newStep) /// Raised when the Back button in the is clicked. The Back button is always the first button /// in the array of Buttons passed to the constructor, if any. /// - public event EventHandler MovingBack; + public event EventHandler? MovingBack; /// /// Raised when the Next/Finish button in the is clicked (or the user presses Enter). The @@ -376,7 +380,7 @@ public bool GoToStep (WizardStep newStep) /// constructor, if any. This event is only raised if the is the last Step in the Wizard flow /// (otherwise the event is raised). /// - public event EventHandler MovingNext; + public event EventHandler? MovingNext; /// /// is derived from and Dialog causes Esc to call @@ -410,7 +414,7 @@ protected override bool OnKeyDownNotHandled (Key key) /// The step the Wizard changed from /// The step the Wizard has changed to /// True if the change is to be cancelled. - public virtual bool OnStepChanged (WizardStep oldStep, WizardStep newStep) + public virtual bool OnStepChanged (WizardStep? oldStep, WizardStep? newStep) { var args = new StepChangeEventArgs (oldStep, newStep); StepChanged?.Invoke (this, args); @@ -425,7 +429,7 @@ public virtual bool OnStepChanged (WizardStep oldStep, WizardStep newStep) /// The step the Wizard is about to change from /// The step the Wizard is about to change to /// True if the change is to be cancelled. - public virtual bool OnStepChanging (WizardStep oldStep, WizardStep newStep) + public virtual bool OnStepChanging (WizardStep? oldStep, WizardStep? newStep) { var args = new StepChangeEventArgs (oldStep, newStep); StepChanging?.Invoke (this, args); @@ -434,26 +438,26 @@ public virtual bool OnStepChanging (WizardStep oldStep, WizardStep newStep) } /// This event is raised after the has changed the . - public event EventHandler StepChanged; + public event EventHandler? StepChanged; /// /// This event is raised when the current ) is about to change. Use /// to abort the transition. /// - public event EventHandler StepChanging; + public event EventHandler? StepChanging; - private void BackBtn_Clicked (object sender, EventArgs e) + private void BackBtn_Accepting (object? sender, CommandEventArgs e) { var args = new WizardButtonEventArgs (); MovingBack?.Invoke (this, args); if (!args.Cancel) { - GoBack (); + e.Cancel = GoBack (); } } - private void NextfinishBtn_Clicked (object sender, EventArgs e) + private void NextFinishBtn_Accepting (object? sender, CommandEventArgs e) { if (CurrentStep == GetLastStep ()) { @@ -467,6 +471,7 @@ private void NextfinishBtn_Clicked (object sender, EventArgs e) if (IsCurrentTop) { Application.RequestStop (this); + e.Cancel = true; } // Wizard was created as a non-modal (just added to another View). @@ -480,7 +485,7 @@ private void NextfinishBtn_Clicked (object sender, EventArgs e) if (!args.Cancel) { - GoNext (); + e.Cancel = GoNext (); } } } @@ -548,7 +553,7 @@ private void UpdateButtonsAndTitle () SetNeedsLayout (); } - private void Wizard_Closing (object sender, ToplevelClosingEventArgs obj) + private void Wizard_Closing (object? sender, ToplevelClosingEventArgs obj) { if (!_finishedPressed) { @@ -557,14 +562,14 @@ private void Wizard_Closing (object sender, ToplevelClosingEventArgs obj) } } - private void Wizard_Loaded (object sender, EventArgs args) + private void Wizard_Loaded (object? sender, EventArgs args) { CurrentStep = GetFirstStep (); // gets the first step if CurrentStep == null } - private void Wizard_TitleChanged (object sender, EventArgs e) + private void Wizard_TitleChanged (object? sender, EventArgs e) { if (string.IsNullOrEmpty (_wizardTitle)) { diff --git a/Terminal.Gui/Views/Wizard/WizardStep.cs b/Terminal.Gui/Views/Wizard/WizardStep.cs index e3d94f6b3e..8d9be18b05 100644 --- a/Terminal.Gui/Views/Wizard/WizardStep.cs +++ b/Terminal.Gui/Views/Wizard/WizardStep.cs @@ -1,4 +1,5 @@ -namespace Terminal.Gui; +#nullable enable +namespace Terminal.Gui; /// /// Represents a basic step that is displayed in a . The view is @@ -15,26 +16,6 @@ /// public class WizardStep : View { - ///// - ///// The title of the . - ///// - ///// The Title is only displayed when the is used as a modal pop-up (see . - //public new string Title { - // // BUGBUG: v2 - No need for this as View now has Title w/ notifications. - // get => title; - // set { - // if (!OnTitleChanging (title, value)) { - // var old = title; - // title = value; - // OnTitleChanged (old, title); - // } - // base.Title = value; - // SetNeedsDraw (); - // } - //} - - //private string title = string.Empty; - // The contentView works like the ContentView in FrameView. private readonly View _contentView = new () { @@ -140,7 +121,7 @@ public string HelpText /// Add the specified to the . /// to add to this container - public override View Add (View view) + public override View Add (View? view) { _contentView.Add (view); @@ -156,10 +137,10 @@ public override View Add (View view) /// Removes a from . /// - public override View Remove (View view) + public override View? Remove (View? view) { SetNeedsDraw (); - View container = view?.SuperView; + View? container = view?.SuperView; if (container == this) { diff --git a/UICatalog/Scenarios/Wizards.cs b/UICatalog/Scenarios/Wizards.cs index 7507852494..024991904b 100644 --- a/UICatalog/Scenarios/Wizards.cs +++ b/UICatalog/Scenarios/Wizards.cs @@ -263,7 +263,7 @@ void Win_Loaded (object sender, EventArgs args) }; thirdStep.Add (progLbl, progressBar); thirdStep.Enabled = thirdStepEnabledCeckBox.CheckedState == CheckState.Checked; - thirdStepEnabledCeckBox.CheckedStateChanging += (s, e) => { thirdStep.Enabled = thirdStepEnabledCeckBox.CheckedState == CheckState.Checked; }; + thirdStepEnabledCeckBox.CheckedStateChanged += (s, e) => { thirdStep.Enabled = thirdStepEnabledCeckBox.CheckedState == CheckState.Checked; }; // Add 4th step var fourthStep = new WizardStep { Title = "Step Four" }; @@ -357,7 +357,7 @@ void Win_Loaded (object sender, EventArgs args) "This step only shows if it was enabled on the other last step."; finalFinalStep.Enabled = thirdStepEnabledCeckBox.CheckedState == CheckState.Checked; - finalFinalStepEnabledCeckBox.CheckedStateChanging += (s, e) => + finalFinalStepEnabledCeckBox.CheckedStateChanged += (s, e) => { finalFinalStep.Enabled = finalFinalStepEnabledCeckBox.CheckedState == CheckState.Checked; };