From fe1eb832e9e1e92e2bf98c33011465658192f033 Mon Sep 17 00:00:00 2001 From: Han-Wen Nienhuys Date: Fri, 13 Feb 2004 12:33:20 +0000 Subject: [PATCH] * lily/rest.cc (polyphonic_offset_callback): new function. Do vertical positioning for polyphony, without RestCollision object. * lily/note-column.cc (add_head): prevent rests & note heads on one stem. * lily/rest-collision.cc (do_shift): ignore rests with beams. (do_shift): rewrite only-rests case: use common refpoints: the routine will have sensible results when other rest-translations have taken place. * lily/simple-spacer.cc (solve): cleanup: remove code for linelen < 0 case. * input/GNUmakefile (SUBDIRS): remove ascii-art --- ChangeLog | 14 ++ Documentation/topdocs/NEWS.texi | 2 + input/mutopia/F.Schubert/morgenlied.ly | 25 --- input/mutopia/F.Schubert/standchen.ly | 50 ------ .../J.S.Bach/baerenreiter-sarabande.ly | 5 - input/mutopia/J.S.Bach/bwv940.ly | 4 - input/mutopia/J.S.Bach/wtk1-fugue2.ly | 4 - input/mutopia/R.Schumann/romanze-op28-2.ly | 56 ------ .../mutopia/W.A.Mozart/mozart-hrn3-allegro.ly | 28 --- .../mutopia/W.A.Mozart/mozart-hrn3-romanze.ly | 8 - input/mutopia/W.A.Mozart/mozart-hrn3-rondo.ly | 12 -- input/regression/rest-collision-beam.ly | 46 +++-- input/regression/rest-collision-default.ly | 19 -- input/regression/rest-polyphonic.ly | 2 +- lily/column-x-positions.cc | 2 +- lily/gourlay-breaking.cc | 6 +- lily/include/column-x-positions.hh | 2 +- lily/include/note-column.hh | 12 +- lily/include/rest.hh | 1 + lily/include/simple-spacer.hh | 6 +- lily/note-column.cc | 32 +++- lily/rest-collision-engraver.cc | 9 +- lily/rest-collision.cc | 162 ++++++++---------- lily/rest.cc | 13 +- lily/simple-spacer.cc | 57 +++--- scm/define-grobs.scm | 4 +- scm/music-functions.scm | 2 +- scripts/abc2ly.py | 10 +- scripts/etf2ly.py | 2 +- 29 files changed, 216 insertions(+), 379 deletions(-) delete mode 100644 input/regression/rest-collision-default.ly diff --git a/ChangeLog b/ChangeLog index d7469abbd8..83766b2b40 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,19 @@ 2004-02-13 Han-Wen Nienhuys + * lily/rest.cc (polyphonic_offset_callback): new function. Do + vertical positioning for polyphony, without RestCollision object. + + * lily/note-column.cc (add_head): prevent rests & note heads on + one stem. + + * lily/rest-collision.cc (do_shift): ignore rests with beams. + (do_shift): rewrite only-rests case: use common refpoints: the + routine will have sensible results when other rest-translations + have taken place. + + * lily/simple-spacer.cc (solve): cleanup: remove code for linelen + < 0 case. + * input/GNUmakefile (SUBDIRS): remove ascii-art 2004-02-13 Jan Nieuwenhuizen diff --git a/Documentation/topdocs/NEWS.texi b/Documentation/topdocs/NEWS.texi index 7edf2db43f..2e43336150 100644 --- a/Documentation/topdocs/NEWS.texi +++ b/Documentation/topdocs/NEWS.texi @@ -22,6 +22,8 @@ Version 2.1.13 the following table lists the differences: @example + (old) (new) + \property A.B = #C \set A.B = #C \property A.B \unset \unset A.B \property A.B \set #C = #D \override A.B #C = #D diff --git a/input/mutopia/F.Schubert/morgenlied.ly b/input/mutopia/F.Schubert/morgenlied.ly index 07d58201b2..416e7c3c65 100644 --- a/input/mutopia/F.Schubert/morgenlied.ly +++ b/input/mutopia/F.Schubert/morgenlied.ly @@ -73,21 +73,12 @@ melody = \notes \relative c'' \repeat volta 2 \context Voice = singer { } -<<<<<<< morgenlied.ly -ignoreMelisma = \set ignoreMelismata = ##t -ignoreMelismaOff = \unset ignoreMelismata -======= ignoreMelisma = \set ignoreMelismata = ##t ignoreMelismaOff = \unset ignoreMelismata ->>>>>>> 1.20 firstVerse = \lyrics { -<<<<<<< morgenlied.ly - \set stanza = "1." -======= \set stanza = "1." ->>>>>>> 1.20 Sü -- ßes Licht! Aus \ignoreMelisma @@ -102,11 +93,7 @@ firstVerse = \lyrics { } secondVerse = \lyrics { -<<<<<<< morgenlied.ly - \set stanza = "2." -======= \set stanza = "2." ->>>>>>> 1.20 Ach, der Lie -- be sanf -- tes We -- hen schwellt mir | das be -- weg -- te __ Herz, sanft, wie ein ge -- lieb -- ter Schmerz. __ Dürft ich | @@ -119,11 +106,7 @@ pianoRH = \notes \relative c''' \repeat volta 2 { g16(_\p fis a g fis g f e d c b a ) | 8( ) r8 r | r8 c'( e,) f r a | -<<<<<<< morgenlied.ly - \once \override DynamicLineSpanner #'padding =#3 -======= \once \override DynamicLineSpanner #'padding =#3 ->>>>>>> 1.20 r8_\> << { s8 s8-\! } << { fis( g) } \\ { c,4 } >> >> r8 | 4. r8 \clef bass | @@ -153,11 +136,7 @@ pianoLH = \notes \relative c'' \repeat volta 2 { fis r4 8( | 4.) -<<<<<<< morgenlied.ly \once \override Slur #'height-limit = #1.0 -======= - \once \override Slur #'height-limit = #1.0 ->>>>>>> 1.20 4.( | 4.) | c,4 r8 g4 r8 | @@ -176,11 +155,7 @@ pianoLH = \notes \relative c'' \repeat volta 2 { \lyricsto "singer" \new Lyrics \firstVerse \lyricsto "singer" \new Lyrics \secondVerse \new PianoStaff << -<<<<<<< morgenlied.ly - \set PianoStaff.instrument = \markup { -======= \set PianoStaff.instrument = \markup { ->>>>>>> 1.20 \bold \bigger\bigger\bigger\bigger \huge "2. " } \new Staff \pianoRH diff --git a/input/mutopia/F.Schubert/standchen.ly b/input/mutopia/F.Schubert/standchen.ly index 600e8fe192..48dc67195e 100644 --- a/input/mutopia/F.Schubert/standchen.ly +++ b/input/mutopia/F.Schubert/standchen.ly @@ -66,21 +66,13 @@ vocalVerse = \notes\relative c''{ g8. b16 es4. d8 | c8. g16 es4. c8 | \grace { -<<<<<<< standchen.ly - \override Stem #'stroke-style = #"grace" -======= \override Stem #'stroke-style = #"grace" ->>>>>>> 1.31 as'32[( bes ] \revert Stem #'stroke-style } \times 2/3 { as8[)( g)] as } c4. as8 | g2. | \grace { -<<<<<<< standchen.ly - \override Stem #'stroke-style = #"grace" -======= \override Stem #'stroke-style = #"grace" ->>>>>>> 1.31 f32[( g ] \revert Stem #'stroke-style } \times 2/3 { f8[)( e)] f } as4. f8 | @@ -89,11 +81,7 @@ vocalVerse = \notes\relative c''{ g8. b16 es4. d8 | c8. g16 e4. c8 | \grace { -<<<<<<< standchen.ly - \override Stem #'stroke-style = #"grace" -======= \override Stem #'stroke-style = #"grace" ->>>>>>> 1.31 a'32[( b ] \revert Stem #'stroke-style } \times 2/3 { a!8[)( gis)] a } c4. a8 | @@ -113,11 +101,7 @@ vocalThrough = \notes\relative c{ R2. | R2. | \grace { -<<<<<<< standchen.ly - \override Stem #'stroke-style = #"grace" -======= \override Stem #'stroke-style = #"grace" ->>>>>>> 1.31 a32[( b ] \revert Stem #'stroke-style } \times 2/3 { a!8[)( gis)] a } c4. a8 | @@ -209,17 +193,9 @@ trebleVerseOne = \notes\relative c{ r8\pp | %20 r8 | -<<<<<<< standchen.ly - \override Slur #'attachment = #'(stem . stem) -======= \override Slur #'attachment = #'(stem . stem) ->>>>>>> 1.31 \grace { -<<<<<<< standchen.ly - \override Stem #'stroke-style = #"grace" -======= \override Stem #'stroke-style = #"grace" ->>>>>>> 1.31 as'32[( bes ] \revert Stem #'stroke-style } @@ -280,11 +256,7 @@ trebleThrough = \notes \relative c'{ 4.-> 8) 2. | 2. | -<<<<<<< standchen.ly - \override TextScript #'font-shape = #'italic -======= \override TextScript #'font-shape = #'italic ->>>>>>> 1.31 2._"decresc." \revert TextScript #'font-shape @@ -298,11 +270,7 @@ trebleThrough = \notes \relative c'{ 4. 8(-. -. )-. | %80 -<<<<<<< standchen.ly - \override TextScript #'font-shape = #'italic -======= \override TextScript #'font-shape = #'italic ->>>>>>> 1.31 2._"dim." \revert TextScript #'font-shape @@ -435,20 +403,11 @@ vocals = \context Voice = leise \notes { R1 * 3/4 * 6 } -<<<<<<< standchen.ly -trebleStaff = \context Staff = treble<< - \set Staff.midiInstrument = "acoustic grand" -======= trebleStaff = \context Staff = treble<< \set Staff.midiInstrument = "acoustic grand" ->>>>>>> 1.31 \global {\clef treble -<<<<<<< standchen.ly \override autoBeamSettings #'(begin * * * *) = #(ly:make-moment 0 1) -======= - \override autoBeamSettings #'(begin * * * *) = #(ly:make-moment 0 1) ->>>>>>> 1.31 \trebleIntro \trebleVerseOne \trebleEentje @@ -456,13 +415,8 @@ trebleStaff = \context Staff = treble<< \trebleThrough } >> -<<<<<<< standchen.ly -bassStaff = \context Staff = bass<< - \set Staff.midiInstrument = "acoustic grand" -======= bassStaff = \context Staff = bass<< \set Staff.midiInstrument = "acoustic grand" ->>>>>>> 1.31 \global \clef bass {\bassIntro @@ -476,11 +430,7 @@ bassStaff = \context Staff = bass<< \score{ << \new Staff << -<<<<<<< standchen.ly - \set Staff.midiInstrument = "synth voice" -======= \set Staff.midiInstrument = "synth voice" ->>>>>>> 1.31 %% insert \transpose if necessary, depending on voice range. \global \vocals diff --git a/input/mutopia/J.S.Bach/baerenreiter-sarabande.ly b/input/mutopia/J.S.Bach/baerenreiter-sarabande.ly index c9f299d83e..273ea88be5 100644 --- a/input/mutopia/J.S.Bach/baerenreiter-sarabande.ly +++ b/input/mutopia/J.S.Bach/baerenreiter-sarabande.ly @@ -121,14 +121,9 @@ sarabandeA = \context Voice \notes \relative c { d'[ cis] | %% d4 d,,2 | d4 -<<<<<<< baerenreiter-sarabande.ly - \override NoteHead #'after-line-breaking-callback - = #(lambda (smob) (assert-system-count smob 6)) -======= \override NoteHead #'after-line-breaking-callback = #(lambda (smob) (assert-system-count smob 6)) ->>>>>>> 1.30 d,,2 | } diff --git a/input/mutopia/J.S.Bach/bwv940.ly b/input/mutopia/J.S.Bach/bwv940.ly index eb4b751d3c..fd26dc6e3f 100644 --- a/input/mutopia/J.S.Bach/bwv940.ly +++ b/input/mutopia/J.S.Bach/bwv940.ly @@ -116,11 +116,7 @@ four = \notes\relative c{ a gis ~ gis16 gis fis e \skip 4*1 \change Staff=lower \stemDown -<<<<<<< bwv940.ly - \override NoteColumn #'horizontal-shift = #0 -======= \override NoteColumn #'horizontal-shift = #0 ->>>>>>> 1.7 \stemUp\tieUp b2 a | g a4. gis16 a | diff --git a/input/mutopia/J.S.Bach/wtk1-fugue2.ly b/input/mutopia/J.S.Bach/wtk1-fugue2.ly index 8f3c772f86..db7a991564 100644 --- a/input/mutopia/J.S.Bach/wtk1-fugue2.ly +++ b/input/mutopia/J.S.Bach/wtk1-fugue2.ly @@ -192,11 +192,7 @@ bassdux = \context Voice=three \notes \relative c' { \score { \notes \context PianoStaff << -<<<<<<< wtk1-fugue2.ly \override Score.TimeSignature #'style = #'C -======= - \override Score.TimeSignature #'style = #'C ->>>>>>> 1.15 \context Staff = treble << \key c \minor \dux diff --git a/input/mutopia/R.Schumann/romanze-op28-2.ly b/input/mutopia/R.Schumann/romanze-op28-2.ly index 2205f15ede..7a5250149e 100644 --- a/input/mutopia/R.Schumann/romanze-op28-2.ly +++ b/input/mutopia/R.Schumann/romanze-op28-2.ly @@ -33,17 +33,9 @@ global = \notes { \key fis \major \time 6/8 righta = \notes \transpose c cis' { % \stemUp \slurUp \tieUp \stemUp -<<<<<<< romanze-op28-2.ly - \override Slur #'attachment = #'(stem . stem) -======= \override Slur #'attachment = #'(stem . stem) ->>>>>>> 1.32 \repeat volta 2 { -<<<<<<< romanze-op28-2.ly - \override TextScript #'extra-offset = #'(-8.0 . 2.5) -======= \override TextScript #'extra-offset = #'(-8.0 . 2.5) ->>>>>>> 1.32 \m a,16[^\p( \u c^\markup { \large "Einfach (" \note #"8" #1 @@ -115,13 +107,8 @@ rightb = \notes \transpose c cis' { c_3 g,_2 es, g, h,_4 g, d, g, c g,8 f,16 | c g, es, g, es c_3 as, c^2 d^3 c h, c | e des b,\< des g e_3 ces_4 d_2 f^3 d cis d | -<<<<<<< romanze-op28-2.ly - \override PhrasingSlur #'extra-offset = #'(0 . 3) - \override PhrasingSlur #'beautiful = #42 -======= \override PhrasingSlur #'extra-offset = #'(0 . 3) \override PhrasingSlur #'beautiful = #42 ->>>>>>> 1.32 g\( fes des fes b g_3 es_1\! ges_2 a^3 ges f_1 ges_2 | r ges_2 b des_1 ges b,_2 des ges,^1 b, \d des,^1 \stemDown \transpose c' c { b,[_1 as,] | g,8 b,16[ g, e, cis,] d,\)_4 \< f, h, d_3 f_2 r16\! } @@ -136,22 +123,14 @@ rightb = \notes \transpose c cis' { f,8.. f32^1 g8^2 a4.) | a4^1( c8^1_\accent~[c b)] g16^1([ b^2] | c4)^1 es8^1~es d^1 f^1~ | -<<<<<<< romanze-op28-2.ly \override PianoStaff.Arpeggio #'direction = #1 -======= - \override PianoStaff.Arpeggio #'direction = #1 ->>>>>>> 1.32 f f8.. f32^1( as4.)^\fermata\arpeggio ~ | \revert PianoStaff.Arpeggio #'direction \stemUp \tieUp as r4 r8 | } s2. s \u s4. \grace { -<<<<<<< romanze-op28-2.ly - \override Stem #'stroke-style = #"grace" -======= \override Stem #'stroke-style = #"grace" ->>>>>>> 1.32 f8( \revert Stem #'stroke-style } f4) e8 | @@ -193,11 +172,7 @@ lefta = \notes \transpose c cis { c4) r8 f4-4( as8-5~ | as g-4 b)-5 as4-5( ces'8-4~ | ces' b des'-4 c'4)-5( 8 | \stemDown \tieDown des'4.)_5~des'~ | -<<<<<<< romanze-op28-2.ly - \override NoteColumn #'horizontal-shift = #-1 des' s -======= \override NoteColumn #'horizontal-shift = #-1 des' s ->>>>>>> 1.32 } >> \change Staff=down \stemUp \slurUp \tieUp \phrasingSlurUp @@ -211,11 +186,7 @@ lefta = \notes \transpose c cis { s2.*2 s8 r16 h\( c' d' es' as g8\arpeggio fis( ges)\) f16-2( a-1 c'-3 f')-1 \grace { -<<<<<<< romanze-op28-2.ly - \override Stem #'stroke-style = #"grace" -======= \override Stem #'stroke-style = #"grace" ->>>>>>> 1.32 \stemDown \slurUp b,[( f] \stemUp \revert Stem #'stroke-style } e')-1( d' c' b-1 a-2\prall g @@ -268,15 +239,6 @@ leftb = \notes \transpose c cis { \score { \notes \context PianoStaff << \pianoCautionaries -<<<<<<< romanze-op28-2.ly - \override PianoStaff.NoteCollision #'merge-differently-dotted = ##t - \set PianoStaff.connectArpeggios = ##t - \override PianoStaff.Arpeggio #'print-function = \arpeggioBracket - - \override PianoStaff.InstrumentName #'font-size = #6 - \override PianoStaff.InstrumentName #'font-shape = #'italic - \override PianoStaff.InstrumentName #'font-magnification = #3 -======= \override PianoStaff.NoteCollision #'merge-differently-dotted = ##t \set PianoStaff.connectArpeggios = ##t \override PianoStaff.Arpeggio #'print-function = \arpeggioBracket @@ -284,41 +246,23 @@ leftb = \notes \transpose c cis { \override PianoStaff.InstrumentName #'font-size = #6 \override PianoStaff.InstrumentName #'font-shape = #'italic \override PianoStaff.InstrumentName #'font-magnification = #3 ->>>>>>> 1.32 \set PianoStaff.instrument = "2. " \context Staff = up { -<<<<<<< romanze-op28-2.ly - \override Staff.DynamicLineSpanner #'direction = #-1 -======= \override Staff.DynamicLineSpanner #'direction = #-1 ->>>>>>> 1.32 \clef G <<\global \context Voice=upv \righta >> } \context Staff = mid { -<<<<<<< romanze-op28-2.ly - \override Staff.InstrumentName #'font-size = #0 - \override Staff.InstrumentName #'font-shape = #'upright - \override Staff.InstrumentName #'font-magnification = #1 - \override Staff.InstrumentName #'extra-offset = #'(0 . 6) - % \set Staff.instrument = "\\begin{turn}{-90}{Rechte Hand}\\end{turn}" - \set Staff.instrument = \markup { \column < Rechte Hand > } -======= \override Staff.InstrumentName #'font-size = #0 \override Staff.InstrumentName #'font-shape = #'upright \override Staff.InstrumentName #'font-magnification = #1 \override Staff.InstrumentName #'extra-offset = #'(0 . 6) % \set Staff.instrument = "\\begin{turn}{-90}{Rechte Hand}\\end{turn}" \set Staff.instrument = \markup { \column < Rechte Hand > } ->>>>>>> 1.32 \clef F <<\global \context Voice=midv \rightb>> } \context Staff = down { -<<<<<<< romanze-op28-2.ly - \override Staff.DynamicLineSpanner #'direction = #1 -======= \override Staff.DynamicLineSpanner #'direction = #1 ->>>>>>> 1.32 \clef F << \global \context Voice=lva \lefta \context Voice=lvb \leftb >> } diff --git a/input/mutopia/W.A.Mozart/mozart-hrn3-allegro.ly b/input/mutopia/W.A.Mozart/mozart-hrn3-allegro.ly index 16bf8ebfc0..d8799725a3 100644 --- a/input/mutopia/W.A.Mozart/mozart-hrn3-allegro.ly +++ b/input/mutopia/W.A.Mozart/mozart-hrn3-allegro.ly @@ -68,11 +68,7 @@ allegro = << a1(\trill { s2 \grace { -<<<<<<< mozart-hrn3-allegro.ly - \override Stem #'stroke-style = #"grace" -======= \override Stem #'stroke-style = #"grace" ->>>>>>> 1.16 g16[ a] \revert Stem #'stroke-style } } >> @@ -115,11 +111,7 @@ allegro = a, ( d g, c) d d \grace { -<<<<<<< mozart-hrn3-allegro.ly - \override Stem #'stroke-style = #"grace" -======= \override Stem #'stroke-style = #"grace" ->>>>>>> 1.16 e8( \revert Stem #'stroke-style } @@ -133,20 +125,12 @@ allegro = c[( b)] b4 r2 c2 (bes a) a8[(b c cis)] d2( ~ d8[ e16 d] \grace { -<<<<<<< mozart-hrn3-allegro.ly - \override Stem #'stroke-style = #"grace" -======= \override Stem #'stroke-style = #"grace" ->>>>>>> 1.16 \longgrace d16( \endlonggrace \revert Stem #'stroke-style } c8[) b16 c)] \grace { -<<<<<<< mozart-hrn3-allegro.ly - \override Stem #'stroke-style = #"grace" -======= \override Stem #'stroke-style = #"grace" ->>>>>>> 1.16 \longgrace c16 \endlonggrace \revert Stem #'stroke-style } b8[( a16 g)] g4 r2 | @@ -169,22 +153,14 @@ allegro = f4. ( d8) f8[ ( d) f d] c[ (e] g2) \grace { -<<<<<<< mozart-hrn3-allegro.ly - \override Stem #'stroke-style = #"grace" -======= \override Stem #'stroke-style = #"grace" ->>>>>>> 1.16 \longgrace f16( \endlonggrace \revert Stem #'stroke-style } e8[)( d16 c)] << d1\trill ( { s2 \grace { -<<<<<<< mozart-hrn3-allegro.ly - \override Stem #'stroke-style = #"grace" -======= \override Stem #'stroke-style = #"grace" ->>>>>>> 1.16 c16[ d] \revert Stem #'stroke-style } } >> @@ -202,11 +178,7 @@ allegro = << d1(\trill { s2 \grace { -<<<<<<< mozart-hrn3-allegro.ly - \override Stem #'stroke-style = #"grace" -======= \override Stem #'stroke-style = #"grace" ->>>>>>> 1.16 c16[ d] \revert Stem #'stroke-style } } >> diff --git a/input/mutopia/W.A.Mozart/mozart-hrn3-romanze.ly b/input/mutopia/W.A.Mozart/mozart-hrn3-romanze.ly index 0ddbe7a8fe..d0f1c64488 100644 --- a/input/mutopia/W.A.Mozart/mozart-hrn3-romanze.ly +++ b/input/mutopia/W.A.Mozart/mozart-hrn3-romanze.ly @@ -45,11 +45,7 @@ romanze = \notes \relative c' { c[ ( e) g g] g[( f e d)] c4( \grace { -<<<<<<< mozart-hrn3-romanze.ly - \override Stem #'stroke-style = #"grace" -======= \override Stem #'stroke-style = #"grace" ->>>>>>> 1.15 \longgrace e16 \endlonggrace \revert Stem #'stroke-style } @@ -57,11 +53,7 @@ romanze = \notes \relative c' { \mark "C" %% this is a trick to get the sfp-s to align. -<<<<<<< mozart-hrn3-romanze.ly - \override Hairpin #'transparent = ##t -======= \override Hairpin #'transparent = ##t ->>>>>>> 1.15 des1\sfp \> g,1\sfp\! \> c\sfp \! \> diff --git a/input/mutopia/W.A.Mozart/mozart-hrn3-rondo.ly b/input/mutopia/W.A.Mozart/mozart-hrn3-rondo.ly index b9447a4d2f..e6db7e0634 100644 --- a/input/mutopia/W.A.Mozart/mozart-hrn3-rondo.ly +++ b/input/mutopia/W.A.Mozart/mozart-hrn3-rondo.ly @@ -48,21 +48,13 @@ rondo = \notes \relative c' R2.*7 \mark "A" c4.\p \grace { -<<<<<<< mozart-hrn3-rondo.ly - \override Stem #'stroke-style = #"grace" -======= \override Stem #'stroke-style = #"grace" ->>>>>>> 1.15 e16( \revert Stem #'stroke-style } d8[) c d] c4 r8 r4 r8 e4. \grace { -<<<<<<< mozart-hrn3-rondo.ly - \override Stem #'stroke-style = #"grace" -======= \override Stem #'stroke-style = #"grace" ->>>>>>> 1.15 g16( \revert Stem #'stroke-style } f8[) e f] @@ -180,11 +172,7 @@ rondo = \notes \relative c' << d2.(\trill { s2 \grace { -<<<<<<< mozart-hrn3-rondo.ly - \override Stem #'stroke-style = #"grace" -======= \override Stem #'stroke-style = #"grace" ->>>>>>> 1.15 c16[ d] \revert Stem #'stroke-style } } >> diff --git a/input/regression/rest-collision-beam.ly b/input/regression/rest-collision-beam.ly index 2a1fcf6e77..d2eb5696bb 100644 --- a/input/regression/rest-collision-beam.ly +++ b/input/regression/rest-collision-beam.ly @@ -1,25 +1,37 @@ - \header { - texidoc = "Rests under beams are only moved if necessary." - } \version "2.1.22" +fig = \notes \relative c' { + 8[ r r r ] r | +} + + \score { - \new Staff - \notes { - \stemUp - \transpose c c' { - c''8[ r8 c''8 c''8] - c8[ r8 c8 c8] - c8[ r8 r8 c'''8] - \stemDown - c8[ r8 c8 c8] - c''8[ r8 c''8 c''8] - c'8[ r8 r8 c'''8] - } - } - \paper { raggedright = ##t } + \notes \relative c' \new Staff { + \fig + \transpose c c, \fig + \new Voice { \stemUp \transpose c f \fig } + << + \\ + \transpose f c \fig + >> + + << + { \transpose c c' \fig } + \\ + {} + >> + + << \transpose c c' \fig \\ + \transpose f c \fig + >> + } + + \paper { + raggedright = ##t + } } + diff --git a/input/regression/rest-collision-default.ly b/input/regression/rest-collision-default.ly deleted file mode 100644 index d0aa5c4143..0000000000 --- a/input/regression/rest-collision-default.ly +++ /dev/null @@ -1,19 +0,0 @@ -\version "2.1.22" - -\header -{ -texidoc = "Rests in collisions sit opposite of the note if no direction is - specified for the voice containing the rest." -} - - - \paper { raggedright= ##t } - -\score{\notes\relative c'' - \context Staff << -\time 2/4 -\new Voice { - r4 } -\new Voice {\voiceTwo -b8 }>>} - diff --git a/input/regression/rest-polyphonic.ly b/input/regression/rest-polyphonic.ly index 55ebe73f8b..ae19a08bd8 100644 --- a/input/regression/rest-polyphonic.ly +++ b/input/regression/rest-polyphonic.ly @@ -14,5 +14,5 @@ staff-spaces. " << { r8 g''4 g8 r g4 g8 } \\ { d,4 r d r } >> } - + \paper { raggedright = ##t } } diff --git a/lily/column-x-positions.cc b/lily/column-x-positions.cc index 42e8a00498..c9a0c06e10 100644 --- a/lily/column-x-positions.cc +++ b/lily/column-x-positions.cc @@ -12,7 +12,7 @@ Column_x_positions::Column_x_positions () { - satisfies_constraints_b_ = false; + satisfies_constraints_ = true; force_ = 0; } diff --git a/lily/gourlay-breaking.cc b/lily/gourlay-breaking.cc index 8f7b0ec9f8..2a4f0f14ac 100644 --- a/lily/gourlay-breaking.cc +++ b/lily/gourlay-breaking.cc @@ -140,7 +140,7 @@ Gourlay_breaking::do_solve () const we couldn't satisfy the constraints, this won't get better if we add more columns, so we get on with the next one */ - if (!cp.satisfies_constraints_b_) + if (!cp.satisfies_constraints_) break ; } @@ -197,7 +197,7 @@ Gourlay_breaking::do_solve () const Column_x_positions cp (optimal_paths[final_breaks[i]].line_config_); lines.push (cp); - if(!cp.satisfies_constraints_b_) + if(!cp.satisfies_constraints_) warning ("Could not find line breaking that satisfies constraints."); } return lines; @@ -247,7 +247,7 @@ Gourlay_breaking::combine_demerits (Column_x_positions const &prev, Real demerit = abs (this_one.force_) + abs (prev.force_ - this_one.force_) + break_penalties; - if (!this_one.satisfies_constraints_b_) + if (!this_one.satisfies_constraints_) { /* If it doesn't satisfy constraints, we make this one diff --git a/lily/include/column-x-positions.hh b/lily/include/column-x-positions.hh index e5ae4f92bd..6fd40ad5fa 100644 --- a/lily/include/column-x-positions.hh +++ b/lily/include/column-x-positions.hh @@ -18,7 +18,7 @@ struct Column_x_positions Array config_; Real force_; - bool satisfies_constraints_b_; + bool satisfies_constraints_; Column_x_positions (); }; diff --git a/lily/include/note-column.hh b/lily/include/note-column.hh index b9d7d46770..1760eb3474 100644 --- a/lily/include/note-column.hh +++ b/lily/include/note-column.hh @@ -22,19 +22,13 @@ class Note_column { public: static int shift_compare (Grob *const &, Grob*const&); - - /** The relative position of the "voice" containing this - chord. Normally this would be the same as the stem direction, - - JUNKME. - */ - - static Grob * accidentals (Grob*me); static Direction dir (Grob*me); + static Grob * accidentals (Grob*me); static Slice head_positions_interval (Grob* me); static Direction static_dir (Grob*); static void translate_rests (Grob*me,int dy); - static Grob * first_head (Grob*me); + static Grob *first_head (Grob*me); + static Grob *get_rest (Grob*me); static void set_stem (Grob*me,Grob*); static void set_dotcol (Grob*me,Grob*); static void add_head (Grob*me,Grob*); diff --git a/lily/include/rest.hh b/lily/include/rest.hh index 88e9a74eed..b6f256af86 100644 --- a/lily/include/rest.hh +++ b/lily/include/rest.hh @@ -20,6 +20,7 @@ public: static String glyph_name (Grob*, int, String); static SCM brew_internal_stencil (SCM); DECLARE_SCHEME_CALLBACK (extent_callback, (SCM,SCM)); + DECLARE_SCHEME_CALLBACK (polyphonic_offset_callback, (SCM,SCM)); DECLARE_SCHEME_CALLBACK (print, (SCM )); }; #endif // REST_HH diff --git a/lily/include/simple-spacer.hh b/lily/include/simple-spacer.hh index 4395912c2f..6c2a16f5d8 100644 --- a/lily/include/simple-spacer.hh +++ b/lily/include/simple-spacer.hh @@ -18,7 +18,7 @@ struct Spring_description { Real ideal_; Real hooke_; - bool active_b_; + bool is_active_; Real block_force_; @@ -50,10 +50,10 @@ struct Simple_spacer Real range_stiffness (int, int) const; void add_rod (int l, int r, Real dist); Real range_ideal_len (int l, int r)const; - Real active_blocking_force ()const; + Real is_activelocking_force ()const; Real configuration_length ()const; void set_active_states (); - bool active_b () const; + bool is_active () const; }; #endif /* SIMPLE_SPACER_HH */ diff --git a/lily/note-column.cc b/lily/note-column.cc index d92a3b19a4..1d711642a3 100644 --- a/lily/note-column.cc +++ b/lily/note-column.cc @@ -18,6 +18,11 @@ #include "note-head.hh" #include "accidental-placement.hh" +/* + TODO: figure out if we can prune this class. This is just an + annoying layer between (rest)collision & (note-head + stem) + */ + bool Note_column::has_rests (Grob*me) { @@ -82,31 +87,48 @@ Note_column::set_stem (Grob*me,Grob * stem) Axis_group_interface::add_element (me, stem); } + +Grob* +Note_column::get_rest (Grob*me) +{ + return unsmob_grob (me->get_grob_property ("rest")); +} + void Note_column::add_head (Grob*me,Grob *h) { + bool both = false; if (Rest::has_interface (h)) { - me->set_grob_property ("rest", h->self_scm ()); + if (gh_pair_p (me->get_grob_property ("note-heads"))) + both = true; + else + me->set_grob_property ("rest", h->self_scm ()); } else if (Note_head::has_interface (h)) { + if (unsmob_grob (me->get_grob_property ("rest"))) + both = true; Pointer_group_interface::add_grob (me, ly_symbol2scm ("note-heads"),h); } - Axis_group_interface::add_element (me, h); + + if (both) + me->warning ("Can't have rests and note heads together on a stem."); + else + Axis_group_interface::add_element (me, h); } /** - translate the rest symbols vertically by amount DY_I, but only if + translate the rest symbols vertically by amount DY, but only if they have no staff-position set. */ void -Note_column::translate_rests (Grob*me,int dy_i) +Note_column::translate_rests (Grob*me, int dy) { Grob * r = unsmob_grob (me->get_grob_property ("rest")); if (r && !gh_number_p (r->get_grob_property ("staff-position"))) { - r->translate_axis (dy_i * Staff_symbol_referencer::staff_space (r)/2.0, Y_AXIS); + r->translate_axis (dy * Staff_symbol_referencer::staff_space (r)/2.0, Y_AXIS); } } diff --git a/lily/rest-collision-engraver.cc b/lily/rest-collision-engraver.cc index af3d0ecc89..893a781501 100644 --- a/lily/rest-collision-engraver.cc +++ b/lily/rest-collision-engraver.cc @@ -7,9 +7,8 @@ */ #include "warn.hh" -#include "rest-collision.hh" #include "engraver.hh" -#include "note-collision.hh" +#include "rest-collision.hh" #include "note-column.hh" class Rest_collision_engraver : public Engraver @@ -25,8 +24,6 @@ public: TRANSLATOR_DECLARATIONS(Rest_collision_engraver); }; - - Rest_collision_engraver::Rest_collision_engraver () { rest_collision_ =0; @@ -38,7 +35,9 @@ Rest_collision_engraver::process_acknowledged_grobs () { if (rest_collision_ || note_columns_.is_empty () - || !rest_count_) + || !rest_count_ + || (note_columns_.size () == rest_count_ + && rest_count_ < 2)) return; rest_collision_ = make_item ("RestCollision"); diff --git a/lily/rest-collision.cc b/lily/rest-collision.cc index e80e0d9cd7..a0f7e74491 100644 --- a/lily/rest-collision.cc +++ b/lily/rest-collision.cc @@ -18,6 +18,7 @@ #include "group-interface.hh" #include "staff-symbol-referencer.hh" #include "duration.hh" +#include "directional-element-interface.hh" MAKE_SCHEME_CALLBACK (Rest_collision,force_shift_callback,2); SCM @@ -39,6 +40,8 @@ Rest_collision::force_shift_callback (SCM element_smob, SCM axis) return gh_double2scm (0.0); } + + void Rest_collision::add_column (Grob*me,Grob *p) { @@ -49,7 +52,7 @@ Rest_collision::add_column (Grob*me,Grob *p) only add callback for the rests, since we don't move anything else. - (not?) + (not?) */ p->add_offset_callback (Rest_collision::force_shift_callback_proc, Y_AXIS); p->set_grob_property ("rest-collision", me->self_scm ()); @@ -77,7 +80,6 @@ head_characteristic (Grob * col) TODO: look at horizontal-shift to determine ordering between rests for more than two voices. - TODO: look at previous note to determine vertical position? */ SCM @@ -92,7 +94,16 @@ Rest_collision::do_shift (Grob *me) { Grob * e = unsmob_grob (ly_car (s)); if (unsmob_grob (e->get_grob_property ("rest"))) - rests.push (e); + { + /* + Ignore rests under beam. + */ + Grob* st = unsmob_grob (e->get_grob_property ("stem")); + if (st && unsmob_grob (st->get_grob_property ("beam"))) + continue; + + rests.push (e); + } else notes.push (e); } @@ -103,126 +114,105 @@ Rest_collision::do_shift (Grob *me) [todo] * decide not to print rest if too crowded? - - * ignore rests under beams. */ - // no rests to collide - if (!rests.size ()) + /* + no partners to collide with + */ + if (rests.size () + notes.size () < 2) return SCM_UNSPECIFIED; - // no partners to collide with - if (rests.size () + notes.size () < 2) - { - if (rests.size () == 1 - && Note_column::dir (rests[0])) - { - Note_column::translate_rests (rests[0], - 4 * Note_column::dir (rests[0])); - } - } - // meisjes met meisjes + + Real staff_space = Staff_symbol_referencer::staff_space (me); + /* + only rests + */ if (!notes.size ()) { - SCM characteristic = head_characteristic (rests[0]); - int i = 1; - for (; i < rests.size (); i++) - { - if (!gh_equal_p (head_characteristic (rests[i]), characteristic)) - break; - } /* - If all durations are the same, we'll check if there are more - rests than maximum-rest-count. - Otherwise (different durations), we'll try to display them all - (urg: all 3 of them, currently). + This is incomplete: in case of an uneven number of rests, the + center one should be centered on the staff. */ - int display_count; - SCM s = me->get_grob_property ("maximum-rest-count"); - if (i == rests.size () - && gh_number_p (s) && gh_scm2int (s) < rests.size ()) + Drul_array< Link_array > ordered_rests; + for (int i= 0; i < rests.size (); i++) { - display_count = gh_scm2int (s); - for (; i > display_count; i--) + Grob * r = Note_column::get_rest (rests[i]); + + Direction d = get_grob_direction (r); + if (d) { - Grob* r = unsmob_grob (rests[i-1]->get_grob_property ("rest")); - if (r) - { - Grob * d = unsmob_grob (r->get_grob_property ("dot")); - if (d) - d->suicide(); - r->suicide (); - } - rests[i-1]->suicide (); + ordered_rests[d].push (rests[i]); } + else + rests[d]->warning (_("rest direction not set. Cannot resolve collision.")); } - else - display_count = rests.size (); + + Direction d = LEFT; + do { + ordered_rests[d].sort (Note_column::shift_compare); + } while (flip (&d) != LEFT); - /* - Ugh. Should have minimum dist. + if (ordered_rests[UP].size () + ordered_rests[DOWN].size () < 2) + return SCM_UNSPECIFIED; - Ugh. What do we do if we have three different rests? - - */ - int dy = display_count > 2 ? 6 : 4; // FIXME Should get dims from table. - if (display_count > 1) - { - Direction d0 = Note_column::dir (rests[0]); - Direction d1 = Note_column::dir (rests[1]); + Grob *common = common_refpoint_of_array (ordered_rests[DOWN], me, Y_AXIS); + common = common_refpoint_of_array (ordered_rests[UP], common, Y_AXIS); - if (!d0 && !d1) - { - d0= UP; - d1 = DOWN; - } - else if (!d0) - d0 = - d1; - else if (!d1) - d1 = -d0; - - Note_column::translate_rests (rests[0],d0 *dy); - Note_column::translate_rests (rests[1], d1 *dy); + Real diff = + (ordered_rests[DOWN].top ()->extent (common, Y_AXIS)[UP] + - ordered_rests[UP].top ()->extent (common, Y_AXIS)[DOWN]) /staff_space; + + if (diff > 0) + { + int amount_down = (int) ceil (diff / 2); + diff -= amount_down; + Note_column::translate_rests (ordered_rests[DOWN].top (), + -2 * amount_down); + if (diff > 0) + Note_column::translate_rests (ordered_rests[UP].top (), + 2 * int (ceil (diff))); } + + do { + for (int i = ordered_rests[d].size () -1; i-- > 0;) + { + Real last_y = ordered_rests[d][i+1]->extent (common, Y_AXIS)[d]; + Real y = ordered_rests[d][i]->extent (common, Y_AXIS)[-d]; + + Real diff = d * ((last_y - y) /staff_space); + if (diff > 0) + Note_column::translate_rests (ordered_rests[d][i],d * (int) ceil (diff) * 2); + } + } while (flip (&d) != LEFT); } - // meisjes met jongetjes else { + /* + Rests and notes. + */ if (rests.size () > 1) { warning (_ ("too many colliding rests")); } Grob * rcol = rests[0]; + Grob *common = common_refpoint_of_array (notes, rcol, Y_AXIS); + Direction dir = Note_column::dir (rests[0]); - - if (!dir) - { - dir = - Note_column::dir (notes[0]); - } - Grob * r = unsmob_grob (rcol->get_grob_property ("rest")); - Interval restdim = r->extent (r, Y_AXIS); // ?? - + + Interval restdim = rcol->extent (common, Y_AXIS); if (restdim.is_empty ()) return SCM_UNSPECIFIED; - Real staff_space = Staff_symbol_referencer::staff_space (rcol); - Real minimum_dist = robust_scm2double (me->get_grob_property ("minimum-distance"), 1.0) * staff_space; - - Grob *common = common_refpoint_of_array (notes, rcol, Y_AXIS); - Interval notedim; for (int i = 0; i < notes.size (); i++) { notedim.unite (notes[i]->extent (common, Y_AXIS)); } - Interval inter (notedim); - inter.intersect (restdim); - Real dist = minimum_dist + dir * (notedim[dir] - restdim[-dir]) >? 0; @@ -239,7 +229,7 @@ Rest_collision::do_shift (Grob *me) // move by whole spaces inside the staff. if (discrete_dist < stafflines+1) discrete_dist = int (ceil (discrete_dist / 2.0)* 2.0); - + Note_column::translate_rests (rcol,dir * discrete_dist); } return SCM_UNSPECIFIED; diff --git a/lily/rest.cc b/lily/rest.cc index 0d01e41155..ffc32784b5 100644 --- a/lily/rest.cc +++ b/lily/rest.cc @@ -13,6 +13,7 @@ #include "dots.hh" #include "paper-score.hh" #include "staff-symbol-referencer.hh" +#include "directional-element-interface.hh" // -> offset callback MAKE_SCHEME_CALLBACK (Rest,after_line_breaking,1); @@ -159,7 +160,17 @@ Rest::extent_callback (SCM smob, SCM ax) return ly_interval2scm (unsmob_stencil (m)->extent (a)); } - +MAKE_SCHEME_CALLBACK (Rest,polyphonic_offset_callback,2); +SCM +Rest::polyphonic_offset_callback (SCM smob, SCM) +{ + Grob* me = unsmob_grob (smob); + Direction d = get_grob_direction (me); + Real off = 2* d ; + if(off) + off *= Staff_symbol_referencer::staff_space (me); + return gh_double2scm (off); +} ADD_INTERFACE (Rest,"rest-interface", "a rest", diff --git a/lily/simple-spacer.cc b/lily/simple-spacer.cc index 91aa56a2b6..ff044d676e 100644 --- a/lily/simple-spacer.cc +++ b/lily/simple-spacer.cc @@ -122,7 +122,7 @@ Simple_spacer::range_stiffness (int l, int r) const Real den =0.0; for (int i=l; i < r; i++) { - if (springs_[i].active_b_) + if (springs_[i].is_active_) den += 1 / springs_[i].hooke_; } @@ -130,11 +130,11 @@ Simple_spacer::range_stiffness (int l, int r) const } Real -Simple_spacer::active_blocking_force () const +Simple_spacer::is_activelocking_force () const { Real bf = - infinity_f; for (int i=0; i < springs_.size (); i++) - if (springs_[i].active_b_) + if (springs_[i].is_active_) { bf = bf >? springs_[i].block_force_; } @@ -152,10 +152,10 @@ Simple_spacer::set_active_states () { /* float comparison is safe, since force is only copied. */ for (int i=0 ; i = force_) { - springs_[i].active_b_ = false; + springs_[i].is_active_ = false; active_count_ --; } } @@ -171,7 +171,7 @@ Simple_spacer::configuration_length () const } bool -Simple_spacer::active_b () const +Simple_spacer::is_active () const { return active_count_; } @@ -179,9 +179,9 @@ Simple_spacer::active_b () const void Simple_spacer::my_solve_linelen () { - while (active_b ()) + while (is_active ()) { - force_ = active_blocking_force (); + force_ = is_activelocking_force (); Real conf = configuration_length (); if (conf < line_len_) @@ -198,9 +198,9 @@ Simple_spacer::my_solve_linelen () void Simple_spacer::my_solve_natural_len () { - while (active_b ()) + while (is_active ()) { - force_ = active_blocking_force () >? 0.0; + force_ = is_activelocking_force () >? 0.0; if (force_ < 1e-8) // ugh., break; @@ -264,7 +264,7 @@ Simple_spacer::add_columns (Link_array const &icols) if (isinf (desc.hooke_)) { - desc.active_b_ = false; + desc.is_active_ = false; springs_.push (desc); } else @@ -295,8 +295,6 @@ Simple_spacer::add_columns (Link_array const &icols) } } } - - } /* @@ -317,21 +315,17 @@ Simple_spacer::add_columns (Link_array const &icols) void Simple_spacer::solve (Column_x_positions *positions, bool ragged) { - /* - TODO: should support natural length on only the last line. - */ - ragged = ragged || (line_len_ < 0) ; if (ragged) my_solve_natural_len (); else my_solve_linelen (); positions->force_ = force_; + /* We used to have a penalty for compression, no matter what, but that fucked up wtk1-fugue2 (taking 3 full pages.) */ - positions->config_.push (indent_); for (int i=0; i 0) + if (ragged) { Real len = positions->config_.top (); - positions->force_ = (line_len_ - len) * active_springs_stiffness (); + if (line_len_ - len >= 0) + positions->force_ = ((line_len_ - len) * active_springs_stiffness ()); + else + { + positions->force_ = 0.0; + /* + Don't go past end-of-line in ragged right. + */ + positions->satisfies_constraints_ = false; + } } positions->cols_ = spaced_cols_; positions->loose_cols_ = loose_cols_; - positions->satisfies_constraints_b_ = (line_len_ < 0) || active_b (); + positions->satisfies_constraints_ = + positions->satisfies_constraints_ && is_active (); /* Check if breaking constraints are met. @@ -375,11 +379,8 @@ Simple_spacer::solve (Column_x_positions *positions, bool ragged) } - positions->satisfies_constraints_b_ = - positions->satisfies_constraints_b_ && break_satisfy; - - if (ragged && force_ < 0) - positions->satisfies_constraints_b_ = false; + positions->satisfies_constraints_ = + positions->satisfies_constraints_ && break_satisfy; } /****************************************************************/ @@ -388,7 +389,7 @@ Spring_description::Spring_description () { ideal_ =0.0; hooke_ =0.0; - active_b_ = true; + is_active_ = true; block_force_ = 0.0; } @@ -402,7 +403,7 @@ Spring_description::sane_b () const Real Spring_description::length (Real f) const { - if (!active_b_) + if (!is_active_) f = block_force_; return ideal_ + f / hooke_ ; } diff --git a/scm/define-grobs.scm b/scm/define-grobs.scm index 22c9c253fd..9c141f4d1b 100644 --- a/scm/define-grobs.scm +++ b/scm/define-grobs.scm @@ -769,7 +769,9 @@ (X-extent-callback . ,Rest::extent_callback) (Y-extent-callback . ,Rest::extent_callback) (print-function . ,Rest::print) - (Y-offset-callbacks . (,Staff_symbol_referencer::callback)) + (Y-offset-callbacks . (,Staff_symbol_referencer::callback + ,Rest::polyphonic_offset_callback + )) (minimum-distance . 0.25) (meta . ( (interfaces . (font-interface diff --git a/scm/music-functions.scm b/scm/music-functions.scm index aa7f5e9343..29194e3326 100644 --- a/scm/music-functions.scm +++ b/scm/music-functions.scm @@ -215,7 +215,7 @@ i.e. this is not an override" )) (define direction-polyphonic-grobs - '(Tie Slur Script TextScript Stem Dots DotColumn)) + '(Tie Rest Slur Script TextScript Stem Dots DotColumn)) (define-public (make-voice-props-set n) (make-sequential-music diff --git a/scripts/abc2ly.py b/scripts/abc2ly.py index bde1e8cfe5..df73f40793 100644 --- a/scripts/abc2ly.py +++ b/scripts/abc2ly.py @@ -151,10 +151,10 @@ def select_voice (name, rol): check_clef(value) elif keyword == "name": value = re.sub ('\\\\','\\\\\\\\', value) - voices_append ("\\property Staff.instrument = %s\n" % value ) + voices_append ("\\set Staff.instrument = %s\n" % value ) __main__.part_names = 1 elif keyword == "sname" or keyword == "snm": - voices_append ("\\property Staff.instr = %s\n" % value ) + voices_append ("\\set Staff.instr = %s\n" % value ) else: break @@ -183,7 +183,7 @@ def dump_default_bar (outf): """ Nowadays abc2ly outputs explicits barlines (?) """ - outf.write ("\n\\property Score.defaultBarType=\"empty\"\n") + outf.write ("\n\\set Score.defaultBarType=\"empty\"\n") def dump_slyrics (outf): @@ -605,12 +605,12 @@ def try_parse_header_line (ln, state): if a == 'C': if not state.common_time: state.common_time = 1 - voices_append ("\\property Staff.TimeSignature \\override #\'style = #'C\n") + voices_append ("\\override Staff.TimeSignature #\'style = #'C\n") a = '4/4' if a == 'C|': if not state.common_time: state.common_time = 1 - voices_append ("\\property Staff.TimeSignature \\override #\'style = #'C\n") + voices_append ("\\override Staff.TimeSignature #\'style = #'C\n") a = '2/2' if not length_specified: set_default_len_from_time_sig (a) diff --git a/scripts/etf2ly.py b/scripts/etf2ly.py index 34a1c9e018..307f16c449 100644 --- a/scripts/etf2ly.py +++ b/scripts/etf2ly.py @@ -559,7 +559,7 @@ class Staff: str = string.join (map (lambda x: '(volta %s)' % x, strs)) - e = e + ' \\property Score.repeatCommands = #\'(%s) ' % str + e = e + ' \\set Score.repeatCommands = #\'(%s) ' % str if g.force_break: e = e + ' \\break ' -- 2.39.2