Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix #311788: gap between staff and end barline with courtesy clef
Resolves: https://musescore.org/en/node/311788 A recent commit fixed some issues with courtesy clefs, but introduced a regression - courtesy clefs on invisible staves were not being ignored, causing the segment to be marked visible and rhen in turn the measure width to be recalculated as if the clef were visible. This puts the barline too far to the right, with gap between the end of the staff and the barline. The clef itself was still ignored in the width calculation, so the discrepancy is not large - only the size of the margins before and after the clef. Fix is to skip invisible staves in the code that is checking for measures that need their width recalculated. AIn debugging this, I became aware this clef on an invisible staff was also appearing to affect the skyline of the visible staff, leading me on a wild goose chase, But that turns out to be an illusion - the clef is not added to the skyline of the visible staff at all. It's just that the skyline drawing code (used when turning "Show Skylines" in the Debug menu) is *also* failing to skip invisible staves. So I have fixed that as well.
- Loading branch information