-
Notifications
You must be signed in to change notification settings - Fork 27.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[TextField]backgroundColor
covers/hides cursor and text selection
#96112
Comments
Hi @uvizhe, thanks for reporting the issue. I am able to reproduce the issue on the stable and the master channel on all platforms. By adding the background color to text, text selection is not visible. Also, the textSelectionTheme doesn't seem to take effect, unless the theme: ThemeData(
textSelectionTheme: const TextSelectionThemeData(
selectionColor: Colors.red,
)), flutter doctor -v
|
backgroundColor
covers/hides cursor and text selection
I had find the reason and solve that: #96276 |
Duplicate of #79168. According to @LongCatIsLooong's comment there, it's currently blocked on #39420 |
Blocking issue seems like merged, is there an update on this issue? |
cc: @LongCatIsLooong |
This comment was marked as off-topic.
This comment was marked as off-topic.
This is a serious issue for me; I have to define background color for reasons, but i need selection to actually appear, and i do not want to do this custom. |
I've managed to get around this by stacking rich texts, (bottom one has the background color and transparent text, top one has the text color but no background) but this should not be necessary guys! |
…ble code selection highlight (#7090) fixes: flutter/flutter#150053 related to : flutter/flutter#96112
Setting
backgroundColor
onTextField
appears to mask cursor and text selection. That is when you type some text in a text box and move cursor back it disappears. Selecting text doesn't show any visual indicator of a selection either.Below is a code to reproduce this.
I observe this behavior at least on linux and android.
https://dartpad.dev/?id=c76c8bd3543de7eeea64cd6d0b225835 <== you can test it here
The text was updated successfully, but these errors were encountered: