-
Notifications
You must be signed in to change notification settings - Fork 31
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Newer DWMWINDOWATTRIBUTE / DWMA_ values are missing #252
Comments
It has 2 values, it's first value was 19 then a later build changed it to 20. So that value will have to be an property so it can do a Windows versions check to return either 19 or 20. Just for simplicity the version where it changed is: OperatingSystem.IsWindowsVersionAtLeast(10, 0, 18985) ? /* DWMWA_USE_IMMERSIVE_DARK_MODE is 20 */ : /* DWMWA_USE_IMMERSIVE_DARK_MODE is 19 */; |
Yeah I've seen the "old" version of the constant named something like |
https://github.com/terrafx/terrafx.interop.windows/blob/main/sources/Interop/Windows/Windows/um/dwmapi/DWMWINDOWATTRIBUTE.cs I see it here now for some reason though but it is set to 20. In this case (like you said) we also need the 19 one which is The only think I can think of is making that type a static class with all the constants being properties or something as idk if that file is auto generated or not. |
I took the liberty to document it myself: https://github.com/MicrosoftDocs/sdk-api/pull/966/files/ |
@rickbrew, could you please clarify which enum values you are seeing as missing: https://source.terrafx.dev/#TerraFX.Interop.Windows/Windows/um/dwmapi/DWMWINDOWATTRIBUTE.cs,13dae90f41e4a48c? The older value ( If users want or need to rely on undocumented values/behaviors, they'll need to define their own constants to represent it. |
The undocumented one shouldn't be included, I agree These are missing:
Since these values are documented at https://docs.microsoft.com/en-us/windows/win32/api/dwmapi/ne-dwmapi-dwmwindowattribute , and in the header, they should be included |
Perhaps it will be included when TerraFX updates the Windows SDK perhaps? |
True, but I technically did document it in a PR to sdk-api indirectly by documenting the one that is provided in the Windows SDK. 😄 |
Only if they accept your PR that documents it. I'm only asking for the ones that are documented to be included in TerraFX.Interop.Windows. |
@rickbrew, its worth calling out that TerraFX.Interop.Windows currently exposes
Windows DWMWA_USE_IMMERSIVE_DARK_MODE = 20,
+ DWMWA_WINDOW_CORNER_PREFERENCE = 33,
+ DWMWA_BORDER_COLOR,
+ DWMWA_CAPTION_COLOR,
+ DWMWA_TEXT_COLOR,
+ DWMWA_VISIBLE_FRAME_BORDER_THICKNESS,
DWMWA_LAST |
Also note that my docs was merged 8 hours ago 🎉. |
This was resolved when I moved forward to 10.0.22000.0 |
Looks like
DWMWA_USE_IMMERSIVE_DARK_MODE
and a few others are now in the headers and listed in the docs page https://docs.microsoft.com/en-us/windows/win32/api/dwmapi/ne-dwmapi-dwmwindowattribute, although they lack descriptionsThe text was updated successfully, but these errors were encountered: