-
-
Notifications
You must be signed in to change notification settings - Fork 242
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Angle snapping tolerance functionality #5945
base: master
Are you sure you want to change the base?
Conversation
df6f764
to
aa21c33
Compare
🎉 Ta-daaa, freshly created APKs are available for d0f8a2a: arm64-android |
6571111
to
c3bcd17
Compare
c3bcd17
to
f434250
Compare
f434250
to
b8d7c3d
Compare
Alright, first, UI-wise, I think we need to make sure we have our text labels aligned vertically, which means you'll need to push add padding to pretty much everything there, i.e.: Also, I think we've discussed this briefly but just as a recall, I think we should not close the popup when someone clicks on elements of the popup as I think it'd be quite likely a user would want to change more than one setting at a time. Onto the actual functionality, I see there's a problem that needs resolving: when tolerance is set to largest, snapping doesn't occur when your coordinate cursor gets close to the last entered point. It's actually something that's happening even at normal snapping tolerance, but it's most visible when set at large. Looking at the code now. |
src/qml/CoordinateLocator.qml
Outdated
case 0 // Narrow | ||
: | ||
return 0.5; | ||
case 1 // Normal | ||
: | ||
return 1; | ||
case 2 // Large | ||
: | ||
return 4; | ||
default: | ||
return 1; | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ouf, what's happening with the formatting here? Is it caused by the // comment next to the case forcing the column (:) to go onto next line? Let's fix that.
also, you should have case 1 and default both be together. The logic here is that default == normal. If we keep them separated, it's quite likely we'll end up changing one value and forget the other.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ah, yes formatting did this, Agreed 👍
Add padding, fix typo, fix formatting, try to fix logic.
PR Description
The snapping to angles functionality was working, but the snapping tolerance (the distance within which the cursor would snap to an angle) was too low. This low tolerance made it difficult to snap accurately to angles, especially when digitizing without a mouse. The precision required to hit the right angles was cumbersome, causing a less intuitive experience for users.
Solution:
To address this, we added a new option that allows users to configure the snapping tolerance for angles. This change improves usability by giving users more flexibility in setting the snapping distance to their preference, making it easier to snap to angles accurately without requiring precise cursor placement.
Changes Made:
Narrow
Normal
Large
This enhancement improves the overall user experience, especially when precision is important.
Image: