Windows 10 Dark Mode

Do you have a typical platform dependent issue you're battling with ? Ask it here. Make sure you mention your platform, compiler, and wxWidgets version.
Post Reply
User avatar
rocrail
I live to help wx-kind
I live to help wx-kind
Posts: 179
Joined: Fri Oct 02, 2009 2:02 pm
Contact:

Windows 10 Dark Mode

Post by rocrail » Mon May 13, 2019 12:17 pm

Hi,

under macOS the Desktop Dark Mode is also reflected in wxWidgets based applications.
The same application remains 'Light mode' under Windows even if Windows has set Dark Mode.

The diff between both builds is that under macOS the Git master is used, and under Windows wxWidgets release 3.0.3.
Should I also build the Windows target with the Git master?
Best regards,
Rob.

PB
Part Of The Furniture
Part Of The Furniture
Posts: 2065
Joined: Sun Jan 03, 2010 5:45 pm

Re: Windows 10 Dark Mode

Post by PB » Mon May 13, 2019 12:44 pm

Just curious: Is there really a dark mode in Windows 10 that affects not only UWP but also Win32 applications (such as Notepad, Wordpad, MSPaint)?

Anyway, AFAIK the "dark mode" support has been introduced relatively recently and therefore is available only in the 3.1 branch and for MacOS only.

EDITI just tested (v1809): none of the applications mentioned above respond to the dark mode setting being on, also in a generic application colors returned by ::GetSysColor() seem to be the same. I could not find any information about there being a relevant compatibility manifest setting...

User avatar
rocrail
I live to help wx-kind
I live to help wx-kind
Posts: 179
Joined: Fri Oct 02, 2009 2:02 pm
Contact:

Re: Windows 10 Dark Mode

Post by rocrail » Mon May 13, 2019 1:17 pm

Hi,

the Windows setting is found here:
win10dark.png
The File Explorer, Calendar, ... does change its color automatically, but other common Apps like Wordpad does not.
Best regards,
Rob.

ONEEYEMAN
Part Of The Furniture
Part Of The Furniture
Posts: 3503
Joined: Sat Apr 16, 2005 7:22 am
Location: USA, Ukraine

Re: Windows 10 Dark Mode

Post by ONEEYEMAN » Mon May 13, 2019 2:28 pm

Hi,
You should recompile with the Git HEAD on Windows.
But if my memory serves me right, the "Dark Mode" was introduced to OSX only.

Patches always welcome. ;-)

Thank you.

PB
Part Of The Furniture
Part Of The Furniture
Posts: 2065
Joined: Sun Jan 03, 2010 5:45 pm

Re: Windows 10 Dark Mode

Post by PB » Mon May 13, 2019 5:40 pm

rocrail wrote:
Mon May 13, 2019 1:17 pm
The File Explorer, Calendar, ... does change its color automatically, but other common Apps like Wordpad does not.
Calendar is not a Win32 application*. Adding dark mode to File Explorer, which is, was not that simple, i.e. it had to be done for this single application by hand.

Most of wxWidgets controls on MSW are wrappers of their native Win32 equivalents. UWP "features" are exposed to C++ Win32 applications via winrt API (which wxWidgets AFAIK currently uses only for wxNotificationMessage). The native Win32 controls seem to be unaware of dark mode so adding some winrt support (e.g. wxSystemSettings::GetColour() using UISettings::GetColorValue() instead of ::GetSysColor()) would probably not be that useful. And I am just guessing here but I do not think Microsoft will make it easy/easier by releasing a new version of Common Controls capable of dark mode, similarly to what they did for themed controls when going from Win98 to WinXP. MS wants everyone to go UWP and likely will not spend any money on teaching the old dog new tricks...

* By Win32 / native Windows application I mean an application which uses the controls available since many Windows versions ago, not the UWP ones.

catalin
Moderator
Moderator
Posts: 1525
Joined: Wed Nov 12, 2008 7:23 am
Location: Romania

Re: Windows 10 Dark Mode

Post by catalin » Wed May 15, 2019 10:38 am

PB wrote:
Mon May 13, 2019 5:40 pm
MS wants everyone to go UWP and likely will not spend any money on teaching the old dog new tricks...
Actually it seems that Microsoft wants to close the UWP, Win32 divide. But indeed, at lest for now, UWP-only features are not available through wxW.

PB
Part Of The Furniture
Part Of The Furniture
Posts: 2065
Joined: Sun Jan 03, 2010 5:45 pm

Re: Windows 10 Dark Mode

Post by PB » Wed May 15, 2019 11:15 am

catalin wrote:
Wed May 15, 2019 10:38 am
But indeed, at lest for now, UWP-only features are not available through wxW.
TBH, I cannot see wxWidgets adapting the UWP controls anytime soon. It would probably mean undertaking a great effort and creating a compatibility nightmare. Partially adopting UWP controls may not be that great either, mixing UWP and Win32 controls in a single app would look odd. I am not really familiar with UWP but to me it seems that the controls may not be well suited to rich desktop apps, think MSVS or MS Office...

Sadly, I think Windows desktop is not in a good state, with at least 3 different major technologies being used (Win32 vs UWP vs web browser-based).

Post Reply