WinUI-Gallery icon indicating copy to clipboard operation
WinUI-Gallery copied to clipboard

Context Menu Text Highlighting Doesn't Update with Theme Change

Open Zakariathr22 opened this issue 9 months ago • 4 comments

Description

When changing the app theme from Light to Dark (or vice versa), the text highlighting in the context menu does not update correctly. It appears that the context menu text uses static resources, causing it to retain the previous theme's colors until the app is restarted.

Steps to Reproduce

  1. Clone the repository.
  2. Switch to and run the main branch.
  3. Go to Settings and change the theme (e.g., from Light to Dark or Dark to Light).
  4. Navigate to any component where you can write or select text (e.g., RichTextBox).
  5. Right-click to open the context menu and observe the text highlighting.

Expected Behavior

The text in the context menu should correctly update to match the selected theme.

Actual Behavior

The context menu text appears to use static resources, preventing it from updating dynamically when the theme changes.

Screenshots

Image

Additional Context

  • This issue does not appear in version 2.5.1 but is present in the main branch.
  • It may be related to the WindowsAppSDK version update (#1729).

Zakariathr22 avatar Jan 29 '25 23:01 Zakariathr22