mac: Setting to explicitly choose pan or zoom for mouse wheel (#1339) by nanoant · Pull Request #1344 · solvespace/solvespace · GitHub
Skip to content

mac: Setting to explicitly choose pan or zoom for mouse wheel (#1339)#1344

Open
nanoant wants to merge 1 commit into
solvespace:masterfrom
nanoant:mac/explicit-zoom-pan-setting
Open

mac: Setting to explicitly choose pan or zoom for mouse wheel (#1339)#1344
nanoant wants to merge 1 commit into
solvespace:masterfrom
nanoant:mac/explicit-zoom-pan-setting

Conversation

@nanoant

@nanoant nanoant commented Feb 20, 2023

Copy link
Copy Markdown
Contributor

While auto remains the default, we now support explicit choice of doing pan or zoom when scrolling with mouse wheel or touch pad.

This can be also adapted for other (non-macOS) platforms.

…pace#1339)

While auto remains the default, we now support explicit choice of doing
pan or zoom when scrolling with mouse wheel or touch pad.

This can be also adapted for other (non-macOS) platforms.
@vespakoen

Copy link
Copy Markdown
Contributor

@phkahler

Copy link
Copy Markdown
Member

I'm with @vespakoen on this. It also should not be platform specific. And pan with scroll wheel doesn't make sense because it only works vertically. Scroll means zoom.

@nanoant

nanoant commented Feb 22, 2023

Copy link
Copy Markdown
Contributor Author

@phkahler @vespakoen I can reiterate on this, what should be then the correct name for the setting?
Pointing device (*) Auto-detect ( ) Mouse ( ) Trackpad ?

@phkahler

Copy link
Copy Markdown
Member

I should have been clearer, but sometimes I don't want to upset contributors. I don't want scroll wheel to pan even as an option. Won't merge it.

@nanoant

nanoant commented Feb 22, 2023

Copy link
Copy Markdown
Contributor Author

@phkahler No problem for me. And yes this is a follow up for #1339 and #1093 e1b0784 which started all of this by introducing panning behavior on trackpads implemented inside of - (void)scrollWheel:(NSEvent *)nsEvent.

Please note that the event is called "scroll wheel", not "touch" or "track pad". So its purpose is to handle scrolling not anything else. This implementation broke my Apple Magic Mouse workflow that suddenly started panning instead of zooming. I tried to un-break it by extending too weak nsEvent.subtype == NSEventSubtypeTabletPoint && kind == Platform::Window::Kind::TOPLEVEL check, adding activeTrackpadTouches > 0. But apparently it stills trips on some weird Logitech mice setups. I tested #1274 cf4defc with my two Logitech mice and some 2 Chinese unbranded ones, and they all worked fine. But I don't use any Logitech customization software and I can only suspect such a software may make USB HID look like touch pad to guimac.m code for whatever reason.

So long story short, I am trying to make this software work for all macOS users, but I am not responsible for having #1339 guys complaining that wheel is panning instead of moving, because I did not contribute that panning implementation in the first place. (Un?)fortunately I was called up with my GitHub id, because I was last person trying to fix the flawed #1093 implementation.

If #1093 was implemented using gestures maybe we had no such a problem, but the original author decided to do it within scrollWheel and now we have 2 camps of touch pad users wanting to pan and mouse users wanting to zoom, both via single scrollWheel implementation.

So I hope this is clear. And I am not upset (contributor), but I want to make sure you get the whole picture that I am just an ex-macOS developer who's now doing something completely else for living and doing 3D printing for fun trying to help 🥲

@phkahler

Copy link
Copy Markdown
Member

@ruevs ruevs force-pushed the master branch 2 times, most recently from 93215ea to bc2bca8 Compare March 28, 2026 09:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants