[cairo-commit] cairo-perl ChangeLog, 1.83, 1.84 CairoSurface.xs, 1.22, 1.23
Torsten Schoenfeld
commit at pdx.freedesktop.org
Mon Jan 7 09:34:11 PST 2008
Committed by: tsch
Update of /cvs/cairo/cairo-perl
In directory kemper:/tmp/cvs-serv5083
Modified Files:
ChangeLog CairoSurface.xs
Log Message:
* CairoSurface.xs
* t/CairoSurface.t: Wrap cairo_ps_surface_restrict_to_level,
cairo_ps_get_levels, and cairo_ps_level_to_string.
Index: ChangeLog
===================================================================
RCS file: /cvs/cairo/cairo-perl/ChangeLog,v
retrieving revision 1.83
retrieving revision 1.84
diff -u -d -r1.83 -r1.84
--- ChangeLog 7 Jan 2008 17:13:33 -0000 1.83
+++ ChangeLog 7 Jan 2008 17:34:09 -0000 1.84
@@ -4,6 +4,10 @@
* t/CairoSurface.t: Wrap cairo_surface_copy_page and
cairo_surface_show_page.
+ * CairoSurface.xs
+ * t/CairoSurface.t: Wrap cairo_ps_surface_restrict_to_level,
+ cairo_ps_get_levels, and cairo_ps_level_to_string.
+
2007-12-29 Torsten Schoenfeld <kaffeetisch at gmx.de>
* Cairo.xs
Index: CairoSurface.xs
===================================================================
RCS file: /cvs/cairo/cairo-perl/CairoSurface.xs,v
retrieving revision 1.22
retrieving revision 1.23
diff -u -d -r1.22 -r1.23
--- CairoSurface.xs 7 Jan 2008 17:13:33 -0000 1.22
+++ CairoSurface.xs 7 Jan 2008 17:34:09 -0000 1.23
@@ -504,6 +504,40 @@
#endif
+#if CAIRO_VERSION >= CAIRO_VERSION_ENCODE(1, 5, 2) /* FIXME: 1.6 */
+
+void cairo_ps_surface_restrict_to_level (cairo_surface_t *surface, cairo_ps_level_t level);
+
+# void cairo_ps_get_levels (cairo_ps_level_t const **levels, int *num_levels);
+void
+cairo_ps_surface_get_levels (class=NULL)
+ PREINIT:
+ cairo_ps_level_t const *levels = NULL;
+ int num_levels = 0, i;
+ PPCODE:
+ PERL_UNUSED_VAR (ax);
+ cairo_ps_get_levels (&levels, &num_levels);
+ EXTEND (sp, num_levels);
+ for (i = 0; i < num_levels; i++)
+ PUSHs (sv_2mortal (newSVCairoPsLevel (levels[i])));
+
+# const char * cairo_ps_level_to_string (cairo_ps_level_t level);
+const char *
+cairo_ps_surface_level_to_string (...)
+ CODE:
+ if (items == 1) {
+ RETVAL = cairo_ps_level_to_string (SvCairoPsLevel (ST (0)));
+ } else if (items == 2) {
+ RETVAL = cairo_ps_level_to_string (SvCairoPsLevel (ST (1)));
+ } else {
+ RETVAL = NULL;
+ croak ("Usage: Cairo::PsSurface::level_to_string (level) or Cairo::PsSurface->level_to_string (level)");
+ }
+ OUTPUT:
+ RETVAL
+
+#endif
+
#endif
# --------------------------------------------------------------------------- #
More information about the cairo-commit
mailing list