[PATCH synaptics] support inverted scroll direction

Michal Suchanek hramrach at gmail.com
Fri Apr 13 02:34:09 PDT 2012


On 13 April 2012 05:50, Peter Hutterer <peter.hutterer at who-t.net> wrote:
> On Wed, Apr 11, 2012 at 10:00:56PM -0400, Alyssa Hung wrote:
>> This patch adds two options to the synaptics driver: InvertEdgeScroll
>> and InvertTwoFingerScroll.
>>
>> When enabled, they will cause the scroll direction to be inverted when
>> edge scrolling and two-finger scrolling, respectively. For instance,
>> moving a finger downward along the right edge will pull the scrolled
>> content down (causing the page to scroll up). This behaviour is
>> consistent with scrolling on modern touchscreen devices.
>>
>> Options are provided separately for edge scrolling and two-finger
>> scrolling because they follow different metaphors; edge scrolling has
>> traditionally been analogous to dragging the scrollbar tab, and may
>> therefore be sensible to leave uninverted even when two-finger scroll
>> direction is inverted.
>>
>> Signed-off-by: Alyssa Hung <ahung at isisview.org>
>
> Thansk Alyssa, two comments regarding this option:
> In general, I'm not in favour of adding more options to synaptics. This
> particular one is something that we need to deal with in other drivers as
> well. With server 1.12, scrolling is now controlled by the increment in the
> XIScrollClass, simply changing that could change not only the speed but
> also the direction. While support for modifying the increment is the best
> solution, it needs a protocol revision.
>
> In this particular case, synaptics already has a
> VertScrollDelta and HorizScrollDelta option that controls the amount of
> movement before a scroll event is emitted. I think it should be simple
> enough to change the code that negative deltas are permitted for scroll
> direction inversion.

Hello,

this does not cover the case when you need to generate different
direction for edge scrolling and two-finger scrolling.

These events are generated in synaptics driver so only synaptics
driver can set the direction appropriately.

I think it is quite sensible to support setting sane default that work
for either edge scrolling or finger scrolling.

Thanks

Michal


More information about the xorg-devel mailing list