Split measure does not apply selected barline type
P2 - Medium
S4 - Minor
When adding a barline with ctrl+doubleclick or ctrl+drag in order to split a measure, the barline is not added with the type the user has chosen from the palette.
It always adds a simple barline.
I'll take a look at this one.
I started working on this after it was first mentioned here, and I have a fix for it. But I kept finding other related issues that want fixing as well. A proper solution will change the barline in all staves and in all linked scores. But the split and join measure operations don't work well on linked parts. (See #51401: Split and join measure commands corrupt linked parts, which was never really fixed.) I have a fix for #51401 which is almost ready, except for making sure that the original end barline type is preserved after a measure is split. And I just noticed that when a barline type is changed, that change is not reflected in linked parts. Also, if you select a barline and double-click a "Start Repeat" barline in the palette, the "Start Repeat" is applied to the wrong measure.
And another thing: If you drop a barline onto a chord/rest without splitting the measure, the barline is only applied to that particular staff. Is this intended/expected? Shouldn't a barline be added at the same point in the measure for all staves? Is there a reason why the current behavior may be desirable?
Oh good, I'm glad someone else can fix this. Trying to find a solution was driving me mad, because, as you said, there's a raft of other issues related to this. One I found was an error related to drawing the Timeline view which caused a segfault when a measure with an additional barline was selected, every time.
As for expected behaviour, all I can say is that MS2 behaviour is to apply a dropped barline to one staff only.
Update: the segfault I was talking about is caused by the method Timeline::drawSelection(), specifically by the calling of measure->mmRest(). So, I'd guess that at some point the measure's _mmRest is assigned to a temporary variable, and then this variable is deleted.
I've fixed and documented that segfault issue, which I think is different to what you've been working on: #277326: Segfault when selecting first measure with a barline that isn't an EndBarLine