Fix issue 11939: [Dark Mode]HelpProvider text color is barely visible#14338
Fix issue 11939: [Dark Mode]HelpProvider text color is barely visible#14338SimonZhao888 wants to merge 1 commit intodotnet:mainfrom
Conversation
There was a problem hiding this comment.
Pull request overview
This PR fixes issue #11939 where the HelpProvider popup text color was barely visible in WinForms dark mode. Previously, clrForeground in the HH_POPUP struct was set to 0xFFFFFFFF (commented as "Ignore" — a "use default" sentinel), which caused the HtmlHelp API to use a default foreground color that didn't adapt to the WinForms theme. The fix replaces this with SystemColors.WindowText, consistent with how clrBackground was already set using SystemColors.Window.
Changes:
- Replace the
clrForeground"ignore" sentinel value inHH_POPUPwithSystemColors.WindowTextto ensure the popup text color matches the current WinForms theme (including dark mode).
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #14338 +/- ##
===================================================
+ Coverage 77.25545% 77.31714% +0.06168%
===================================================
Files 3280 3265 -15
Lines 645315 644447 -868
Branches 47780 47631 -149
===================================================
- Hits 498541 498268 -273
+ Misses 143088 142482 -606
- Partials 3686 3697 +11
Flags with carried forward coverage won't be shown. Click here to find out more. 🚀 New features to boost your workflow:
|
Fixes #11939
Proposed changes
Customer Impact
Regression?
Risk
Screenshots
Before
After
2026-03-02.095343.mp4
2026-03-02.095705.mp4
Test methodology
Test environment(s)
Microsoft Reviewers: Open in CodeFlow