summaryrefslogtreecommitdiff
path: root/platform
diff options
context:
space:
mode:
authorRĂ©mi Verschelde <rverschelde@gmail.com>2023-03-05 18:16:06 +0100
committerYuri Sizov <yuris@humnom.net>2023-03-13 22:06:14 +0100
commitb1c8a4085319ff5433da3868c5784fbecb2c8f6b (patch)
tree8c7375f8f8257d5bd723266bdcdb01d24fdd9f1c /platform
parent90dbf3bd38ecd06ef32fb3cc4958cff6d132786d (diff)
Windows: Workaround missing DWRITE_FONT_WEIGHT value in old MinGW
Fixes #74339. (cherry picked from commit b7ecb9584a1fc141d70140f6b0e573d870fa0dcb)
Diffstat (limited to 'platform')
-rw-r--r--platform/windows/os_windows.cpp5
1 files changed, 5 insertions, 0 deletions
diff --git a/platform/windows/os_windows.cpp b/platform/windows/os_windows.cpp
index 91d2d1e996..6e219fb929 100644
--- a/platform/windows/os_windows.cpp
+++ b/platform/windows/os_windows.cpp
@@ -69,6 +69,11 @@ __declspec(dllexport) int AmdPowerXpressRequestHighPerformance = 1;
#define WM_POINTERUPDATE 0x0245
#endif
+// Missing in MinGW headers before 8.0.
+#ifndef DWRITE_FONT_WEIGHT_SEMI_LIGHT
+#define DWRITE_FONT_WEIGHT_SEMI_LIGHT (DWRITE_FONT_WEIGHT)350
+#endif
+
#if defined(__GNUC__)
// Workaround GCC warning from -Wcast-function-type.
#define GetProcAddress (void *)GetProcAddress