Skip to content
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

Fix #297482 - Score layout shifts when saved with fingering on acciaccatura #5822

Merged
merged 1 commit into from
Mar 17, 2020

Conversation

njvdberg
Copy link
Contributor

@njvdberg njvdberg commented Mar 16, 2020

…catura

Resolves: https://musescore.org/en/node/297482#comment-984598

Solves the shift of the fingering on the grace note, and therefor the shift of the line above the fingering.

The root cause was StemSlash. Shapes for the StemSlash are created during the layout of the beams of the grace notes and the layout of these beams is with the layout of the complete Chord to which the grace notes belong. As a result, the shapes of StemSlash are added to the skyline after the layout of the Fingering so the layout of the Fingering was based of the layout of the Stem only.
After a re-layout the StemSlash is included in the skyline so the re-layout will move
the Fingering and, in this case, also the line.
The solution was a extra layout of the StemSlash in Score::layoutChords3() so its StemSlash is included in the skyline in time.

Although this issue is very similar to #302316 and fix #297501, the root cause is different.

  • I signed CLA
  • I made sure the code in the PR follows the coding rules
  • I made sure the code compiles on my machine
  • I made sure there are no unnecessary changes in the code
  • I made sure the title of the PR reflects the core meaning of the issue you are solving
  • I made sure the commit message(s) contain a description and answer the question "Why do those changes fix that particular issue?" or "Why are those changes really necessary as improvements?"
  • I made sure the commit message title starts with "fix #424242:" if there is a related issue
  • I created the test (mtest, vtest, script test) to verify the changes I made

…catura

Solves the shift of the fingering on the grace note, and therefor the shift of the line above the fingering.

The root cause was StemSlash. Shapes for the StemSlash are created during the layout of the
beams of the grace notes and the layout of these beams is with the layout of the complete Chord
to which the grace notes belong. As a result, the shapes of StemSlash are added to the skyline
after the layout of the Fingering so the layout of the Fingering was based of the layout of the
Stem only.
After a re-layout the StemSlash is included in the skyline so the re-layout will move
the Fingering and, in this case, also the line.
The solution was a extra layout of the StemSlash in Score::layoutChords3() so it StemSlash is
included in the skyline in time.

Although this issue is vert similar as #302316 and fix #297501, the root cause is
different.
@njvdberg
Copy link
Contributor Author

This PR is related to #5812 but has a different root cause and is therefor independent.

@dmitrio95 dmitrio95 changed the title Fix #297482 - Score layout shifts when saved with fingering on acciac… Fix #297482 - Score layout shifts when saved with fingering on acciaccatura Mar 17, 2020
@dmitrio95 dmitrio95 merged commit 72ef2a5 into musescore:master Mar 17, 2020
@njvdberg njvdberg deleted the issue-297482-layout-shifts branch March 27, 2020 10:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants