bug-lilypond
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Enhancement: automatically translate tagline


From: Simon Albrecht
Subject: Enhancement: automatically translate tagline
Date: Sun, 15 Mar 2015 17:18:28 +0100
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:31.0) Gecko/20100101 Thunderbird/31.5.0

Hello,

in my stylesheets, I usually include

germanTagline = \markup {
  \italic
  \pad-to-box #'(0 . 0) #'(0 . 3)
  {
    \with-url #"http://lilypond.org/";
    \line {
      #(format #f "Noten gesetzt mit LilyPond ~a ~a www.lilypond.org"
         (lilypond-version)
         (ly:wide-char->utf-8 #x2013) ;;2013 = en dash.
         )
    }
  }
}

and write

\header {
  tagline = \germanTagline
}

in the score.

Wouldn’t it be possible to do this automatically on the grounds of the \language command?

As another approach one might provide a function which, in \header {}, allows to write

\Tagline "deutsch" or
\Tagline "de" or similar

and thus easily choose a preset text for the desired language. I attached a draft of this, which I couldn’t get to work, unfortunately, since \displayScheme can’t handle \header blocks. I think it gives an idea, nevertheless.

What do you think?

Yours, Simon

Attachment: tagline-auto-translate.ly
Description: Text Data

Attachment: tagline.ly
Description: Text Data


reply via email to

[Prev in Thread] Current Thread [Next in Thread]