Compare commits

...

26 Commits

Author SHA1 Message Date
Povilas Kanapickas
cbdd9efaab xf86-input-libinput 1.2.0
Signed-off-by: Povilas Kanapickas <povilas@radix.lt>
2021-09-19 19:55:46 +03:00
Peter Hutterer
4c54f4d0d2 Rename HAS_GESTURES to HAVE_GESTURES
HAVE_FOO is generally used everywhere (see HAVE_CONFIG_H) so let's keep
this consistent.

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2021-09-16 11:23:53 +10:00
Povilas Kanapickas
8331214771 gitlab-ci: Configure xorgproto build from source
We need newer xorgproto than what's in fedora as we depend on inputproto
2.3.99.1 or newer.
2021-09-16 11:23:53 +10:00
Povilas Kanapickas
8588a19f63 Require inputproto 2.4 to build the gesture support
Signed-off-by: Povilas Kanapickas <povilas@radix.lt>
2021-09-16 11:23:33 +10:00
Peter Hutterer
beb94333e1 Use the new v120 API from libinput if available
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2021-08-06 08:45:01 +02:00
José Expósito
ca9042c7f0 Get scroll source in the event handler
Where libinput supports high-resolution scroll events, the scroll source
is encoded in the event type.

Get the scroll source in xf86libinput_handle_event to facilitate the
migration.

Refactor, no functional changes.

Signed-off-by: José Expósito <jose.exposito89@gmail.com>
2021-08-04 17:51:26 +02:00
Peter Hutterer
bf8dc2e2ed Upgrade the default scroll distance to 120
This is just a number, to be used as divider and shouldn't have any effect in
correctly written clients. With the high-res scrolling coming up however, we
have a few devices where the dist cannot be expressed as an integer fraction
of 15, so let's up it to 120 because we know all hardware wheels have to be an
integer fraction of that that, thanks to Microsoft's API requirements.

For non-wheel scrolls we need to now map into the new range. Previously we
just passed the scroll events on from the touchpad/button scrolling, meaning a
vdist of 15 meant 15 "libinput pixels" of scrolling resulted in a logical
wheel click. Now that we have 120 as vdist, we need to times the input data by
8 to keep the same proportions.

See 39b0bb4585 for the previous revert.

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2021-08-04 12:09:54 +02:00
Povilas Kanapickas
ecd845c307 Implement support for touchpad gestures 2021-07-05 13:35:02 +00:00
Peter Hutterer
0d9184cb76 xf86-input-libinput 1.1.0
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2021-06-24 08:26:19 +10:00
Peter Hutterer
9bb9e635df Implement a touchpad scroll distance property
To be used for touchpads and continuous (i.e. button-based scrolling).

libinput provides us with pixel data for finger-based and button-based
scrolling but the X server does support this - XI2.1 smooth scrolling is
merely centered around a logical scroll click (defined as "increment"), with
smooth scrolling being a fraction of that increment. For example, in the old
synaptics driver that value was in device-specific units and thus different
for every device.

The increment is a constant value set in the ScrollClass and cannot be changed
at device runtime. So we simply initialize with a random default (15, because
that works well for wheels) and then scale our pixel delta in to that range.

With the default value, a 15 pixel movement would result in a logical scroll
click, if the distance is set to 30 the users has to move 30 pixels to trigger
that scroll click. Pixel here being defined as the deltas that libinput
provides to us.

From the client's perspective nothing changes, the increment is still the
same.

