Unity Issue Tracker - selectionColor and cursorColor methods do not change color when using TextField.textSelection
Fixed
UUM-98451
selectionColor and cursorColor methods do not change color when using TextField.textSelection
Unity: Text (TextCore)
Fixed
6.2.X
6.1.X
6.0.X
Won't Fix
2022.3.X
Mark color selection API as obsolete
The Color selection C# API is now obsolete. Please use the corresponding USS properties instead.
The Color selection C# API is now obsolete. Please use the corresponding USS properties instead.
How to reproduce:
1. Open the attached “IN-92703” project
2. Open the “SampleScene” Scene
3. Enter Play mode
4. Click on the Game view and type “aaaa”
5. Press the left arrow key twice
6. Observe the text at the bottom of the Game view
7. Select that same text with the mouse
8. Observe the text at the bottom of the Game view
Expected result: Observing text the first time the caret color should be white and observing it the second time the selected portion of the text highlight color should also be white
Actual result: Observing text the first time the caret color is black and observing it the second time the selected portion of the text highlight color is blue