Marc Sabatella wrote > Thanks for looking into this further! [...] > >> I see two possible strategies: >> >> 1) *Score::layoutSystem()* checks for potential courtesy elements before >> adding another measure to the system. >> >> 2) *Score::layoutSystemRow()* checks for available room before adding the >> courtesy elements it sees needed and removes the last system measure if >> they >> do not fit. > > [...] My gut feel is that #1 makes more sense, because if > layoutSystemRow(0 decides it needs to remove a measure from a system, it > is going to need to call layoutSystem() again on every system from then > on, and this process could potentially go on and on. I think I'd rather > layoutSystem get the calculation "right" the first time - even if that > means being a bit conservative. Not sure it would, but I'd be willing to > live with it. [...]
Precisely along these lines, further investigation unearthed a function *Score::cautionaryWidth()* in layout.cpp, which is apparently supposed to do exactly that: detect and compute the width of cautionary/courtesy elements after a measure. A TODO note in *Score::layoutSystem()* hints it should be used there, but in fact it is not (it is actually not used at all). Anybody knows why? Is *Score::cautionaryWidth()* still unfinished or wrong? Is an old lead now abandoned? Thanks, M. -- View this message in context: http://dev-list.musescore.org/On-ping-pong-ing-layout-tp7578972p7578979.html Sent from the MuseScore Developer mailing list archive at Nabble.com. ------------------------------------------------------------------------------ Slashdot TV. Video for Nerds. Stuff that matters. http://tv.slashdot.org/ _______________________________________________ Mscore-developer mailing list Mscore-developer@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/mscore-developer