Time Signature position of numerals not updated when staff size change

• Mar 18, 2017 - 08:22
Reported version
3.0
Type
Functional
Severity
S4 - Minor
Status
closed
Project

Observed on 3543170

1. my first score
2. right click staff and make small

result is the time signature numerals are correctly displayed with correct new smaller size, but their positions remain as they were when big:

small-staff-time-sig-messed-up.png

Interestingly if save and reload small.mscz then will find that the time sigs are dispalyed correctly. So the act of toggling staff properties small staff checkbox needs to tell the time sigs to update position.

Interestingly started from that saved small staff, if then make staff large again, then have buggy behavior as well, since the numerals keep their position, but display in the new bigger size:

after-make-staff-big-again.png


Comments

interestingly, the "generated" courtesy time sig at end of a system is rendered correctly.

Probably is simply a matter of re-triggering the placement of the numbers when staff properties modified.

So I set breakpoint in the following:

void TimeSig::layout()
      {
      if (_needLayout)
            layout1();
      }

And I found when I toggle small on/off, that that layout() is called, but _needLayout is false, so the real layout in layout1() doesn't execute. So clearly _needLayout should be set true when small is toggled.

I'm giving up...because I don't know the codebase well enough. But the solution lies in somewhere in EditStaff::apply() calling TimeSIg::setNeedLayout(true).