Range checks are quite restrictive, this option is supposed to improve
usability, not as a workaround around other bugs.

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2021-05-05 13:34:36 +10:00
Peter Hutterer
cc10918bdc Fix a spacing issue
yay for copy/paste proliferation

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2021-05-05 13:18:19 +10:00
Peter Hutterer
69888cef81 xf86-input-libinput 1.0.1
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2021-04-16 12:18:24 +10:00
Peter Hutterer
6c1c53d296 Make sure the device is valid when setting the tap button map
Fixes #34

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2021-04-09 10:33:15 +10:00
Peter Hutterer
34f14fdf12 xf86-input-libinput 1.0.0
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2021-04-06 15:55:45 +10:00
Peter Hutterer
92047e5d99 gitlab CI: bump to use Fedora 33
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2021-04-06 15:55:45 +10:00
Peter Hutterer
b8d3c29f59 Remove trailing whitespaces
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2021-04-06 15:51:35 +10:00
Peter Hutterer
2bbc4727a1 Switch to the real MIT license
Due to a copy/paste error, the COPYING file and subsequently created files
with the same content referred to the "Historical Permission Notice and
Disclaimer - sell variant", not the proper MIT license.

Replace with the proper MIT (Expat) license and add the use SPDX license
identifiers.

Acks below are from contributors with substantial changes, collected in MR !19
or via private email correspondence.

https://gitlab.freedesktop.org/xorg/driver/xf86-input-libinput/-/merge_requests/19

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Acked-by: Dorian Stoll <dorian.stoll@tmsp.io>
Acked-by: Jonas Ådahl <jadahl@gmail.com>
Acked-by: Benjamin Tissoires <benjamin.tissoires@gmail.com>
Acked-by: Evangelos Foutras <evangelos@foutrelis.com>
Acked-by: Niklas Haas <git@haasn.xyz>
Acked-by: Olivier Fourdan <ofourdan@redhat.com>
Acked-by: David Rosca <nowrep@gmail.com>
Acked-by: Lyude Paul <lyude@redhat.com>
Acked-by: Keith Packard <keithp@keithp.com>
Acked-by: Alan Coopersmith <alan.coopersmith@oracle.com>
Acked-by: Michel Dänzer <michel@daenzer.net>
Acked-by: Tim Writer <tim.writer@amd.com>
Acked-by: Friedrich Schöller <code@schoeller.se>
Acked-by: Mikhail Konev <k.mvc@ya.ru>
Acked-by: Martin Pieuchot <mpi@openbsd.org>
2021-03-24 13:28:56 +10:00
Dorian Stoll
39be944991 Lift canceled touch inputs
If a touch input gets turned into a palm (by setting ABS_MT_TOOL_TYPE to
MT_TOOL_PALM), libinput will emit a cancel event instead of the normal
up event. The xorg wrapper needs to be able to handle a canceled touch
and lift it, otherwise these inputs will never get lifted and will stick
around forever.

Signed-off-by: Dorian Stoll <dorian.stoll@tmsp.io>
2020-11-04 23:53:01 +01:00
Povilas Kanapickas
bd2aaa246d Remove extraneous semicolon 2020-10-19 21:09:49 +03:00
Povilas Kanapickas
99773d7bda Remove unused btnmap variables 2020-10-19 21:07:47 +03:00
Peter Hutterer
3afb6244e3 Bump the server requirement to 1.19 to get rid of a bunch of ifdefs
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2020-05-19 16:34:18 +10:00
Peter Hutterer
f279108ffd Bump the libinput requirement to 1.11
Released June 2018, that should be recent enough.

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2020-05-19 16:30:35 +10:00
Peter Hutterer
583ed5acdc xf86-input-libinput 0.30.0
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2020-05-19 15:58:13 +10:00
Peter Hutterer
e8e5d1a6b5 gitlab CI: update to latest CI templates
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2020-05-19 15:58:13 +10:00
Peter Hutterer
639b21d78a gitlab CI: bump to Fedora 32
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2020-05-19 15:47:11 +10:00
Peter Hutterer
e52daf203b Implement support for scroll button locks
Add a boolean option/property to enable/disable the scroll button lock. Where
enabled, the button can be clicked and released as opposed to having to be
held down.

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2019-10-11 11:18:52 +10:00
15 changed files with 739 additions and 304 deletions

4
.gitignore vendored
View File

