gesturepan: Convert docs

This commit is contained in:
Matthias Clasen 2021-03-01 01:43:55 -05:00 committed by Emmanuele Bassi
parent 207c4cd9e1
commit ca3363466f

View File

@ -18,24 +18,22 @@
*/
/**
* SECTION:gtkgesturepan
* @Short_description: Pan gesture
* @Title: GtkGesturePan
* GtkGesturePan:
*
* #GtkGesturePan is a #GtkGesture implementation able to recognize
* pan gestures, those are drags that are locked to happen along one
* axis. The axis that a #GtkGesturePan handles is defined at
* construct time, and can be changed through
* gtk_gesture_pan_set_orientation().
* `GtkGesturePan` is a `GtkGesture` for pan gestures.
*
* When the gesture starts to be recognized, #GtkGesturePan will
* These are drags that are locked to happen along one axis. The axis
* that a `GtkGesturePan` handles is defined at construct time, and
* can be changed through [method@Gtk.GesturePan.set_orientation].
*
* When the gesture starts to be recognized, `GtkGesturePan` will
* attempt to determine as early as possible whether the sequence
* is moving in the expected direction, and denying the sequence if
* this does not happen.
*
* Once a panning gesture along the expected axis is recognized,
* the #GtkGesturePan::pan signal will be emitted as input events
* are received, containing the offset in the given axis.
* the [signal@Gtk.GesturePan::pan] signal will be emitted as input
* events are received, containing the offset in the given axis.
*/
#include "config.h"
@ -226,7 +224,7 @@ gtk_gesture_pan_class_init (GtkGesturePanClass *klass)
drag_gesture_class->drag_end = gtk_gesture_pan_drag_end;
/**
* GtkGesturePan:orientation:
* GtkGesturePan:orientation: (attributes org.gtk.Property.get=gtk_gesture_pan_get_orientation org.gtk.Property.set=gtk_gesture_pan_set_orientation)
*
* The expected orientation of pan gestures.
*/
@ -245,8 +243,7 @@ gtk_gesture_pan_class_init (GtkGesturePanClass *klass)
* @direction: current direction of the pan gesture
* @offset: Offset along the gesture orientation
*
* This signal is emitted once a panning gesture along the
* expected axis is detected.
* Emitted once a panning gesture along the expected axis is detected.
*/
signals[PAN] =
g_signal_new (I_("pan"),
@ -275,10 +272,10 @@ gtk_gesture_pan_init (GtkGesturePan *gesture)
* gtk_gesture_pan_new:
* @orientation: expected orientation
*
* Returns a newly created #GtkGesture that recognizes pan gestures.
* Returns a newly created `GtkGesture` that recognizes pan gestures.
*
* Returns: a newly created #GtkGesturePan
**/
* Returns: a newly created `GtkGesturePan`
*/
GtkGesture *
gtk_gesture_pan_new (GtkOrientation orientation)
{
@ -288,8 +285,8 @@ gtk_gesture_pan_new (GtkOrientation orientation)
}
/**
* gtk_gesture_pan_get_orientation:
* @gesture: A #GtkGesturePan
* gtk_gesture_pan_get_orientation: (attributes org.gtk.Method.get_property=orientation)
* @gesture: A `GtkGesturePan`
*
* Returns the orientation of the pan gestures that this @gesture expects.
*
@ -308,8 +305,8 @@ gtk_gesture_pan_get_orientation (GtkGesturePan *gesture)
}
/**
* gtk_gesture_pan_set_orientation:
* @gesture: A #GtkGesturePan
* gtk_gesture_pan_set_orientation: (attributes org.gtk.Method.set_property=orientation)
* @gesture: A `GtkGesturePan`
* @orientation: expected orientation
*
* Sets the orientation to be expected on pan gestures.