lilypond-user
[Top][All Lists]
Advanced

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

Re: Abbreviations


From: Urs Liska
Subject: Re: Abbreviations
Date: Sat, 04 Apr 2015 09:33:12 +0200
User-agent: Mozilla/5.0 (X11; Linux i686; rv:31.0) Gecko/20100101 Thunderbird/31.6.0



Am 03.04.2015 um 20:28 schrieb Mattes:
Am Freitag, 03. April 2015 20:15 CEST, Urs Liska <address@hidden> schrieb:

Am 03.04.2015 um 19:45 schrieb Kevin Barry:
On Fri, Apr 3, 2015 at 2:23 PM, Urs Liska <address@hidden
<mailto:address@hidden>> wrote:

     I'll note that for explaining in a blog post because it seems like
     a good example for demonstrating the relation between Scheme and
     LilyPond variables and the role of symbols.

     Maybe it fits into a post I've just started to plan (explaining
     what "#(define-music-function" actually means).


I would be very interested to read it. I have figured out over time
what kind of things tend to work and which things don't (when it comes
to variables and substitution) but I don't always understand why, for
example `t = \tuplet' doesn't work, but `#(define t tuplet)' does.
Well, think of it like this (slightly oversimplified):

  'tuplet' is a lilypond function, '\' will _call_ this function.
Let's quickly check that:

   guile> tuplet
     #<Music function #<procedure #f (parser location ratio tuplet-span music)>>

If you do '#(define t tuplet)'  't' will have the same value as 'tuplet':

  guile> (define t tuplet)
  guile> t
    #<Music function #<procedure #f (parser location ratio tuplet-span music)>>

If you write:

  t = \tuplet

't' would have the value of calling 'tuplet' .

  HTH RalfD

I've started writing the post today, and it may well be that it fits in.
But I'll have to figure out if I've understood it fully myself (or if I
manage to do so during the process of writing ...).
If it doesn't fit it would also be a good topic for an individual post.
Nothing bad with having some shorter posts in between ...

Best
Urs

Along that line I noticed that

t = #tuplet

works too.

Urs



reply via email to

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