@@ -71,11 +71,11 @@ core
*.tar.bz2
*.tar.gz
#
# Add & Override patterns for xf86-input-libinput
# Add & Override patterns for xf86-input-libinput
#
# Edit the following section as needed
# For example, !report.pc overrides *.pc. See 'man gitignore'
#
#
*.log
*.trs
*.swp

View File

@@ -1,33 +1,46 @@
# vim: set expandtab shiftwidth=2 tabstop=8 textwidth=0:
include:
- project: 'wayland/ci-templates'
ref: 955e61e67cf29327cf907432f668df9eec4ca6a2 # see https://docs.gitlab.com/ee/ci/yaml/#includefile
- project: 'freedesktop/ci-templates'
ref: 59de540b620c45739871d1a073d76d5521989d11 # see https://docs.gitlab.com/ee/ci/yaml/#includefile
file: '/templates/fedora.yml'
variables:
FEDORA_RPMS: 'git autoconf automake libtool make xorg-x11-server-devel libudev-devel libevdev-devel libinput-devel xorg-x11-util-macros'
FEDORA_TAG: '2019-08-12.0'
UPSTREAM_REPO: xorg/drivers/xf86-input-libinput
BUILDAH_IMAGE: $CI_REGISTRY/wayland/ci-templates/buildah:latest
FEDORA_CONTAINER_IMAGE: $CI_REGISTRY_IMAGE/fedora/$FEDORA_VERSION:$FEDORA_TAG
FDO_UPSTREAM_REPO: xorg/drivers/xf86-input-libinput
stages:
- containers-build
- containers
- build
container_build:
extends: .fedora@container-ifnot-exists
stage: containers-build
.fedora:
variables:
FDO_DISTRIBUTION_VERSION: 33
FDO_DISTRIBUTION_PACKAGES: 'git autoconf automake libtool make xorg-x11-server-devel libudev-devel libevdev-devel libinput-devel xorg-x11-util-macros'
FDO_DISTRIBUTION_EXEC: 'env FDO_CI_CONCURRENT=${FDO_CI_CONCURRENT} bash .gitlab-ci/fedora-install.sh'
FDO_DISTRIBUTION_TAG: '2021-09-15.0'
fedora@container_build:
extends:
- .fedora
- .fdo.container-build@fedora
stage: containers
variables:
GIT_STRATEGY: none
FEDORA_VERSION: 30
.default_artifacts: &default_artifacts
.default_build:
stage: build
script:
- mkdir _builddir _inst
- pushd _builddir > /dev/null
- ../autogen.sh --prefix=$(realpath ../_inst) --disable-silent-rules
- make && make check
- make install
- popd > /dev/null
artifacts:
name: "automake-logs-$CI_JOB_NAME"
when: always
@@ -36,29 +49,8 @@ container_build:
- _builddir/config.log
.default_build: &default_build
script:
- mkdir _builddir _inst
- pushd _builddir > /dev/null
- ../autogen.sh --prefix=$(realpath ../_inst) --disable-silent-rules
- make && make check
- make install
- popd > /dev/null
.build@template:
stage: build
<<: *default_artifacts
<<: *default_build
dependencies: []
.fedora-build@template:
extends: .build@template
image: $FEDORA_CONTAINER_IMAGE
fedora:30@default-build:
extends: .fedora-build@template
variables:
FEDORA_VERSION: 30
fedora:33@default-build:
extends:
- .fedora
- .fdo.distribution-image@fedora
- .default_build

9
.gitlab-ci/fedora-install.sh Executable file
View File

@@ -0,0 +1,9 @@
#!/bin/bash
# we require at least inputproto >= 2.3.99.1 which has been released in xorgproto 2021.5
git clone https://gitlab.freedesktop.org/xorg/proto/xorgproto.git --depth 1 --branch=xorgproto-2021.5
pushd xorgproto
./autogen.sh
make -j${FDO_CI_CONCURRENT:-4} install
popd
rm -rf xorgproto

