From 6a3217394fa31a9f6c79df9a6e1f7cf73e37fb54 Mon Sep 17 00:00:00 2001 From: David Kastrup Date: Sun, 25 Sep 2011 09:17:36 +0200 Subject: [PATCH] Change the argument order of \pushToTag and \appendToTag to something making better sense --- Documentation/notation/input.itely | 14 ++++++++------ input/regression/push-to-tag.ly | 9 +++++++-- ly/music-functions-init.ly | 4 ++-- 3 files changed, 17 insertions(+), 10 deletions(-) diff --git a/Documentation/notation/input.itely b/Documentation/notation/input.itely index e418d96fb4..ed13816045 100644 --- a/Documentation/notation/input.itely +++ b/Documentation/notation/input.itely @@ -1545,15 +1545,17 @@ safe bets: test = { \tag #'here { \tag #'here <> } } { - \pushToTag #'here \pushToTag #'here - \pushToTag #'here \test g' e' c' - \appendToTag #'here \appendToTag #'here - \appendToTag #'here \test g' e' c' + \pushToTag #'here c' + \pushToTag #'here e' + \pushToTag #'here g' \test + \appendToTag #'here c' + \appendToTag #'here e' + \appendToTag #'here g' \test } @end lilypond -Both commands get a tag, the tagged expression, and finally the material -you want to splice in at every given tag. The commands make sure to +Both commands get a tag, the material to splice in at every occurence of +the tag, and the tagged expression. The commands make sure to copy everything that they change so that the original @code{\test} retains its meaning. diff --git a/input/regression/push-to-tag.ly b/input/regression/push-to-tag.ly index 2cb4d43f3f..610f11c5d8 100644 --- a/input/regression/push-to-tag.ly +++ b/input/regression/push-to-tag.ly @@ -16,6 +16,11 @@ equivalent of test = { \tag #'here { \tag #'here <> }} { - \pushToTag #'here \pushToTag #'here \pushToTag #'here \test g' e' c' - \appendToTag #'here \appendToTag #'here \appendToTag #'here \test g' e' c' + \pushToTag #'here c' + \pushToTag #'here e' + \pushToTag #'here g' \test + \appendToTag #'here c' + \appendToTag #'here e' + \appendToTag #'here g' \test } + diff --git a/ly/music-functions-init.ly b/ly/music-functions-init.ly index 7d80c6b511..23043f2565 100644 --- a/ly/music-functions-init.ly +++ b/ly/music-functions-init.ly @@ -86,7 +86,7 @@ markups), or inside a score.") 'break-permission 'allow)))) appendToTag = -#(define-music-function (parser location tag music more) +#(define-music-function (parser location tag more music) (symbol? ly:music? ly:music?) (_i "Append @var{more} to the @code{elements} of all music expressions in @var{music} that are tagged with @var{tag}.") @@ -846,7 +846,7 @@ print @var{secondary-note} as a stemless note head in parentheses.") main-note)) pushToTag = -#(define-music-function (parser location tag music more) +#(define-music-function (parser location tag more music) (symbol? ly:music? ly:music?) (_i "Add @var{more} to the front of @code{elements} of all music expressions in @var{music} that are tagged with @var{tag}.") -- 2.39.5