[Bug 54410] New: .NET 3.5 Checkbox checkmarks should be black instead of "Foreground" color
https://bugs.winehq.org/show_bug.cgi?id=54410 Bug ID: 54410 Summary: .NET 3.5 Checkbox checkmarks should be black instead of "Foreground" color Product: Wine Version: 8.0 Hardware: x86-64 OS: Linux Status: UNCONFIRMED Severity: normal Priority: P2 Component: mscoree Assignee: wine-bugs(a)winehq.org Reporter: matombo(a)arcor.de Distribution: --- On Windows the Checkbox "Foreground" property only affects the color of the checkbox label, but not the checkmark, which is always black. On current wine(-mono) the "Foreground" property also affects the color of the checkmark. The result is that with Foreground="white" (and Background being unset) the checkmark is not visible anymore and one cannot tell if a box is checked or not. -- Do not reply to this email, post in Bugzilla using the above URL to reply. You are receiving this mail because: You are watching all bug changes.
https://bugs.winehq.org/show_bug.cgi?id=54410 --- Comment #1 from Esme Povirk <madewokherd(a)gmail.com> --- Are you using the default Light theme? (Desktop Integration tab in winecfg) The rendering codepath is different depending on whether a visual style theme is enabled. This appears to be the behavior without visual styles. -- Do not reply to this email, post in Bugzilla using the above URL to reply. You are receiving this mail because: You are watching all bug changes.
https://bugs.winehq.org/show_bug.cgi?id=54410 Esme Povirk <madewokherd(a)gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |madewokherd(a)gmail.com -- Do not reply to this email, post in Bugzilla using the above URL to reply. You are receiving this mail because: You are watching all bug changes.
https://bugs.winehq.org/show_bug.cgi?id=54410 --- Comment #2 from Esme Povirk <madewokherd(a)gmail.com> --- I did a quick test setting ForeColor on a CheckBox (there is no Foreground property), and I do not see this behavior regardless of whether I have a theme enabled. But I'm now realizing, you didn't specify what toolkit you were using. My test was with System.Windows.Forms. -- Do not reply to this email, post in Bugzilla using the above URL to reply. You are receiving this mail because: You are watching all bug changes.
https://bugs.winehq.org/show_bug.cgi?id=54410 --- Comment #3 from matombo(a)arcor.de --- Sorry forgot to add: It's a wpf UI. The Wine theme has no effect on the color of the checkmark. I build a minimal example with source code. See the attachment (precompiled in the bin/Debug folder). I chose green for the foreground color to show the difference between windows and wine without making the checkmark go invisible. -- Do not reply to this email, post in Bugzilla using the above URL to reply. You are receiving this mail because: You are watching all bug changes.
https://bugs.winehq.org/show_bug.cgi?id=54410 --- Comment #4 from matombo(a)arcor.de --- Created attachment 74042 --> https://bugs.winehq.org/attachment.cgi?id=74042 Minimal checkbox example WPF .NET Framework 3.5 -- Do not reply to this email, post in Bugzilla using the above URL to reply. You are receiving this mail because: You are watching all bug changes.
https://bugs.winehq.org/show_bug.cgi?id=54410 --- Comment #5 from Esme Povirk <madewokherd(a)gmail.com> --- I'd assume it's something to do with this in the theme: https://github.com/madewokherd/wpf/blob/main/src/Microsoft.DotNet.Wpf/src/Th... I guess that Foreground here is supposed to resolve to "{DynamicResource {x:Static SystemColors.WindowTextBrushKey}}" and that this should be from the Windows theme, not the Foreground property. I wonder of loading XAML instead of BAML messes this up somehow. -- Do not reply to this email, post in Bugzilla using the above URL to reply. You are receiving this mail because: You are watching all bug changes.
https://bugs.winehq.org/show_bug.cgi?id=54410 Esme Povirk <madewokherd(a)gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Keywords| |download, source -- Do not reply to this email, post in Bugzilla using the above URL to reply. You are receiving this mail because: You are watching all bug changes.
https://bugs.winehq.org/show_bug.cgi?id=54410 --- Comment #6 from Esme Povirk <madewokherd(a)gmail.com> --- Best I can tell from reading the code and the documentation at https://learn.microsoft.com/en-us/dotnet/api/system.windows.templatebindinge..., this was an intentional choice by whoever coded the Classic theme in WPF. It's difficult to test on Windows because modern Windows does not allow selecting the Classic theme. On modern themes, the Foreground property isn't referenced in this way. So I'm not sure if this is strictly correct, and you may find that the issue comes back if you use .NET Core (where I can't modify the theme). -- Do not reply to this email, post in Bugzilla using the above URL to reply. You are receiving this mail because: You are watching all bug changes.
https://bugs.winehq.org/show_bug.cgi?id=54410 --- Comment #7 from Esme Povirk <madewokherd(a)gmail.com> --- I'm going to go ahead and change this, on the basis that the theme currently uses the Foreground/Background properties in some cases and SystemColors in other cases. Foreground and background colors should never be set together, specifically to prevent this kind of issue. -- Do not reply to this email, post in Bugzilla using the above URL to reply. You are receiving this mail because: You are watching all bug changes.
https://bugs.winehq.org/show_bug.cgi?id=54410 --- Comment #8 from Esme Povirk <madewokherd(a)gmail.com> --- I said that backwards, the two colors should always be set together, which is the rule this theme currently breaks. -- Do not reply to this email, post in Bugzilla using the above URL to reply. You are receiving this mail because: You are watching all bug changes.
https://bugs.winehq.org/show_bug.cgi?id=54410 --- Comment #9 from Esme Povirk <madewokherd(a)gmail.com> --- Should be fixed by this commit in Wine Mono: https://github.com/madewokherd/wine-mono/commit/f9dd3b8c6896cf39cbd4268dc6ce... The fix will make its way into the next major Wine Mono release. -- Do not reply to this email, post in Bugzilla using the above URL to reply. You are receiving this mail because: You are watching all bug changes.
https://bugs.winehq.org/show_bug.cgi?id=54410 --- Comment #10 from matombo(a)arcor.de --- Thanks for the patch -- Do not reply to this email, post in Bugzilla using the above URL to reply. You are receiving this mail because: You are watching all bug changes.
https://bugs.winehq.org/show_bug.cgi?id=54410 Esme Povirk <madewokherd(a)gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Resolution|--- |FIXED Status|UNCONFIRMED |RESOLVED Fixed by SHA1| |0a3fe99d2bb00ad2f8867551915 | |a82c7983e6f5a --- Comment #11 from Esme Povirk <madewokherd(a)gmail.com> --- Should be fixed by Wine Mono 8.0.0. -- Do not reply to this email, post in Bugzilla using the above URL to reply. You are receiving this mail because: You are watching all bug changes.
https://bugs.winehq.org/show_bug.cgi?id=54410 Alexandre Julliard <julliard(a)winehq.org> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|RESOLVED |CLOSED --- Comment #12 from Alexandre Julliard <julliard(a)winehq.org> --- Closing bugs fixed in 8.10. -- Do not reply to this email, post in Bugzilla using the above URL to reply. You are receiving this mail because: You are watching all bug changes.
participants (1)
-
WineHQ Bugzilla