[gtk+] Fix up docs for new cursor apis
- From: Matthias Clasen <matthiasc src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk+] Fix up docs for new cursor apis
- Date: Sat, 10 Aug 2013 00:25:21 +0000 (UTC)
commit 2cdc5d440a10d0f24434b2350d44b669f3b58158
Author: Matthias Clasen <mclasen redhat com>
Date: Fri Aug 9 19:48:23 2013 -0400
Fix up docs for new cursor apis
The docs for gdk_cursor_new_from_surface were talking about
pixbufs. And the new APIs were not appearing in the docs
at all yet.
docs/reference/gdk/gdk3-sections.txt | 2 ++
gdk/gdkcursor.c | 21 ++++++++++-----------
2 files changed, 12 insertions(+), 11 deletions(-)
---
diff --git a/docs/reference/gdk/gdk3-sections.txt b/docs/reference/gdk/gdk3-sections.txt
index 0de0a14..e8568f0 100644
--- a/docs/reference/gdk/gdk3-sections.txt
+++ b/docs/reference/gdk/gdk3-sections.txt
@@ -897,10 +897,12 @@ GdkCursor
GdkCursorType
gdk_cursor_new
gdk_cursor_new_from_pixbuf
+gdk_cursor_new_from_surface
gdk_cursor_new_from_name
gdk_cursor_new_for_display
gdk_cursor_get_display
gdk_cursor_get_image
+gdk_cursor_get_surface
gdk_cursor_get_cursor_type
gdk_cursor_ref
gdk_cursor_unref
diff --git a/gdk/gdkcursor.c b/gdk/gdkcursor.c
index a336ea7..7d4e453 100644
--- a/gdk/gdkcursor.c
+++ b/gdk/gdkcursor.c
@@ -391,10 +391,10 @@ gdk_cursor_new_from_pixbuf (GdkDisplay *display,
* gdk_cursor_new_from_surface:
* @display: the #GdkDisplay for which the cursor will be created
* @surface: the cairo image surface containing the cursor pixel data
- * @x: the horizontal offset of the 'hotspot' of the cursor.
- * @y: the vertical offset of the 'hotspot' of the cursor.
+ * @x: the horizontal offset of the 'hotspot' of the cursor
+ * @y: the vertical offset of the 'hotspot' of the cursor
*
- * Creates a new cursor from a pixbuf.
+ * Creates a new cursor from a cairo image surface.
*
* Not all GDK backends support RGBA cursors. If they are not
* supported, a monochrome approximation will be displayed.
@@ -413,10 +413,10 @@ gdk_cursor_new_from_pixbuf (GdkDisplay *display,
* Since: 3.10
*/
GdkCursor *
-gdk_cursor_new_from_surface (GdkDisplay *display,
+gdk_cursor_new_from_surface (GdkDisplay *display,
cairo_surface_t *surface,
- gdouble x,
- gdouble y)
+ gdouble x,
+ gdouble y)
{
g_return_val_if_fail (GDK_IS_DISPLAY (display), NULL);
g_return_val_if_fail (surface != NULL, NULL);
@@ -514,7 +514,7 @@ gdk_cursor_get_image (GdkCursor *cursor)
* @x_hot: Location to store the hotspot x position, or %NULL
* @y_hot: Location to store the hotspot y position, or %NULL
*
- * Returns a #cairo_surface_t (image surface) with the image used to display the cursor.
+ * Returns a cairo image surface with the image used to display the cursor.
*
* Note that depending on the capabilities of the windowing system and
* on the cursor, GDK may not be able to obtain the image data. In this
@@ -526,11 +526,10 @@ gdk_cursor_get_image (GdkCursor *cursor)
*/
cairo_surface_t *
gdk_cursor_get_surface (GdkCursor *cursor,
- gdouble *x_hot,
- gdouble *y_hot)
+ gdouble *x_hot,
+ gdouble *y_hot)
{
g_return_val_if_fail (GDK_IS_CURSOR (cursor), NULL);
- return GDK_CURSOR_GET_CLASS (cursor)->get_surface (cursor,
- x_hot, y_hot);
+ return GDK_CURSOR_GET_CLASS (cursor)->get_surface (cursor, x_hot, y_hot);
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]