> Have you tried looking into the "Extending LilyPond" manual?
> 
> <URL:http://lilypond.org/doc/v2.16/Documentation/extending/markup-functions>

I did not reach it, because I did not understand the sections 2.1 and
2.2 and then I gave up. Examples would help me a lot in these sections.
I played around, but I could not figure out how functions are defined
and how scheme works. My test is below, just to show on which basic
level I am stuck.

\version "2.17.9"

function = % does not work
#(define-scheme-function
  (parser location text)
  (markup?)
  \markup{ \with-url #"http" #text} )

\function "Hallo"

Section 2.5.3 finally has an example and using that, I could finally
write the following function. But I only understand the part in #{ #}.
The words "layout props" and the "interpret-markup" are still cryptic to
me. Is there a documentation where this is described for noobs like me?

#(define-markup-command (myfunction layout props text) (markup?)
  "Draw a double box around text."
  (interpret-markup layout props
    #{\markup \with-url #"http" { #text }#}))

How can I combine two strings? The #"http" and the #text in this example?
How can I change a string to lower case?

Cheers,
Joram

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

Reply via email to