-
Notifications
You must be signed in to change notification settings - Fork 2.7k
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
Beam / tremolo layout refactor #16223
Conversation
72105f0
to
7e1eebb
Compare
This comment was marked as resolved.
This comment was marked as resolved.
9e04765
to
68976e6
Compare
345b291
to
25f0e85
Compare
fe002d0
to
1bff2d2
Compare
src/engraving/libmscore/beam.h
Outdated
double y2; | ||
}; | ||
|
||
class BeamLayout |
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.
I would recommend moving this class to a separate file inside the engraving/layout folder
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.
All BeamLayout functionality moved out into beamlayout.cpp
!
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.
You should also move the declaration of this class into beamlayout.h. Both of these files (beamlayout.h/cpp) should be placed in engraving/layout
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.
done! moved both into beamtremololayout
.cpp/.h
c0605db
to
fb99cdf
Compare
so that two-note tremolos can use it as well
The vast majority of these utest fixes are due to beam positions being able to occupy a floater space outside the staff if they slant away. A few others add tremolo anchor point information which this PR added
bebc3d7
to
9cf89c5
Compare
and rebase shenanigans for PR musescore#16719
computeUp can be called before the beam is laid out, so we need to do that if necessary
Resolves: #15470
The idea of this PR is to factor out our fancy new beam positioning algorithm into its own class, which can be used by both beams and two-note tremolos. This doesn't change anything about beams, but rather radically changes two-note trems' behavior to use the beam layout algorithm.