[gtk-theme-engine-clearlooks] Wrap radio/checkbutton rendering in cairo_save/restore
- From: Carlos Garnacho <carlosg src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk-theme-engine-clearlooks] Wrap radio/checkbutton rendering in cairo_save/restore
- Date: Mon, 6 Dec 2010 21:22:27 +0000 (UTC)
commit 140ddfa212d64ae90fb3ec395dbb2482f203962f
Author: Carlos Garnacho <carlosg gnome org>
Date: Tue Nov 30 02:52:20 2010 +0100
Wrap radio/checkbutton rendering in cairo_save/restore
src/clearlooks_draw.c | 7 +++++++
1 files changed, 7 insertions(+), 0 deletions(-)
---
diff --git a/src/clearlooks_draw.c b/src/clearlooks_draw.c
index 575fe2a..99d5337 100644
--- a/src/clearlooks_draw.c
+++ b/src/clearlooks_draw.c
@@ -2489,6 +2489,8 @@ clearlooks_draw_radiobutton (cairo_t *cr,
cy = height / 2.0;
radius = MIN (width, height) / 2.0;
+ cairo_save (cr);
+
state = gtk_theming_engine_get_state (engine);
gtk_theming_engine_get (engine, state,
@@ -2574,6 +2576,7 @@ clearlooks_draw_radiobutton (cairo_t *cr,
}
}
+ cairo_restore (cr);
gdk_rgba_free ((GdkRGBA *) bg_color);
}
@@ -2594,6 +2597,8 @@ clearlooks_draw_checkbox (cairo_t *cr,
draw_bullet = (state & GTK_STATE_FLAG_ACTIVE);
draw_bullet |= inconsistent;
+ cairo_save (cr);
+
gtk_theming_engine_get (engine, state,
"border-radius", &radius,
"background-color", &bg_color,
@@ -2669,6 +2674,8 @@ clearlooks_draw_checkbox (cairo_t *cr,
cairo_stroke (cr);
}
+ cairo_restore (cr);
+
gdk_rgba_free ((GdkRGBA *) bg_color);
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]