Hello, Paul:

How do your inner definitions help this? Example?

Consider the 'A' section from my "Upside-Down Rag" (slightly simplified for this example), which is of the form abac:


rh = \notes \relative c'
{
e16 g,8 e'16 g,8 e'16 a,~
a4~ a16 <c e c'>( <b d b'>-.) <bf df bf'>
<a c a'> <f a f'> <g b g'> <a c a'>~ <a c a'> <d f d'> <b f' b>8
<c e c'>4~ <c e c'>8 fs16( f)
e16 g,8 e'16 g,8 e'16 g,~
g4~ g8 <a cs a'>16 <b! b'!>
<c fs c'>( <a a'>-.) <fs fs'> <d fs d'>~ <d fs d'> <e e'> <fs c' fs> <a a'>
<g b g'>4~ <g b g'>8 fs'16( f)
e16 g,8 e'16 g,8 e'16 a,~
a4~ a16 <c e c'>( <b d b'>-.) <bf df bf'>
<a c a'> <f a f'> <g b g'> <a c a'>~ <a c a'> <d f d'> <b f' b>8
<c e c'>4~ <c e c'>8 <e e'>16 <d d'>
<c c'> <e e'> <d d'> <c c'>~ <c c'> <e e'>( <d d'>-.) <e e'>
<c c'> <e e'> <d d'> <c c'>~ <c c'> <c e c'>( <b d b'>-.) <c e c'>
<a c a'> <c e c'> <b d b'> <a c a'>~ <a c a'> <d f d'> <b f' b>8
<c e c'>4~ <c e c'>8 fs16( f)
}


With an "inline definition", I could do this:

rh = \notes \relative c'
{
{
e16 g,8 e'16 g,8 e'16 a,~
a4~ a16 <c e c'>( <b d b'>-.) <bf df bf'>
<a c a'> <f a f'> <g b g'> <a c a'>~ <a c a'> <d f d'> <b f' b>8
<c e c'>4~ <c e c'>8
} == secOne
fs16( f) e16 g,8 e'16 g,8 e'16 g,~
g4~ g8 <a cs a'>16 <b! b'!>
<c fs c'>( <a a'>-.) <fs fs'> <d fs d'>~ <d fs d'> <e e'> <fs c' fs> <a a'>
<g b g'>4~ <g b g'>8 fs'16( f)
\secOne
<e e'>16 <d d'> <c c'> <e e'> <d d'> <c c'>~ <c c'> <e e'>( <d d'>-.) <e e'>
<c c'> <e e'> <d d'> <c c'>~ <c c'> <c e c'>( <b d b'>-.) <c e c'>
<a c a'> <c e c'> <b d b'> <a c a'>~ <a c a'> <d f d'> <b f' b>8
<c e c'>4~ <c e c'>8 fs16( f)
}


Currently, it would have to be:

secOne = \notes
{
    e16 g,8 e'16 g,8 e'16 a,~
    a4~ a16  <c e c'>( <b d b'>-.) <bf df bf'>
    <a c a'> <f a f'> <g b g'> <a c a'>~ <a c a'> <d f d'> <b f' b>8
    <c e c'>4~ <c e c'>8
}

rh = \notes \relative c'
{
\secOne
fs16( f) e16 g,8 e'16 g,8 e'16 g,~
g4~ g8 <a cs a'>16 <b! b'!>
<c fs c'>( <a a'>-.) <fs fs'> <d fs d'>~ <d fs d'> <e e'> <fs c' fs> <a a'>
<g b g'>4~ <g b g'>8 fs'16( f)
\secOne
<e e'>16 <d d'> <c c'> <e e'> <d d'> <c c'>~ <c c'> <e e'>( <d d'>-.) <e e'>
<c c'> <e e'> <d d'> <c c'>~ <c c'> <c e c'>( <b d b'>-.) <c e c'>
<a c a'> <c e c'> <b d b'> <a c a'>~ <a c a'> <d f d'> <b f' b>8
<c e c'>4~ <c e c'>8 fs16( f)
}


In this small an example, it may not seem like that big a deal, but with a larger set of variables (including tweaks, etc.), having all the definitions up in a lump above the main note block -- and therefore, by definition, *out of chronological order* -- might not be the best organization.

Hope this makes it clearer what I mean*.
Kieren.

* not that it means it's any more correct or desirable! ;-)



_______________________________________________
Lilypond-user mailing list
[EMAIL PROTECTED]
http://mail.gnu.org/mailman/listinfo/lilypond-user

Reply via email to