Hi Paul,

Am 17.05.2013 09:45, schrieb Paul Malcolm:

excuse me, just a trivial question, but I cannot seem to find the answer.
I want to add the date variable to one element of text in my title.

I have this in the preamble

date = #(strftime "%d-%m-%Y" (localtime (current-time)))

What I want to do is somehow add/concatenate this to a text string
for the name of person doing the arranging, which appears in the
header block, i.e.

arranger = "Arr.  Maestro Smithington-Smythe"

How do I do this so I finally see

  Arr. Maestro Smithington-Smythe, 17/May/2013

?
to concatenate strings you can use
#(string-append "Arr. Maestro Smithington-Smythe" ", " (strftime "%d-%m-%Y" (localtime (current-time))) )

or
#(format "~A, ~A" arranger date)
(if arranger and date are variables with the desired strings)

To use this in a headerblock, you can use a construct like this:


\header {

arrangername = "Arr.  Maestro Smithington-Smythe"

arrangerdate = #(strftime "%d-%m-%Y" (localtime (current-time)))

arranger = #(string-append arrangername ", " arrangerdate)

}


HTH

Best, Jan-Peter

_______________________________________________
lilypond-user mailing list
[email protected]
https://lists.gnu.org/mailman/listinfo/lilypond-user

Reply via email to