trackpoint-configuration.rst 5.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154
  1. .. _trackpoint_configuration:
  2. ==============================================================================
  3. Trackpoint configuration
  4. ==============================================================================
  5. The sections below describe the trackpoint magic multiplier and how to apply
  6. it to your local device. See :ref:`trackpoint_range` for an explanation on
  7. why this multiplier is needed.
  8. .. note:: The magic trackpoint multiplier **is not user visible configuration**. It is
  9. part of the :ref:`device-quirks` system and provided once per device.
  10. User-specific preferences can be adjusted with the
  11. :ref:`config_pointer_acceleration` setting.
  12. .. _trackpoint_multiplier:
  13. ------------------------------------------------------------------------------
  14. The magic trackpoint multiplier
  15. ------------------------------------------------------------------------------
  16. To accommodate for the wildly different input data on trackpoint, libinput
  17. uses a multiplier that is applied to input deltas. Trackpoints that send
  18. comparatively high deltas can be "slowed down", trackpoints that send low
  19. deltas can be "sped up" to match the expected range. The actual acceleration
  20. profile is applied to these pre-multiplied deltas.
  21. Given a trackpoint delta ``(dx, dy)``, a multiplier ``M`` and a pointer acceleration
  22. function ``f(dx, dy) → (dx', dy')``, the algorithm is effectively:
  23. ::
  24. f(M * dx, M * dy) → (dx', dy')
  25. .. _trackpoint_multiplier_adjustment:
  26. ..............................................................................
  27. Adjusting the magic trackpoint multiplier
  28. ..............................................................................
  29. This section only applies if:
  30. - the trackpoint default speed (speed setting 0) is unusably slow or
  31. unusably fast, **and**
  32. - the lowest speed setting (-1) is still too fast **or** the highest speed
  33. setting is still too slow, **and**
  34. - the :ref:`device-quirks` for this device do not list a trackpoint multiplier
  35. (see :ref:`device-quirks-debugging`)
  36. If the only satisfactory speed settings are less than -0.75 or greater than
  37. 0.75, a multiplier *may* be required.
  38. A specific multiplier will apply to **all users with the same laptop
  39. model**, so proceed with caution. You must be capable/willing to adjust
  40. device quirks, build libinput from source and restart the session frequently
  41. to adjust the multiplier. If this does not apply, wait for someone else with
  42. the same hardware to do this.
  43. Finding the correct multiplier is difficult and requires some trial and
  44. error. The default multiplier is always 1.0. A value between 0.0 and 1.0
  45. slows the trackpoint down, a value above 1.0 speeds the trackpoint up.
  46. Values below zero are invalid.
  47. .. warning:: The multiplier is not a configuration to adjust to personal
  48. preferences. The multiplier normalizes the input data into a range that
  49. can then be configured with the speed setting.
  50. To adjust the local multiplier, first
  51. :ref:`build libinput from git master <building_libinput>`. It is not
  52. required to install libinput from git. The below assumes that all
  53. :ref:`building_dependencies` are already
  54. installed.
  55. ::
  56. $ cd path/to/libinput.git
  57. # Use an approximate multiplier in the quirks file
  58. $ cat > quirks/99-trackpoint-override.quirks <<EOF
  59. [Trackpoint Override]
  60. MatchUdevType=pointingstick
  61. AttrTrackpointMultiplier=1.0
  62. EOF
  63. # Use your trackpoint's event node. If the Attr does not show up
  64. # then the quirk does not apply to your trackpoint.
  65. $ ./builddir/libinput quirks list /dev/input/event18
  66. AttrTrackpointMultiplier=1.0
  67. # Now start a GUI program to debug the trackpoint speed.
  68. # ESC closes the debug GUI
  69. $ sudo ./builddir/libinput debug-gui
  70. Replace the multiplier with an approximate value and the event node with
  71. your trackpoint's event node. Try to use trackpoint and verify the
  72. multiplier is good enough. If not, adjust the ``.quirks`` file and re-run the
  73. ``libinput debug-gui``. Note that the ``libinput debug-gui`` always feels
  74. less responsive than libinput would behave in a normal install.
  75. Once the trackpoint behaves correctly you are ready to test the system
  76. libinput:
  77. ::
  78. $ sudo cp quirks/99-trackpoint-override.quirks /etc/libinput/local-overrides.quirks
  79. Now verify the override is seen by the system libinput
  80. ::
  81. $ libinput quirks list
  82. AttrTrackpointMultiplier=1.0
  83. If the multiplier is listed, restart your Wayland session or X server. The
  84. new multiplier is now applied to your trackpoint.
  85. If the trackpoint behavior is acceptable, you are ready to submit this file
  86. upstream. First, find add a more precise match for the device so it only
  87. applies to the built-in trackpoint on your laptop model. Usually a
  88. variation of the following is sufficient:
  89. ::
  90. [Trackpoint Override]
  91. MatchUdevType=pointingstick
  92. MatchName=*TPPS/2 IBM TrackPoint*
  93. MatchDMIModalias=dmi:*:svnLENOVO:*:pvrThinkPadT440p:*
  94. AttrTrackpointMultiplier=1.0
  95. Look at your ``/sys/class/dmi/id/modalias`` file for the values to add. Verify
  96. that ``libinput quirks list`` still shows the ``AttrTrackpointMultiplier``. If
  97. it does, then you should :ref:`report a bug <reporting_bugs>` with the contents of
  98. the file. Alternatively, file a merge request with the data added.
  99. .. _trackpoint_range_measure:
  100. ------------------------------------------------------------------------------
  101. Measuring the trackpoint range
  102. ------------------------------------------------------------------------------
  103. This section only applied to libinput version 1.9.x, 1.10.x, and 1.11.x and
  104. has been removed. See :ref:`trackpoint_multiplier` for versions 1.12.x and later.
  105. If using libinput version 1.11.x or earlier, please see
  106. `the 1.11.0 documentation <https://wayland.freedesktop.org/libinput/doc/1.11.0/trackpoints.html#trackpoint_range_measure>`_