[cairo-commit] cairo-demo/cairo_snippets/snippets arc.cairo, 1.1,
1.2 arc_negative.cairo, 1.1, 1.2 curve_rectangle.cairo, 1.2,
1.3 curve_to.cairo, 1.1, 1.2 operator_add.cairo, 1.1,
1.2 operator_atop.cairo, 1.1, 1.2 operator_atop_reverse.cairo,
1.1, 1.2 operator_in.cairo, 1.1, 1.2 operator_in_reverse.cairo,
1.1, 1.2 operator_out.cairo, 1.1,
1.2 operator_out_reverse.cairo, 1.1, 1.2 operator_over.cairo,
1.1, 1.2 operator_over_reverse.cairo, 1.1,
1.2 operator_saturate.cairo, 1.1, 1.2 operator_xor.cairo, 1.1,
1.2 text.cairo, 1.1, 1.2 text_align_center.cairo, 1.1,
1.2 text_extents.cairo, 1.1, 1.2
Carl Worth
commit at pdx.freedesktop.org
Thu Apr 21 14:05:24 PDT 2005
- Previous message: [cairo-commit] cairo-demo/cairo_snippets ChangeLog, 1.31,
1.32 cairo_snippets_pdf.c, 1.5, 1.6 cairo_snippets_ps.c, 1.3,
1.4 prepare_snippets.c, 1.6, 1.7
- Next message: [cairo-commit] talks/lca_2005_04_22 - New directory,NONE,NONE
- Messages sorted by:
[ date ]
[ thread ]
[ subject ]
[ author ]
Committed by: cworth
Update of /cvs/cairo/cairo-demo/cairo_snippets/snippets
In directory gabe:/tmp/cvs-serv7501/snippets
Modified Files:
arc.cairo arc_negative.cairo curve_rectangle.cairo
curve_to.cairo operator_add.cairo operator_atop.cairo
operator_atop_reverse.cairo operator_in.cairo
operator_in_reverse.cairo operator_out.cairo
operator_out_reverse.cairo operator_over.cairo
operator_over_reverse.cairo operator_saturate.cairo
operator_xor.cairo text.cairo text_align_center.cairo
text_extents.cairo
Log Message:
* cairo_snippets_pdf.c:
* cairo_snippets_ps.c:
* prepare_snippets.c: (make_util):
* snippets/arc.cairo:
* snippets/arc_negative.cairo:
* snippets/curve_rectangle.cairo:
* snippets/curve_to.cairo:
* snippets/operator_add.cairo:
* snippets/operator_atop.cairo:
* snippets/operator_atop_reverse.cairo:
* snippets/operator_in.cairo:
* snippets/operator_in_reverse.cairo:
* snippets/operator_out.cairo:
* snippets/operator_out_reverse.cairo:
* snippets/operator_over.cairo:
* snippets/operator_over_reverse.cairo:
* snippets/operator_saturate.cairo:
* snippets/operator_xor.cairo:
* snippets/text.cairo:
* snippets/text_align_center.cairo:
* snippets/text_extents.cairo: Update for changes in the cairo
API, including:
Use 72.0 scale factor instead of 96.0
Use unsigned char as appropriate
Use cairo_set_source_rgba instead of cairo_set_rgb_color
and cairo_set_alpha.
Index: arc.cairo
===================================================================
RCS file: /cvs/cairo/cairo-demo/cairo_snippets/snippets/arc.cairo,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -d -r1.1 -r1.2
--- arc.cairo 1 Feb 2005 22:58:09 -0000 1.1
+++ arc.cairo 21 Apr 2005 21:05:22 -0000 1.2
@@ -10,8 +10,7 @@
cairo_stroke (cr);
/* draw helping lines */
-cairo_set_rgb_color (cr, 1,0.2,0.2);
-cairo_set_alpha (cr, 0.6);
+cairo_set_source_rgba (cr, 1,0.2,0.2,0.6);
cairo_arc (cr, xc, yc, 0.05, 0, 2*M_PI);
cairo_fill (cr);
cairo_set_line_width (cr, 0.03);
Index: arc_negative.cairo
===================================================================
RCS file: /cvs/cairo/cairo-demo/cairo_snippets/snippets/arc_negative.cairo,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -d -r1.1 -r1.2
--- arc_negative.cairo 1 Feb 2005 22:58:09 -0000 1.1
+++ arc_negative.cairo 21 Apr 2005 21:05:22 -0000 1.2
@@ -10,8 +10,7 @@
cairo_stroke (cr);
/* draw helping lines */
-cairo_set_rgb_color (cr, 1,0.2,0.2);
-cairo_set_alpha (cr, 0.6);
+cairo_set_source_rgba (cr, 1,0.2,0.2,0.6);
cairo_arc (cr, xc, yc, 0.05, 0, 2*M_PI);
cairo_fill (cr);
cairo_set_line_width (cr, 0.03);
Index: curve_rectangle.cairo
===================================================================
RCS file: /cvs/cairo/cairo-demo/cairo_snippets/snippets/curve_rectangle.cairo,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -d -r1.2 -r1.3
--- curve_rectangle.cairo 2 Feb 2005 04:46:43 -0000 1.2
+++ curve_rectangle.cairo 21 Apr 2005 21:05:22 -0000 1.3
@@ -55,6 +55,5 @@
cairo_set_rgb_color (cr, 0.5,0.5,1);
cairo_fill (cr);
cairo_restore (cr);
-cairo_set_alpha (cr, 0.5);
-cairo_set_rgb_color (cr, 0.5, 0,0);
+cairo_set_source_rgba (cr, 0.5, 0, 0, 0.5);
cairo_stroke (cr);
Index: curve_to.cairo
===================================================================
RCS file: /cvs/cairo/cairo-demo/cairo_snippets/snippets/curve_to.cairo,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -d -r1.1 -r1.2
--- curve_to.cairo 1 Feb 2005 22:58:09 -0000 1.1
+++ curve_to.cairo 21 Apr 2005 21:05:22 -0000 1.2
@@ -10,8 +10,7 @@
cairo_stroke (cr);
-cairo_set_rgb_color (cr, 1,0.2,0.2);
-cairo_set_alpha (cr, 0.6);
+cairo_set_source_rgba (cr, 1,0.2,0.2,0.6);
cairo_set_line_width (cr, 0.03);
cairo_move_to (cr,x,y); cairo_line_to (cr,x1,y1);
cairo_move_to (cr,x2,y2); cairo_line_to (cr,x3,y3);
Index: operator_add.cairo
===================================================================
RCS file: /cvs/cairo/cairo-demo/cairo_snippets/snippets/operator_add.cairo,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -d -r1.1 -r1.2
--- operator_add.cairo 1 Feb 2005 22:58:09 -0000 1.1
+++ operator_add.cairo 21 Apr 2005 21:05:22 -0000 1.2
@@ -2,8 +2,7 @@
snippet_set_bg_svg (cr, "data/freedesktop.svg");
cairo_set_operator (cr, CAIRO_OPERATOR_ADD);
-cairo_set_alpha (cr, 0.5);
-cairo_set_rgb_color (cr, 1,0,0);
+cairo_set_source_rgba (cr, 1,0,0,0.5);
cairo_rectangle (cr, 0.2,0.2, 0.5,0.5);
cairo_fill (cr);
cairo_set_rgb_color (cr, 0,1,0);
Index: operator_atop.cairo
===================================================================
RCS file: /cvs/cairo/cairo-demo/cairo_snippets/snippets/operator_atop.cairo,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -d -r1.1 -r1.2
--- operator_atop.cairo 1 Feb 2005 22:58:09 -0000 1.1
+++ operator_atop.cairo 21 Apr 2005 21:05:22 -0000 1.2
@@ -2,8 +2,7 @@
snippet_set_bg_svg (cr, "data/freedesktop.svg");
cairo_set_operator (cr, CAIRO_OPERATOR_ATOP);
-cairo_set_alpha (cr, 0.5);
-cairo_set_rgb_color (cr, 1,0,0);
+cairo_set_source_rgba (cr, 1,0,0,0.5);
cairo_rectangle (cr, 0.2,0.2, 0.5,0.5);
cairo_fill (cr);
cairo_set_rgb_color (cr, 0,1,0);
Index: operator_atop_reverse.cairo
===================================================================
RCS file: /cvs/cairo/cairo-demo/cairo_snippets/snippets/operator_atop_reverse.cairo,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -d -r1.1 -r1.2
--- operator_atop_reverse.cairo 1 Feb 2005 22:58:09 -0000 1.1
+++ operator_atop_reverse.cairo 21 Apr 2005 21:05:22 -0000 1.2
@@ -1,8 +1,7 @@
snippet_normalize (cr, width, height);
snippet_set_bg_svg (cr, "data/freedesktop.svg");
cairo_set_operator (cr, CAIRO_OPERATOR_ATOP_REVERSE);
-cairo_set_alpha (cr, 0.5);
-cairo_set_rgb_color (cr, 1,0,0);
+cairo_set_source_rgba (cr, 1,0,0,0.5);
cairo_rectangle (cr, 0.2,0.2, 0.5,0.5);
cairo_fill (cr);
cairo_set_rgb_color (cr, 0,1,0);
Index: operator_in.cairo
===================================================================
RCS file: /cvs/cairo/cairo-demo/cairo_snippets/snippets/operator_in.cairo,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -d -r1.1 -r1.2
--- operator_in.cairo 1 Feb 2005 22:58:09 -0000 1.1
+++ operator_in.cairo 21 Apr 2005 21:05:22 -0000 1.2
@@ -1,8 +1,7 @@
snippet_normalize (cr, width, height);
snippet_set_bg_svg (cr, "data/freedesktop.svg");
cairo_set_operator (cr, CAIRO_OPERATOR_IN);
-cairo_set_alpha (cr, 0.5);
-cairo_set_rgb_color (cr, 1,0,0);
+cairo_set_source_rgba (cr, 1,0,0,0.5);
cairo_rectangle (cr, 0.2,0.2, 0.5,0.5);
cairo_fill (cr);
cairo_set_rgb_color (cr, 0,1,0);
Index: operator_in_reverse.cairo
===================================================================
RCS file: /cvs/cairo/cairo-demo/cairo_snippets/snippets/operator_in_reverse.cairo,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -d -r1.1 -r1.2
--- operator_in_reverse.cairo 1 Feb 2005 22:58:09 -0000 1.1
+++ operator_in_reverse.cairo 21 Apr 2005 21:05:22 -0000 1.2
@@ -1,8 +1,7 @@
snippet_normalize (cr, width, height);
snippet_set_bg_svg (cr, "data/freedesktop.svg");
cairo_set_operator (cr, CAIRO_OPERATOR_IN_REVERSE);
-cairo_set_alpha (cr, 0.5);
-cairo_set_rgb_color (cr, 1,0,0);
+cairo_set_source_rgba (cr, 1,0,0,0.5);
cairo_rectangle (cr, 0.2,0.2, 0.5,0.5);
cairo_fill (cr);
cairo_set_rgb_color (cr, 0,1,0);
Index: operator_out.cairo
===================================================================
RCS file: /cvs/cairo/cairo-demo/cairo_snippets/snippets/operator_out.cairo,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -d -r1.1 -r1.2
--- operator_out.cairo 1 Feb 2005 22:58:09 -0000 1.1
+++ operator_out.cairo 21 Apr 2005 21:05:22 -0000 1.2
@@ -1,8 +1,7 @@
snippet_normalize (cr, width, height);
snippet_set_bg_svg (cr, "data/freedesktop.svg");
cairo_set_operator (cr, CAIRO_OPERATOR_OUT);
-cairo_set_alpha (cr, 0.5);
-cairo_set_rgb_color (cr, 1,0,0);
+cairo_set_source_rgba (cr, 1,0,0,0.5);
cairo_rectangle (cr, 0.2,0.2, 0.5,0.5);
cairo_fill (cr);
cairo_set_rgb_color (cr, 0,1,0);
Index: operator_out_reverse.cairo
===================================================================
RCS file: /cvs/cairo/cairo-demo/cairo_snippets/snippets/operator_out_reverse.cairo,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -d -r1.1 -r1.2
--- operator_out_reverse.cairo 1 Feb 2005 22:58:09 -0000 1.1
+++ operator_out_reverse.cairo 21 Apr 2005 21:05:22 -0000 1.2
@@ -1,8 +1,7 @@
snippet_normalize (cr, width, height);
snippet_set_bg_svg (cr, "data/freedesktop.svg");
cairo_set_operator (cr, CAIRO_OPERATOR_OUT_REVERSE);
-cairo_set_alpha (cr, 0.5);
-cairo_set_rgb_color (cr, 1,0,0);
+cairo_set_source_rgba (cr, 1,0,0,0.5);
cairo_rectangle (cr, 0.2,0.2, 0.5,0.5);
cairo_fill (cr);
cairo_set_rgb_color (cr, 0,1,0);
Index: operator_over.cairo
===================================================================
RCS file: /cvs/cairo/cairo-demo/cairo_snippets/snippets/operator_over.cairo,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -d -r1.1 -r1.2
--- operator_over.cairo 1 Feb 2005 22:58:09 -0000 1.1
+++ operator_over.cairo 21 Apr 2005 21:05:22 -0000 1.2
@@ -1,8 +1,7 @@
snippet_normalize (cr, width, height);
snippet_set_bg_svg (cr, "data/freedesktop.svg");
cairo_set_operator (cr, CAIRO_OPERATOR_OVER);
-cairo_set_alpha (cr, 0.5);
-cairo_set_rgb_color (cr, 1,0,0);
+cairo_set_source_rgba (cr, 1,0,0,0.5);
cairo_rectangle (cr, 0.2,0.2, 0.5,0.5);
cairo_fill (cr);
cairo_set_rgb_color (cr, 0,1,0);
Index: operator_over_reverse.cairo
===================================================================
RCS file: /cvs/cairo/cairo-demo/cairo_snippets/snippets/operator_over_reverse.cairo,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -d -r1.1 -r1.2
--- operator_over_reverse.cairo 1 Feb 2005 22:58:09 -0000 1.1
+++ operator_over_reverse.cairo 21 Apr 2005 21:05:22 -0000 1.2
@@ -1,8 +1,7 @@
snippet_normalize (cr, width, height);
snippet_set_bg_svg (cr, "data/freedesktop.svg");
cairo_set_operator (cr, CAIRO_OPERATOR_OVER_REVERSE);
-cairo_set_alpha (cr, 0.5);
-cairo_set_rgb_color (cr, 1,0,0);
+cairo_set_source_rgba (cr, 1,0,0, 0.5);
cairo_rectangle (cr, 0.2,0.2, 0.5,0.5);
cairo_fill (cr);
cairo_set_rgb_color (cr, 0,1,0);
Index: operator_saturate.cairo
===================================================================
RCS file: /cvs/cairo/cairo-demo/cairo_snippets/snippets/operator_saturate.cairo,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -d -r1.1 -r1.2
--- operator_saturate.cairo 1 Feb 2005 22:58:09 -0000 1.1
+++ operator_saturate.cairo 21 Apr 2005 21:05:22 -0000 1.2
@@ -1,8 +1,7 @@
snippet_normalize (cr, width, height);
snippet_set_bg_svg (cr, "data/freedesktop.svg");
cairo_set_operator (cr, CAIRO_OPERATOR_SATURATE);
-cairo_set_alpha (cr, 0.5);
-cairo_set_rgb_color (cr, 1,0,0);
+cairo_set_source_rgba (cr, 1,0,0, 0.5);
cairo_rectangle (cr, 0.2,0.2, 0.5,0.5);
cairo_fill (cr);
cairo_set_rgb_color (cr, 0,1,0);
Index: operator_xor.cairo
===================================================================
RCS file: /cvs/cairo/cairo-demo/cairo_snippets/snippets/operator_xor.cairo,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -d -r1.1 -r1.2
--- operator_xor.cairo 1 Feb 2005 22:58:09 -0000 1.1
+++ operator_xor.cairo 21 Apr 2005 21:05:22 -0000 1.2
@@ -1,8 +1,7 @@
snippet_normalize (cr, width, height);
snippet_set_bg_svg (cr, "data/freedesktop.svg");
cairo_set_operator (cr, CAIRO_OPERATOR_XOR);
-cairo_set_alpha (cr, 0.5);
-cairo_set_rgb_color (cr, 1,0,0);
+cairo_set_source_rgba (cr, 1,0,0, 0.5);
cairo_rectangle (cr, 0.2,0.2, 0.5,0.5);
cairo_fill (cr);
cairo_set_rgb_color (cr, 0,1,0);
Index: text.cairo
===================================================================
RCS file: /cvs/cairo/cairo-demo/cairo_snippets/snippets/text.cairo,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -d -r1.1 -r1.2
--- text.cairo 1 Feb 2005 22:58:09 -0000 1.1
+++ text.cairo 21 Apr 2005 21:05:22 -0000 1.2
@@ -16,8 +16,7 @@
cairo_stroke (cr);
/* draw helping lines */
-cairo_set_rgb_color (cr, 1,0.2,0.2);
-cairo_set_alpha (cr, 0.6);
+cairo_set_source_rgba (cr, 1,0.2,0.2, 0.6);
cairo_arc (cr, 0.04, 0.53, 0.02, 0, 2*M_PI);
cairo_arc (cr, 0.27, 0.65, 0.02, 0, 2*M_PI);
cairo_fill (cr);
Index: text_align_center.cairo
===================================================================
RCS file: /cvs/cairo/cairo-demo/cairo_snippets/snippets/text_align_center.cairo,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -d -r1.1 -r1.2
--- text_align_center.cairo 1 Feb 2005 22:58:09 -0000 1.1
+++ text_align_center.cairo 21 Apr 2005 21:05:22 -0000 1.2
@@ -18,8 +18,7 @@
cairo_show_text (cr, utf8);
/* draw helping lines */
-cairo_set_rgb_color (cr, 1,0.2,0.2);
-cairo_set_alpha (cr, 0.6);
+cairo_set_source_rgba (cr, 1,0.2,0.2, 0.6);
cairo_arc (cr, x, y, 0.05, 0, 2*M_PI);
cairo_fill (cr);
cairo_move_to (cr, 0.5, 0);
Index: text_extents.cairo
===================================================================
RCS file: /cvs/cairo/cairo-demo/cairo_snippets/snippets/text_extents.cairo,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -d -r1.1 -r1.2
--- text_extents.cairo 1 Feb 2005 22:58:09 -0000 1.1
+++ text_extents.cairo 21 Apr 2005 21:05:22 -0000 1.2
@@ -19,8 +19,7 @@
cairo_show_text (cr, utf8);
/* draw helping lines */
-cairo_set_rgb_color (cr, 1,0.2,0.2);
-cairo_set_alpha (cr, 0.6);
+cairo_set_source_rgba (cr, 1,0.2,0.2, 0.6);
cairo_arc (cr, x, y, 0.05, 0, 2*M_PI);
cairo_fill (cr);
cairo_move_to (cr, x,y);
- Previous message: [cairo-commit] cairo-demo/cairo_snippets ChangeLog, 1.31,
1.32 cairo_snippets_pdf.c, 1.5, 1.6 cairo_snippets_ps.c, 1.3,
1.4 prepare_snippets.c, 1.6, 1.7
- Next message: [cairo-commit] talks/lca_2005_04_22 - New directory,NONE,NONE
- Messages sorted by:
[ date ]
[ thread ]
[ subject ]
[ author ]
More information about the cairo-commit
mailing list