Skip to content

Shift-scroll does not work for smooth wheel events #942

Description

@valterschutz

Is there an existing issue for this?

  • I have searched the existing issues

Problem

Holding shift and scrolling does not do anything with my mouse. Full disclosure, this is what GPT-5.5 found:


Shift + scroll does not work for smooth mouse-wheel events

Zathura currently implements horizontal scrolling with Shift + wheel for discrete scroll events:
GDK_SHIFT_MASK + GIRARA_EVENT_SCROLL_UP -> LEFT
GDK_SHIFT_MASK + GIRARA_EVENT_SCROLL_DOWN -> RIGHT

However, some mice / desktop stacks emit smooth wheel input as GIRARA_EVENT_SCROLL_BIDIRECTIONAL instead of discrete SCROLL_UP / SCROLL_DOWN events. In that case, holding Shift while scrolling does nothing.

Expected behavior:
Shift + vertical wheel scroll should scroll horizontally, regardless of whether the device emits discrete or smooth/bidirectional scroll events.

Actual behavior:
Shift + scroll works for devices emitting discrete wheel events, but not for devices emitting GIRARA_EVENT_SCROLL_BIDIRECTIONAL.

Proposed fix:
Add a GDK_SHIFT_MASK + GIRARA_EVENT_SCROLL_BIDIRECTIONAL mouse-event binding and translate the smooth event’s vertical delta into LEFT / RIGHT scrolling, matching the existing discrete wheel behavior.


You can ignore the proposed fix, but I do think that expanding shift-scroll support to more mice would be nice.

Expected behavior

Holding shift and scrolling scrolls horizontally.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions