microsoft-ui-xaml icon indicating copy to clipboard operation
microsoft-ui-xaml copied to clipboard

How to change the selection text foreground color in WPF MS TextBox control

Open YuvarajMasilamani opened this issue 1 year ago • 2 comments

Describe the bug

When we changed the text box selection color using the selection brush property, the foreground color of the selection text was black and the opacity of the selection brush was altered. We then set the selection opacity property to 1, and the selection text was disabled. TextBoxSelectionIssue.zip

Steps to reproduce the bug

  1. Set the SelectionBrush property.
  2. Run the sample.
  3. Note the issue

Expected behavior

When the text box selection color was changed, the opacity of the color did not change, and the selection text color was changed to white

Screenshots

After changing the selection color image

After changing the SelectionOpacity image

Expected behaviour image

NuGet package version

None

Windows version

Windows 11 (22H2): Build 22621

Additional context

No response

YuvarajMasilamani avatar Jun 24 '24 05:06 YuvarajMasilamani

Hi I'm an AI powered bot that finds similar issues based off the issue title.

Please view the issues below to see if they solve your problem, and if the issue describes your problem please consider closing this one. Thank you!

Open similar issues:

Closed similar issues:

Note: You can give me feedback by thumbs upping or thumbs downing this comment.

github-actions[bot] avatar Jun 24 '24 05:06 github-actions[bot]

Is there any way to change the selection text foreground color in the textbox control?

YuvarajMasilamani avatar Jun 24 '24 09:06 YuvarajMasilamani

I think the dotnet/wpf repo is the right place for WPF questions.

codendone avatar Jul 02 '24 22:07 codendone