murrine r128 - in trunk: . src
- From: acimitan svn gnome org
- To: svn-commits-list gnome org
- Subject: murrine r128 - in trunk: . src
- Date: Mon, 5 Jan 2009 17:44:27 +0000 (UTC)
Author: acimitan
Date: Mon Jan 5 17:44:27 2009
New Revision: 128
URL: http://svn.gnome.org/viewvc/murrine?rev=128&view=rev
Log:
2009-01-05 Andrea Cimitan <andrea cimitan gmail com>
* src/murrine_draw.c (murrine_draw_button),
(murrine_draw_scrollbar_stepper), (murrine_draw_scrollbar_slider),
(murrine_draw_radiobutton), (murrine_draw_checkbox):
* src/murrine_draw_rgba.c (murrine_rgba_draw_button),
(murrine_rgba_draw_progressbar_fill),
(murrine_rgba_draw_scrollbar_stepper),
(murrine_rgba_draw_scrollbar_slider),
(murrine_rgba_draw_radiobutton), (murrine_rgba_draw_checkbox):
Fixed rounded scrollbars's corners.
Various changes in cairo operators in rgba mode, I hope
that everything renders correctly as before, I can't test it now.
Modified:
trunk/ChangeLog
trunk/src/murrine_draw.c
trunk/src/murrine_draw_rgba.c
Modified: trunk/src/murrine_draw.c
==============================================================================
--- trunk/src/murrine_draw.c (original)
+++ trunk/src/murrine_draw.c Mon Jan 5 17:44:27 2009
@@ -187,10 +187,9 @@
murrine_mix_color (&border, &fill, 0.4, &border);
- /* Draw the bg */
- murrine_rounded_rectangle_closed (cr, xos+1, yos+1, width-(xos*2)-2, height-(yos*2)-2, widget->roundness-1, widget->corners);
-
cairo_save (cr);
+
+ murrine_rounded_rectangle_closed (cr, xos+1, yos+1, width-(xos*2)-2, height-(yos*2)-2, widget->roundness-1, widget->corners);
cairo_clip_preserve (cr);
murrine_draw_glaze (cr, &fill,
@@ -213,7 +212,6 @@
murrine_rounded_rectangle_closed (cr, xos+1, yos+1, width-(xos*2)-2, height-(yos*2)-2, widget->roundness-1,
widget->corners & (MRN_CORNER_TOPLEFT | MRN_CORNER_TOPRIGHT | MRN_CORNER_BOTTOMLEFT));
-
cairo_clip (cr);
cairo_rectangle (cr, xos+1, yos+1, width-(xos*2)-2, 3);
@@ -1393,10 +1391,9 @@
cairo_translate (cr, x, y);
- /* Draw the bg */
- murrine_rounded_rectangle_closed (cr, 1, 1, width-2, height-2, widget->roundness-1, widget->corners);
-
cairo_save (cr);
+
+ murrine_rounded_rectangle_closed (cr, 1, 1, width-2, height-2, widget->roundness-1, widget->corners);
cairo_clip_preserve(cr);
murrine_draw_glaze (cr, fill,
@@ -1464,7 +1461,10 @@
width = tmp;
}
+ cairo_save (cr);
+
murrine_rounded_rectangle_closed (cr, 1, 1, width-2, height-2, widget->roundness, widget->corners);
+ cairo_clip_preserve (cr);
murrine_draw_glaze (cr, &fill,
widget->glow_shade, widget->highlight_shade, widget->lightborder_shade,
@@ -1552,6 +1552,8 @@
}
}
+ cairo_restore (cr);
+
murrine_set_color_rgb (cr, &border);
murrine_rounded_rectangle (cr, 0.5, 0.5, width-1, height-1, widget->roundness, widget->corners);
cairo_stroke (cr);
@@ -1890,6 +1892,7 @@
murrine_rounded_rectangle_closed (cr, 1.5, 1.5, width-3, height-3, roundness, widget->corners);
cairo_clip_preserve (cr);
+
if (draw_bullet)
{
murrine_draw_glaze (cr, bg,
@@ -1995,6 +1998,7 @@
murrine_rounded_rectangle_closed (cr, 1.5, 1.5, width-3, height-3, roundness, widget->corners);
cairo_clip_preserve (cr);
+
if (draw_bullet)
{
murrine_draw_glaze (cr, bg,
Modified: trunk/src/murrine_draw_rgba.c
==============================================================================
--- trunk/src/murrine_draw_rgba.c (original)
+++ trunk/src/murrine_draw_rgba.c Mon Jan 5 17:44:27 2009
@@ -186,12 +186,11 @@
murrine_mix_color (&border, &widget->parentbg, 0.2, &border);
murrine_mix_color (&border, &fill, 0.25, &border);
- /* Draw the bg */
- murrine_rounded_rectangle_closed (cr, xos+1, yos+1, width-(xos*2)-2, height-(yos*2)-2, widget->roundness-1, widget->corners);
-
cairo_save (cr);
+
cairo_set_operator (cr, CAIRO_OPERATOR_SOURCE);
+ murrine_rounded_rectangle_closed (cr, xos+1, yos+1, width-(xos*2)-2, height-(yos*2)-2, widget->roundness-1, widget->corners);
cairo_clip_preserve (cr);
murrine_draw_glaze (cr, &fill,
@@ -199,8 +198,6 @@
mrn_gradient_custom, widget, xos+1, yos+1, width-(xos*2)-2, height-(yos*2)-2,
widget->roundness, widget->corners, horizontal);
- cairo_set_operator (cr, CAIRO_OPERATOR_OVER);
-
cairo_restore (cr);
/* Draw pressed button shadow */
@@ -215,7 +212,6 @@
murrine_rounded_rectangle_closed (cr, xos+1, yos+1, width-(xos*2)-2, height-(yos*2)-2, widget->roundness-1,
widget->corners & (MRN_CORNER_TOPLEFT | MRN_CORNER_TOPRIGHT | MRN_CORNER_BOTTOMLEFT));
-
cairo_clip (cr);
cairo_rectangle (cr, xos+1, yos+1, width-(xos*2)-2, 3);
@@ -498,6 +494,7 @@
x_step = (((float)stroke_width/10)*offset);
cairo_save (cr);
+
cairo_set_operator (cr, CAIRO_OPERATOR_SOURCE);
murrine_rounded_rectangle_closed (cr, 2, 1, width-4+roundness, height-2,
@@ -514,6 +511,8 @@
widget->mrn_gradient, widget, 2, 1, width-4, height-2,
roundness, widget->corners, TRUE);
+ cairo_set_operator (cr, CAIRO_OPERATOR_OVER);
+
switch (progressbar->style)
{
case 0:
@@ -1187,12 +1186,11 @@
cairo_translate (cr, x, y);
+ cairo_save (cr);
+
cairo_set_operator (cr, CAIRO_OPERATOR_SOURCE);
- /* Draw the bg */
murrine_rounded_rectangle_closed (cr, 1, 1, width-2, height-2, widget->roundness-1, widget->corners);
-
- cairo_save (cr);
cairo_clip_preserve(cr);
murrine_draw_glaze (cr, fill,
@@ -1260,9 +1258,12 @@
width = tmp;
}
+ cairo_save (cr);
+
cairo_set_operator (cr, CAIRO_OPERATOR_SOURCE);
murrine_rounded_rectangle_closed (cr, 1, 1, width-2, height-2, widget->roundness, widget->corners);
+ cairo_clip_preserve (cr);
murrine_draw_glaze (cr, &fill,
widget->glow_shade, widget->highlight_shade, widget->lightborder_shade,
@@ -1274,6 +1275,8 @@
if (scrollbar->style > 0)
murrine_shade (&fill, 0.55, &style);
+ cairo_set_operator (cr, CAIRO_OPERATOR_OVER);
+
switch (scrollbar->style)
{
case 1:
@@ -1350,6 +1353,8 @@
}
}
+ cairo_restore (cr);
+
murrine_set_color_rgb (cr, &border);
murrine_rounded_rectangle (cr, 0.5, 0.5, width-1, height-1, widget->roundness, widget->corners);
cairo_stroke (cr);
@@ -1498,6 +1503,7 @@
murrine_rounded_rectangle_closed (cr, 1.5, 1.5, width-3, height-3, roundness, widget->corners);
cairo_clip_preserve (cr);
+
if (draw_bullet)
{
murrine_draw_glaze (cr, bg,
@@ -1605,6 +1611,7 @@
murrine_rounded_rectangle_closed (cr, 1.5, 1.5, width-3, height-3, roundness, widget->corners);
cairo_clip_preserve (cr);
+
if (draw_bullet)
{
murrine_draw_glaze (cr, bg,
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]