Commit graph

213 commits

Author SHA1 Message Date
Peter Hutterer
00272cfbb1 Add support for LIBINPUT_IGNORE_DEVICE
The recommended way to have libinput ignore specific devices so far was to
remove the ID_INPUT* properties from the device. That may also affect other
pieces of the stack that need access to this device.

For the niche case of a device that should only be ignored by libinput but
otherwise be treated normally by the system, we now support the
LIBINPUT_IGNORE_DEVICE property.

If the property is set to "0", it's equivalent to being unset. This gets
around some technical limitations in udev where unsetting a property is
impossible via a hwdb entry.

https://bugs.freedesktop.org/show_bug.cgi?id=102229

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-08-23 14:56:51 +10:00
Peter Hutterer
55d1bb1217 pointer: add button debouncing
Some devices have worn-out switches or just cheap switches that trigger
multiple button events for each press. These can be identified by unfeasably
short time deltas between the release and the next press event. In the
recordings I've seen so far, that timeout is 8ms.

We have a two-stage behavior: by default, we do not delay any events but we
monitor timestamps. The first time a bouncing button is detected we switch to
debounce mode. From then on, release events are delayed slightly to check for
subsequent button events. If one occurs, the releas and press are filtered. If
none occurs, the release event is passed to the caller.

https://bugs.freedesktop.org/show_bug.cgi?id=100057

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-07-26 00:21:46 +10:00
Peter Hutterer
87b5682824 filter: add a custom trackpoint accelerator
Switch to a pure factor with a max scaled after a function. The offset is just
0 now (will be removed eventually). Both are determined with a function based
on a linear/exponential regression of a sample set of data pairs.

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-07-20 11:53:01 +10:00
Ming-Yang Lu
5dc330bdea touchpad: add upper edge into exclusion zone
This reduces unexpected cursor moves when placing the thumb near the border
of trackpoint buttons and upper edge of touchpad.

https://bugs.freedesktop.org/show_bug.cgi?id=101574

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-07-10 09:33:24 +10:00
Peter Hutterer
930714a094 doc: update the soname, remove the warning
The soname will remain fixed now, we're going through all the trouble of
having a proper map file so that we don't have to bump it all the time.

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-07-05 11:13:31 +10:00
Peter Hutterer
9b738d0071 doc: fix a few typos
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-07-05 11:13:31 +10:00
Peter Hutterer
696778cc78 doc: move the autotools instructions into their own section
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-07-05 11:13:31 +10:00
Peter Hutterer
7b98f8ef47 doc: expand on the meson build instructions
https://bugs.freedesktop.org/show_bug.cgi?id=101686

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-07-05 09:53:13 +10:00
Peter Hutterer
ca9d6a88d7 Merge branch 'wip/touchpad-palm-pressure' 2017-07-04 13:57:32 +10:00
Peter Hutterer
302aaa548e Drop autotools
This also makes the gitignore files shorter and/or obsolete.

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-07-04 13:44:07 +10:00
Peter Hutterer
cf0d442ad3 tools: add a tool to measure touch pressure
And update the documentation for how to use the new tool. It's much more
interactive than evemu and easier to grasp, so let's advertise that.

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-07-03 15:58:58 +10:00
Peter Hutterer
25d54b90db touchpad: add pressure-base palm detection
If a touch goes past the fixed pressure threshold it is labelled as a palm and
stays a palm. Default value is one that works well here on a T440 and is
virtually impossible to trigger by a normal finger or thumb. A udev property
is exposed so we can handle this in the udev hwdb and the new tool introduce a
few commits ago can help finding the palm detection threshold.

Unlike the other palm detection features, once a palm goes past the threshold
it remains a palm until the touch is released. This means palm overrides any
other palm detection features. For code simplicity, we don't combine the
states but merely check for pressure before and after the other palm detection
functions. If the pressure triggers, it will trigger before anything else. And
if something else is already active (e.g. edge where the pressure doesn't work
well) it will trigger as soon as the palm is released.

The palm threshold should thus be chosen with some room to spare between the
highest finger pressure.

https://bugs.freedesktop.org/show_bug.cgi?id=94236

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-07-03 15:58:13 +10:00
Eric Engestrom
2ee95c7b76 doc: update build instructions for Arch
`abs` has been deprecated, and shut down last month. [1]
`asp` replaces it, so rewrite the instructions to use this instead.

Also, add `--noextract` to the makepkg command, as there is no point
downloading and extracting the sources since they're not going to be
built here.

