Commit e22c4adc authored by Daniel Drake's avatar Daniel Drake Committed by Christian Persch

Generate introspection GIR and typelib

... and add some annotations.

https://bugzilla.gnome.org/show_bug.cgi?id=663049
parent 2b3097d1
SUBDIRS = . gdk-pixbuf-loader data tests tools doc
NULL =
ACLOCAL_AMFLAGS = ${ACLOCAL_FLAGS}
if ENABLE_GTK_ENGINE
......@@ -75,7 +77,12 @@ librsvg_@RSVG_API_MAJOR_VERSION@_la_SOURCES = \
rsvg-gobject.c \
rsvg-file-util.c \
rsvg-xml.c \
rsvg-xml.h
rsvg-xml.h \
rsvg.h \
rsvg-cairo.h \
librsvg-features.h \
librsvg-enum-types.h \
$(NULL)
librsvg_@RSVG_API_MAJOR_VERSION@_la_CPPFLAGS = \
-I$(top_srcdir) \
......@@ -244,6 +251,42 @@ s-enum-types-c: $(headers) Makefile
DISTCHECK_CONFIGURE_FLAGS = --enable-gtk-doc
if HAVE_INTROSPECTION
-include $(INTROSPECTION_MAKEFILE)
INTROSPECTION_GIRS = Rsvg-@RSVG_API_VERSION@.gir
INTROSPECTION_SCANNER_ARGS = --add-include-path=$(srcdir)
INTROSPECTION_COMPILER_ARGS = --includedir=$(srcdir)
Rsvg-@RSVG_API_VERSION_U@.gir: librsvg-@RSVG_API_MAJOR_VERSION@.la
Rsvg_@RSVG_API_VERSION_U@_gir_NAMESPACE = Rsvg
Rsvg_@RSVG_API_VERSION_U@_gir_EXPORT_PACKAGES = librsvg-$(RSVG_API_VERSION)
Rsvg_@RSVG_API_VERSION_U@_gir_FILES = $(librsvg_@RSVG_API_MAJOR_VERSION@_la_SOURCES)
Rsvg_@RSVG_API_VERSION_U@_gir_INCLUDES = \
GLib-2.0 \
GObject-2.0 \
Gio-2.0 \
cairo-1.0 \
GdkPixbuf-2.0 \
$(NULL)
Rsvg_@RSVG_API_VERSION_U@_gir_PACKAGES = \
Pango-1.0 \
libxml2-2.0 \
$(NULL)
Rsvg_@RSVG_API_VERSION_U@_gir_CFLAGS = -I$(top_builddir)
Rsvg_@RSVG_API_VERSION_U@_gir_LIBS = librsvg-@RSVG_API_MAJOR_VERSION@.la
girdir = $(datadir)/gir-1.0
dist_gir_DATA = $(INTROSPECTION_GIRS)
typelibsdir = $(libdir)/girepository-1.0
typelibs_DATA = $(INTROSPECTION_GIRS:.gir=.typelib)
CLEANFILES += $(dist_gir_DATA) $(typelibs_DATA)
endif # HAVE_INTROSPECTION
# ChangeLog generation
ChangeLog:
......
......@@ -21,9 +21,12 @@ dnl ===========================================================================
RSVG_API_VERSION=2.0
RSVG_API_MAJOR_VERSION=2
RSVG_API_MINOR_VERSION=0
AC_SUBST([RSVG_API_VERSION])
AC_SUBST([RSVG_API_MAJOR_VERSION])
AC_SUBST([RSVG_API_MINOR_VERSION])
AC_SUBST([RSVG_API_VERSION_U],[AS_TR_SH([$RSVG_API_VERSION])])
dnl ===========================================================================
......@@ -330,6 +333,16 @@ else
fi
AM_CONDITIONAL([BUILD_MISC_TOOLS], [test "x$build_misc_tools" = "xyes"])
dnl ===========================================================================
dnl Build introspectable bindings
# No automagic please!
if test -z "$enable_introspection"; then
enable_introspection=no
fi
GOBJECT_INTROSPECTION_CHECK([0.10.8])
dnl ===========================================================================
m4_copy([AC_DEFUN],[glib_DEFUN])
......@@ -382,6 +395,7 @@ librsvg-$VERSION
prefix: ${prefix}
compiler: ${CC}
Build introspectable bindings: ${found_introspection}
Build GdkPixbuf loader: ${enable_pixbuf_loader}
Build theme engine: ${enable_gtk_theme}
Build miscellaenous tools: ${build_misc_tools}
......
......@@ -45,7 +45,7 @@ rsvg_handle_fill_with_data (RsvgHandle * handle,
/**
* rsvg_handle_new_from_data:
* @data: The SVG data
* @data: (array length=data_len): The SVG data
* @data_len: The length of #data, in bytes
* @error: return location for errors
*
......
......@@ -1318,7 +1318,7 @@ rsvg_handle_get_desc (RsvgHandle * handle)
/**
* rsvg_handle_get_dimensions
* @handle: A #RsvgHandle
* @dimension_data: A place to store the SVG's size
* @dimension_data: (out): A place to store the SVG's size
*
* Get the SVG's size. Do not call from within the size_func callback, because an infinite loop will occur.
*
......
......@@ -129,7 +129,7 @@ rsvg_handle_get_pixbuf_sub (RsvgHandle * handle, const char *id)
* will be returned. Note that the pixbuf may not be complete until
* @rsvg_handle_close has been called.
*
* Returns: the pixbuf loaded by #handle, or %NULL.
* Returns: (transfer full): the pixbuf loaded by #handle, or %NULL.
**/
GdkPixbuf *
rsvg_handle_get_pixbuf (RsvgHandle * handle)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment