X-Git-Url: https://git.donarmstrong.com/?a=blobdiff_plain;f=input%2Fregression%2Fapply-context.ly;h=712f4ec2373659d5279e2784035d5a55612ca4b5;hb=2fecabf3a5cb332c78b58b02f78c7c64d5c89c19;hp=db059b66c10fe999e75b0ff42fe7187c95ad845b;hpb=955f829883aa125b2b633b1e71f6256da5b773fa;p=lilypond.git diff --git a/input/regression/apply-context.ly b/input/regression/apply-context.ly index db059b66c1..712f4ec237 100644 --- a/input/regression/apply-context.ly +++ b/input/regression/apply-context.ly @@ -1,10 +1,10 @@ -#(ly:set-option 'old-relative) -\version "1.9.0" + +\version "2.16.0" \header { -texidoc = "With \\applycontext, \\properties can be modified +texidoc = "With @code{\\applyContext}, @code{\\properties} can be modified procedurally. Applications include: checking bar numbers, smart octavation. @@ -14,17 +14,17 @@ This example prints a bar-number during processing on stdout. } - \paper { raggedright= ##t } +\layout { ragged-right= ##t } -\score { \notes \relative c'' { - c1 c1 +\relative c'' { + c1 c1 - %% todo: should put something interesting in the .tex output. - - \applycontext - #(lambda (tr) - (format #t "\nWe were called in barnumber ~a.\n" - (ly:get-context-property tr 'currentBarNumber))) - c1 c1 -}} + %% todo: should put something interesting in the .tex output. + + \applyContext + #(lambda (tr) + (ly:progress "\nWe were called in bar number ~a.\n" + (ly:context-property tr 'currentBarNumber))) + c1 c1 +}