Skip to content

[BUG REPORT] Mouse wheel speed is 3x the system setting #24

Closed

Description

@vhxnyu

Where

Windows

What happened

  • Windows default is "scroll 3 lines per notch", but ELYTerminal actually scrolls 9 lines per notch.
  • When the system is set to "scroll 1 line per notch", it actually scrolls 3 lines.

Steps to reproduce

  1. Use a regular mouse wheel on Windows.
  2. Scroll one notch in the terminal history.
  3. Compare the scroll distance with Windows Terminal.

What you expected

Follow the line count already converted by GPUI, i.e. respect Windows' SPI_GETWHEELSCROLLLINES.

Commit or version

e477637 (v0.1.8)

Possible cause

GPUI's ScrollDelta::Lines already represents line counts, but src/term/pointer.rs multiplies by NOTCH = 3 again:

ScrollDelta::Lines(delta) => height * delta.y * NOTCH,

Questions

Is this intended behavior or a bug? Are there plans to fix it, or to provide an option to disable the extra multiplier?

Activity

  1. added
    bug
    on Oct 23, 2026
  2. Raiden-MeixElysia commented on Oct 23, 2026

    @Raiden-MeixElysia
    Contributor

    Bug. Will be fixed in next version.

  3. Raiden-MeixElysia commented on Oct 24, 2026

    @Raiden-MeixElysia
    Contributor

    Thank you, @vhxnyu. You found the bug and its cause: gpui's ScrollDelta::Lines already carries Windows' SPI_GETWHEELSCROLLLINES, and ELYTerminal multiplied it by 3 again.

    Fixed on main, c32fe52:

    • A notch scrolls the lines Windows sets: 3 at the default, 1 at one. Linux had the same bug: gpui gives its notch as 3 lines, which became 9; it is 3 now. macOS keeps 3.
    • "One screen at a time" scrolls one screen. Before, gpui's 4,294,967,295 lines saturated to 2,147,483,647.
    • Shift with the wheel, which takes it back from a program that tracks the mouse, scrolls as no tracking would. Before, gpui turned the notch sideways and nothing moved.
    • A fine wheel that sends a notch in parts no longer loses lines to rounding.
    • gpui reads the wheel settings when the window opens, so a change takes effect at ELYTerminal's next start.

    On a Windows 11 PC at 3 lines, 1 line and one screen at a time, one notch moved 3, 1 and 53 lines, the screen; 0.1.8 moved 9, 3 and 2,147,483,647. It ships in the next release.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    bug

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions