diff --git a/modules/engines/ms-windows/ChangeLog.old b/modules/engines/ms-windows/ChangeLog.old index 467e844f42..4c3fd665f0 100755 --- a/modules/engines/ms-windows/ChangeLog.old +++ b/modules/engines/ms-windows/ChangeLog.old @@ -2,7 +2,9 @@ * src/wimp_style.c: Fixed typ-o (gtk-double-cliNk-time), adjusted cursor blink time to cope with Windows semantics (GTK+ uses cycle - time), fixed clipping area computation. + time), fixed clipping area computation. Fixed XP tree expanders to + cope with clipping area, and made non-XP tree expanders look + pixel-perfect. 2003-09-15 Dom Lachowicz diff --git a/modules/engines/ms-windows/Theme/gtk-2.0/gtkrc b/modules/engines/ms-windows/Theme/gtk-2.0/gtkrc index 3f9fe8607e..f4f2bc2ba0 100755 --- a/modules/engines/ms-windows/Theme/gtk-2.0/gtkrc +++ b/modules/engines/ms-windows/Theme/gtk-2.0/gtkrc @@ -9,6 +9,7 @@ style "wimp-default" GtkSpinButton::shadow-type = in GtkTreeView::allow-rules = 0 + GtkTreeView::expander_size = 11 engine "wimp" { diff --git a/modules/engines/ms-windows/wimp_style.c b/modules/engines/ms-windows/wimp_style.c index 62d6fca184..d1b90432be 100755 --- a/modules/engines/ms-windows/wimp_style.c +++ b/modules/engines/ms-windows/wimp_style.c @@ -644,16 +644,12 @@ draw_expander(GtkStyle *style, break; } - if (xp_theme_draw(window, xp_expander, style, - x, y - expander_size / 2, - expander_size, expander_size, state, area)) - { - return; - } + if ((expander_size % 2) == 0) + expander_size--; if (expander_size > 2) expander_size -= 2; - + if (area) gdk_gc_set_clip_rectangle (style->fg_gc[state], area); @@ -663,6 +659,13 @@ draw_expander(GtkStyle *style, gdk_gc_get_values (style->fg_gc[state], &values); + if (xp_theme_draw(window, xp_expander, style, + x, y, + expander_size, expander_size, state, area)) + { + return; + } + /* RGB values to emulate Windows Classic style */ color.red = color.green = color.blue = 128 << 8; @@ -673,7 +676,8 @@ draw_expander(GtkStyle *style, gdk_gc_set_foreground (style->fg_gc[state], &color); gdk_draw_rectangle - (window, style->fg_gc[state], FALSE, x, y, expander_size, expander_size); + (window, style->fg_gc[state], FALSE, x, y, + expander_size - 1, expander_size - 1); if (success) gdk_gc_set_foreground (style->fg_gc[state], &values.foreground);