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

add courtesy keysig to last measure even if it is followed by frame #25420

Merged
merged 2 commits into from
Dec 17, 2024

Conversation

sammik
Copy link
Contributor

@sammik sammik commented Nov 3, 2024

Resolves: #22256
Resolves: #19759

  • creating courtesy keysig was disabled by MeasureLayout::createEndBarLines(measure, **false**, ctx);, which sets ElementFlag::KEYSIG of measurebase to false, so before adding trailer, we need to re-createEndBarLines with truthy isLastMeasureInSystem value
  • this was already (almost) done, with one exception - it processed last measureBase of system, but we need last real measure (not frame)

keysig-frame

  • I signed the CLA
  • The title of the PR describes the problem it addresses
  • Each commit's message describes its purpose and effects, and references the issue it resolves
  • If changes are extensive, there is a sequence of easily reviewable commits
  • The code in the PR follows the coding rules
  • There are no unnecessary changes
  • The code compiles and runs on my machine, preferably after each commit individually
  • I created a unit test or vtest to verify the changes I made (if applicable)

@sammik sammik force-pushed the courtesy-keysig-before-frame branch from a9e5225 to 04f5687 Compare November 4, 2024 15:18
@oktophonie oktophonie requested a review from mike-spa November 8, 2024 09:35
@mike-spa mike-spa merged commit b532152 into musescore:master Dec 17, 2024
11 checks passed
Jojo-Schmitz pushed a commit to Jojo-Schmitz/MuseScore that referenced this pull request Dec 17, 2024
@Jojo-Schmitz
Copy link
Contributor

Jojo-Schmitz commented Dec 17, 2024

What about section breaks?
image

I don't think courtesy key sigs should show in that case, just like courtesy clefs and courtesy time sigs
image

Changing to

        if (ctx.state().prevMeasure() && ! ctx.state().prevMeasure()->sectionBreak()) {
            MeasureLayout::createEndBarLines(lm, true, ctx);
        }

fixes that, I'll PR this, see #25865

@sammik
Copy link
Contributor Author

sammik commented Dec 18, 2024

What about section breaks?

Thank You, I missed this.

@sammik sammik deleted the courtesy-keysig-before-frame branch December 22, 2024 00:59
Jojo-Schmitz pushed a commit to Jojo-Schmitz/MuseScore that referenced this pull request Dec 22, 2024
Jojo-Schmitz pushed a commit to Jojo-Schmitz/MuseScore that referenced this pull request Dec 22, 2024
Jojo-Schmitz pushed a commit to Jojo-Schmitz/MuseScore that referenced this pull request Dec 25, 2024
Jojo-Schmitz pushed a commit to Jojo-Schmitz/MuseScore that referenced this pull request Dec 27, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
4 participants