# Ctrl + scroll for zoom not working from keyboard but working from mouse

**URL:** <https://community.keyboard.io/t/ctrl-scroll-for-zoom-not-working-from-keyboard-but-working-from-mouse/1649>\
**Category:** Help and Getting Started\
**Created:** [June 16, 2018, 6:58am UTC](https://community.keyboard.io/t/ctrl-scroll-for-zoom-not-working-from-keyboard-but-working-from-mouse/1649 "2018-06-16T06:58:52Z")\
**Posts on this page:** 1\
**Showing post:** 17

<div class="post-metadata">

**Author:** ![jamadagni](https://yyz1.discourse-cdn.com/flex031/user_avatar/community.keyboard.io/jamadagni/32/2030_2.png) [@jamadagni](https://community.keyboard.io/u/jamadagni)\
**Post date:** [August 1, 2018, 3:41pm UTC](https://community.keyboard.io/t/ctrl-scroll-for-zoom-not-working-from-keyboard-but-working-from-mouse/1649/17 "2018-08-01T15:41:10Z")

</div>

OK next problem. As I mentioned [here](https://community.keyboard.io/t/horizontal-mouse-scroll-doesnt-work/1723/4?u=jamadagni), it is found to be preferable to use `keyIsPressed` for the horizontal scroll at least and maybe some may prefer it for zooming too. But even if `keyIsPressed` is used, the macro fires only once and repeated horizontal scrolling is not seen and still requires the use of `handleKeyswitchEvent` only:

```auto
#define PRESS(X) handleKeyswitchEvent(X, Macros.row, Macros.col, keyState)

    case M_WHEEL_LEFT:
        if (keyIsPressed(keyState))
// return MACRODOWN(D(LeftShift), T(mouseScrollUp), U(LeftShift));
        {
            PRESS(Key_LeftShift); PRESS(Key_mouseScrollUp);
        }
        break;

    case M_WHEEL_RIGHT:
        if (keyIsPressed(keyState))
// return MACRODOWN(D(LeftShift), T(mouseScrollDn), U(LeftShift));
        {
            PRESS(Key_LeftShift); PRESS(Key_mouseScrollDn);
        }
        break;

```

I’m starting to wonder if it was worth trying to enable the use of mouse keys in macros (since there exists a non-problematic alternate solution)…

---

_[View the full topic](https://community.keyboard.io/t/ctrl-scroll-for-zoom-not-working-from-keyboard-but-working-from-mouse/1649)._
