1 /* 2 * This file is part of gtkD. 3 * 4 * gtkD is free software; you can redistribute it and/or modify 5 * it under the terms of the GNU Lesser General Public License 6 * as published by the Free Software Foundation; either version 3 7 * of the License, or (at your option) any later version, with 8 * some exceptions, please read the COPYING file. 9 * 10 * gtkD is distributed in the hope that it will be useful, 11 * but WITHOUT ANY WARRANTY; without even the implied warranty of 12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 13 * GNU Lesser General Public License for more details. 14 * 15 * You should have received a copy of the GNU Lesser General Public License 16 * along with gtkD; if not, write to the Free Software 17 * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110, USA 18 */ 19 20 // generated automatically - do not change 21 // find conversion definition on APILookup.txt 22 // implement new conversion functionalities on the wrap.utils pakage 23 24 25 module rsvg.c.functions; 26 27 import std.stdio; 28 import rsvg.c.types; 29 import gtkd.Loader; 30 31 version (Windows) 32 static immutable LIBRARY_RSVG = ["librsvg-2-2.dll;rsvg-2-2.2.dll;rsvg-2.dll"]; 33 else version (OSX) 34 static immutable LIBRARY_RSVG = ["librsvg-2.2.dylib"]; 35 else 36 static immutable LIBRARY_RSVG = ["librsvg-2.so.2"]; 37 38 shared static this() 39 { 40 // rsvg.Handle 41 42 Linker.link(rsvg_handle_get_type, "rsvg_handle_get_type", LIBRARY_RSVG); 43 Linker.link(rsvg_handle_new, "rsvg_handle_new", LIBRARY_RSVG); 44 Linker.link(rsvg_handle_new_from_data, "rsvg_handle_new_from_data", LIBRARY_RSVG); 45 Linker.link(rsvg_handle_new_from_file, "rsvg_handle_new_from_file", LIBRARY_RSVG); 46 Linker.link(rsvg_handle_new_from_gfile_sync, "rsvg_handle_new_from_gfile_sync", LIBRARY_RSVG); 47 Linker.link(rsvg_handle_new_from_stream_sync, "rsvg_handle_new_from_stream_sync", LIBRARY_RSVG); 48 Linker.link(rsvg_handle_new_with_flags, "rsvg_handle_new_with_flags", LIBRARY_RSVG); 49 Linker.link(rsvg_handle_close, "rsvg_handle_close", LIBRARY_RSVG); 50 Linker.link(rsvg_handle_get_base_uri, "rsvg_handle_get_base_uri", LIBRARY_RSVG); 51 Linker.link(rsvg_handle_get_dimensions, "rsvg_handle_get_dimensions", LIBRARY_RSVG); 52 Linker.link(rsvg_handle_get_dimensions_sub, "rsvg_handle_get_dimensions_sub", LIBRARY_RSVG); 53 Linker.link(rsvg_handle_get_geometry_for_element, "rsvg_handle_get_geometry_for_element", LIBRARY_RSVG); 54 Linker.link(rsvg_handle_get_geometry_for_layer, "rsvg_handle_get_geometry_for_layer", LIBRARY_RSVG); 55 Linker.link(rsvg_handle_get_intrinsic_dimensions, "rsvg_handle_get_intrinsic_dimensions", LIBRARY_RSVG); 56 Linker.link(rsvg_handle_get_pixbuf, "rsvg_handle_get_pixbuf", LIBRARY_RSVG); 57 Linker.link(rsvg_handle_get_pixbuf_sub, "rsvg_handle_get_pixbuf_sub", LIBRARY_RSVG); 58 Linker.link(rsvg_handle_get_position_sub, "rsvg_handle_get_position_sub", LIBRARY_RSVG); 59 Linker.link(rsvg_handle_has_sub, "rsvg_handle_has_sub", LIBRARY_RSVG); 60 Linker.link(rsvg_handle_internal_set_testing, "rsvg_handle_internal_set_testing", LIBRARY_RSVG); 61 Linker.link(rsvg_handle_read_stream_sync, "rsvg_handle_read_stream_sync", LIBRARY_RSVG); 62 Linker.link(rsvg_handle_render_cairo, "rsvg_handle_render_cairo", LIBRARY_RSVG); 63 Linker.link(rsvg_handle_render_cairo_sub, "rsvg_handle_render_cairo_sub", LIBRARY_RSVG); 64 Linker.link(rsvg_handle_render_document, "rsvg_handle_render_document", LIBRARY_RSVG); 65 Linker.link(rsvg_handle_render_element, "rsvg_handle_render_element", LIBRARY_RSVG); 66 Linker.link(rsvg_handle_render_layer, "rsvg_handle_render_layer", LIBRARY_RSVG); 67 Linker.link(rsvg_handle_set_base_gfile, "rsvg_handle_set_base_gfile", LIBRARY_RSVG); 68 Linker.link(rsvg_handle_set_base_uri, "rsvg_handle_set_base_uri", LIBRARY_RSVG); 69 Linker.link(rsvg_handle_set_dpi, "rsvg_handle_set_dpi", LIBRARY_RSVG); 70 Linker.link(rsvg_handle_set_dpi_x_y, "rsvg_handle_set_dpi_x_y", LIBRARY_RSVG); 71 Linker.link(rsvg_handle_set_stylesheet, "rsvg_handle_set_stylesheet", LIBRARY_RSVG); 72 Linker.link(rsvg_handle_write, "rsvg_handle_write", LIBRARY_RSVG); 73 Linker.link(rsvg_cleanup, "rsvg_cleanup", LIBRARY_RSVG); 74 Linker.link(rsvg_set_default_dpi, "rsvg_set_default_dpi", LIBRARY_RSVG); 75 Linker.link(rsvg_set_default_dpi_x_y, "rsvg_set_default_dpi_x_y", LIBRARY_RSVG); 76 } 77 78 __gshared extern(C) 79 { 80 81 // rsvg.Handle 82 83 GType function() c_rsvg_handle_get_type; 84 RsvgHandle* function() c_rsvg_handle_new; 85 RsvgHandle* function(ubyte* data, size_t dataLen, GError** err) c_rsvg_handle_new_from_data; 86 RsvgHandle* function(const(char)* filename, GError** err) c_rsvg_handle_new_from_file; 87 RsvgHandle* function(GFile* file, RsvgHandleFlags flags, GCancellable* cancellable, GError** err) c_rsvg_handle_new_from_gfile_sync; 88 RsvgHandle* function(GInputStream* inputStream, GFile* baseFile, RsvgHandleFlags flags, GCancellable* cancellable, GError** err) c_rsvg_handle_new_from_stream_sync; 89 RsvgHandle* function(RsvgHandleFlags flags) c_rsvg_handle_new_with_flags; 90 int function(RsvgHandle* handle, GError** err) c_rsvg_handle_close; 91 const(char)* function(RsvgHandle* handle) c_rsvg_handle_get_base_uri; 92 void function(RsvgHandle* handle, RsvgDimensionData* dimensionData) c_rsvg_handle_get_dimensions; 93 int function(RsvgHandle* handle, RsvgDimensionData* dimensionData, const(char)* id) c_rsvg_handle_get_dimensions_sub; 94 int function(RsvgHandle* handle, const(char)* id, RsvgRectangle* outInkRect, RsvgRectangle* outLogicalRect, GError** err) c_rsvg_handle_get_geometry_for_element; 95 int function(RsvgHandle* handle, const(char)* id, RsvgRectangle* viewport, RsvgRectangle* outInkRect, RsvgRectangle* outLogicalRect, GError** err) c_rsvg_handle_get_geometry_for_layer; 96 void function(RsvgHandle* handle, int* outHasWidth, RsvgLength* outWidth, int* outHasHeight, RsvgLength* outHeight, int* outHasViewbox, RsvgRectangle* outViewbox) c_rsvg_handle_get_intrinsic_dimensions; 97 GdkPixbuf* function(RsvgHandle* handle) c_rsvg_handle_get_pixbuf; 98 GdkPixbuf* function(RsvgHandle* handle, const(char)* id) c_rsvg_handle_get_pixbuf_sub; 99 int function(RsvgHandle* handle, RsvgPositionData* positionData, const(char)* id) c_rsvg_handle_get_position_sub; 100 int function(RsvgHandle* handle, const(char)* id) c_rsvg_handle_has_sub; 101 void function(RsvgHandle* handle, int testing) c_rsvg_handle_internal_set_testing; 102 int function(RsvgHandle* handle, GInputStream* stream, GCancellable* cancellable, GError** err) c_rsvg_handle_read_stream_sync; 103 int function(RsvgHandle* handle, cairo_t* cr) c_rsvg_handle_render_cairo; 104 int function(RsvgHandle* handle, cairo_t* cr, const(char)* id) c_rsvg_handle_render_cairo_sub; 105 int function(RsvgHandle* handle, cairo_t* cr, RsvgRectangle* viewport, GError** err) c_rsvg_handle_render_document; 106 int function(RsvgHandle* handle, cairo_t* cr, const(char)* id, RsvgRectangle* elementViewport, GError** err) c_rsvg_handle_render_element; 107 int function(RsvgHandle* handle, cairo_t* cr, const(char)* id, RsvgRectangle* viewport, GError** err) c_rsvg_handle_render_layer; 108 void function(RsvgHandle* handle, GFile* baseFile) c_rsvg_handle_set_base_gfile; 109 void function(RsvgHandle* handle, const(char)* baseUri) c_rsvg_handle_set_base_uri; 110 void function(RsvgHandle* handle, double dpi) c_rsvg_handle_set_dpi; 111 void function(RsvgHandle* handle, double dpiX, double dpiY) c_rsvg_handle_set_dpi_x_y; 112 int function(RsvgHandle* handle, ubyte* css, size_t cssLen, GError** err) c_rsvg_handle_set_stylesheet; 113 int function(RsvgHandle* handle, char* buf, size_t count, GError** err) c_rsvg_handle_write; 114 void function() c_rsvg_cleanup; 115 void function(double dpi) c_rsvg_set_default_dpi; 116 void function(double dpiX, double dpiY) c_rsvg_set_default_dpi_x_y; 117 } 118 119 120 // rsvg.Handle 121 122 alias c_rsvg_handle_get_type rsvg_handle_get_type; 123 alias c_rsvg_handle_new rsvg_handle_new; 124 alias c_rsvg_handle_new_from_data rsvg_handle_new_from_data; 125 alias c_rsvg_handle_new_from_file rsvg_handle_new_from_file; 126 alias c_rsvg_handle_new_from_gfile_sync rsvg_handle_new_from_gfile_sync; 127 alias c_rsvg_handle_new_from_stream_sync rsvg_handle_new_from_stream_sync; 128 alias c_rsvg_handle_new_with_flags rsvg_handle_new_with_flags; 129 alias c_rsvg_handle_close rsvg_handle_close; 130 alias c_rsvg_handle_get_base_uri rsvg_handle_get_base_uri; 131 alias c_rsvg_handle_get_dimensions rsvg_handle_get_dimensions; 132 alias c_rsvg_handle_get_dimensions_sub rsvg_handle_get_dimensions_sub; 133 alias c_rsvg_handle_get_geometry_for_element rsvg_handle_get_geometry_for_element; 134 alias c_rsvg_handle_get_geometry_for_layer rsvg_handle_get_geometry_for_layer; 135 alias c_rsvg_handle_get_intrinsic_dimensions rsvg_handle_get_intrinsic_dimensions; 136 alias c_rsvg_handle_get_pixbuf rsvg_handle_get_pixbuf; 137 alias c_rsvg_handle_get_pixbuf_sub rsvg_handle_get_pixbuf_sub; 138 alias c_rsvg_handle_get_position_sub rsvg_handle_get_position_sub; 139 alias c_rsvg_handle_has_sub rsvg_handle_has_sub; 140 alias c_rsvg_handle_internal_set_testing rsvg_handle_internal_set_testing; 141 alias c_rsvg_handle_read_stream_sync rsvg_handle_read_stream_sync; 142 alias c_rsvg_handle_render_cairo rsvg_handle_render_cairo; 143 alias c_rsvg_handle_render_cairo_sub rsvg_handle_render_cairo_sub; 144 alias c_rsvg_handle_render_document rsvg_handle_render_document; 145 alias c_rsvg_handle_render_element rsvg_handle_render_element; 146 alias c_rsvg_handle_render_layer rsvg_handle_render_layer; 147 alias c_rsvg_handle_set_base_gfile rsvg_handle_set_base_gfile; 148 alias c_rsvg_handle_set_base_uri rsvg_handle_set_base_uri; 149 alias c_rsvg_handle_set_dpi rsvg_handle_set_dpi; 150 alias c_rsvg_handle_set_dpi_x_y rsvg_handle_set_dpi_x_y; 151 alias c_rsvg_handle_set_stylesheet rsvg_handle_set_stylesheet; 152 alias c_rsvg_handle_write rsvg_handle_write; 153 alias c_rsvg_cleanup rsvg_cleanup; 154 alias c_rsvg_set_default_dpi rsvg_set_default_dpi; 155 alias c_rsvg_set_default_dpi_x_y rsvg_set_default_dpi_x_y;