A lightweight Windows utility that parses and displays DarkMode class mappings embedded in .msstyles theme files (e.g. aero.msstyles).
It reads the CMap resource section of a Visual Styles file and extracts all DarkMode::* class variants, displaying them in a hierarchical tree view.
- 📂 Open any
.msstylesfile via a file dialog - 🌲 Displays DarkMode class groups as a tree (base class → variants)
- 💾 Persists the last opened file path via the Windows Registry
- 🔍 Enumerates all
CMapresources (not just ID=1) - ✅ Supports MSVC and MinGW/GCC builds
Tree view showing DarkMode base classes and their variants parsed from
aero.msstyles.
- Windows SDK
- A C++ compiler (MSVC or MinGW-w64)
- Links against:
Comctl32.lib,Shlwapi.lib,User32.lib,Advapi32.lib,Comdlg32.lib,Gdi32.lib
Open a Developer Command Prompt and run:
cl /W4 /EHsc main.cpp /link Comctl32.lib Shlwapi.lib User32.lib Advapi32.lib Comdlg32.lib Gdi32.lib /SUBSYSTEM:WINDOWSg++ -municode -mwindows main.cpp -o aero-darkmode-parser.exe -lcomctl32 -lshlwapi -luser32 -ladvapi32 -lcomdlg32 -lgdi32- Run
aero-darkmode-parser.exe - A file picker will open on first launch — select a
.msstylesfile
(typically atC:\Windows\Resources\Themes\aero\aero.msstyles) - The tree populates with all discovered
DarkModeclass groups - Use File → Open .msstyles... to load a different file
The last used path is remembered in the registry under:
HKCU\Software\Microsoft\Windows\CurrentVersion\ThemeManager
.msstyles files are PE-format DLLs containing embedded resources. Among these is the CMap resource type, which holds null-delimited wide-string entries mapping theme class names.
This tool:
- Loads the
.msstylesas a data-only module (LOAD_LIBRARY_AS_DATAFILE) - Enumerates all
CMapresources viaEnumResourceNames - Scans each blob for entries containing
DarkMode - Groups them by base class name (the part after
::) - Displays the hierarchy in a TreeView control
aero-darkmode-parser/
├── main.cpp # Full source (single-file Win32 application)
└── README.md
MIT License. See LICENSE.