From cf51b4790e272363559d60fb4b6099fff12e1be1 Mon Sep 17 00:00:00 2001 From: Tor Lillqvist Date: Tue, 18 Jan 2000 22:03:59 +0000 Subject: [PATCH] The correct semantics (to mimic the X11 backend, which just calls 2000-01-19 Tor Lillqvist * gdk/win32/gdkwindow-win32.c (gdk_window_clear_area): The correct semantics (to mimic the X11 backend, which just calls XClearArea) is to check for zero width (and height), and in that case use the window's width minus x (height minus y). This fixes for instance some redraw problems with gtkclist, which were easily noticeable in the gtk file selection widget. (gdk_window_new): Don't set WS_EX_TOPMOST for dialog windows. --- ChangeLog | 12 ++++++++++++ ChangeLog.pre-2-0 | 12 ++++++++++++ ChangeLog.pre-2-10 | 12 ++++++++++++ ChangeLog.pre-2-2 | 12 ++++++++++++ ChangeLog.pre-2-4 | 12 ++++++++++++ ChangeLog.pre-2-6 | 12 ++++++++++++ ChangeLog.pre-2-8 | 12 ++++++++++++ gdk/win32/gdkwindow-win32.c | 12 +++++++----- 8 files changed, 91 insertions(+), 5 deletions(-) diff --git a/ChangeLog b/ChangeLog index 2612854a3a..f0a46a7b8b 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,15 @@ +2000-01-19 Tor Lillqvist + + * gdk/win32/gdkwindow-win32.c (gdk_window_clear_area): The correct + semantics (to mimic the X11 backend, which just calls XClearArea) + is to check for zero width (and height), and in that case use the + window's width minus x (height minus y). This fixes for instance + some redraw problems with gtkclist, which were easily noticeable + in the gtk file selection widget. + + (gdk_window_new): Don't set WS_EX_TOPMOST for dialog + windows. + 2000-01-13 Tor Lillqvist * configure.in diff --git a/ChangeLog.pre-2-0 b/ChangeLog.pre-2-0 index 2612854a3a..f0a46a7b8b 100644 --- a/ChangeLog.pre-2-0 +++ b/ChangeLog.pre-2-0 @@ -1,3 +1,15 @@ +2000-01-19 Tor Lillqvist + + * gdk/win32/gdkwindow-win32.c (gdk_window_clear_area): The correct + semantics (to mimic the X11 backend, which just calls XClearArea) + is to check for zero width (and height), and in that case use the + window's width minus x (height minus y). This fixes for instance + some redraw problems with gtkclist, which were easily noticeable + in the gtk file selection widget. + + (gdk_window_new): Don't set WS_EX_TOPMOST for dialog + windows. + 2000-01-13 Tor Lillqvist * configure.in diff --git a/ChangeLog.pre-2-10 b/ChangeLog.pre-2-10 index 2612854a3a..f0a46a7b8b 100644 --- a/ChangeLog.pre-2-10 +++ b/ChangeLog.pre-2-10 @@ -1,3 +1,15 @@ +2000-01-19 Tor Lillqvist + + * gdk/win32/gdkwindow-win32.c (gdk_window_clear_area): The correct + semantics (to mimic the X11 backend, which just calls XClearArea) + is to check for zero width (and height), and in that case use the + window's width minus x (height minus y). This fixes for instance + some redraw problems with gtkclist, which were easily noticeable + in the gtk file selection widget. + + (gdk_window_new): Don't set WS_EX_TOPMOST for dialog + windows. + 2000-01-13 Tor Lillqvist * configure.in diff --git a/ChangeLog.pre-2-2 b/ChangeLog.pre-2-2 index 2612854a3a..f0a46a7b8b 100644 --- a/ChangeLog.pre-2-2 +++ b/ChangeLog.pre-2-2 @@ -1,3 +1,15 @@ +2000-01-19 Tor Lillqvist + + * gdk/win32/gdkwindow-win32.c (gdk_window_clear_area): The correct + semantics (to mimic the X11 backend, which just calls XClearArea) + is to check for zero width (and height), and in that case use the + window's width minus x (height minus y). This fixes for instance + some redraw problems with gtkclist, which were easily noticeable + in the gtk file selection widget. + + (gdk_window_new): Don't set WS_EX_TOPMOST for dialog + windows. + 2000-01-13 Tor Lillqvist * configure.in diff --git a/ChangeLog.pre-2-4 b/ChangeLog.pre-2-4 index 2612854a3a..f0a46a7b8b 100644 --- a/ChangeLog.pre-2-4 +++ b/ChangeLog.pre-2-4 @@ -1,3 +1,15 @@ +2000-01-19 Tor Lillqvist + + * gdk/win32/gdkwindow-win32.c (gdk_window_clear_area): The correct + semantics (to mimic the X11 backend, which just calls XClearArea) + is to check for zero width (and height), and in that case use the + window's width minus x (height minus y). This fixes for instance + some redraw problems with gtkclist, which were easily noticeable + in the gtk file selection widget. + + (gdk_window_new): Don't set WS_EX_TOPMOST for dialog + windows. + 2000-01-13 Tor Lillqvist * configure.in diff --git a/ChangeLog.pre-2-6 b/ChangeLog.pre-2-6 index 2612854a3a..f0a46a7b8b 100644 --- a/ChangeLog.pre-2-6 +++ b/ChangeLog.pre-2-6 @@ -1,3 +1,15 @@ +2000-01-19 Tor Lillqvist + + * gdk/win32/gdkwindow-win32.c (gdk_window_clear_area): The correct + semantics (to mimic the X11 backend, which just calls XClearArea) + is to check for zero width (and height), and in that case use the + window's width minus x (height minus y). This fixes for instance + some redraw problems with gtkclist, which were easily noticeable + in the gtk file selection widget. + + (gdk_window_new): Don't set WS_EX_TOPMOST for dialog + windows. + 2000-01-13 Tor Lillqvist * configure.in diff --git a/ChangeLog.pre-2-8 b/ChangeLog.pre-2-8 index 2612854a3a..f0a46a7b8b 100644 --- a/ChangeLog.pre-2-8 +++ b/ChangeLog.pre-2-8 @@ -1,3 +1,15 @@ +2000-01-19 Tor Lillqvist + + * gdk/win32/gdkwindow-win32.c (gdk_window_clear_area): The correct + semantics (to mimic the X11 backend, which just calls XClearArea) + is to check for zero width (and height), and in that case use the + window's width minus x (height minus y). This fixes for instance + some redraw problems with gtkclist, which were easily noticeable + in the gtk file selection widget. + + (gdk_window_new): Don't set WS_EX_TOPMOST for dialog + windows. + 2000-01-13 Tor Lillqvist * configure.in diff --git a/gdk/win32/gdkwindow-win32.c b/gdk/win32/gdkwindow-win32.c index f77b98cf88..fb6dd461a4 100644 --- a/gdk/win32/gdkwindow-win32.c +++ b/gdk/win32/gdkwindow-win32.c @@ -364,7 +364,9 @@ gdk_window_new (GdkWindow *parent, break; case GDK_WINDOW_DIALOG: dwStyle = WS_OVERLAPPED | WS_MINIMIZEBOX | WS_SYSMENU | WS_CAPTION | WS_THICKFRAME | WS_CLIPCHILDREN; +#if 0 dwExStyle |= WS_EX_TOPMOST; /* //HB: want this? */ +#endif xparent = gdk_root_window; break; case GDK_WINDOW_TEMP: @@ -1019,10 +1021,10 @@ gdk_window_clear_area (GdkWindow *window, { HDC hdc; - if (width == -1) - width = G_MAXSHORT/2; /* Yeah, right */ - if (height == -1) - height = G_MAXSHORT/2; + if (width == 0) + width = ((GdkDrawablePrivate *) window)->width - x; + if (height == 0) + height = ((GdkDrawablePrivate *) window)->height - y; GDK_NOTE (MISC, g_print ("gdk_window_clear_area: %#x %dx%d@+%d+%d\n", GDK_DRAWABLE_XID (window), width, height, x, y)); hdc = GetDC (GDK_DRAWABLE_XID (window)); @@ -1341,7 +1343,7 @@ gdk_window_set_title (GdkWindow *window, GDK_DRAWABLE_XID (window), title)); if (!GDK_DRAWABLE_DESTROYED (window)) { - /* As the title most is in UTF-8 we must translate it + /* As the title is in UTF-8 we must translate it * to the system codepage. */ titlelen = strlen (title);