murrine r120 - in trunk: . src



Author: acimitan
Date: Sat Jan  3 02:10:45 2009
New Revision: 120
URL: http://svn.gnome.org/viewvc/murrine?rev=120&view=rev

Log:
2009-01-03  Andrea Cimitan  <andrea cimitan gmail com>

	* src/murrine_draw.c (murrine_draw_button):
	* src/murrine_draw_rgba.c (murrine_rgba_draw_button):
	Small performance improvement in button's drawing.


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	Sat Jan  3 02:10:45 2009
@@ -174,10 +174,10 @@
 
 	cairo_translate (cr, x, y);
 
-	if (!widget->active && !widget->disabled && widget->reliefstyle > 1)
+	if (!widget->active && !widget->disabled && widget->reliefstyle > 1 && xos >= 0.5 && yos >= 0.5)
 	{
-		murrine_rounded_rectangle (cr, xos, yos, width-(xos*2), height-(yos*2), widget->roundness, widget->corners);
-		murrine_set_color_rgba (cr, &border, 0.18);
+		murrine_rounded_rectangle (cr, xos-0.5, yos-0.5, width-(xos*2)+1, height-(yos*2)+1, widget->roundness+1, widget->corners);
+		murrine_set_color_rgba (cr, &border, 0.08);
 		cairo_stroke (cr);
 	}
 	else if (widget->reliefstyle != 0 && xos >= 0.5 && yos >= 0.5)

Modified: trunk/src/murrine_draw_rgba.c
==============================================================================
--- trunk/src/murrine_draw_rgba.c	(original)
+++ trunk/src/murrine_draw_rgba.c	Sat Jan  3 02:10:45 2009
@@ -172,10 +172,10 @@
 
 	cairo_translate (cr, x, y);
 
-	if (!widget->active && !widget->disabled && widget->reliefstyle > 1)
+	if (!widget->active && !widget->disabled && widget->reliefstyle > 1 && xos >= 0.5 && yos >= 0.5)
 	{
-		murrine_rounded_rectangle (cr, xos, yos, width-(xos*2), height-(yos*2), widget->roundness, widget->corners);
-		murrine_set_color_rgba (cr, &border, 0.16);
+		murrine_rounded_rectangle (cr, xos-0.5, yos-0.5, width-(xos*2)+1, height-(yos*2)+1, widget->roundness+1, widget->corners);
+		murrine_set_color_rgba (cr, &border, 0.08);
 		cairo_stroke (cr);
 	}
 	else if (widget->reliefstyle != 0 && xos >= 0.5 && yos >= 0.5)



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]