36
COPYING
View File

@@ -1,20 +1,20 @@
Copyright © 2014 Red Hat, Inc.
SPDX-License-Identifier: MIT
Permission to use, copy, modify, distribute, and sell this software
and its documentation for any purpose is hereby granted without
fee, provided that the above copyright notice appear in all copies
and that both that copyright notice and this permission notice
appear in supporting documentation, and that the name of the authors
not be used in advertising or publicity pertaining to distribution of the
software without specific, written prior permission. The authors make no
representations about the suitability of this software for any
purpose. It is provided "as is" without express or implied
warranty.
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to
deal in the Software without restriction, including without limitation the
rights to use, copy, modify, merge, publish, distribute, sublicense, and/or
sell copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:
THE AUTHORS DISCLAIM ALL WARRANTIES WITH REGARD TO THIS SOFTWARE,
INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN
NO EVENT SHALL THE AUTHORS BE LIABLE FOR ANY SPECIAL, INDIRECT OR
CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS
OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT,
NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN
CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
The above copyright notice and this permission notice (including the next
paragraph) shall be included in all copies or substantial portions of the
Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS
IN THE SOFTWARE.

View File

@@ -23,7 +23,7 @@
# Initialize Autoconf
AC_PREREQ([2.60])
AC_INIT([xf86-input-libinput],
[0.29.0],
[1.2.0],
[https://gitlab.freedesktop.org/xorg/driver/xf86-input-libinput/issues],
[xf86-input-libinput])
AC_CONFIG_SRCDIR([Makefile.am])
@@ -38,29 +38,45 @@ AC_DISABLE_STATIC
LT_INIT
# Initialize X.Org macros 1.8 or later for MAN_SUBSTS set by XORG_MANPAGE_SECTIONS
m4_ifndef([XORG_MACROS_VERSION],
m4_ifndef([XORG_MACROS_VERSION],
[m4_fatal([must install xorg-macros 1.8 or later before running autoconf/autogen])])
XORG_MACROS_VERSION(1.8)
XORG_DEFAULT_OPTIONS
# Obtain compiler/linker options from server and required extensions
PKG_CHECK_MODULES(XORG, [xorg-server >= 1.10] xproto [inputproto >= 2.2])
PKG_CHECK_MODULES(LIBINPUT, [libinput >= 1.7.0])
PKG_CHECK_MODULES(XORG, [xorg-server >= 1.19] xproto [inputproto >= 2.2])
PKG_CHECK_MODULES(LIBINPUT, [libinput >= 1.11.0])
PKG_CHECK_MODULES(INPUTPROTO24, [inputproto >= 2.3.99.1],
[AC_DEFINE(HAVE_INPUTPROTO24, [1], [inputproto 2.4 is available])])
OLD_LIBS=$LIBS
OLD_CFLAGS=$CFLAGS
LIBS="$LIBS $LIBINPUT_LIBS"
CFLAGS="$CFLAGS $LIBINPUT_CFLAGS"
AC_MSG_CHECKING([if libinput_device_touch_get_touch_count is available])
AC_MSG_CHECKING([if libinput_device_config_scroll_get_button_lock is available])
AC_LINK_IFELSE(
[AC_LANG_PROGRAM([[#include <libinput.h>]],
[[libinput_device_touch_get_touch_count(NULL)]])],
[[libinput_device_config_scroll_get_button_lock(NULL)]])],
[AC_MSG_RESULT([yes])
AC_DEFINE(HAVE_LIBINPUT_TOUCH_COUNT, [1],
[libinput_device_touch_get_touch_count() is available])
[libinput_have_touch_count=yes]],
AC_DEFINE(HAVE_LIBINPUT_SCROLL_BUTTON_LOCK, [1],
[libinput_device_config_scroll_get_button_lock() is available])
[libinput_have_scroll_button_lock=yes]],
[AC_MSG_RESULT([no])
[libinput_have_touch_count=no]])
[libinput_have_scroll_button_lock=no]])
AC_MSG_CHECKING([if libinput_event_pointer_get_scroll_value_v120 is available])
AC_LINK_IFELSE(
[AC_LANG_PROGRAM([[#include <libinput.h>]],
[[libinput_event_pointer_get_scroll_value_v120(NULL, 0)]])],
[AC_MSG_RESULT([yes])
AC_DEFINE(HAVE_LIBINPUT_AXIS_VALUE_V120, [1],
[libinput_event_pointer_get_scroll_value_v120() is available])
[libinput_have_axis_value_v120=yes]],
[AC_MSG_RESULT([no])
[libinput_have_axis_value_v120=no]])
LIBS=$OLD_LIBS
CFLAGS=$OLD_CFLAGS

View File

@@ -1,24 +1,26 @@
/*
* SPDX-License-Identifier: MIT
*
* Copyright © 2015 Red Hat, Inc.
*
* Permission to use, copy, modify, distribute, and sell this software
* and its documentation for any purpose is hereby granted without
* fee, provided that the above copyright notice appear in all copies
* and that both that copyright notice and this permission notice
* appear in supporting documentation, and that the name of Red Hat
* not be used in advertising or publicity pertaining to distribution
* of the software without specific, written prior permission. Red
* Hat makes no representations about the suitability of this software
* for any purpose. It is provided "as is" without express or implied
* warranty.
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to
* deal in the Software without restriction, including without limitation the
* rights to use, copy, modify, merge, publish, distribute, sublicense, and/or
* sell copies of the Software, and to permit persons to whom the Software is
* furnished to do so, subject to the following conditions:
*
* THE AUTHORS DISCLAIM ALL WARRANTIES WITH REGARD TO THIS SOFTWARE,
* INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN
* NO EVENT SHALL THE AUTHORS BE LIABLE FOR ANY SPECIAL, INDIRECT OR
* CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS
* OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT,
* NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN
* CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
* The above copyright notice and this permission notice (including the next
* paragraph) shall be included in all copies or substantial portions of the
* Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
* FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS
* IN THE SOFTWARE.
*/
#ifndef _LIBINPUT_PROPERTIES_H_
@@ -115,6 +117,18 @@
/* Scroll button for button scrolling: 32-bit int, 1 value, read-only */
#define LIBINPUT_PROP_SCROLL_BUTTON_DEFAULT "libinput Button Scrolling Button Default"
/* Scroll button lock: BOOL, 1 value, TRUE for enabled, FALSE otherwise */
#define LIBINPUT_PROP_SCROLL_BUTTON_LOCK "libinput Button Scrolling Button Lock Enabled"
/* Scroll button lock: BOOL, 1 value, TRUE for enabled, FALSE otherwise, read-only*/
#define LIBINPUT_PROP_SCROLL_BUTTON_LOCK_DEFAULT "libinput Button Scrolling Button Lock Enabled Default"
/* Scroll pixel distance: CARD32, 1 value (with implementation-defined limits) */
#define LIBINPUT_PROP_SCROLL_PIXEL_DISTANCE "libinput Scrolling Pixel Distance"
/* Scroll pixel distance: CARD32, 1 value, read-only */
#define LIBINPUT_PROP_SCROLL_PIXEL_DISTANCE_DEFAULT "libinput Scrolling Pixel Distance Default"
/* Click method: BOOL read-only, 2 values in order buttonareas, clickfinger
shows available click methods */
#define LIBINPUT_PROP_CLICK_METHODS_AVAILABLE "libinput Click Methods Available"

View File

@@ -18,7 +18,7 @@
# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
# FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
# DEALINGS IN THE SOFTWARE.
#
#
drivermandir = $(DRIVER_MAN_DIR)

View File

@@ -139,9 +139,18 @@ Designates a button as scroll button. If the
.BI ScrollMethod
is
.BI button
and the button is logically held down, x/y axis movement is converted into
and the button is logically down, x/y axis movement is converted into
scroll events.
.TP 7
.BI "Option \*qScrollButtonLock\*q \*q" bool \*q
Enables or disables the scroll button lock. If enabled, the
.BI ScrollButton
is considered logically down after the first click and remains down until
the second click of that button. If disabled (the default), the
.BI ScrollButton
button is considered logically down while held down and up once physically
released.
.TP 7
.BI "Option \*qScrollMethod\*q \*q" string \*q
Enables a scroll method. Permitted values are
.BI none,
@@ -151,6 +160,16 @@ Enables a scroll method. Permitted values are
Not all devices support all options, if an option is unsupported, the
default scroll option for this device is used.
.TP 7
.BI "Option \*qScrollPixelDistance\*q \*q" int \*q
Sets the movement distance, in "pixels", required to trigger one logical
wheel click. This option only applies to the scroll methods
.BI twofinger,
.BI edge,
.BI button.
See section
.B SCROLL PIXEL DISTANCE
for more details.
.TP 7
.BI "Option \*qSendEventsMode\*q \*q" (disabled|enabled|disabled-on-external-mouse) \*q
Sets the send events mode to disabled, enabled, or "disable when an external
mouse is connected".
@@ -219,6 +238,12 @@ Indicates which acceleration profile is currently enabled on this device.
setting is independent of the scroll method, to enable button scrolling the
method must be set to button-scrolling and a valid button must be set.
.TP 7
.BI "libinput Button Scrolling Button Lock Enabled"
1 boolean value. If true, the scroll button lock is enabled. This
setting is independent of the scroll method or the scroll button, to enable
button scrolling the method must be set to button-scrolling and a valid
button must be set.
.TP 7
.BI "libinput Calibration Matrix"
9 32-bit float values, representing a 3x3 calibration matrix, order is row
1, row 2, row 3
@@ -264,6 +289,10 @@ Indicates which scroll methods are available on this device.
3 boolean values (8 bit, 0 or 1), in order "two-finger", "edge", "button".
Indicates which scroll method is currently enabled on this device.
.TP 7
.BI "libinput Scroll Pixel Distance"
1 32-bit value (nonzero, with additional implementation-defined range checks).
Changes the movement distance required to trigger one logical wheel click.
.TP 7
.BI "libinput Send Events Modes Available"
2 boolean values (8 bit, 0 or 1), in order "disabled" and
"disabled-on-external-mouse". Indicates which send-event modes are available
@@ -381,6 +410,17 @@ it takes left-handed-ness into account.
.TP
This feature is provided by this driver, not by libinput.
.SH SCROLL PIXEL DISTANCE
The X server does not support per-pixel scrolling but it does support
smooth scrolling. All scroll events however are based around a logical
unit of scrolling (traditionally corresponding to a wheel click).
It is thus not possible to scroll by 10 pixels, but it is possible for a
driver to scroll by 1/10th of a logical wheel click.
.PP
libinput provides scroll data in pixels. The \fBScrollPixelDistance\fR
option defines the amount of movement equivalent to one wheel click. For
example, a value of 50 means the user has to move a finger by 50 pixels to
generate one logical click event and each pixel is 1/50th of a wheel click.
.SH BUGS
This driver does not work with \fBOption \*qDevice\*q\fR set to an event
node in \fI/dev/input/by-id\fR and \fI/dev/input/by-path\fR. This can be

View File

@@ -1,24 +1,26 @@
/*
* SPDX-License-Identifier: MIT
*
* Copyright © 2016 Red Hat, Inc.
*
* Permission to use, copy, modify, distribute, and sell this software
* and its documentation for any purpose is hereby granted without
* fee, provided that the above copyright notice appear in all copies
* and that both that copyright notice and this permission notice
* appear in supporting documentation, and that the name of Red Hat
* not be used in advertising or publicity pertaining to distribution
* of the software without specific, written prior permission. Red
* Hat makes no representations about the suitability of this software
* for any purpose. It is provided "as is" without express or implied
* warranty.
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to
* deal in the Software without restriction, including without limitation the
* rights to use, copy, modify, merge, publish, distribute, sublicense, and/or
* sell copies of the Software, and to permit persons to whom the Software is
* furnished to do so, subject to the following conditions:
*
* THE AUTHORS DISCLAIM ALL WARRANTIES WITH REGARD TO THIS SOFTWARE,
* INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN
* NO EVENT SHALL THE AUTHORS BE LIABLE FOR ANY SPECIAL, INDIRECT OR
* CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS
* OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT,
* NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN
* CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
* The above copyright notice and this permission notice (including the next
* paragraph) shall be included in all copies or substantial portions of the
* Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
* FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS
* IN THE SOFTWARE.
*/
#ifdef HAVE_CONFIG_H

View File

@@ -1,24 +1,26 @@
/*
* SPDX-License-Identifier: MIT
*
* Copyright © 2016 Red Hat, Inc.
*
* Permission to use, copy, modify, distribute, and sell this software
* and its documentation for any purpose is hereby granted without
* fee, provided that the above copyright notice appear in all copies
* and that both that copyright notice and this permission notice
* appear in supporting documentation, and that the name of Red Hat
* not be used in advertising or publicity pertaining to distribution
* of the software without specific, written prior permission. Red
* Hat makes no representations about the suitability of this software
* for any purpose. It is provided "as is" without express or implied
* warranty.
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to
* deal in the Software without restriction, including without limitation the
* rights to use, copy, modify, merge, publish, distribute, sublicense, and/or
* sell copies of the Software, and to permit persons to whom the Software is
* furnished to do so, subject to the following conditions:
*
* THE AUTHORS DISCLAIM ALL WARRANTIES WITH REGARD TO THIS SOFTWARE,
* INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN
* NO EVENT SHALL THE AUTHORS BE LIABLE FOR ANY SPECIAL, INDIRECT OR
* CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS
* OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT,
* NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN
* CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
* The above copyright notice and this permission notice (including the next
* paragraph) shall be included in all copies or substantial portions of the
* Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
* FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS
* IN THE SOFTWARE.
*/
#ifdef HAVE_CONFIG_H

View File

@@ -1,24 +1,26 @@
/*
* SPDX-License-Identifier: MIT
*
* Copyright © 2015 Red Hat, Inc.
*
* Permission to use, copy, modify, distribute, and sell this software
* and its documentation for any purpose is hereby granted without
* fee, provided that the above copyright notice appear in all copies
* and that both that copyright notice and this permission notice
* appear in supporting documentation, and that the name of Red Hat
* not be used in advertising or publicity pertaining to distribution
* of the software without specific, written prior permission. Red
* Hat makes no representations about the suitability of this software
* for any purpose. It is provided "as is" without express or implied
* warranty.
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to
* deal in the Software without restriction, including without limitation the
* rights to use, copy, modify, merge, publish, distribute, sublicense, and/or
* sell copies of the Software, and to permit persons to whom the Software is
* furnished to do so, subject to the following conditions:
*
* THE AUTHORS DISCLAIM ALL WARRANTIES WITH REGARD TO THIS SOFTWARE,
* INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN
* NO EVENT SHALL THE AUTHORS BE LIABLE FOR ANY SPECIAL, INDIRECT OR
* CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS
* OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT,
* NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN
* CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
* The above copyright notice and this permission notice (including the next
* paragraph) shall be included in all copies or substantial portions of the
* Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
* FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS
* IN THE SOFTWARE.
*/
#ifdef HAVE_CONFIG_H

View File

@@ -1,24 +1,26 @@
/*
* SPDX-License-Identifier: MIT
*
* Copyright © 2015 Red Hat, Inc.
*
* Permission to use, copy, modify, distribute, and sell this software
* and its documentation for any purpose is hereby granted without
* fee, provided that the above copyright notice appear in all copies
* and that both that copyright notice and this permission notice
* appear in supporting documentation, and that the name of Red Hat
* not be used in advertising or publicity pertaining to distribution
* of the software without specific, written prior permission. Red
* Hat makes no representations about the suitability of this software
* for any purpose. It is provided "as is" without express or implied
* warranty.
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to
* deal in the Software without restriction, including without limitation the
* rights to use, copy, modify, merge, publish, distribute, sublicense, and/or
* sell copies of the Software, and to permit persons to whom the Software is
* furnished to do so, subject to the following conditions:
*
* THE AUTHORS DISCLAIM ALL WARRANTIES WITH REGARD TO THIS SOFTWARE,
* INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN
* NO EVENT SHALL THE AUTHORS BE LIABLE FOR ANY SPECIAL, INDIRECT OR
* CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS
* OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT,
* NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN
* CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
* The above copyright notice and this permission notice (including the next
* paragraph) shall be included in all copies or substantial portions of the
* Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
* FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS
* IN THE SOFTWARE.
*/
#ifdef HAVE_CONFIG_H

File diff suppressed because it is too large Load Diff

View File

@@ -1,24 +1,26 @@
/*
* SPDX-License-Identifier: MIT
*
* Copyright © 2016 Red Hat, Inc.
*
* Permission to use, copy, modify, distribute, and sell this software
* and its documentation for any purpose is hereby granted without
* fee, provided that the above copyright notice appear in all copies
* and that both that copyright notice and this permission notice
* appear in supporting documentation, and that the name of Red Hat
* not be used in advertising or publicity pertaining to distribution
* of the software without specific, written prior permission. Red
* Hat makes no representations about the suitability of this software
* for any purpose. It is provided "as is" without express or implied
* warranty.
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to
* deal in the Software without restriction, including without limitation the
* rights to use, copy, modify, merge, publish, distribute, sublicense, and/or
* sell copies of the Software, and to permit persons to whom the Software is
* furnished to do so, subject to the following conditions:
*
* THE AUTHORS DISCLAIM ALL WARRANTIES WITH REGARD TO THIS SOFTWARE,
* INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN
* NO EVENT SHALL THE AUTHORS BE LIABLE FOR ANY SPECIAL, INDIRECT OR
* CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS
* OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT,
* NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN
* CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
* The above copyright notice and this permission notice (including the next
* paragraph) shall be included in all copies or substantial portions of the
* Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
* FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS
* IN THE SOFTWARE.
*/
#include "bezier.h"

View File

@@ -1,24 +1,26 @@
/*
* SPDX-License-Identifier: MIT
*
* Copyright © 2013-2015 Red Hat, Inc.
*
* Permission to use, copy, modify, distribute, and sell this software
* and its documentation for any purpose is hereby granted without
* fee, provided that the above copyright notice appear in all copies
* and that both that copyright notice and this permission notice
* appear in supporting documentation, and that the name of Red Hat
* not be used in advertising or publicity pertaining to distribution
* of the software without specific, written prior permission. Red
* Hat makes no representations about the suitability of this software
* for any purpose. It is provided "as is" without express or implied
* warranty.
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to
* deal in the Software without restriction, including without limitation the
* rights to use, copy, modify, merge, publish, distribute, sublicense, and/or
* sell copies of the Software, and to permit persons to whom the Software is
* furnished to do so, subject to the following conditions:
*
* THE AUTHORS DISCLAIM ALL WARRANTIES WITH REGARD TO THIS SOFTWARE,
* INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN
* NO EVENT SHALL THE AUTHORS BE LIABLE FOR ANY SPECIAL, INDIRECT OR
* CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS
* OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT,
* NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN
* CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
* The above copyright notice and this permission notice (including the next
* paragraph) shall be included in all copies or substantial portions of the
* Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
* FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS
* IN THE SOFTWARE.
*/
#include "draglock.h"