Skip to content

Class pinnacle.input.libinput.DeviceHandle

Fields

sysname

sysname: string

Functions

method capabilities

function pinnacle.input.libinput.DeviceHandle:capabilities()
    -> pinnacle.input.libinput.Capabilities

Gets this device's libinput capabilities.

Returns

  1. pinnacle.input.libinput.Capabilities

method name

function pinnacle.input.libinput.DeviceHandle:name()
    -> string

Gets the name of this device.

Returns

  1. string

method product_id

function pinnacle.input.libinput.DeviceHandle:product_id()
    -> integer

Gets this device;s product id.

Returns

  1. integer

method vendor_id

function pinnacle.input.libinput.DeviceHandle:vendor_id()
    -> integer

Gets this devices vendor id.

Returns

  1. integer

method device_type

function pinnacle.input.libinput.DeviceHandle:device_type()
    -> pinnacle.input.libinput.DeviceType

Gets the type of this device.

Note: This uses heuristics to determine the type and may not be correct. For example a device with both pointer and keyboard capabilities will be a "mouse" when it may actually be a keyboard.

Returns

  1. pinnacle.input.libinput.DeviceType

method map_to_output

function pinnacle.input.libinput.DeviceHandle:map_to_output(output: pinnacle.output.OutputHandle)

Maps the absolute input from this device to the corresponding output.

This will cause touch input from this device to map proportionally to the area of an output. For example, tapping in the middle of the device will generate a tap event at the middle of the output.

This only affects devices with touch capability.

Parameters

output: pinnacle.output.OutputHandle - The output to map the device's input to

See also

method map_to_region

function pinnacle.input.libinput.DeviceHandle:map_to_region(region: { x: integer, y: integer, width: integer, height: integer })

Maps the absolute input from this device to the corresponding region in the global space.

This will cause touch input from this device to map proportionally to the given region within the global space. For example, tapping in the middle of the device will generate a tap event at the middle of the region. This can be used to map a touch device to more than one output, for example.

This only affects devices with touch capability.

Parameters

region: { x: integer, y: integer, width: integer, height: integer } - The region in the global space to map input to

See also

method set_accel_profile

function pinnacle.input.libinput.DeviceHandle:set_accel_profile(accel_profile: pinnacle.input.libinput.AccelProfile)

Parameters

accel_profile: pinnacle.input.libinput.AccelProfile

method set_accel_speed

function pinnacle.input.libinput.DeviceHandle:set_accel_speed(accel_speed: number)

Parameters

accel_speed: number

method set_calibration_matrix

function pinnacle.input.libinput.DeviceHandle:set_calibration_matrix(calibration_matrix: number[])

Parameters

calibration_matrix: number[] - 6 floats

method set_click_method

function pinnacle.input.libinput.DeviceHandle:set_click_method(click_method: pinnacle.input.libinput.ClickMethod)

Parameters

click_method: pinnacle.input.libinput.ClickMethod

method set_disable_while_typing

function pinnacle.input.libinput.DeviceHandle:set_disable_while_typing(disable_while_typing: boolean)

Parameters

disable_while_typing: boolean

method set_left_handed

function pinnacle.input.libinput.DeviceHandle:set_left_handed(left_handed: boolean)

Parameters

left_handed: boolean

method set_middle_emulation

function pinnacle.input.libinput.DeviceHandle:set_middle_emulation(middle_emulation: boolean)

Parameters

middle_emulation: boolean

method set_rotation_angle

function pinnacle.input.libinput.DeviceHandle:set_rotation_angle(rotation_angle: integer)

Parameters

rotation_angle: integer

method set_scroll_button

function pinnacle.input.libinput.DeviceHandle:set_scroll_button(scroll_button: integer)

Parameters

scroll_button: integer

method set_scroll_button_lock

function pinnacle.input.libinput.DeviceHandle:set_scroll_button_lock(scroll_button_lock: boolean)

Parameters

scroll_button_lock: boolean

method set_scroll_method

function pinnacle.input.libinput.DeviceHandle:set_scroll_method(scroll_method: pinnacle.input.libinput.ScrollMethod)

Parameters

scroll_method: pinnacle.input.libinput.ScrollMethod

method set_natural_scroll

function pinnacle.input.libinput.DeviceHandle:set_natural_scroll(natural_scroll: boolean)

Parameters

natural_scroll: boolean

method set_tap_button_map

function pinnacle.input.libinput.DeviceHandle:set_tap_button_map(tap_button_map: pinnacle.input.libinput.TapButtonMap)

Parameters

tap_button_map: pinnacle.input.libinput.TapButtonMap

method set_tap_drag

function pinnacle.input.libinput.DeviceHandle:set_tap_drag(tap_drag: boolean)

Parameters

tap_drag: boolean

method set_tap_drag_lock

function pinnacle.input.libinput.DeviceHandle:set_tap_drag_lock(tap_drag_lock: boolean)

Parameters

tap_drag_lock: boolean

method set_tap

function pinnacle.input.libinput.DeviceHandle:set_tap(tap: boolean)

Parameters

tap: boolean

method set_send_events_mode

function pinnacle.input.libinput.DeviceHandle:set_send_events_mode(send_events_mode: pinnacle.input.libinput.SendEventsMode)

Parameters

send_events_mode: pinnacle.input.libinput.SendEventsMode