:right-sidebar: True GestureLongPress =================================================================== .. currentmodule:: gi.repository.Gtk .. class:: GestureLongPress(**properties: ~typing.Any) :no-contents-entry: Superclasses: :class:`~gi.repository.Gtk.GestureSingle`, :class:`~gi.repository.Gtk.Gesture`, :class:`~gi.repository.Gtk.EventController`, :class:`~gi.repository.GObject.Object` :Constructors: :: GestureLongPress(**properties) new() -> Gtk.Gesture Constructors ------------ .. rst-class:: interim-class .. class:: GestureLongPress :no-index: .. classmethod:: new() -> ~gi.repository.Gtk.Gesture Returns a newly created ``GtkGesture`` that recognizes long presses. Methods ------- .. rst-class:: interim-class .. class:: GestureLongPress :no-index: .. method:: get_delay_factor() -> float Returns the delay factor. .. method:: set_delay_factor(delay_factor: float) -> None Applies the given delay factor. The default long press time will be multiplied by this value. Valid values are in the range [0.5..2.0]. :param delay_factor: The delay factor to apply Properties ---------- .. rst-class:: interim-class .. class:: GestureLongPress :no-index: .. attribute:: props.delay_factor :type: float Factor by which to modify the default timeout. Signals ------- .. rst-class:: interim-class .. class:: GestureLongPress.signals :no-index: .. method:: cancelled() -> None Emitted whenever a press moved too far, or was released before :obj:`~gi.repository.Gtk.GestureLongPress.signals.pressed` happened. .. method:: pressed(x: float, y: float) -> None Emitted whenever a press goes unmoved/unreleased longer than what the GTK defaults tell. :param x: the X coordinate where the press happened, relative to the widget allocation :param y: the Y coordinate where the press happened, relative to the widget allocation