On 19.01.2016 22:13, k...@aspodata.se wrote:
David Kastrup:
k...@aspodata.se writes:
David Kastrup:
k...@aspodata.se writes:
...
BTW, does someone know why add-text-replacements in attached file
doesn't work ?
  I got the syntax from:
http://www.gnu.org/software/guile/manual/html_node/String-Syntax.html#String-Syntax
That's the Guile-2.0 manual.  LilyPond uses 1.8 at the moment.
Hmm, so basically it can't be done.
Nonsense.  You just need to use octal escapes for the actual UTF-8 byte
sequences.  And you'll probably need to revisit that input once
Guile-2.0 actually gets used: I don't think there is an obvious
"portable" way to do it.
So, if neither of the ;-commented out lines below work, what do I do?

Well, the method used in ‘ly/text-replacements.ly’ (in the LilyPond source) is as simple as that:

\version "2.19.35"
\paper {
  #(include-special-characters)
  #(add-text-replacements!
    '(
       ("&:a;" . "ä")
       ))
}
\markup "&:a;"

Now, I can’t recall any more if the rationale behind this was to use pure ASCII input; if you’re not bound to that, then it’s solved. And David: The character map application gives me ‘\303\244’ as octal escape for ‘ä’, and I found that one can use them in C, but not how to use them in Guile (1.8). Can one?

Best, Simon

_______________________________________________
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user

Reply via email to