[gtk+] GSK: Fix a bunch of warnings from the GIR scanner



commit 3d11edf1bc18a778d725f69bf388c43d8b333156
Author: Daniel Boles <dboles src gnome org>
Date:   Mon Mar 27 20:13:15 2017 +0100

    GSK: Fix a bunch of warnings from the GIR scanner
    
    arising from conflicting argument names, missing annotations, etc.

 gsk/gskrenderer.c       |   15 ++++++++++++++-
 gsk/gskrendernode.h     |    2 +-
 gsk/gskrendernodeimpl.c |   15 +++++++++------
 gsk/gskroundedrect.c    |   10 +++++-----
 gsk/gskroundedrect.h    |    2 +-
 5 files changed, 30 insertions(+), 14 deletions(-)
---
diff --git a/gsk/gskrenderer.c b/gsk/gskrenderer.c
index adc5040..35747c9 100644
--- a/gsk/gskrenderer.c
+++ b/gsk/gskrenderer.c
@@ -849,7 +849,7 @@ static struct {
 
 /**
  * gsk_renderer_new_for_window:
- * @display: a #GdkDisplay
+ * @window: a #GdkWindow
  *
  * Creates an appropriate #GskRenderer instance for the given @window.
  *
@@ -922,6 +922,19 @@ gsk_renderer_create_cairo_surface (GskRenderer    *renderer,
   return GSK_RENDERER_GET_CLASS (renderer)->create_cairo_surface (renderer, format, width, height);
 }
 
+/**
+ * gsk_renderer_begin_draw_frame:
+ * @renderer: a #GskRenderer
+ * @region: the #cairo_region_t that you wish to draw
+ *
+ * Indicates that you are beginning the process of redrawing @region using
+ * @renderer, and provides you with a #GdkDrawingContext to use for this.
+ *
+ * Returns: (transfer none): a #GdkDrawingContext context that should be used to
+ * draw the contents of the @renderer. This context is owned by GDK.
+ *
+ * Since: 3.90
+ */
 GdkDrawingContext *
 gsk_renderer_begin_draw_frame (GskRenderer          *renderer,
                                const cairo_region_t *region)
diff --git a/gsk/gskrendernode.h b/gsk/gskrendernode.h
index f46c283..08bb87d 100644
--- a/gsk/gskrendernode.h
+++ b/gsk/gskrendernode.h
@@ -183,7 +183,7 @@ GDK_AVAILABLE_IN_3_90
 const char *            gsk_render_node_get_name                (GskRenderNode *node);
 GDK_AVAILABLE_IN_3_90
 void                    gsk_render_node_get_bounds              (GskRenderNode   *node,
-                                                                 graphene_rect_t *frame);
+                                                                 graphene_rect_t *bounds);
 
 GDK_AVAILABLE_IN_3_90
 void                    gsk_render_node_draw                    (GskRenderNode *node,
diff --git a/gsk/gskrendernodeimpl.c b/gsk/gskrendernodeimpl.c
index 7827ece..0dac4ff 100644
--- a/gsk/gskrendernodeimpl.c
+++ b/gsk/gskrendernodeimpl.c
@@ -123,7 +123,7 @@ gsk_color_node_peek_color (GskRenderNode *node)
 
 /**
  * gsk_color_node_new:
- * @color: the #GskColor
+ * @rgba: the #GskColor
  * @bounds: the rectangle to render the color into
  *
  * Creates a #GskRenderNode that will render the given
@@ -303,11 +303,14 @@ static const GskRenderNodeClass GSK_REPEATING_LINEAR_GRADIENT_NODE_CLASS = {
 
 /**
  * gsk_linear_gradient_node_new:
- * @linear_gradient: the #GskLinearGradient
- * @bounds: the rectangle to render the linear_gradient into
+ * @bounds: the rectangle to render the linear gradient into
+ * @start: the point at which the linear gradient will begin
+ * @end: the point at which the linear gradient will finish
+ * @color_stops: a pointer to an array of #GskColorStop defining the gradient
+ * @n_color_stops: the number of elements in @color_stops
  *
- * Creates a #GskRenderNode that will render the given
- * @linear_gradient into the area given by @bounds.
+ * Creates a #GskRenderNode that will create a linear gradient from the given
+ * points and color stops, and render that into the area given by @bounds.
  *
  * Returns: A new #GskRenderNode
  *
@@ -2818,7 +2821,7 @@ static const GskRenderNodeClass GSK_REPEAT_NODE_CLASS = {
  * gsk_repeat_node_new:
  * @bounds: The bounds of the area to be painted
  * @child: The child to repeat
- * @child_bounds: (optional): The area of the child to repeat or %NULL to
+ * @child_bounds: (allow-none): The area of the child to repeat or %NULL to
  *     use the child's bounds
  *
  * Creates a #GskRenderNode that will repeat the drawing of @child across
diff --git a/gsk/gskroundedrect.c b/gsk/gskroundedrect.c
index c381e47..a1279a7 100644
--- a/gsk/gskroundedrect.c
+++ b/gsk/gskroundedrect.c
@@ -179,8 +179,8 @@ gsk_rounded_rect_normalize (GskRoundedRect *self)
 /**
  * gsk_rounded_rect_offset:
  * @self: a #GskRoundedRect
- * @d_x: the horizontal offset
- * @d_y: the vertical offset
+ * @dx: the horizontal offset
+ * @dy: the vertical offset
  *
  * Offsets the bound's origin by @dx and @dy.
  *
@@ -222,7 +222,7 @@ border_radius_shrink (graphene_size_t *corner,
 
 /**
  * gsk_rounded_rect_shrink:
- * @self: The @GskRoundedRect to shrink or grow
+ * @self: The #GskRoundedRect to shrink or grow
  * @top: How far to move the top side downwards
  * @right: How far to move the right side to the left
  * @bottom: How far to move the bottom side upwards
@@ -236,7 +236,7 @@ border_radius_shrink (graphene_size_t *corner,
  * This function also works for growing rectangles if you pass
  * negative values for the @top, @right, @bottom or @left.
  *
- * Returns: @self
+ * Returns: (transfer none): the resized #GskRoundedRect
  **/
 GskRoundedRect *
 gsk_rounded_rect_shrink (GskRoundedRect *self,
@@ -275,7 +275,7 @@ gsk_rounded_rect_shrink (GskRoundedRect *self,
   return self;
 }
 
-/* XXX: Fina a better name */
+/* XXX: Find a better name */
 gboolean
 gsk_rounded_rect_is_circular (const GskRoundedRect *self)
 {
diff --git a/gsk/gskroundedrect.h b/gsk/gskroundedrect.h
index 98819e4..d12156c 100644
--- a/gsk/gskroundedrect.h
+++ b/gsk/gskroundedrect.h
@@ -67,7 +67,7 @@ struct _GskRoundedRect
 
 GDK_AVAILABLE_IN_3_90
 GskRoundedRect *        gsk_rounded_rect_init                   (GskRoundedRect           *self,
-                                                                 const graphene_rect_t    *rect,
+                                                                 const graphene_rect_t    *bounds,
                                                                  const graphene_size_t    *top_left,
                                                                  const graphene_size_t    *top_right,
                                                                  const graphene_size_t    *bottom_right,


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