Re: Split percent repeats at line breaks

2020-03-01 Thread antlists

On 29/02/2020 13:10, Davide Liessi wrote:

Hi all.
I'd like to have percent repeats automatically split at line breaks,
i.e., in the following example I'd like the first score to look like
the second.

\version "2.19.84"
\score {
   \repeat percent 30 { c'1 }
}
\score {
   {
 \repeat percent 14 { c'1 }
 \repeat percent 16 { c'1 }
   }
}

I think that this should typically also reset the percent repeat
counter, effectively behaving as if they were distinct percent
repeats, but being able to choose whether to reset it or not would be
nice.

Is there a way to achieve this?

I think your first requirement is the norm for human engraving, 
certainly I've never come across any music outside of lilypond where a 
staff has a percent as its first bar. Equally, I've never seen it reset 
the count - that just carries on. What I have seen is where the count 
only starts at eg bar 5.


I don't know enough about lilypond internals, but I guess the big 
problem is that if the line-breaking calculation actually affects the 
size of the bar (changing the first bar of a line from a percent to a 
copy of bar 1 of the repeat), then the calculation itself could get into 
quite a tangle.


Cheers,

Wol




Split percent repeats at line breaks

2020-02-29 Thread Davide Liessi
Hi all.
I'd like to have percent repeats automatically split at line breaks,
i.e., in the following example I'd like the first score to look like
the second.

\version "2.19.84"
\score {
  \repeat percent 30 { c'1 }
}
\score {
  {
\repeat percent 14 { c'1 }
\repeat percent 16 { c'1 }
  }
}

I think that this should typically also reset the percent repeat
counter, effectively behaving as if they were distinct percent
repeats, but being able to choose whether to reset it or not would be
nice.

Is there a way to achieve this?

Best wishes.
Davide