lilypond-user
[Top][All Lists]
Advanced

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

Re: Creating markup macros


From: Paul Scott
Subject: Re: Creating markup macros
Date: Sat, 27 Nov 2004 02:46:35 -0700
User-agent: Mozilla/5.0 (X11; U; Linux i586; en-US; rv:1.7.3) Gecko/20041007 Debian/1.7.3-5

Nicolas Sceaux wrote:

Paul Scott <address@hidden> writes:

#(def-markup-command (restOne layout props) ()
 (interpret-markup layout props (markup #:number "1")))

rOne = { R1^\markup \restOne }

\score{ \rOne }


Thank you very much.   Now can you give me a hint as to a good way to
combine those two definitions so a the second definition of rOne isn't
necessary?  This is because I want to make rOne eventually generate
the correct one measure rest for any time signature.

AFAICT, it will not be possible to have \rOne automagically generate a
one measure rest for any time signature, as the current time signature
is not known at the time the one measure rest music expression will be
generated (a time signature indication is just another music
expression). You will have to give \rOne a duration parameter, but then
using directly R1^\one or R1*3/4^\one will be cleaner (more readable)
Ok, that looks pretty simple but I'm not quite sure yet how to combine my two definitions so I won't have to type '\markup' each time. (see below).

Even so I would like to understand the scheme code. I have been searching through the scm directory trying to make sense of all of this. In scm/translation-functions.scm I found references to numerator and denominator which are listed as properties in the manual. 1. Is that code actually referring to the same properties listed in the manual?

2. In that same file there is a reference to 'make-bold-markup' but I can't find it's definition anywhere. I thought that might help me discover how to define 'one' so I can do R1*3/4^\one as you have suggested.

Can you comment on either of these two points so I can do more of this on my own?

I only yesterday discovered that you had used the new version of the code you wrote (for me?) some time ago as an example of setting properties. That helped me generate a newer version of many property shortcuts I have that are based on the original help you gave me.

Thank you very much for that!

Paul





reply via email to

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