[gtk/gtk-3-24: 1/2] GDK W32: Use SPI_GETFONTSMOOTHINGTYPE instead of SPI_GETCLEARTYPE
- From: LRN <ruslanizhb src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk/gtk-3-24: 1/2] GDK W32: Use SPI_GETFONTSMOOTHINGTYPE instead of SPI_GETCLEARTYPE
- Date: Sun, 10 May 2020 13:51:26 +0000 (UTC)
commit f67bad2346c6e49e01501713170fdc39e5572a5f
Author: Руслан Ижбулатов <lrn1986 gmail com>
Date: Sun May 10 00:40:26 2020 +0000
GDK W32: Use SPI_GETFONTSMOOTHINGTYPE instead of SPI_GETCLEARTYPE
It turns out that SPI_GETCLEARTYPE always returns TRUE.
Fixes #1774 (for real this time).
gdk/win32/gdkmonitor-win32.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
---
diff --git a/gdk/win32/gdkmonitor-win32.c b/gdk/win32/gdkmonitor-win32.c
index 5c0a47756a..1c5d9ff994 100644
--- a/gdk/win32/gdkmonitor-win32.c
+++ b/gdk/win32/gdkmonitor-win32.c
@@ -802,17 +802,17 @@ _gdk_win32_monitor_get_pixel_structure (GdkMonitor *monitor)
GdkWin32Monitor *w32_m;
BOOL enabled = TRUE;
unsigned int smoothing_orientation = FE_FONTSMOOTHINGORIENTATIONRGB;
- BOOL cleartype = TRUE;
+ UINT cleartype = FE_FONTSMOOTHINGCLEARTYPE;
g_return_val_if_fail (monitor != NULL, NULL);
w32_m = GDK_WIN32_MONITOR (monitor);
SystemParametersInfoW (SPI_GETFONTSMOOTHING, 0, &enabled, 0);
- SystemParametersInfoW (SPI_GETCLEARTYPE, 0, &cleartype, 0);
+ SystemParametersInfoW (SPI_GETFONTSMOOTHINGTYPE, 0, &cleartype, 0);
if (!enabled ||
- !cleartype ||
+ (cleartype == FE_FONTSMOOTHINGSTANDARD) ||
!SystemParametersInfoW (SPI_GETFONTSMOOTHINGORIENTATION, 0, &smoothing_orientation, 0))
return "none";
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]