ImageGlass
ImageGlass copied to clipboard
Sync dark/light theme with Windows 10
Chris:
The latest version of windows has a dark theme, which changes elements such as context menus to be dark, so if I schedule windows to change to the dark theme automatically at night, it wouldn't affect ImageGlass, because all elements are skinned.
Need to research the message code for WndProc function
https://github.com/d2phap/ImageGlass/blob/master/Source/ImageGlass/frmMain.cs#L2065
The configuration can be queried in the registry's following location:
- Key:
HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Themes\Personalize - Value:
AppsUseLightTheme
When the value equals 0 (DWORD), it means it is in dark mode. Altering the value triggers immediately Windows Explorer to go/exit dark mode.
Some resources:
- https://stackoverflow.com/questions/53501268/win10-dark-theme-how-to-use-in-winapi
- https://github.com/ysc3839/win32-darkmode
- https://github.com/microsoft/terminal/issues/277#issuecomment-428831635
Implemented in v9.0 beta 4.
In igconfig.json file, you can specify the theme for dark and light mode:
{
"DarkTheme": "Kobe",
"LightTheme": "Kobe - Light",
}