[prev in list] [next in list] [prev in thread] [next in thread]
List: lilypond-user
Subject: Re: Is it possible to replace a number with variable inside a pair?
From: David Kastrup <dak () gnu ! org>
Date: 2018-07-26 8:28:40
Message-ID: 87y3dy9z9j.fsf () fencepost ! gnu ! org
[Download RAW message or body]
Jan-Peter Voigt <jp.voigt@gmx.de> writes:
> Hi Risto,
>
> you might go this way:
>
> lineThickness = 5
> \markup \override #`(thickness . ,lineThickness) \draw-hline
>
> That is semi-quote the pair with ` (instead of ') and then "unquote" the
> variable to retrieve the value with a comma (,)
Which is equivalent to
\markup \override #(cons 'thickness lineThickness) \draw-hline
Either will create a pair at "runtime" rather than directly in the
"Scheme reader" which does not access variables but rather creates
symbols when given an identifier.
--
David Kastrup
_______________________________________________
lilypond-user mailing list
lilypond-user@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-user
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic