[perl-Cairo] Wrap cairo_in_clip
- From: Torsten Schönfeld <tsch src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [perl-Cairo] Wrap cairo_in_clip
- Date: Sun, 1 May 2011 18:03:07 +0000 (UTC)
commit f67949066e757405472f2f03fccc5f9fae91d6af
Author: Torsten Schönfeld <kaffeetisch gmx de>
Date: Sun May 1 17:30:19 2011 +0200
Wrap cairo_in_clip
Cairo.xs | 6 ++++++
t/Cairo.t | 9 ++++++++-
2 files changed, 14 insertions(+), 1 deletions(-)
---
diff --git a/Cairo.xs b/Cairo.xs
index b8bb1a9..1dde8f6 100644
--- a/Cairo.xs
+++ b/Cairo.xs
@@ -548,6 +548,12 @@ void cairo_clip_extents (cairo_t *cr, OUTLIST double x1, OUTLIST double y1, OUTL
#endif
+#if CAIRO_VERSION >= CAIRO_VERSION_ENCODE(1, 10, 0)
+
+cairo_bool_t cairo_in_clip (cairo_t *cr, double x, double y);
+
+#endif
+
void cairo_reset_clip (cairo_t *cr);
void cairo_select_font_face (cairo_t *cr, const char *family, cairo_font_slant_t slant, cairo_font_weight_t weight);
diff --git a/t/Cairo.t b/t/Cairo.t
index 9194b6a..440611e 100644
--- a/t/Cairo.t
+++ b/t/Cairo.t
@@ -10,7 +10,7 @@
use strict;
use warnings;
-use Test::More tests => 74;
+use Test::More tests => 75;
unless (eval 'use Test::Number::Delta; 1;') {
my $reason = 'Test::Number::Delta not available';
@@ -174,6 +174,13 @@ $cr->clip_preserve;
$cr->reset_clip;
SKIP: {
+ skip 'new stuff', 1
+ unless Cairo::VERSION >= Cairo::VERSION_ENCODE (1, 10, 0);
+
+ ok ($cr->in_clip (23, 42));
+}
+
+SKIP: {
skip 'new stuff', 7
unless Cairo::VERSION >= Cairo::VERSION_ENCODE (1, 4, 0);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]