Gtk.Gesture_Drag.Gtk_Gesture_Drag is a Gtk.Gesture.Gtk_Gesture implementation that recognizes drag operations. The drag operation itself can be tracked throught the Gtk.Gesture_Drag.Gtk_Gesture_Drag::drag-begin, Gtk.Gesture_Drag.Gtk_Gesture_Drag::drag-update and Gtk.Gesture_Drag.Gtk_Gesture_Drag::drag-end signals, or the relevant coordinates be extracted through Gtk.Gesture_Drag.Get_Offset and Gtk.Gesture_Drag.Get_Start_Point.
type Cb_GObject_Gdouble_Gdouble_Void is not null access procedure
(Self : access Glib.Object.GObject_Record'Class;
Start_X : Gdouble;
Start_Y : Gdouble);
type Cb_Gtk_Gesture_Drag_Gdouble_Gdouble_Void is not null access procedure
(Self : access Gtk_Gesture_Drag_Record'Class;
Start_X : Gdouble;
Start_Y : Gdouble);
function Get_Offset
(Self : not null access Gtk_Gesture_Drag_Record;
X : access Gdouble;
Y : access Gdouble) return Boolean
If the Gesture is active, this function returns True and fills in X and Y with the coordinates of the current point, as an offset to the starting drag point. Since: gtk+ 3.14
X offset for the current point
Y offset for the current point
True if the gesture is active
function Get_Start_Point
(Self : not null access Gtk_Gesture_Drag_Record;
X : access Gdouble;
Y : access Gdouble) return Boolean
If the Gesture is active, this function returns True and fills in X and Y with the drag start coordinates, in window-relative coordinates. Since: gtk+ 3.14
X coordinate for the drag start point
Y coordinate for the drag start point
True if the gesture is active
function Get_Type return Glib.GType
type Gtk_Gesture_Drag is access all Gtk_Gesture_Drag_Record'Class;
function Gtk_Gesture_Drag_New
(Widget : not null access Gtk.Widget.Gtk_Widget_Record'Class)
return Gtk_Gesture_Drag
Returns a newly created Gtk.Gesture.Gtk_Gesture that recognizes drags. Since: gtk+ 3.14
a Gtk.Widget.Gtk_Widget
type Gtk_Gesture_Drag_Record is new Gtk_Gesture_Single_Record with null record;
procedure Gtk_New
(Self : out Gtk_Gesture_Drag;
Widget : not null access Gtk.Widget.Gtk_Widget_Record'Class)
Returns a newly created Gtk.Gesture.Gtk_Gesture that recognizes drags. Since: gtk+ 3.14 Initialize does nothing if the object was already created with another call to Initialize* or G_New.
a Gtk.Widget.Gtk_Widget
procedure Initialize
(Self : not null access Gtk_Gesture_Drag_Record'Class;
Widget : not null access Gtk.Widget.Gtk_Widget_Record'Class)
Returns a newly created Gtk.Gesture.Gtk_Gesture that recognizes drags. Since: gtk+ 3.14 Initialize does nothing if the object was already created with another call to Initialize* or G_New.
a Gtk.Widget.Gtk_Widget
procedure On_Drag_Begin
(Self : not null access Gtk_Gesture_Drag_Record;
Call : Cb_GObject_Gdouble_Gdouble_Void;
Slot : not null access Glib.Object.GObject_Record'Class;
After : Boolean := False)
This signal is emitted whenever dragging starts.
Callback parameters: -- @param Start_X X coordinate, relative to the widget allocation -- @param Start_Y Y coordinate, relative to the widget allocation
procedure On_Drag_Begin
(Self : not null access Gtk_Gesture_Drag_Record;
Call : Cb_Gtk_Gesture_Drag_Gdouble_Gdouble_Void;
After : Boolean := False)
This signal is emitted whenever dragging starts.
Callback parameters: -- @param Start_X X coordinate, relative to the widget allocation -- @param Start_Y Y coordinate, relative to the widget allocation
procedure On_Drag_End
(Self : not null access Gtk_Gesture_Drag_Record;
Call : Cb_GObject_Gdouble_Gdouble_Void;
Slot : not null access Glib.Object.GObject_Record'Class;
After : Boolean := False)
This signal is emitted whenever the dragging is finished.
Callback parameters: -- @param Offset_X X offset, relative to the start point -- @param Offset_Y Y offset, relative to the start point
procedure On_Drag_End
(Self : not null access Gtk_Gesture_Drag_Record;
Call : Cb_Gtk_Gesture_Drag_Gdouble_Gdouble_Void;
After : Boolean := False)
This signal is emitted whenever the dragging is finished.
Callback parameters: -- @param Offset_X X offset, relative to the start point -- @param Offset_Y Y offset, relative to the start point
procedure On_Drag_Update
(Self : not null access Gtk_Gesture_Drag_Record;
Call : Cb_GObject_Gdouble_Gdouble_Void;
Slot : not null access Glib.Object.GObject_Record'Class;
After : Boolean := False)
This signal is emitted whenever the dragging point moves.
Callback parameters: -- @param Offset_X X offset, relative to the start point -- @param Offset_Y Y offset, relative to the start point
procedure On_Drag_Update
(Self : not null access Gtk_Gesture_Drag_Record;
Call : Cb_Gtk_Gesture_Drag_Gdouble_Gdouble_Void;
After : Boolean := False)
This signal is emitted whenever the dragging point moves.
Callback parameters: -- @param Offset_X X offset, relative to the start point -- @param Offset_Y Y offset, relative to the start point
Signal_Drag_Begin : constant Glib.Signal_Name := "drag-begin";
This signal is emitted whenever dragging starts.
Callback parameters: -- @param Start_X X coordinate, relative to the widget allocation -- @param Start_Y Y coordinate, relative to the widget allocation
Signal_Drag_End : constant Glib.Signal_Name := "drag-end";
This signal is emitted whenever the dragging is finished.
Callback parameters: -- @param Offset_X X offset, relative to the start point -- @param Offset_Y Y offset, relative to the start point
Signal_Drag_Update : constant Glib.Signal_Name := "drag-update";
This signal is emitted whenever the dragging point moves.
Callback parameters: -- @param Offset_X X offset, relative to the start point -- @param Offset_Y Y offset, relative to the start point