package ocgtk

  1. Overview
  2. Docs
Legend:
Page
Library
Module
Module type
Parameter
Class
Class type
Source

Module Wrappers.Scroll_event

type t = [ `scroll_event | `event ] Gobject.obj
val is_stop : t -> bool

Check whether a scroll event is a stop scroll event.

Scroll sequences with smooth scroll information may provide a stop scroll event once the interaction with the device finishes, e.g. by lifting a finger. This stop scroll event is the signal that a widget may trigger kinetic scrolling based on the current velocity.

Stop scroll events always have a delta of 0/0.

val get_unit : t -> Gdk_enums.scrollunit

Extracts the scroll delta unit of a scroll event.

The unit will always be %GDK_SCROLL_UNIT_WHEEL if the scroll direction is not %GDK_SCROLL_SMOOTH.

val get_direction : t -> Gdk_enums.scrolldirection

Extracts the direction of a scroll event.

val get_deltas : t -> float * float

Extracts the scroll deltas of a scroll event.

The deltas will be zero unless the scroll direction is %GDK_SCROLL_SMOOTH.

For the representation unit of these deltas, see method@Gdk.ScrollEvent.get_unit.