diff options
Diffstat (limited to 'examples/cairo_snippets/snippets/fill_and_stroke.py')
-rwxr-xr-x | examples/cairo_snippets/snippets/fill_and_stroke.py | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/examples/cairo_snippets/snippets/fill_and_stroke.py b/examples/cairo_snippets/snippets/fill_and_stroke.py new file mode 100755 index 0000000..6d66192 --- /dev/null +++ b/examples/cairo_snippets/snippets/fill_and_stroke.py @@ -0,0 +1,12 @@ +snippet_normalize (cr, width, height) + +cr.move_to (0.5, 0.1) +cr.line_to (0.9, 0.9) +cr.rel_line_to (-0.4, 0.0) +cr.curve_to (0.2, 0.9, 0.2, 0.5, 0.5, 0.5) +cr.close_path() + +cr.set_source_rgb (0, 0, 1) +cr.fill_preserve () +cr.set_source_rgb (0, 0, 0) +cr.stroke () |