[1] https://www.archlinux.org/news/deprecation-of-abs/

Signed-off-by: Eric Engestrom <eric.engestrom@imgtec.com>
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-06-21 08:41:45 +10:00
Peter Hutterer
948cd6ee54 doc: add instructions for handling SELinux denials
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Eric Engestrom <eric.engestrom@imgtec.com>
2017-06-21 08:30:55 +10:00
Philippe Coval
4cf9f8bee1 doc: Fix mistake in Matrix example to relect only X along Y axis
On some devices, X coordinate is not working well, like if it is swapped:
click on right, pointer appear on left and vice versa.

To sort this issue, coordinates should be reflected on Y axis:
- new X position is changed (width is subtracted by X position)
- Y is unchanged (it was wrongly set to X)

In landscape (or portrait) mode:

                [  x  ]
                [  y  ]
                [  1  ]
              *    =
  [ -1 0 1  ]   [  x' ] = -x + 0*y + 1*width
  [  0 1 0  ]   [  y' ] = 0*x + 1*y + 0*height
  [  0 0 1  ]   [  1  ]

This was verified using this touch screen (usb="0eef:0001")

  E: ID_VENDOR=eGalax_Inc.
  E: ID_VENDOR_ENC=eGalax\x20Inc.
  E: ID_VENDOR_ID=0eef

https://bugs.freedesktop.org/show_bug.cgi?id=101474

Signed-off-by: Philippe Coval <philippe.coval@osg.samsung.com>
Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-06-20 16:43:49 +10:00
Peter Hutterer
3a17d0da5e doc: drop the Fedora "ninja-build" note
The packages have been in stable for 6 weeks as of this patch, let's not worry
about the old ones.

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-06-19 13:11:58 +10:00
Peter Hutterer
2c9de57667 doc: use the same formatting for the gcc command as for everything else
Without the @code tag, the font size differs to everything else in this file

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-06-13 12:32:43 +10:00
Peter Hutterer
bb5db8dbca doc: update building notes with the bug to ninja vs ninja-build on Fedora
Up-to-date Fedora doesn't need to use ninja-build anymore

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-06-13 12:30:35 +10:00
Peter Hutterer
b3779caef7 doc: add a short blurb regarding lid switch handling
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-06-13 12:21:33 +10:00
Peter Hutterer
319db5b7df doc: update for the new libinput tool
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-06-02 12:21:35 +10:00
Peter Hutterer
96fa4266d0 doc: add build instructions for meson
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-05-04 13:50:06 +10:00
Peter Hutterer
64cac88a9f doc: drop the explicit input from the doxygen.in
We pass in the input via the commandline, so having the files here is
misleading. Replace it with an @INPUT@ - in autotools that one is ignored but
it'll help meson.

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-05-04 13:49:37 +10:00
Peter Hutterer
de7365bb0a doc: update build instructions for lack of autodetection
Since we dropped autodetection of features in configure, these instructions
were incorrect.

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-05-04 13:47:26 +10:00
Peter Hutterer
2d032019b6 doc: document the event timestamps
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-05-02 15:32:19 +10:00
Peter Hutterer
8a626394c9 doc: add a faq for synclient/syndaemon
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-04-28 10:12:29 +10:00
Peter Hutterer
bed7e62a0d doc: add documentation for touchpad pressure detection
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-04-26 12:38:15 +10:00
Peter Hutterer
938aa25843 Rename README to README.md, include properly from doxygen
As of doxygen 1.8.3 (Dec 2012) doxygen can include a README.md directly as
mainpage. This avoids the ugly doxygen bits we have in the current README.

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-04-25 10:56:51 +10:00
Peter Hutterer
927ad51fad doc: link the seats doc from the seat udev properties
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-04-24 09:53:20 +10:00
Peter Hutterer
c7039eacb3 doc: drop superfluous </pre> tag
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-04-20 13:50:21 +10:00
Nate Graham
88eaa7c1fd Fix build instructions for openSUSE
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=100527

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-04-04 10:24:26 +10:00
Peter Hutterer
e6342d409e doc: expand on the default tap settings
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-03-09 14:03:22 +10:00
Peter Hutterer
bb3d6e000e doc: expand build instructinos
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-03-08 14:36:56 +10:00
Peter Hutterer
fd67204cf2 doc: add a custom css for local overrides
Easier to track if we leave the original files alone. Actual changes to the
doxygen style:

* indent <dd> blocks
* hide the navigation sub-items. Our current style expands the full navigation
  menu but File-list, etc. is mostly useless and just wastes space.
* force some space below the main bar
* change the header sizes around a bit. Primary goal here: making <h1> smaller
  than the title

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-02-23 08:20:20 +10:00
Peter Hutterer
8a79d8a487 doc: allow custom styles to overide the bootstrap style
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-02-23 08:19:37 +10:00
Peter Hutterer
5bb4a6e87f doc: disable the search engine/search box
It was just floating around lonely there and I doubt anyone really used it.

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-02-23 08:19:32 +10:00
Peter Hutterer
d248049f8d doc: minor documentation fix
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-02-23 07:04:55 +10:00
Peter Hutterer
b23318492e doc: add a page "what is libinput"
This will eventually feature the architecture diagrams, etc. But for now it's
mostly just a list of what will be and what won't be supported.

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-02-13 10:47:11 +10:00
Peter Hutterer
00db4252f3 doc: link to tapping page from the FAQ
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-02-13 10:46:59 +10:00
Peter Hutterer
7920691464 doc: make the tap-to-click default setting a separate section
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-02-13 10:45:47 +10:00
Peter Hutterer
45d7794de2 Merge branch 'wip/switch-interface' 2017-02-01 13:56:32 +10:00
Peter Hutterer
a5cefb76ac doc: add a table of contents to the FAQ
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-01-31 09:52:22 +10:00
Peter Hutterer
aae997e60e doc: update the FAQ entry with how config options are stored
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-01-30 10:11:21 +10:00
James Ye
1f0223e9fd Add a "switch" interface for parts of the SW_* range
This will allow switch devices known to libinput to be exposed. Currently,
this is SW_LID.

libinput also handles switch events internally, e.g. a laptop touchpad will
be disabled autmoatically when the lid is closed. This is transparent to
the caller, although the caller will also receive the event. See
https://bugs.freedesktop.org/show_bug.cgi?id=86223
This features is intended to be the main driver for the interface.

Co-Authored-By: Peter Hutterer <peter.hutterer@who-t.net>
Signed-off-by: James Ye <jye836@gmail.com>
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2017-01-26 14:44:04 +10:00
Peter Hutterer
7e5062f632 doc: update the touchpad pointer acceleration svg
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Hans de Goede <hdegoede@redhat.com>
2016-12-21 10:55:57 +10:00
Peter Hutterer
ab83c8e626 doc: remove unnecessary linebreak in doxygen file
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2016-11-23 10:42:57 +10:00
Peter Hutterer
e0ccfc87f0 doc: expand trackpoint pointer acceleration documentation a bit
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2016-11-03 14:01:39 +10:00
Peter Hutterer
33ee8d46e6 doc: add a small page about contributing to libinput
To be expanded at some future time...

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2016-10-25 10:02:07 +10:00
Peter Hutterer
9590fb953f doc: reshuffle the "reporting bugs" page
Split it into several device-specific sections

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2016-10-19 10:21:51 +10:00
Peter Hutterer
31a168abcd doc: specify the https path for mathjax
freedesktop.org always serves https for the documentation. if Mathjax is
pulled in from http, browsers reject it [1]

Let's take the default doxygen value but just add the https to it. In the
future we should just ship a copy of mathjax with our documentation.

[1] https://developer.mozilla.org/en-US/docs/Web/Security/Mixed_content/How_to_fix_website_with_mixed_content

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Wheres-my-beer-by: Yong Bakos <ybakos@humanoriented.com>
Reviewed-by: Yong Bakos <ybakos@humanoriented.com>
2016-09-14 16:23:02 +10:00
Peter Hutterer
b519ea4ab5 tablet: add touch arbitration
So far we've relied on the wacom kernel module to do touch arbitration for us
but that won't be the case in upcoming kernels. Implement touch arbitration in
userspace by pairing the two devices and suspending the touch device whenever
a tool comes into proximity.

In the future more sophisticated arbitration can be done (e.g. only touches
which are close to the pen) but let's burn that bridge when we have to cross
it.

Note that touch arbitration is "device suspend light", i.e. we leave the
device enabled and the fd is active. Tablet interactions are comparatively
short-lived, so closing the fd and asking logind for a new one every time the
pen changes proximity is suboptimal. Instead, we just keep a boolean around
and discard all events while it is set.

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
Reviewed-by: Jason Gerecke <jason.gerecke@wacom.com>
2016-09-07 11:17:03 +10:00