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 #294082: TAB - Mixing mensural value symbols and beaming in historic tablatures is broken. #5304

Merged
merged 1 commit into from
Oct 2, 2019

Conversation

mattmcclinch
Copy link
Contributor

@mattmcclinch mattmcclinch commented Sep 5, 2019

Resolves: https://musescore.org/en/node/294082.

TabDurationSymbol::layout2() is responsible for setting the _beamLength for the tab duration symbol, which is used to determine the length of the line to draw. Problem is, TabDurationSymbol::layout2() is only ever called from Chord::layoutStem(), and Chord::layoutStem() is not being called at all, except from ChordRest::removeDeleteBeam(). Therefore, _beamLength is always equal to 0, which results in zero-length lines being drawn.

This adds a call to Chord::layoutStem() TabDurationSymbol::layout2() from LayoutContext::collectPage() Chord::layout2(), so that _beamLength can be set to the correct value.

@MarcSabatella
Copy link
Contributor

MarcSabatella commented Sep 5, 2019

I don't have a really specific concern, but I do know that the relationship between stem and beam layout is very delicate - tons of things can go wrong, like bad placement of slashes on grace notes, bad layout of rhythmic slash notation, bad layout of cross-staff beams, etc - if things get thrown off. So it scares me a little to add this code for all cases. Could we maybe do it only for tab staves?

EDIT: or find a different place to call TabDurationSymbol::layout2()

…ric tablatures is broken.

TabDurationSymbol::layout2() is responsible for setting the _beamLength for the tab duration symbol, which is used to determine the length of the line to draw. Problem is, TabDurationSymbol::layout2() is only ever called from Chord::layoutStem(), and Chord::layoutStem() is not being called at all, except from ChordRest::removeDeleteBeam(). Therefore, _beamLength is always equal to 0, which results in zero-length lines being drawn.

This adds a call to TabDurationSymbol::layout2() from Chord::layout2(), so that _beamLength can be set to the correct value.
@mattmcclinch
Copy link
Contributor Author

It seems natural to call TabDurationSymbol::layout2() from Chord::layout2(), so that is what this does now.

@anatoly-os anatoly-os merged commit 7fea86b into musescore:master Oct 2, 2019
anatoly-os added a commit that referenced this pull request Oct 2, 2019
fix #294082: TAB - Mixing mensural value symbols and beaming in historic tablatures is broken.
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.

3 participants