lilypond-user
[Top][All Lists]
Advanced

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

Re: string variable for markup


From: Mark Knoop
Subject: Re: string variable for markup
Date: Mon, 30 Mar 2015 19:56:49 +0100

At 14:39 on 30 Mar 2015, Stephen MacNeil wrote:
>how would i get the input string to attach to a markup?
>
>eg
>
>\version "2.18.2"
>
>acdy =
>
>\markup \pad-markup #.5 \halign #-1.3
>
>{ \combine
>
>\draw-line #'($str . .5) \draw-line #'($str . -.5)
>
> }
>
>The idea is to be able to assign  a length $str

Looks like you want a number, not a string. Try the following. When you
use the variable you have to quasiquote the pair, thus the syntax
changes slightly. Note the backtick and comma.

\version "2.18.2"
#(define str 5)

\markup 
  \pad-markup #.5 \halign #-1.3 
  \combine
    \draw-line #`(,str . 0.5) 
    \draw-line #`(,str . -0.5)


-- 
Mark Knoop



reply via email to

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