enabled cairo
[monky] / lua / cairo.pkg
index a2cd91a..3058d41 100644 (file)
@@ -2,7 +2,10 @@ $#include <cairo-features.h>
 $#include <cairo-deprecated.h>
 $#include <cairo.h>
 $#include <cairo-xlib.h>
+/*$#include <cairo-qt.h>*/
 $#include <X11/Xlib.h>
+$#include "libcairo-helper.h"
+/*$#include <gdk/gdk.h>*/
 /*
  * This code was mostly copied from cairo.h and cairo-xlib.h with comments
  * removed.  The licence noticed below is present for the sake of clarity.
@@ -59,6 +62,7 @@ typedef struct _cairo_matrix {
        double yy;
        double x0;
        double y0;
+       static tolua_outside cairo_matrix_t* create_cairo_matrix_t @ create();
 } cairo_matrix_t;
 typedef int cairo_bool_t;
 
@@ -147,6 +151,22 @@ cairo_surface_t *cairo_xlib_surface_create(Display * dpy,
                Drawable drawable,
                Visual * visual, int width, int height);
 
+/*
+cairo_surface_t *cairo_qt_surface_create (QPainter *painter);
+
+cairo_surface_t *cairo_qt_surface_create_with_qimage (cairo_format_t format,
+               int width, int height);
+
+cairo_surface_t *cairo_qt_surface_create_with_qpixmap (cairo_content_t content,
+               int width, int height);
+
+QPainter *cairo_qt_surface_get_qpainter (cairo_surface_t *surface);
+
+cairo_surface_t *cairo_qt_surface_get_image (cairo_surface_t *surface);
+
+QImage *cairo_qt_surface_get_qimage (cairo_surface_t *surface);
+*/
+
 cairo_surface_t *cairo_xlib_surface_create_for_bitmap(Display * dpy,
                Pixmap bitmap,
                Screen * screen, int width, int height);
@@ -176,6 +196,9 @@ const char *cairo_version_string(void);
 
 cairo_t *cairo_create(cairo_surface_t * target);
 
+/*cairo_t *gdk_cairo_create(GdkDrawable *drawable);*/
+
+
 cairo_t *cairo_reference(cairo_t * cr);
 
 void cairo_destroy(cairo_t * cr);
@@ -375,6 +398,7 @@ typedef struct {
        double height;
        double x_advance;
        double y_advance;
+       static tolua_outside cairo_text_extents_t* create_cairo_text_extents_t @ create();
 } cairo_text_extents_t;
 
 typedef struct {
@@ -383,6 +407,7 @@ typedef struct {
        double height;
        double max_x_advance;
        double max_y_advance;
+       static tolua_outside cairo_font_extents_t* create_cairo_font_extents_t @ create();
 } cairo_font_extents_t;
 
 typedef enum _cairo_font_slant {
@@ -692,6 +717,7 @@ typedef enum _cairo_surface_type {
        CAIRO_SURFACE_TYPE_OS2,
        CAIRO_SURFACE_TYPE_WIN32_PRINTING,
        CAIRO_SURFACE_TYPE_QUARTZ_IMAGE
+//     ,CAIRO_SURFACE_TYPE_QT
 } cairo_surface_type_t;
 
 cairo_surface_type_t cairo_surface_get_type(cairo_surface_t * surface);