[glade] 2011-02-03 Pablo Castellano <pablog gnome org>
- From: Tristan Van Berkom <tvb src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [glade] 2011-02-03 Pablo Castellano <pablog gnome org>
- Date: Thu, 3 Feb 2011 19:11:23 +0000 (UTC)
commit b17b3bb647c7ab10b8dc571b4e2d13d88a441b82
Author: Tristan Van Berkom <tristan van berkom gmail com>
Date: Fri Feb 4 04:19:27 2011 +0900
2011-02-03 Pablo Castellano <pablog gnome org>
Make libgladeui-2 library come with introspection data, patch based on original
patch by Alan Knowles.
* configure.ac: Added gobject-introspection m4 stuff
* gladeui/Makefile.am: Added rules to build Gladeui-2.0 gir and typelib
* gladeui/glade-app.c, gladeui/glade-command.c, gladeui/glade-project.c: Some changes
made to pass the introspection build.
ChangeLog | 12 ++++++++++++
Makefile.am | 2 +-
configure.ac | 6 ++++++
gladeui/Makefile.am | 34 +++++++++++++++++++++++++++++++++-
gladeui/glade-app.c | 6 +++++-
gladeui/glade-command.c | 37 +++++++++++++++++++++++--------------
gladeui/glade-project.c | 9 ++++-----
7 files changed, 84 insertions(+), 22 deletions(-)
---
diff --git a/ChangeLog b/ChangeLog
index 411a92e..fd2b4bd 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,15 @@
+2011-02-03 Pablo Castellano <pablog gnome org>
+
+ Make libgladeui-2 library come with introspection data, patch based on original
+ patch by Alan Knowles.
+
+ * configure.ac: Added gobject-introspection m4 stuff
+
+ * gladeui/Makefile.am: Added rules to build Gladeui-2.0 gir and typelib
+
+ * gladeui/glade-app.c, gladeui/glade-command.c, gladeui/glade-project.c: Some changes
+ made to pass the introspection build.
+
2011-02-03 Frederic Peters <fpeters 0d be>
* src/glade-window.c: Put File->Properties before Quit in the File menu
diff --git a/Makefile.am b/Makefile.am
index fccb151..be6bbc4 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -20,4 +20,4 @@ DISTCLEANFILES = intltool-extract \
intltool-update \
gnome-doc-utils.make
-DISTCHECK_CONFIGURE_FLAGS = --disable-scrollkeeper --enable-gtk-doc
+DISTCHECK_CONFIGURE_FLAGS = --disable-scrollkeeper --enable-gtk-doc --enable-introspection
diff --git a/configure.ac b/configure.ac
index 57b0815..1ee53c1 100644
--- a/configure.ac
+++ b/configure.ac
@@ -120,6 +120,11 @@ dnl ================================================================
GTK_DOC_CHECK([1.13],[--flavour no-tmpl])
dnl ================================================================
+dnl Check for introspection
+dnl ================================================================
+GOBJECT_INTROSPECTION_CHECK([0.6.7])
+
+dnl ================================================================
dnl Check for gtk+
dnl ================================================================
GTK_REQUIRED=2.99.0
@@ -289,6 +294,7 @@ Configuration:
Compiler: ${CC}
GTK+ UNIX Print Widgets: ${have_unix_print}
PYTHON Widgets support: ${have_python}
+ Introspection Data: ${found_introspection}
Build Reference Manual: ${enable_gtk_doc}
Build User Manual: ${gdu_cv_have_gdu}
diff --git a/gladeui/Makefile.am b/gladeui/Makefile.am
index e8c840c..0094c3a 100644
--- a/gladeui/Makefile.am
+++ b/gladeui/Makefile.am
@@ -190,5 +190,37 @@ glade-marshallers.c: glade-marshallers.list $(GLIB_GENMARSHAL)
&& mv glade-marshallers-c.tmp glade-marshallers.c \
|| ( rm -f glade-marshallers-c.tmp && exit 1 )
-
CLEANFILES = $(BUILT_SOURCES) gladeui.def
+
+#
+# Introspection generation
+#
+
+-include $(INTROSPECTION_MAKEFILE)
+INTROSPECTION_GIRS =
+INTROSPECTION_SCANNER_ARGS = \
+ --add-include-path=$(srcdir) \
+ --identifier-prefix=Glade \
+ --symbol-prefix=glade \
+ --pkg=gtk+-3.0 -I../
+
+INTROSPECTION_COMPILER_ARGS = --includedir=$(srcdir)
+
+if HAVE_INTROSPECTION
+introspection_sources = $(libgladeui_2_la_SOURCES) $(libgladeuiinclude_HEADERS)
+
+Gladeui-2.0.gir: libgladeui-2.la
+Gladeui_2_0_gir_INCLUDES = Gtk-3.0
+Gladeui_2_0_gir_CFLAGS = $(INCLUDES)
+Gladeui_2_0_gir_LIBS = libgladeui-2.la
+Gladeui_2_0_gir_FILES = $(introspection_sources)
+INTROSPECTION_GIRS += Gladeui-2.0.gir
+
+girdir = $(datadir)/gir-1.0
+gir_DATA = $(INTROSPECTION_GIRS)
+
+typelibdir = $(libdir)/girepository-1.0
+typelib_DATA = $(INTROSPECTION_GIRS:.gir=.typelib)
+
+CLEANFILES += $(gir_DATA) $(typelib_DATA)
+endif
diff --git a/gladeui/glade-app.c b/gladeui/glade-app.c
index ef75c6f..6683024 100644
--- a/gladeui/glade-app.c
+++ b/gladeui/glade-app.c
@@ -586,7 +586,11 @@ glade_app_get_clipboard (void)
GladeApp *app = glade_app_get ();
return app->priv->clipboard;
}
-
+/**
+ * glade_app_get_catalogs:
+ *
+ * Return value: (element-type GladeCatalog): catalogs
+ */
GList *
glade_app_get_projects (void)
{
diff --git a/gladeui/glade-command.c b/gladeui/glade-command.c
index 930691d..617994c 100644
--- a/gladeui/glade-command.c
+++ b/gladeui/glade-command.c
@@ -653,7 +653,11 @@ glade_command_set_property_description (GladeCommandSetProperty * me)
return description;
}
-
+/**
+ * glade_command_set_properties_list:
+ *
+ * @props (element-type GladeProperty): List of #GladeProperty
+ */
void
glade_command_set_properties_list (GladeProject * project, GList * props)
{
@@ -971,7 +975,12 @@ glade_command_placeholder_connect (CommandData * cdata,
G_CALLBACK (glade_command_placeholder_destroyed), cdata);
}
-
+/**
+ * get_all_parentless_reffed_widgetst:
+ *
+ * @props (element-type GladeWidget) : List of #GladeWidget
+ * @return (element-type GladeWidget) : List of #GladeWidget
+ */
static GList *
get_all_parentless_reffed_widgets (GList * reffed, GladeWidget * widget)
{
@@ -996,7 +1005,7 @@ get_all_parentless_reffed_widgets (GList * reffed, GladeWidget * widget)
/**
* glade_command_add:
- * @widgets: a #Glist
+ * @widgets (element-type GladeWidget): a #Glist
* @parent: a #GladeWidget
* @placeholder: a #GladePlaceholder
* @pasting: whether we are pasting an existing widget or creating a new one.
@@ -1171,7 +1180,7 @@ glade_command_remove_locked (GladeWidget * widget, GList * reffed)
/**
* glade_command_remove:
- * @widgets: a #GList of #GladeWidgets
+ * @widgets (element-type GladeWidget): a #GList of #GladeWidgets
* @return_placeholders: whether or not to return a list of placehodlers
*
* Performs a remove command on all widgets in @widgets from @parent.
@@ -1553,8 +1562,8 @@ glade_command_add_remove_collapse (GladeCommand * this_cmd,
/**
* glade_command_create:
* @adaptor: A #GladeWidgetAdaptor
- * @parent: the parent #GladeWidget to add the new widget to.
- * @placeholder: the placeholder which will be substituted by the widget
+ * @parent (allow-none): the parent #GladeWidget to add the new widget to.
+ * @placeholder (allow-none): the placeholder which will be substituted by the widget
* @project: the project his widget belongs to.
*
* Creates a new widget using @adaptor and put in place of the @placeholder
@@ -1603,7 +1612,7 @@ glade_command_create (GladeWidgetAdaptor * adaptor, GladeWidget * parent,
/**
* glade_command_delete:
- * @widgets: a #GList of #GladeWidgets
+ * @widgets (element-type GladeWidget): a #GList of #GladeWidgets
*
* Performs a delete command on the list of widgets.
*/
@@ -1624,7 +1633,7 @@ glade_command_delete (GList * widgets)
/**
* glade_command_cut:
- * @widgets: a #GList of #GladeWidgets
+ * @widgets (element-type GladeWidget): a #GList of #GladeWidgets
*
* Removes the list of widgets and adds them to the clipboard.
*/
@@ -1714,9 +1723,9 @@ glade_command_break_references (GladeProject * project, GList * widgets)
/**
* glade_command_paste:
- * @widgets: a #GList of #GladeWidget
- * @parent: a #GladeWidget
- * @placeholder: a #GladePlaceholder
+ * @widgets (element-type GladeWidget): a #GList of #GladeWidget
+ * @parent (allow-none): a #GladeWidget
+ * @placeholder (allow-none): a #GladePlaceholder
*
* Performs a paste command on all widgets in @widgets to @parent, possibly
* replacing @placeholder (note toplevels dont need a parent; the active project
@@ -1756,9 +1765,9 @@ glade_command_paste (GList * widgets, GladeWidget * parent,
/**
* glade_command_dnd:
- * @widgets: a #GList of #GladeWidget
- * @parent: a #GladeWidget
- * @placeholder: a #GladePlaceholder
+ * @widgets (element-type GladeWidget): a #GList of #GladeWidget
+ * @parent (allow-none): a #GladeWidget
+ * @placeholder (allow-none): a #GladePlaceholder
*
* Performs a drag-n-drop command, i.e. removes the list of widgets and adds them
* to the new parent, possibly replacing @placeholder (note toplevels dont need a
diff --git a/gladeui/glade-project.c b/gladeui/glade-project.c
index 2fb2213..a7c42d3 100644
--- a/gladeui/glade-project.c
+++ b/gladeui/glade-project.c
@@ -181,9 +181,9 @@ glade_pointer_mode_get_type (void)
if (etype == 0)
{
static const GEnumValue values[] = {
- {GLADE_POINTER_SELECT, "select", "Select widgets"},
- {GLADE_POINTER_ADD_WIDGET, "add", "Add widgets"},
- {GLADE_POINTER_DRAG_RESIZE, "drag-resize", "Drag and resize widgets"},
+ {GLADE_POINTER_SELECT, "select", "Select-widgets"},
+ {GLADE_POINTER_ADD_WIDGET, "add", "Add-widgets"},
+ {GLADE_POINTER_DRAG_RESIZE, "drag-resize", "Drag-and-resize-widgets"},
{0, NULL, NULL}
};
etype = g_enum_register_static ("GladePointerMode", values);
@@ -3181,8 +3181,7 @@ glade_project_selection_set (GladeProject * project,
* glade_project_selection_get:
* @project: a #GladeProject
*
- * Returns: a #GList containing the #GtkWidget items currently selected in
- * @project
+ * Returns: a #GList containing the #GtkWidget items currently selected in @project
*/
GList *
glade_project_selection_get (GladeProject * project)
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]