Skip to content

Use mouse button as keyboard modifier key #582

Open

Description

@Odrin

OS

macOS 13.3.1 (a) (Build 22E772610a)

LinearMouse

v0.9.3

Is your feature request related to a problem?

No response

Describe the solution you'd like

Is it possible to use mouse additional button as a keyboard modifier keys like shift or control? I'm able to bind mouse button to keyboard shortcut (ex. shift), but it doesn't work as expected: holding mouse button doesn't work as pressed shift key modifier, but triggers single shift key press on release (or multiple individual button presses if I check "repeat on hold" option).

Describe alternatives you've considered

No response

Additional context

No response

Activity

  1. added
    enhancement
    on Aug 22, 2023
  2. lujjjh commented on Aug 24, 2023

    @lujjjh
    Collaborator

    Thanks for your feedback!

    Could you provide the steps to reproduce?

    I tried mapping button 3 to shift+command (without checking "repeat on hold" option), and then holding down button 3 while pressing key 3, and a screenshot was successfully captured.

  3. Odrin commented on Aug 24, 2023

    @Odrin
    Author

    @lujjjh No, you got me wrong. I want to use mouse button as shift (or any other modifier), not as shift + something. I mean holding mouse button and getting UPPER case while typing.

    I checked your example and it seems not working as you described with my logi mx anywhere 3. I guess it could be hardware issue.

  4. lujjjh commented on Aug 24, 2023

    @lujjjh
    Collaborator

    I mapped button 3 to shift and it worked as expected. Do you have Logi Options+ or other mouse utilities installed?

    It would be helpful to attach the logs which you can export from General Settings.

  5. Odrin commented on Sep 9, 2023

    @Odrin
    Author

    Sorry for the long response. I don't have any other mouse utilities installed.
    Here is my log. I mapped button 3 to shift and wrote "test" three times while holding down the mouse button 3.

  6. lujjjh commented on Sep 9, 2023

    @lujjjh
    Collaborator

    Thank you for providing the logs!

    Based on the logs, it appears that button 3 (identified as usage ID 04) was pressed and released within a second. This supports your hypothesis that this might be a hardware issue.

    2023-09-09 13:34:47 +0000	info	Device	Received input value from: USB Receiver (VID=0x046D, PID=0xC52B): timestamp: 10081340369354 length: 1 data: [1] integerValue: 1 element=(usagePage: 09 usage: 04)
    2023-09-09 13:34:47 +0000	info	ButtonActions	Down keys: [⇧]
    2023-09-09 13:34:47 +0000	info	Device	Received input value from: USB Receiver (VID=0x046D, PID=0xC52B): timestamp: 10081340752417 length: 1 data: [0] integerValue: 0 element=(usagePage: 09 usage: 04)
    2023-09-09 13:34:47 +0000	info	ButtonActions	Up keys: [⇧]
    

    I would leave this issue open and see if others can reproduce it.

  7. added
    bug
    help wanted
    and removed
    enhancement
    on Sep 9, 2023
  8. RumplesWrinkles commented on Dec 26, 2023

    @RumplesWrinkles

    Hi everyone! I am having a similar issue. I have a Logitech G602, which has 11 programmable buttons.

    I have assigned one of the side buttons to the "shift" keyboard shortcut, to use it with a left click. The idea is that I can hold that button, click a URL, and it will open into a new window.

    For some reason, this doesn't seem to work. The button functions as a shift correctly when pressed on the mouse (letters are typed in uppercase), but when held down and used with a left click, links do not open into a new window.

    Any ideas?

  9. vegadj commented on Jan 3, 2026

    @vegadj

    I have the same issue.
    I assigned one mouse button to act as Ctrl. What I want is to use Ctrl + mouse scroll to toggle the Accessibility Zoom feature in macOS.

    macOS does detect the Ctrl key correctly — I can see it in the Virtual Keyboard. However, when I scroll the mouse wheel at the same time, the zoom feature does not activate.
    The same problem happens with other combinations, such as Ctrl + right-click or Ctrl + click etc. My main aim to use one key as CTRL CMD etc and with mouse only to toggle more commands.

    My mouse is no longer supported by Logitech software on the current macOS version. This setup used to work correctly in Logitech Control Center, where modifier keys could be assigned to mouse buttons.
    Has anyone found a workaround or solution for this on newer macOS versions?

  10. JonathanGurkan commented on Mar 11, 2026

    @JonathanGurkan

    I share this issue as well

    Image

    I have these settings when using my Dell mouse with "Back" and "Forward" buttons on the side. I want to use these buttons as ⌘ and ⌥ to use with my ⌘+Scroll and ⌥+Scroll shortcuts. That way I don't need to use my keyboard. Since I have an external monitor, my laptop is often closed and I primarily use my monitor

    Thanks to all developers for this amazing application!

  11. lujjjh commented on Oct 11, 2026

    @lujjjh
    Collaborator

    Thanks to @GtechGovind, v0.13.0-beta.4 includes a fix for mapped modifiers not applying to mouse clicks and scrolling (#1438).

    I tried mapping my back button to command using “Keyboard shortcut…” with Behavior set to “Hold keys while pressed”. Holding the back button while scrolling worked as command + scroll for me. Hopefully this helps with some of the issues mentioned here.

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

    bughelp wanted

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions