summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorFederico Mena Quintero <federico@gnome.org>2018-01-08 14:21:29 -0600
committerFederico Mena Quintero <federico@gnome.org>2018-01-08 14:21:29 -0600
commitb567478e77baf9c9ffb295c06c94b48562aa610e (patch)
treef6ad42b418163a576856b824943687438985fbf7
parent29f1d9a71fb2a0968b19e6d0b9afb6fe140a9cda (diff)
downloadlibrsvg-b567478e77baf9c9ffb295c06c94b48562aa610e.tar.gz
gitlab:175 - Clarify docs about needing a hash sign in the "_sub()" APIs.
https://gitlab.gnome.org/GNOME/librsvg/issues/175
-rw-r--r--rsvg-handle.c16
-rw-r--r--rsvg.c5
2 files changed, 9 insertions, 12 deletions
diff --git a/rsvg-handle.c b/rsvg-handle.c
index f0ac86aa..1083f813 100644
--- a/rsvg-handle.c
+++ b/rsvg-handle.c
@@ -807,12 +807,11 @@ rsvg_handle_get_dimensions (RsvgHandle * handle, RsvgDimensionData * dimension_d
* rsvg_handle_get_dimensions_sub:
* @handle: A #RsvgHandle
* @dimension_data: (out): A place to store the SVG's size
- * @id: (nullable): An element's id within the SVG, or %NULL to get
- * the dimension of the whole SVG. For example, if you have a layer
- * called "layer1" for that you want to get the dimension, pass
- * "#layer1" as the id.
+ * @id: (nullable): An element's id within the SVG, starting with "##", for
+ * example, "##layer1"; or %NULL to use the whole SVG.
*
- * Get the size of a subelement of the SVG file. Do not call from within the size_func callback, because an infinite loop will occur.
+ * Get the size of a subelement of the SVG file. Do not call from within the
+ * size_func callback, because an infinite loop will occur.
*
* Since: 2.22
*/
@@ -914,9 +913,8 @@ rsvg_handle_get_dimensions_sub (RsvgHandle * handle, RsvgDimensionData * dimensi
* rsvg_handle_get_position_sub:
* @handle: A #RsvgHandle
* @position_data: (out): A place to store the SVG fragment's position.
- * @id: An element's id within the SVG.
- * For example, if you have a layer called "layer1" for that you want to get
- * the position, pass "##layer1" as the id.
+ * @id: (nullable): An element's id within the SVG, starting with "##", for
+ * example, "##layer1"; or %NULL to use the whole SVG.
*
* Get the position of a subelement of the SVG file. Do not call from within
* the size_func callback, because an infinite loop will occur.
@@ -1000,7 +998,7 @@ bail:
/**
* rsvg_handle_has_sub:
* @handle: a #RsvgHandle
- * @id: an element's id within the SVG
+ * @id: an element's id within the SVG, starting with "##", for example, "##layer1".
*
* Checks whether the element @id exists in the SVG document.
*
diff --git a/rsvg.c b/rsvg.c
index 8c993410..cf3e4dba 100644
--- a/rsvg.c
+++ b/rsvg.c
@@ -45,9 +45,8 @@
/**
* rsvg_handle_get_pixbuf_sub:
* @handle: An #RsvgHandle
- * @id: (nullable): The id of an element inside the SVG, or %NULL to
- * render the whole SVG. For example, if you have a layer called
- * "layer1" that you wish to render, pass "##layer1" as the id.
+ * @id: (nullable): An element's id within the SVG, starting with "##", for
+ * example, "##layer1"; or %NULL to use the whole SVG.
*
* Returns the pixbuf loaded by @handle. The pixbuf returned will be reffed, so
* the caller of this function must assume that ref. If insufficient data has