fix: flatten slur if distance is too large#279
Merged
yinanazhou merged 1 commit intodevelopfrom Apr 17, 2025
Merged
Conversation
- Added condition when the horizontal distance is more than 2000 - Used two control points for this condition refs: #271
Member
|
@yinanazhou I tried this on a few scores and it seems to work, visually. Thanks! If I understand correctly, you rely on pixel distances in your algorithm. Are these distances independent of zoom level? If they are, then please go ahead and merge the PR—it looks good. If not, we need to adjust the algorithm so that its decision to flatten is independent of the current zoom level. |
Collaborator
Author
|
@yrammos the width is calculated using SVG coordinate system, whereas zoom uses CSS transforms. The zoom level will not affect the calculation of the width. |
Member
|
Excellent. Then we can merge this in, @yinanazhou. There are some potential adjustments to discuss, but they would be separate PRs. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
refs: #271
before:
after: