ephemeralViolette
Freshman Member
Posts: 29
OS: Windows 10 (20H2)
Theme: Luna
CPU: AMD Ryzen 7 1700
RAM: 32 GB
GPU: Radeon RX 580
|
Post by ephemeralViolette on Jul 23, 2023 14:32:23 GMT -8
Hello, I have been working on a Windhawk mod over the past couple of days in order to fix ghosting behaviour, and it has now been accepted into the Windhawk marketplace!
DWM Ghost Mods:
This allows you to customise the appearance of ghosted windows, including disabling DWM's custom window frames and changing the frost effect which brightens the window.
You should use this in conjunction with ClassicThemeTray or BasicThemer in order to restore the correct appearance to unresponsive windows. Historically, there has been a problem with these tools where windows that stop responding will continue to use the DWM window frames. This is because DWM manages the ghost copies of unresponsive windows and third-party tools cannot theme DWM's child windows. This hooks into DWM itself to restore the correct appearance.
Notice: This will only work with the standard version of Windhawk, not the portable version. The portable version does not run with sufficient permissions to inject into DWM.
This is tested, and should work, on Windows 8.1 through Windows 11.
See the Windhawk mod page for more details:
|
|
|
|
Post by OrthodoxWin32 on Jul 23, 2023 15:45:53 GMT -8
|
|
|
|
Post by The Jackal on Jul 24, 2023 4:25:24 GMT -8
Oh nice, one of my chief annoyances with modern Windows! Thank you for all your hard work.
|
|
|
|
Post by anixx on Jul 24, 2023 21:58:09 GMT -8
Does not work for me :-(
|
|
|
|
Post by The Jackal on Jul 25, 2023 2:03:29 GMT -8
It's working for me - check out the Settings tab, you might need to enable "Use Classic Theme" if you haven't done so already.
|
|
Guest
New Member
Posts: 12
OS: Windows 11
CPU: I5-12450H
RAM: 16
GPU: GTX 1650
|
Post by Guest on Jul 25, 2023 3:25:49 GMT -8
will this work for Windows 11 22H2? and thank you.
|
|
|
|
Post by anixx on Jul 25, 2023 3:26:38 GMT -8
It's working for me - check out the Settings tab, you might need to enable "Use Classic Theme" if you haven't done so already. Did it. Does not work.
|
|
|
|
Post by The Jackal on Jul 25, 2023 4:19:15 GMT -8
It's working for me - check out the Settings tab, you might need to enable "Use Classic Theme" if you haven't done so already. Did it. Does not work. Well if it matters I use it in conjunction with BasicThemer and it works for me.
|
|
|
|
Post by The Jackal on Jul 25, 2023 4:21:44 GMT -8
will this work for Windows 11 22H2? and thank you. From the mod's Windhawk page: The mod is tested on the following versions of Windows and is confirmed to work as intended. ✅ Windows 8.1 (build 9600) ✅ Windows 10 version 1607 (build 14393) ✅ Windows 10 version 1809 (build 17763) ✅ Windows 10 version 20H2 (build 19042) ✅ Windows 10 version 21H1 (build 19043) ✅ Windows 10 version 21H2 (build 19044) ✅ Windows 11 version 22H2 (build 22621)
|
|
|
|
Post by anixx on Jul 25, 2023 4:25:59 GMT -8
Well if it matters I use it in conjunction with BasicThemer and it works for me. I use classic theme
|
|
ephemeralViolette
Freshman Member
Posts: 29
OS: Windows 10 (20H2)
Theme: Luna
CPU: AMD Ryzen 7 1700
RAM: 32 GB
GPU: Radeon RX 580
|
Post by ephemeralViolette on Jul 25, 2023 4:46:01 GMT -8
I would love to provide support. Most known errors should open a message box dialog, however admittedly I didn't thoroughly test them. If you hadn't enabled the classic theme option as suggested, there would still be a noticeable effect, just that the windows would have basic themed frames instead of classic.
Could you tell me the specific build of Windows you are running? I will check if I can get it working. If you have the required Windhawk setup (standard install as opposed to portable), then the most likely issue you're encountering is it silently failing to download symbols, meaning you need to follow the manual download instructions provided in the mod's README and toggle the mod on and off to restart it. Please tell me if this is the case so I can push a patch, if so.
|
|
|
|
Post by anixx on Jul 25, 2023 14:25:41 GMT -8
I would love to provide support. Most known errors should open a message box dialog, however admittedly I didn't thoroughly test them. If you hadn't enabled the classic theme option as suggested, there would still be a noticeable effect, just that the windows would have basic themed frames instead of classic.
Could you tell me the specific build of Windows you are running? I will check if I can get it working. If you have the required Windhawk setup (standard install as opposed to portable), then the most likely issue you're encountering is it silently failing to download symbols, meaning you need to follow the manual download instructions provided in the mod's README and toggle the mod on and off to restart it. Please tell me if this is the case so I can push a patch, if so.
Microsoft Windows [Version 10.0.22000.1641]
I used this BadApp program. After clicking on "hang" the frame is not classic-themed. The option "classic theme" doed not affect anything
|
|
ephemeralViolette
Freshman Member
Posts: 29
OS: Windows 10 (20H2)
Theme: Luna
CPU: AMD Ryzen 7 1700
RAM: 32 GB
GPU: Radeon RX 580
|
Post by ephemeralViolette on Jul 25, 2023 17:13:17 GMT -8
I would love to provide support. Most known errors should open a message box dialog, however admittedly I didn't thoroughly test them. If you hadn't enabled the classic theme option as suggested, there would still be a noticeable effect, just that the windows would have basic themed frames instead of classic.
Could you tell me the specific build of Windows you are running? I will check if I can get it working. If you have the required Windhawk setup (standard install as opposed to portable), then the most likely issue you're encountering is it silently failing to download symbols, meaning you need to follow the manual download instructions provided in the mod's README and toggle the mod on and off to restart it. Please tell me if this is the case so I can push a patch, if so.
Microsoft Windows [Version 10.0.22000.1641]
I used this BadApp program. After clicking on "hang" the frame is not classic-themed. The option "classic theme" doed not affect anything

I managed to get it working on a fresh install following the standard setup procedure. Ignore the graphical issue in the screenshot; that only occurs because I didn't fully enable classic theme in the VM.
Please check the following:
- That you are running the standard version of Windhawk, which uses a service to startup. It is impossible to modify DWM with the portable version of Windhawk due to extra protections Microsoft put on the process.
- The most likely scenario is that you haven't allowed Windhawk to inject into system processes. This option is hidden deep inside the Windhawk settings, so you have to open a few menus to get to it. You have to go to Settings -> Advanced settings -> More advanced settings, and it should be at the very bottom of that dialog. You can confirm that this is the case if you go to edit mod, enable logging, open the log window, and then toggle the mod on and off to restart it. If it is injecting into DWM at all, you should see a message pop up saying "Init dwm-ghost-mods version 1.1", informing you that the mod is trying to be loaded into DWM.
- If that doesn't work, try manually downloading the symbols as detailed in the README. The downloaded folder should be merged such that you have a folder called dwmghost.pdb containing a folder that has a MD5 hash as a name that has a file called dwmghost.pdb. This entire thing should go in C:\ProgramData\Windhawk\Engine\Symbols. If you enabled logging and this action is required, then you will see an init message and no subsequent messages.
|
|
|
|
Post by anixx on Jul 25, 2023 23:51:46 GMT -8
Wait, are you injecting into DWM? It is disabled by default in Windhawk (injecting all system processes is disabled). If I enable it, the system is not bootable.
|
|
|
|
Post by OrthodoxWin32 on Jul 26, 2023 0:49:08 GMT -8
Wait, are you injecting into DWM? It is disabled by default in Windhawk (injecting all system processes is disabled). If I enable it, the system is not bootable. Usually this happens if you are using a mod that crashes a critical process. I had recently tried with this mod (which you shared previously) : // ==WindhawkMod== // @id classic-browser-fix // @name Unthemed+Nocomposition // @description Removes composition from windows and sets Light window frame // @version 0.1 // @include msedge.exe // @include chrome.exe // @compilerOptions -luxtheme // ==/WindhawkMod==
#include <uxtheme.h>
BOOL Wh_ModInit() { Wh_Log(L"Init"); SetThemeAppProperties(0); return TRUE; }
I had launched this mod at startup, with the injection in all the processes. So modifying : // @include msedge.exe
// @include chrome.exeTo :
// @include *This works fine without injecting critical processes, but crashes the system otherwise.
So, your problem may be related (I haven't tested it) to this mod, which affects all processes :
// ==WindhawkMod== // @id classic-browser-fix // @name Unthemed+Nocomposition // @description Removes composition from windows and sets Light window frame // @version 0.1 // @include msedge.exe // @include chrome.exe // @compilerOptions -luxtheme // ==/WindhawkMod==
#include <uxtheme.h>
BOOL Wh_ModInit() { Wh_Log(L"Init"); SetThemeAppProperties(0); return TRUE; }
I told the Windhawks developer about the problem, he advised me to find the process that is crashing the system, and add it to the mod's exclusion list. The challenge seems to be to find the process responsible for the crash. Afterwards, your problem may be related to another mod, I'm not sure what I'm saying.
|
|
ephemeralViolette
Freshman Member
Posts: 29
OS: Windows 10 (20H2)
Theme: Luna
CPU: AMD Ryzen 7 1700
RAM: 32 GB
GPU: Radeon RX 580
|
Post by ephemeralViolette on Jul 26, 2023 3:06:29 GMT -8
Wait, are you injecting into DWM? It is disabled by default in Windhawk (injecting all system processes is disabled). If I enable it, the system is not bootable. Yes, this is only possible by injecting into DWM.
The instability you describe is most definitely caused by another mod, and is most likely caused by a mod that sets classic theme like the one OrthodoxWin32 described; in fact, attempting to use classic theme at all in DWM is likely to cause it to crash (I could only get it working by disabling themed frames, but controls always seemed to crash). You will need to exclude such a mod from injecting into DWM as well. The only reason something like ClassicThemeTray works is because the theme stays loaded in DWM for the duration of its lifetime. In fact, you may notice that DWM will fail to restart if you have ClassicThemeTray running for this very reason, because DWM relies on the theme engine for storing and loading its graphical resources.
You don't have to modify the source code of a mod to change its injection list. I recommend that you add any custom exclusions to the list in the advanced tab of the mod, since this will still enable you to receive updates for the mod and will persist after them.
If you could provide a list of mods that you use, I could hopefully provide further assistance.
|
|
|
|
Post by OrthodoxWin32 on Jul 26, 2023 4:04:51 GMT -8
This is strange, because I'm on a version of Windows that has been tested (Windows 10 21H2).
This window is not in the classic theme because Windhawks loads before the scheduled task of the ClassicThemeTray, the rest of the system is in the classic theme.
|
|
|
|
Post by OrthodoxWin32 on Jul 26, 2023 4:24:11 GMT -8
For the problem of mods bringing the classic theme, it's solved on my side. I added DWM to the exclusion list of both mods, and I no longer have the crash.
|
|
ephemeralViolette
Freshman Member
Posts: 29
OS: Windows 10 (20H2)
Theme: Luna
CPU: AMD Ryzen 7 1700
RAM: 32 GB
GPU: Radeon RX 580
|
Post by ephemeralViolette on Jul 26, 2023 5:02:08 GMT -8
This is strange, because I'm on a version of Windows that has been tested (Windows 10 21H2).
This window is not in the classic theme because Windhawks loads before the scheduled task of the ClassicThemeTray, the rest of the system is in the classic theme.
Does dwmghost.dll exist in System32? I know that this DLL never existed before Windows 10, but I went with the assumption all versions after 10.0.10240 would have it. Perhaps you do not have it.
If the file indeed exists, then there is likely something wrong with the version check function IsWindows10OrGreater(), which is checked on line 408. If the file exists, try changing the line to:
if (TRUE) and if it does not exist, try changing it to:
if (FALSE)
I have implemented it in this manner to prevent it from logging an error in Windhawk, but if you're encountering troubles with this, then I will fix this check in a future version. Either way, please report back to me your findings.
I'm not sure why you would have issues with a tested version, but sometimes the patch updates can change behaviour. Come to think of it, are you sure you didn't delete dwmghost.dll as an earlier solution? That was the advice I heard around, but I never liked it because it prevented programs from ghosting entirely, which is why I made this. It's possible that the reason it can't find this library which should be loaded into DWM is because you forgot to restore it after applying such a modification.
By the way, the window is not in classic theme because it is a child of DWM, not necessarily because Windhawk loads before ClassicThemeTray. Non-system tasks, even if they're running as administrator, cannot modify DWM child windows, which is the premise of this mod itself.
|
|
|
|
Post by OrthodoxWin32 on Jul 26, 2023 5:14:04 GMT -8
I'm not sure why you would have issues with a tested version, but sometimes the patch updates can change behaviour. Come to think of it, are you sure you didn't delete dwmghost.dll as an earlier solution? That was the advice I heard around, but I never liked it because it prevented programs from ghosting entirely, which is why I made this. It's possible that the reason it can't find this library which should be loaded into DWM is because you forgot to restore it after applying such a modification.
Yes, I had renamed DWMGhost.exe in the past, and had forgotten. Thanks, now it works.
|
|