doc/user: more documentation cleanups and fixes

Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
This commit is contained in:
Peter Hutterer 2018-07-31 18:17:48 +10:00
parent f955b2b73a
commit 6304dc1b19
10 changed files with 570 additions and 88 deletions

View file

@ -32,8 +32,8 @@ immediately and most release events are delivered immediately. The
does not enable this method unless a faulty event sequence is detected. A
message is printed to the log when spurious deboucing was detected.
Note that libinput's debouncing intended to correct hardware damage or
substandard hardware. Debouncing is also used as an accessibility feature
libinput's debouncing is supposed to correct hardware damage or
substandard hardware. Debouncing also exists as an accessibility feature
but the requirements are different. In the accessibility feature, multiple
physical key presses, usually caused by involuntary muscle movement, must be
filtered to only one key press. This feature must be implemented higher in
@ -49,3 +49,8 @@ correspond to the buttons 'pressed' and 'released' states, respectively.
:align: center
Diagram illustrating button debouncing"
Some devices send events in bursts, erroneously triggering the button
debouncing detection. Please :ref:`file a bug <reporting_bugs>` if that
occurs for your device.

View file

@ -4,22 +4,23 @@
Clickpad software button behavior
==============================================================================
Clickpad is the name given to touchpads without physical buttons below the
touchpad. Instead, the whole touchpad acts as a button and left or right
button clicks are distinguished by the location and/or number of fingers on
the touchpad.
("ClickPad" is a trademark by Synaptics Inc.)[http://www.synaptics.com/en/clickpad.php]
"Clickpads" are touchpads without separate physical buttons. Instead, the
whole touchpad acts as a button and left or right button clicks are
distinguished by :ref:`the location of the fingers <software_buttons>` or
the :ref:`number of fingers on the touchpad <clickfinger>`.
"ClickPad" is a trademark by `Synaptics Inc. <http://www.synaptics.com/en/clickpad.php>`_
but for simplicity we refer to any touchpad with the above feature as Clickpad,
regardless of the manufacturer.
A clickpad is always marked with the
The kernel marks clickpads with the
`INPUT_PROP_BUTTONPAD <https://www.kernel.org/doc/Documentation/input/event-codes.txt>`_
property. To perform a right-click on a Clickpad, libinput provides
:ref:`software_buttons` and @ref clickfinger.
property. Without this property, libinput would not know whether a touchpad
is a clickpad or not. To perform a right-click on a Clickpad, libinput
provides :ref:`software_buttons` and :ref:`clickfinger`.
In the page below, the term "click" shall refer to a physical button press
and/or release of the touchpad, the term "button event" refers to the events
generated by libinput and passed to the caller in response to a click.
.. note:: The term "click" refers refer to a physical button press
and/or release of the touchpad, the term "button event" refers to
the events generated by libinput in response to a click.
.. _software_buttons:
@ -27,10 +28,15 @@ generated by libinput and passed to the caller in response to a click.
Software button areas
------------------------------------------------------------------------------
On most clickpads, this is the default behavior. The bottom of the touchpad
is split into three distinct areas generate left, middle or right button
events on click. The height of the button area depends on the hardware but
is usually around 10mm.
The bottom of the touchpad is split into three distinct areas generate left,
middle or right button events on click. The height of the button area
depends on the hardware but is usually around 10mm.
.. figure :: software-buttons-visualized.svg
:align: center
The locations of the virtual button areas.
Left, right and middle button events can be triggered as follows:
@ -39,34 +45,49 @@ Left, right and middle button events can be triggered as follows:
- if a finger is in the right area, a click generates right button events.
- if a finger is in the middle area, a click generates middle button events.
The middle button is always centered on the touchpad and smaller in size
than the left or right button. The actual size is device-dependent though as
many touchpads do not have visible markings for the middle button the exact
location of the button is not visibly obvious.
.. figure:: software-buttons.svg
:align: center
Left, right and middle-button click with software button areas"
Left, right and middle-button click with software button areas
.. note:: If middle button emulation is enabled on a clickpad, only left and right
button areas are available. For more details, see
**libinput_device_config_middle_emulation_set_enabled()**.
The middle button is always centered on the touchpad and smaller in size
than the left or right button. The actual size is device-dependent. Many
touchpads do not have visible markings so the exact location of the button
is unfortunately not visibly obvious.
.. note:: If :ref:`middle button emulation <middle_button_emulation>` is
enabled on a clickpad, only left and right button areas are
available.
If fingers are down in the main area in addition to fingers in the
left or right button area, those fingers are are ignored.
A release event always releases the buttons logically down, regardless of
the current finger position
.. figure:: software-buttons-thumbpress.svg
:align: center
Only the location of the thumb determines whether it is a left, right or
middle click.
The movement of a finger can alter the button area behavior:
- if a finger starts in the main area and moves into the software button
area, the software buttons do not apply to that finger
- a finger in the software button area does not move the pointer
- if a finger moves out out of the button area it will control the pointer
if it's the first finger in the main area
- once a finger has moved out of the button area, it cannot move back in and
trigger a right or middle button event
- a finger moving within the software button area does not move the pointer
- once a finger moves out out of the button area it will control the
pointer (this only applies if there is no other finger down on the
touchpad)
.. figure:: software-buttons-conditions.svg
:align: center
**Left:** moving a finger into the right button area does not trigger a
right-button click.
**Right:** moving within the button areas does not generate pointer
motion.
On some touchpads, notably the 2015 Lenovo X1 Carbon 3rd series, the very
bottom end of the touchpad is outside of the sensor range but it is possible
@ -90,7 +111,7 @@ software-defined button areas.
.. figure:: clickfinger.svg
:align: center
One, two and three-finger click with Clickfinger behavior"
One, two and three-finger click with Clickfinger behavior
On some touchpads, libinput imposes a limit on how the fingers may be placed
on the touchpad. In the most common use-case this allows for a user to
@ -100,18 +121,12 @@ the touchpad.
.. figure:: clickfinger-distance.svg
:align: center
Illustration of the distance detection algorithm"
Illustration of the distance detection algorithm
In the illustration above the red area marks the proximity area around the
first finger. Since the thumb is outside of that area libinput considers the
click a single-finger click rather than a two-finger click.
Clickfinger configuration can be enabled through the
**libinput_device_config_click_set_method()** call. If clickfingers are
enabled on a touchpad with top software buttons, the top area will keep
acting as softbuttons for use with the trackpoint. Clickfingers will be used
everywhere else on the touchpad.
.. _special_clickpads:
------------------------------------------------------------------------------

View file

@ -6,7 +6,7 @@ libinput Features
Below is a list of features supported by libinput. The availability of
features usually depends on the device type and a device's capabilties.
Not all features are user-configurable, some rely on @see device-quirks
Not all features are user-configurable, some rely on :ref:`device-quirks`
to be useful.

View file

@ -4,42 +4,25 @@
Gestures
==============================================================================
libinput supports basic gestures on touchpads and other indirect input
devices. Two types of gestures are supported: :ref:`gestures_pinch` and
@ref gestures_swipe. Support for gestures depends on the hardware device, most
touchpads support both gestures and any device that may send gesture events
has the **LIBINPUT_DEVICE_CAP_GESTURE** capability set.
Note that libinput **does not** support gestures on touchscreens, see
:ref:`gestures_touchscreens`.
libinput supports :ref:`gestures_pinch` and :ref:`gestures_swipe` on most
modern touchpads and other indirect touch devices. Note that libinput **does
not** support gestures on touchscreens, see :ref:`gestures_touchscreens`.
.. _gestures_lifetime:
------------------------------------------------------------------------------
-----------------------------------------------------------------------------
Lifetime of a gesture
------------------------------------------------------------------------------
-----------------------------------------------------------------------------
A gesture's lifetime has three distinct stages: begin, update and end, each
with their own event types. Begin is sent when the fingers are first set
down or libinput decides that the gesture begins. For :ref:`gestures_pinch`
this sets the initial scale. Any events changing properties of the gesture
are sent as update events. On termination of the gesture, an end event is
sent.
A gesture starts when the finger position and/or finger motion is
unambiguous as to what gesture to trigger and continues until the first
finger belonging to this gesture is lifted.
A gesture includes the finger count (see
**libinput_event_gesture_get_finger_count()**) and that finger count remains the
same for the lifetime of a gesture. Thus, if a user puts down a fourth
finger during a three-finger swipe gesture, libinput will end
the three-finger gesture and, if applicable, start a four-finger swipe
gesture. A caller may decide that those gestures are semantically identical
and continue the two gestures as one single gesture.
**LIBINPUT_EVENT_GESTURE_PINCH_BEGIN**
**LIBINPUT_EVENT_GESTURE_PINCH_UPDATE**
**LIBINPUT_EVENT_GESTURE_PINCH_END**
**LIBINPUT_EVENT_GESTURE_PINCH_BEGIN**
**LIBINPUT_EVENT_GESTURE_SWIPE_UPDATE**
**LIBINPUT_EVENT_GESTURE_SWIPE_END**
A single gesture cannot change the finger count. For example, if a user
puts down a fourth finger during a three-finger swipe gesture, libinput will
end the three-finger gesture and, if applicable, start a four-finger swipe
gesture. A caller may however decide that those gestures are semantically
identical Tand continue the two gestures as one single gesture.
.. _gestures_pinch:
@ -59,7 +42,7 @@ to the initial finger position.
.. figure:: pinch-gestures.svg
:align: center
The pinch and rotate gestures"
The pinch and rotate gestures
The illustration above shows a basic pinch in the left image and a rotate in
the right angle. Not shown is a movement of the logical center if the
@ -85,7 +68,7 @@ gesture into an action or limit a gesture to specific directions only.
.. figure:: swipe-gestures.svg
:align: center
The swipe gestures"
The swipe gestures
The illustration above shows a vertical three-finger swipe. The coordinates
provided during the gesture are the movements of the logical center.
@ -107,14 +90,13 @@ screen as well as the context of those virtual objects:
.. figure:: touchscreen-gestures.svg
:align: center
Context-sensitivity of touchscreen gestures"
Context-sensitivity of touchscreen gestures
In this example, the finger movements are identical but in the left case
both fingers are located within the same window, thus suggesting an attempt
to zoom. In the right case both fingers are located on a window border,
thus suggesting a window movement. libinput only has knowledge of the finger
coordinates (and even then only in device coordinates, not in screen
coordinates) and thus cannot differentiate the two.
In the above example, the finger movements are identical but in the left
case both fingers are located within the same window, thus suggesting an
attempt to zoom. In the right case both fingers are located on a window
border, thus suggesting a window movement. libinput has no knowledge of the
window coordinates and thus cannot differentiate the two.
.. _gestures_softbuttons:
@ -124,14 +106,14 @@ Gestures with enabled software buttons
If the touchpad device is a :ref:`Clickpad <touchpads_buttons_clickpads>`, it
is recommended that a caller switches to :ref:`clickfinger`.
Usually fingers placed in a :ref:`software button area <software_buttons>` is not
considered for gestures, resulting in some gestures to be interpreted as
pointer motion or two-finger scroll events.
Usually fingers placed in a :ref:`software button area <software_buttons>`
are not considered for gestures, resulting in some gestures to be
interpreted as pointer motion or two-finger scroll events.
.. figure:: pinch-gestures-softbuttons.svg
:align: center
Interference of software buttons and pinch gestures"
Interference of software buttons and pinch gestures
In the example above, the software button area is highlighted in red. The
user executes a three-finger pinch gesture, with the thumb remaining in the
@ -161,7 +143,7 @@ determined.
.. figure:: gesture-2fg-ambiguity.svg
:align: center
Ambiguity of three-finger gestures on two-finger touchpads"
Ambiguity of three-finger gestures on two-finger touchpads
The image above illustrates this ambiguity. The index and middle finger are
set down first, the data stream from both finger positions looks identical.

View file

@ -37,6 +37,9 @@ src_extra = [
'svg/ptraccel-touchpad.svg',
'svg/ptraccel-trackpoint.svg',
'svg/software-buttons.svg',
'svg/software-buttons-conditions.svg',
'svg/software-buttons-thumbpress.svg',
'svg/software-buttons-visualized.svg',
'svg/swipe-gestures.svg',
'svg/tablet-axes.svg',
'svg/tablet-cintiq24hd-modes.svg',

View file

@ -0,0 +1,210 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!-- Created with Inkscape (http://www.inkscape.org/) -->
<svg
xmlns:dc="http://purl.org/dc/elements/1.1/"
xmlns:cc="http://creativecommons.org/ns#"
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
xmlns:svg="http://www.w3.org/2000/svg"
xmlns="http://www.w3.org/2000/svg"
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
version="1.1"
width="700.66412"
height="272.14511"
id="svg2"
inkscape:version="0.92.2 (5c3e80d, 2017-08-06)"
sodipodi:docname="software-buttons-conditions.svg">
<metadata
id="metadata4314">
<rdf:RDF>
<cc:Work
rdf:about="">
<dc:format>image/svg+xml</dc:format>
<dc:type
rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
<dc:title></dc:title>
</cc:Work>
</rdf:RDF>
</metadata>
<sodipodi:namedview
pagecolor="#ffffff"
bordercolor="#666666"
borderopacity="1"
objecttolerance="10"
gridtolerance="10"
guidetolerance="10"
inkscape:pageopacity="0"
inkscape:pageshadow="2"
inkscape:window-width="1920"
inkscape:window-height="1101"
id="namedview4312"
showgrid="false"
inkscape:zoom="1.1559716"
inkscape:cx="212.0146"
inkscape:cy="238.29755"
inkscape:window-x="1920"
inkscape:window-y="28"
inkscape:window-maximized="1"
inkscape:current-layer="svg2"
showguides="true"
inkscape:guide-bbox="true"
inkscape:snap-page="false"
fit-margin-top="0"
fit-margin-left="0"
fit-margin-right="0"
fit-margin-bottom="0">
<sodipodi:guide
position="563.298,393.72836"
orientation="0,1"
id="guide4473"
inkscape:locked="false" />
<sodipodi:guide
position="0,-89.159632"
orientation="1,0"
id="guide33334"
inkscape:locked="false" />
</sodipodi:namedview>
<defs
id="defs4">
<marker
inkscape:stockid="Arrow1Lend"
orient="auto"
refY="0"
refX="0"
id="marker34335"
style="overflow:visible"
inkscape:isstock="true">
<path
id="path34333"
d="M 0,0 5,-5 -12.5,0 5,5 Z"
style="fill:#000000;fill-opacity:1;fill-rule:evenodd;stroke:#000000;stroke-width:1.00000003pt;stroke-opacity:1"
transform="matrix(-0.8,0,0,-0.8,-10,0)"
inkscape:connector-curvature="0" />
</marker>
<marker
inkscape:stockid="Arrow1Lend"
orient="auto"
refY="0"
refX="0"
id="marker34049"
style="overflow:visible"
inkscape:isstock="true">
<path
id="path34047"
d="M 0,0 5,-5 -12.5,0 5,5 Z"
style="fill:#000000;fill-opacity:1;fill-rule:evenodd;stroke:#000000;stroke-width:1.00000003pt;stroke-opacity:1"
transform="matrix(-0.8,0,0,-0.8,-10,0)"
inkscape:connector-curvature="0" />
</marker>
<marker
inkscape:stockid="Arrow1Lstart"
orient="auto"
refY="0"
refX="0"
id="Arrow1Lstart"
style="overflow:visible"
inkscape:isstock="true">
<path
id="path33345"
d="M 0,0 5,-5 -12.5,0 5,5 Z"
style="fill:#000000;fill-opacity:1;fill-rule:evenodd;stroke:#000000;stroke-width:1.00000003pt;stroke-opacity:1"
transform="matrix(0.8,0,0,0.8,10,0)"
inkscape:connector-curvature="0" />
</marker>
<inkscape:path-effect
effect="spiro"
id="path-effect34019"
is_visible="true" />
<marker
inkscape:stockid="Arrow1Lend"
orient="auto"
refY="0"
refX="0"
id="Arrow1Lend"
style="overflow:visible"
inkscape:isstock="true">
<path
id="path33348"
d="M 0,0 5,-5 -12.5,0 5,5 Z"
style="fill:#000000;fill-opacity:1;fill-rule:evenodd;stroke:#000000;stroke-width:1.00000003pt;stroke-opacity:1"
transform="matrix(-0.8,0,0,-0.8,-10,0)"
inkscape:connector-curvature="0" />
</marker>
<inkscape:path-effect
effect="spiro"
id="path-effect33343"
is_visible="true" />
</defs>
<rect
width="313.09872"
height="167.89594"
x="2.5968816"
y="2.5968816"
id="rect2858-0"
style="color:#000000;display:inline;overflow:visible;visibility:visible;fill:#b3b3b3;fill-opacity:1;fill-rule:nonzero;stroke:#000000;stroke-width:5.19376326;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1;marker:none;enable-background:accumulate" />
<rect
width="313.09872"
height="167.89594"
x="384.96854"
y="2.5968931"
id="rect2858"
style="color:#000000;display:inline;overflow:visible;visibility:visible;fill:#b3b3b3;fill-opacity:1;fill-rule:nonzero;stroke:#000000;stroke-width:5.19376326;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1;marker:none;enable-background:accumulate" />
<g
transform="translate(-776.70962,4.38162)"
id="g4656-3">
<g
id="g4639-2">
<path
inkscape:connector-curvature="0"
style="fill:none;stroke:#000000;stroke-width:0.72135597px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1"
id="path2820-0-5-6"
d="m 970.15914,263.93369 32.58666,-97.47985 c 0,0 12.2603,-46.32869 38.5506,-33.925 20.7457,9.78778 17.4301,24.72594 16.4399,28.75425 -10.1846,41.43257 -30.105,105.84033 -30.105,105.84033 l -0.428,-0.37827 z"
sodipodi:nodetypes="ccssccc" />
<path
inkscape:connector-curvature="0"
style="color:#000000;display:inline;overflow:visible;visibility:visible;fill:#ffccaa;fill-opacity:1;fill-rule:nonzero;stroke:#000000;stroke-width:0.00144271;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1;marker:none;enable-background:accumulate"
id="path2824-9-3-6"
d="m 987.16367,214.84092 c 8.97014,-26.84686 16.75933,-50.19953 17.30923,-51.89481 3.8651,-11.91483 10.3862,-22.76212 16.5622,-27.54951 6.8496,-5.30946 13.8243,-5.75615 21.9108,-1.40323 3.7999,2.04543 6.0302,3.61208 8.2265,5.77836 2.5214,2.487 3.6881,4.17002 5.1008,7.35828 1.3655,3.08181 1.9391,7.11725 1.5051,10.58923 -0.597,4.77663 -10.2821,40.41668 -20.9931,77.25236 -7.7256,26.56907 -9.371,31.11182 -9.5644,31.10964 -0.1479,-0.002 -55.70067,-1.83937 -56.08626,-2.18017 -0.16723,-0.1478 6.29681,-19.93218 16.02913,-49.06015 z"
sodipodi:nodetypes="scsssscsccs" />
<path
inkscape:connector-curvature="0"
style="color:#000000;display:inline;overflow:visible;visibility:visible;opacity:0.92000002;fill:#ffe6d5;fill-opacity:1;fill-rule:nonzero;stroke:none;stroke-width:0.2;marker:none;enable-background:accumulate"
id="path2824-7-8-8-4"
d="m 1008.3595,164.57667 c 3.8651,-11.91483 7.6606,-19.35039 13.8366,-24.13778 6.8495,-5.30946 12.0833,-5.57765 20.1698,-1.22474 9.3061,4.73331 12.9905,9.62271 11.9094,19.03362 -6.3459,19.3209 -6.9054,22.12042 -9.2168,26.32727 -0.1479,-0.002 -33.6651,-14.70742 -35.0296,-15.23839 -1.4035,-0.54616 -1.8884,-3.70289 -1.6694,-4.75998 z" />
</g>
</g>
<path
style="opacity:1;vector-effect:none;fill:none;fill-opacity:1;fill-rule:evenodd;stroke:#000000;stroke-width:1.23500001;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;marker-end:url(#marker34335)"
d="M 72.262856,47.254699 C 87.505219,34.288464 106.29239,25.531663 126.02382,22.196431 c 19.73142,-3.335232 40.35297,-1.239746 59.01017,5.996395 18.65721,7.236141 35.29888,19.59309 47.62145,35.360371 12.32257,15.767281 20.29224,34.901646 22.80582,54.754473 0.32542,2.57024 0.56139,5.1518 0.70733,7.73844"
id="path33341"
inkscape:connector-curvature="0"
inkscape:path-effect="#path-effect33343"
inkscape:original-d="M 72.262856,47.254699 C 133.3298,70.938208 194.39594,94.622538 255.46126,118.30767 c 61.06532,23.68514 0.47237,5.15815 0.70733,7.73844" />
<path
style="opacity:1;vector-effect:none;fill:none;fill-opacity:1;fill-rule:evenodd;stroke:#000000;stroke-width:1.23500001;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-dashoffset:0;stroke-opacity:1;marker-start:url(#Arrow1Lstart);marker-end:url(#marker34049)"
d="M 429.07628,149.3047 H 647.07471"
id="path34017"
inkscape:connector-curvature="0"
inkscape:path-effect="#path-effect34019"
inkscape:original-d="m 429.07628,149.3047 c 72.66714,-0.001 145.33329,-0.001 217.99843,0" />
<g
transform="matrix(0.79657897,0.11742288,-0.14814182,0.631399,377.36191,-341.92052)"
id="g3663-9-5">
<path
d="m 388.57143,893.79076 -57.14285,-130 c 0,0 -30.0247,-58.84827 4.28571,-70.00001 27.07438,-8.79984 37.32196,9.59496 40,14.64286 27.54455,51.91936 84.64285,173.21429 84.64285,173.21429 h -0.71428 z"
id="path2820-6-6"
style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1"
inkscape:connector-curvature="0" />
<path
d="m 360.32021,827.78041 c -15.74169,-35.7991 -29.44655,-66.92657 -30.45523,-69.17214 -7.08929,-15.78239 -10.8761,-32.88254 -9.6176,-43.43026 1.39575,-11.69796 7.19746,-18.50389 18.22574,-21.38044 5.18218,-1.35169 8.54724,-1.76827 12.41155,-1.53649 4.43642,0.26609 6.95929,0.93715 11.03011,2.93391 3.93491,1.9301 8.0085,5.56248 10.68932,9.53159 3.68818,5.46055 26.56068,50.9623 49.57778,98.62829 16.60192,34.38082 37.06388,77.41994 36.89013,77.59369 -0.13286,0.13286 -69.01932,11.92114 -69.66286,11.92114 -0.27909,0 -12.00972,-26.24842 -29.08894,-65.08929 z"
id="path2824-1-1"
style="color:#000000;display:inline;overflow:visible;visibility:visible;fill:#ffccaa;fill-opacity:1;fill-rule:nonzero;stroke:#000000;stroke-width:0.002;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1;marker:none;enable-background:accumulate"
inkscape:connector-curvature="0" />
<path
d="m 334.75785,756.75053 c -7.08929,-15.78239 -10.28437,-26.89033 -9.02587,-37.43805 1.39575,-11.69796 5.8085,-16.73613 16.83678,-19.61268 12.44766,-3.59459 20.03902,-1.91353 27.39013,8.75815 11.42622,25.66382 13.40166,29.05484 15.06365,35.48866 -0.13286,0.13286 -42.89663,15.49027 -44.57776,16.18518 -1.72922,0.71479 -4.94789,-2.09377 -5.68693,-3.38126 z"
id="path2824-7-1-4"
style="color:#000000;display:inline;overflow:visible;visibility:visible;opacity:0.92000002;fill:#ffe6d5;fill-opacity:1;fill-rule:nonzero;stroke:none;stroke-width:0.2;marker:none;enable-background:accumulate"
inkscape:connector-curvature="0" />
</g>
</svg>

After

Width:  |  Height:  |  Size: 10 KiB

View file

@ -0,0 +1,107 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!-- Created with Inkscape (http://www.inkscape.org/) -->
<svg
xmlns:dc="http://purl.org/dc/elements/1.1/"
xmlns:cc="http://creativecommons.org/ns#"
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
xmlns:svg="http://www.w3.org/2000/svg"
xmlns="http://www.w3.org/2000/svg"
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
version="1.1"
width="318.29248"
height="224.63223"
id="svg2"
inkscape:version="0.92.2 (5c3e80d, 2017-08-06)"
sodipodi:docname="software-buttons-thumbpress.svg">
<metadata
id="metadata4314">
<rdf:RDF>
<cc:Work
rdf:about="">
<dc:format>image/svg+xml</dc:format>
<dc:type
rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
<dc:title></dc:title>
</cc:Work>
</rdf:RDF>
</metadata>
<sodipodi:namedview
pagecolor="#ffffff"
bordercolor="#666666"
borderopacity="1"
objecttolerance="10"
gridtolerance="10"
guidetolerance="10"
inkscape:pageopacity="0"
inkscape:pageshadow="2"
inkscape:window-width="1920"
inkscape:window-height="1101"
id="namedview4312"
showgrid="false"
inkscape:zoom="0.81739537"
inkscape:cx="284.62214"
inkscape:cy="70.498403"
inkscape:window-x="1920"
inkscape:window-y="28"
inkscape:window-maximized="1"
inkscape:current-layer="svg2"
showguides="true"
inkscape:guide-bbox="true"
inkscape:snap-page="false"
fit-margin-top="0"
fit-margin-left="0"
fit-margin-right="0"
fit-margin-bottom="0">
<sodipodi:guide
position="563.298,346.2155"
orientation="0,1"
id="guide4473"
inkscape:locked="false" />
</sodipodi:namedview>
<defs
id="defs4" />
<rect
width="313.09872"
height="167.89594"
x="2.5968816"
y="2.5968816"
id="rect2858-0"
style="color:#000000;display:inline;overflow:visible;visibility:visible;fill:#b3b3b3;fill-opacity:1;fill-rule:nonzero;stroke:#000000;stroke-width:5.19376326;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1;marker:none;enable-background:accumulate" />
<g
transform="matrix(0.79657897,0.11742288,-0.14814182,0.631399,23.947506,-457.51364)"
id="g3663-9-5">
<path
d="m 388.57143,893.79076 -57.14285,-130 c 0,0 -30.0247,-58.84827 4.28571,-70.00001 27.07438,-8.79984 37.32196,9.59496 40,14.64286 27.54455,51.91936 84.64285,173.21429 84.64285,173.21429 h -0.71428 z"
id="path2820-6-6"
style="fill:none;stroke:#000000;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1"
inkscape:connector-curvature="0" />
<path
d="m 360.32021,827.78041 c -15.74169,-35.7991 -29.44655,-66.92657 -30.45523,-69.17214 -7.08929,-15.78239 -10.8761,-32.88254 -9.6176,-43.43026 1.39575,-11.69796 7.19746,-18.50389 18.22574,-21.38044 5.18218,-1.35169 8.54724,-1.76827 12.41155,-1.53649 4.43642,0.26609 6.95929,0.93715 11.03011,2.93391 3.93491,1.9301 8.0085,5.56248 10.68932,9.53159 3.68818,5.46055 26.56068,50.9623 49.57778,98.62829 16.60192,34.38082 37.06388,77.41994 36.89013,77.59369 -0.13286,0.13286 -69.01932,11.92114 -69.66286,11.92114 -0.27909,0 -12.00972,-26.24842 -29.08894,-65.08929 z"
id="path2824-1-1"
style="color:#000000;display:inline;overflow:visible;visibility:visible;fill:#ffccaa;fill-opacity:1;fill-rule:nonzero;stroke:#000000;stroke-width:0.002;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1;marker:none;enable-background:accumulate"
inkscape:connector-curvature="0" />
<path
d="m 334.75785,756.75053 c -7.08929,-15.78239 -10.28437,-26.89033 -9.02587,-37.43805 1.39575,-11.69796 5.8085,-16.73613 16.83678,-19.61268 12.44766,-3.59459 20.03902,-1.91353 27.39013,8.75815 11.42622,25.66382 13.40166,29.05484 15.06365,35.48866 -0.13286,0.13286 -42.89663,15.49027 -44.57776,16.18518 -1.72922,0.71479 -4.94789,-2.09377 -5.68693,-3.38126 z"
id="path2824-7-1-4"
style="color:#000000;display:inline;overflow:visible;visibility:visible;opacity:0.92000002;fill:#ffe6d5;fill-opacity:1;fill-rule:nonzero;stroke:none;stroke-width:0.2;marker:none;enable-background:accumulate"
inkscape:connector-curvature="0" />
</g>
<g
transform="matrix(1.0545106,0.16057813,-0.16057813,1.0545106,-220.12096,-375.662)"
id="g4151">
<path
sodipodi:nodetypes="sszzzcss"
d="m 353.70196,495.15765 c -24.01774,-7.29937 -29.0012,-10.10221 -30.51977,-10.54973 -10.67294,-3.14527 -18.27051,-5.54063 -23.77758,-13.4704 -5.50707,-7.92977 -5.34967,-20.78347 8.87612,-26.31604 14.2258,-5.53257 39.34351,8.79597 60.13061,16.16341 20.7871,7.36744 33.04563,11.44545 39.33422,13.87551 -8.10022,18.05041 -7.22129,21.15857 -10.11054,33.34117 -0.0481,0.20261 -17.87459,-5.12433 -43.93306,-13.04392 z"
id="path2824-1-1-3"
style="color:#000000;display:inline;overflow:visible;visibility:visible;fill:#ffccaa;fill-opacity:1;fill-rule:nonzero;stroke:#000000;stroke-width:1.00100005;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1;marker:none;enable-background:accumulate"
inkscape:connector-curvature="0" />
<path
sodipodi:nodetypes="ccccc"
d="m 324.44991,483.39364 c -10.67294,-1.94747 -17.88441,-5.64478 -21.62691,-8.75386 -8.11652,-9.03765 -6.31775,-15.03428 -3.3272,-13.99784 8.90495,-0.9097 30.20384,9.01528 33.86042,10.17935 -5.80268,11.37909 -1.08919,13.70271 -8.90631,12.57235 z"
id="path2824-7-1-4-3"
style="color:#000000;display:inline;overflow:visible;visibility:visible;opacity:0.92000002;fill:#ffe6d5;fill-opacity:1;fill-rule:nonzero;stroke:none;stroke-width:0.2;marker:none;enable-background:accumulate"
inkscape:connector-curvature="0" />
</g>
</svg>

After

Width:  |  Height:  |  Size: 5.7 KiB

View file

@ -0,0 +1,146 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<!-- Created with Inkscape (http://www.inkscape.org/) -->
<svg
xmlns:dc="http://purl.org/dc/elements/1.1/"
xmlns:cc="http://creativecommons.org/ns#"
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
xmlns:svg="http://www.w3.org/2000/svg"
xmlns="http://www.w3.org/2000/svg"
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
version="1.1"
width="318.29248"
height="173.08969"
id="svg2"
inkscape:version="0.92.2 (5c3e80d, 2017-08-06)"
sodipodi:docname="software-buttons-visualized.svg">
<metadata
id="metadata4314">
<rdf:RDF>
<cc:Work
rdf:about="">
<dc:format>image/svg+xml</dc:format>
<dc:type
rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
<dc:title></dc:title>
</cc:Work>
</rdf:RDF>
</metadata>
<sodipodi:namedview
pagecolor="#ffffff"
bordercolor="#666666"
borderopacity="1"
objecttolerance="10"
gridtolerance="10"
guidetolerance="10"
inkscape:pageopacity="0"
inkscape:pageshadow="2"
inkscape:window-width="1920"
inkscape:window-height="1101"
id="namedview4312"
showgrid="false"
inkscape:zoom="2.3119432"
inkscape:cx="188.48331"
inkscape:cy="69.297483"
inkscape:window-x="1920"
inkscape:window-y="28"
inkscape:window-maximized="1"
inkscape:current-layer="svg2"
showguides="true"
inkscape:guide-bbox="true"
inkscape:snap-page="false"
fit-margin-top="0"
fit-margin-left="0"
fit-margin-right="0"
fit-margin-bottom="0">
<sodipodi:guide
position="563.298,294.67296"
orientation="0,1"
id="guide4473"
inkscape:locked="false" />
</sodipodi:namedview>
<defs
id="defs4">
<inkscape:path-effect
is_visible="true"
id="path-effect22667"
effect="spiro" />
<inkscape:path-effect
effect="spiro"
id="path-effect22663"
is_visible="true" />
<inkscape:path-effect
effect="spiro"
id="path-effect22659"
is_visible="true" />
</defs>
<rect
width="313.09872"
height="167.89594"
x="2.5968816"
y="2.5968816"
id="rect2858-0"
style="color:#000000;display:inline;overflow:visible;visibility:visible;fill:#b3b3b3;fill-opacity:1;fill-rule:nonzero;stroke:#000000;stroke-width:5.19376326;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1;marker:none;enable-background:accumulate" />
<path
style="opacity:1;vector-effect:none;fill:none;fill-opacity:1;fill-rule:evenodd;stroke:#000000;stroke-width:1.00157475;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:1.00157475, 6.00944853;stroke-dashoffset:0;stroke-opacity:1"
d="M 1.2976097,125.94773 H 314.88662"
id="path22657"
inkscape:connector-curvature="0"
inkscape:path-effect="#path-effect22659"
inkscape:original-d="m 1.2976097,125.94773 c 104.5306703,-0.001 209.0603403,-0.001 313.5890103,0" />
<path
style="opacity:1;vector-effect:none;fill:none;fill-opacity:1;fill-rule:evenodd;stroke:#000000;stroke-width:1.00157475;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:1.00157475, 6.00944853;stroke-dashoffset:0;stroke-opacity:1"
d="m 124.9176,127.3866 v 43.12479"
id="path22661"
inkscape:connector-curvature="0"
inkscape:path-effect="#path-effect22663"
inkscape:original-d="m 124.9176,127.3866 c 0.001,14.27198 0.001,28.74886 0,43.12479" />
<path
inkscape:original-d="m 184.9176,127.3866 c 0.001,14.27198 0.001,28.74886 0,43.12479"
inkscape:path-effect="#path-effect22667"
inkscape:connector-curvature="0"
id="path22665"
d="m 184.9176,127.3866 v 43.12479"
style="opacity:1;vector-effect:none;fill:none;fill-opacity:1;fill-rule:evenodd;stroke:#000000;stroke-width:1.00157475;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:1.00157475, 6.00944853;stroke-dashoffset:0;stroke-opacity:1" />
<text
xml:space="preserve"
style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:12px;line-height:100%;font-family:Helvetica;-inkscape-font-specification:Helvetica;text-align:start;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;"
x="128.8959"
y="73.610809"
id="text22671"><tspan
sodipodi:role="line"
id="tspan22669"
x="128.8959"
y="73.610809">main area</tspan></text>
<text
id="text22693"
y="151.37802"
x="215.27881"
style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:12px;line-height:100%;font-family:Helvetica;-inkscape-font-specification:Helvetica;text-align:start;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;"
xml:space="preserve"><tspan
y="151.37802"
x="215.27881"
id="tspan22691"
sodipodi:role="line">right button</tspan></text>
<text
xml:space="preserve"
style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:12px;line-height:100%;font-family:Helvetica;-inkscape-font-specification:Helvetica;text-align:start;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;"
x="37.278809"
y="151.37802"
id="text22697"><tspan
sodipodi:role="line"
id="tspan22695"
x="37.278809"
y="151.37802">left button</tspan></text>
<text
xml:space="preserve"
style="font-style:normal;font-variant:normal;font-weight:normal;font-stretch:normal;font-size:12px;line-height:100%;font-family:Helvetica;-inkscape-font-specification:Helvetica;text-align:start;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1;"
x="137.27881"
y="151.37802"
id="text22701"><tspan
sodipodi:role="line"
id="tspan22699"
x="137.27881"
y="151.37802">middle</tspan></text>
</svg>

After

Width:  |  Height:  |  Size: 6.4 KiB

View file

@ -14,11 +14,10 @@ what libinput is **not**.
What libinput is
------------------------------------------------------------------------------
libinput is an input stack for applications that need full input device
processing by commonly used input devices. That includes mice, keyboards,
touchpads, touchscreens and graphics tablets. libinput handles
device-specific quirks and provides an easy-to-use API to receive
events from devices.
libinput is an input stack for processes that need to provide events from
commonly used input devices. That includes mice, keyboards, touchpads,
touchscreens and graphics tablets. libinput handles device-specific quirks
and provides an easy-to-use API to receive events from devices.
libinput is designed to handle all input devices available on a system but
it is possible to limit which devices libinput has access to.
@ -32,6 +31,10 @@ those features. One example for this are the top software buttons on the
touchpad in the Lenovo T440. While there may be use-cases for providing top
software buttons on other devices, libinput does not do so.
`This introductory blog post from 2015
<https://who-t.blogspot.com/2015/06/libinput-and-lack-of-device-types.html>`_
describes some of the motivations.
.. _what_libinput_is_not:
------------------------------------------------------------------------------

View file

@ -912,6 +912,13 @@ libinput_event_get_touch_event(struct libinput_event *event);
* Return the gesture event that is this input event. If the event type does
* not match the gesture event types, this function returns NULL.
*
* A gesture's lifetime has three distinct stages: begin, update and end, each
* with their own event types. Begin is sent when the fingers are first set
* down or libinput decides that the gesture begins. For @ref
* LIBINPUT_EVENT_GESTURE_PINCH_BEGIN this sets the initial scale. Any
* events changing properties of the gesture are sent as update events. On
* termination of the gesture, an end event is sent.
*
* The inverse of this function is libinput_event_gesture_get_base_event().
*
* @return A gesture event, or NULL for other events
@ -1634,7 +1641,11 @@ libinput_event_gesture_get_base_event(struct libinput_event_gesture *event);
* to differentiate between 3 or 4 finger swipes.
*
* This function can be called on all gesture events and the returned finger
* count value will not change during a sequence.
* count value remains the same for the lifetime of a gesture. Thus, if a
* user puts down a fourth finger during a three-finger swipe gesture,
* libinput will end the three-finger gesture and, if applicable, start a
* four-finger swipe gesture. A caller may decide that those gestures are
* semantically identical and continue the two gestures as one single gesture.
*
* @return the number of fingers used for a gesture
*/