Tig 3 luni în urmă
părinte
comite
b59ac3b69c

+ 6 - 6
Terminal.Gui/Resources/config.json

@@ -511,8 +511,8 @@
                 "Style": "None"
               },
               "Editable": {
-                "Foreground": "Goldenrod",
-                "Background": "WhiteSmoke",
+                "Foreground": "Black",
+                "Background": "LemonChiffon",
                 "Style": "None"
               },
               "ReadOnly": {
@@ -565,8 +565,8 @@
                 "Style": "None"
               },
               "Editable": {
-                "Foreground": "Goldenrod",
-                "Background": "WhiteSmoke",
+                "Foreground": "Black",
+                "Background": "LemonChiffon",
                 "Style": "None"
               },
               "ReadOnly": {
@@ -669,7 +669,7 @@
               },
               "Highlight": {
                 "Foreground": "Black",
-                "Background": "LightGray",
+                "Background": "LemonChiffon",
                 "Style": "None"
               },
               "Editable": {
@@ -727,7 +727,7 @@
                 "Style": "None"
               },
               "Editable": {
-                "Foreground": "Goldenrod",
+                "Foreground": "Black",
                 "Background": "WhiteSmoke",
                 "Style": "None"
               },

+ 3 - 2
Terminal.Gui/Views/TextInput/TextView.cs

@@ -3,6 +3,7 @@
 // TextView.cs: multi-line text editing
 using System.Globalization;
 using System.Runtime.CompilerServices;
+using static Unix.Terminal.Delegates;
 
 namespace Terminal.Gui.Views;
 
@@ -1868,6 +1869,7 @@ public class TextView : View, IDesignable
 
             if (col < right)
             {
+                SetAttributeForRole (ReadOnly ? VisualRole.ReadOnly : VisualRole.Editable);
                 ClearRegion (col, row, right, row + 1);
             }
 
@@ -1876,11 +1878,10 @@ public class TextView : View, IDesignable
 
         if (row < bottom)
         {
+            SetAttributeForRole (ReadOnly ? VisualRole.ReadOnly : VisualRole.Editable);
             ClearRegion (Viewport.Left, row, right, bottom);
         }
 
-        //PositionCursor ();
-
         _isDrawing = false;
 
         return false;