gi-gdk-3.0.16: Gdk bindings

CopyrightWill Thompson Iñaki García Etxebarria and Jonas Platte
LicenseLGPL-2.1
MaintainerIñaki García Etxebarria (garetxe@gmail.com)
Safe HaskellNone
LanguageHaskell2010

GI.Gdk.Structs.EventTouch

Contents

Description

Used for touch events. type field will be one of EventTypeTouchBegin, EventTypeTouchUpdate, EventTypeTouchEnd or EventTypeTouchCancel.

Touch events are grouped into sequences by means of the sequence field, which can also be obtained with eventGetEventSequence. Each sequence begins with a EventTypeTouchBegin event, followed by any number of EventTypeTouchUpdate events, and ends with a EventTypeTouchEnd (or EventTypeTouchCancel) event. With multitouch devices, there may be several active sequences at the same time.

Synopsis

Exported types

newtype EventTouch Source #

Memory-managed wrapper type.

newZeroEventTouch :: MonadIO m => m EventTouch Source #

Construct a EventTouch struct initialized to zero.

Properties

axes

x, y translated to the axes of device, or Nothing if device is the mouse

getEventTouchAxes :: MonadIO m => EventTouch -> m Double Source #

Get the value of the “axes” field. When overloading is enabled, this is equivalent to

get eventTouch #axes

setEventTouchAxes :: MonadIO m => EventTouch -> Double -> m () Source #

Set the value of the “axes” field. When overloading is enabled, this is equivalent to

set eventTouch [ #axes := value ]

device

the master device that the event originated from. Use eventGetSourceDevice to get the slave device.

clearEventTouchDevice :: MonadIO m => EventTouch -> m () Source #

Set the value of the “device” field to Nothing. When overloading is enabled, this is equivalent to

clear #device

getEventTouchDevice :: MonadIO m => EventTouch -> m (Maybe Device) Source #

Get the value of the “device” field. When overloading is enabled, this is equivalent to

get eventTouch #device

setEventTouchDevice :: MonadIO m => EventTouch -> Ptr Device -> m () Source #

Set the value of the “device” field. When overloading is enabled, this is equivalent to

set eventTouch [ #device := value ]

emulatingPointer

whether the event should be used for emulating pointer event

getEventTouchEmulatingPointer :: MonadIO m => EventTouch -> m Bool Source #

Get the value of the “emulating_pointer” field. When overloading is enabled, this is equivalent to

get eventTouch #emulatingPointer

setEventTouchEmulatingPointer :: MonadIO m => EventTouch -> Bool -> m () Source #

Set the value of the “emulating_pointer” field. When overloading is enabled, this is equivalent to

set eventTouch [ #emulatingPointer := value ]

sendEvent

True if the event was sent explicitly.

getEventTouchSendEvent :: MonadIO m => EventTouch -> m Int8 Source #

Get the value of the “send_event” field. When overloading is enabled, this is equivalent to

get eventTouch #sendEvent

setEventTouchSendEvent :: MonadIO m => EventTouch -> Int8 -> m () Source #

Set the value of the “send_event” field. When overloading is enabled, this is equivalent to

set eventTouch [ #sendEvent := value ]

sequence

the event sequence that the event belongs to

clearEventTouchSequence :: MonadIO m => EventTouch -> m () Source #

Set the value of the “sequence” field to Nothing. When overloading is enabled, this is equivalent to

clear #sequence

getEventTouchSequence :: MonadIO m => EventTouch -> m (Maybe EventSequence) Source #

Get the value of the “sequence” field. When overloading is enabled, this is equivalent to

get eventTouch #sequence

setEventTouchSequence :: MonadIO m => EventTouch -> Ptr EventSequence -> m () Source #

Set the value of the “sequence” field. When overloading is enabled, this is equivalent to

set eventTouch [ #sequence := value ]

state

a bit-mask representing the state of the modifier keys (e.g. Control, Shift and Alt) and the pointer buttons. See ModifierType

getEventTouchState :: MonadIO m => EventTouch -> m [ModifierType] Source #

Get the value of the “state” field. When overloading is enabled, this is equivalent to

get eventTouch #state

setEventTouchState :: MonadIO m => EventTouch -> [ModifierType] -> m () Source #

Set the value of the “state” field. When overloading is enabled, this is equivalent to

set eventTouch [ #state := value ]

time

the time of the event in milliseconds.

getEventTouchTime :: MonadIO m => EventTouch -> m Word32 Source #

Get the value of the “time” field. When overloading is enabled, this is equivalent to

get eventTouch #time

setEventTouchTime :: MonadIO m => EventTouch -> Word32 -> m () Source #

Set the value of the “time” field. When overloading is enabled, this is equivalent to

set eventTouch [ #time := value ]

type

getEventTouchType :: MonadIO m => EventTouch -> m EventType Source #

Get the value of the “type” field. When overloading is enabled, this is equivalent to

get eventTouch #type

setEventTouchType :: MonadIO m => EventTouch -> EventType -> m () Source #

Set the value of the “type” field. When overloading is enabled, this is equivalent to

set eventTouch [ #type := value ]

window

the window which received the event

clearEventTouchWindow :: MonadIO m => EventTouch -> m () Source #

Set the value of the “window” field to Nothing. When overloading is enabled, this is equivalent to

clear #window

getEventTouchWindow :: MonadIO m => EventTouch -> m (Maybe Window) Source #

Get the value of the “window” field. When overloading is enabled, this is equivalent to

get eventTouch #window

setEventTouchWindow :: MonadIO m => EventTouch -> Ptr Window -> m () Source #

Set the value of the “window” field. When overloading is enabled, this is equivalent to

set eventTouch [ #window := value ]

x

the x coordinate of the pointer relative to the window

getEventTouchX :: MonadIO m => EventTouch -> m Double Source #

Get the value of the “x” field. When overloading is enabled, this is equivalent to

get eventTouch #x

setEventTouchX :: MonadIO m => EventTouch -> Double -> m () Source #

Set the value of the “x” field. When overloading is enabled, this is equivalent to

set eventTouch [ #x := value ]

xRoot

the x coordinate of the pointer relative to the root of the screen

getEventTouchXRoot :: MonadIO m => EventTouch -> m Double Source #

Get the value of the “x_root” field. When overloading is enabled, this is equivalent to

get eventTouch #xRoot

setEventTouchXRoot :: MonadIO m => EventTouch -> Double -> m () Source #

Set the value of the “x_root” field. When overloading is enabled, this is equivalent to

set eventTouch [ #xRoot := value ]

y

the y coordinate of the pointer relative to the window

getEventTouchY :: MonadIO m => EventTouch -> m Double Source #

Get the value of the “y” field. When overloading is enabled, this is equivalent to

get eventTouch #y

setEventTouchY :: MonadIO m => EventTouch -> Double -> m () Source #

Set the value of the “y” field. When overloading is enabled, this is equivalent to

set eventTouch [ #y := value ]

yRoot

the y coordinate of the pointer relative to the root of the screen

getEventTouchYRoot :: MonadIO m => EventTouch -> m Double Source #

Get the value of the “y_root” field. When overloading is enabled, this is equivalent to

get eventTouch #yRoot

setEventTouchYRoot :: MonadIO m => EventTouch -> Double -> m () Source #

Set the value of the “y_root” field. When overloading is enabled, this is equivalent to

set eventTouch [ #yRoot := value ]