[gtk/wip/nielsdg/fix-gir-warnings: 7/7] Fix some GObject introspection annotations



commit df9aed6c61630a659f140f846059a79d8ebe1f7a
Author: Niels De Graef <nielsdegraef gmail com>
Date:   Thu May 30 17:05:02 2019 +0200

    Fix some GObject introspection annotations
    
    Fixes several warnings by the GIR compiler.

 gdk/x11/gdksurface-x11.c | 8 ++++++++
 gsk/gskrendernode.c      | 3 ++-
 gsk/gskrendernodeimpl.c  | 8 ++++++++
 gtk/gtkmenubutton.c      | 2 +-
 gtk/gtknative.c          | 4 ++--
 gtk/gtkpopover.c         | 7 +++++++
 gtk/gtkroot.h            | 2 +-
 7 files changed, 29 insertions(+), 5 deletions(-)
---
diff --git a/gdk/x11/gdksurface-x11.c b/gdk/x11/gdksurface-x11.c
index f792cd0061..f4ecd5d2f8 100644
--- a/gdk/x11/gdksurface-x11.c
+++ b/gdk/x11/gdksurface-x11.c
@@ -3317,6 +3317,14 @@ gdk_x11_surface_set_keep_below (GdkSurface *surface, gboolean setting)
                                 setting ? GDK_SURFACE_STATE_BELOW : 0);
 }
 
+/**
+ * gdk_x11_surface_get_group:
+ * @surface: The #GdkSurface
+ *
+ * Returns the group this surface belongs to.
+ *
+ * Returns: (transfer none): The group of this surface;
+ */
 GdkSurface *
 gdk_x11_surface_get_group (GdkSurface *surface)
 {
diff --git a/gsk/gskrendernode.c b/gsk/gskrendernode.c
index b19396c961..781eb797d1 100644
--- a/gsk/gskrendernode.c
+++ b/gsk/gskrendernode.c
@@ -350,7 +350,8 @@ gsk_render_node_write_to_file (GskRenderNode *node,
 /**
  * gsk_render_node_deserialize:
  * @bytes: the bytes containing the data
- * @error: (allow-none): location to store error or %NULL
+ * @error_func: (nullable) (scope call): Callback on parsing errors or %NULL
+ * @user_data: (closure error_func): user_data for @error_func
  *
  * Loads data previously created via gsk_render_node_serialize(). For a
  * discussion of the supported format, see that function.
diff --git a/gsk/gskrendernodeimpl.c b/gsk/gskrendernodeimpl.c
index 32e5d57827..0a432306ee 100644
--- a/gsk/gskrendernodeimpl.c
+++ b/gsk/gskrendernodeimpl.c
@@ -3556,6 +3556,14 @@ gsk_text_node_peek_color (GskRenderNode *node)
   return &self->color;
 }
 
+/**
+ * gsk_text_node_peek_font:
+ * @node: The #GskRenderNode
+ *
+ * Returns the font used by the text node.
+ *
+ * Returns: (transfer none): The used #PangoFont.
+ */
 PangoFont *
 gsk_text_node_peek_font (GskRenderNode *node)
 {
diff --git a/gtk/gtkmenubutton.c b/gtk/gtkmenubutton.c
index d1b0618406..485e46dacc 100644
--- a/gtk/gtkmenubutton.c
+++ b/gtk/gtkmenubutton.c
@@ -1306,7 +1306,7 @@ gtk_menu_button_get_icon_name (GtkMenuButton *menu_button)
 /**
  * gtk_menu_button_set_label:
  * @menu_button: a #GtkMenuButton
- * @icon_name: the label
+ * @label: the label
  *
  * Sets the label to show inside the menu button.
  */
diff --git a/gtk/gtknative.c b/gtk/gtknative.c
index 5b8f760349..a14a0af864 100644
--- a/gtk/gtknative.c
+++ b/gtk/gtknative.c
@@ -74,7 +74,7 @@ gtk_native_default_init (GtkNativeInterface *iface)
  *
  * Returns the surface of this #GtkNative.
  *
- * Returns: the surface of @self
+ * Returns: (transfer none): the surface of @self
  */
 GdkSurface *
 gtk_native_get_surface (GtkNative *self)
@@ -90,7 +90,7 @@ gtk_native_get_surface (GtkNative *self)
  *
  * Returns the renderer that is used for this #GtkNative.
  *
- * Returns: the renderer for @self
+ * Returns: (transfer none): the renderer for @self
  */
 GskRenderer *
 gtk_native_get_renderer (GtkNative *self)
diff --git a/gtk/gtkpopover.c b/gtk/gtkpopover.c
index 73005e92f7..d1fdd73218 100644
--- a/gtk/gtkpopover.c
+++ b/gtk/gtkpopover.c
@@ -1395,6 +1395,13 @@ size_changed (GtkWidget   *widget,
     gtk_popover_move_resize (popover);
 }
 
+/**
+ * gtk_popover_get_popovers:
+ *
+ * Returns the list of all existing #GtkPopover widgets.
+ *
+ * Returns: (transfer none): The list of existing popovers.
+ */
 GListModel *
 gtk_popover_get_popovers (void)
 {
diff --git a/gtk/gtkroot.h b/gtk/gtkroot.h
index 648defa380..c147c09ff0 100644
--- a/gtk/gtkroot.h
+++ b/gtk/gtkroot.h
@@ -49,7 +49,7 @@ struct _GtkRootInterface
 };
 
 GDK_AVAILABLE_IN_ALL
-GdkDisplay * gtk_root_get_display (GtkRoot *root);
+GdkDisplay * gtk_root_get_display (GtkRoot *self);
 
 GDK_AVAILABLE_IN_ALL
 void        gtk_root_set_focus (GtkRoot   *self,


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]