lilypond-user
[Top][All Lists]
Advanced

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

Re: Score layout in a separate file


From: Siska Ádám
Subject: Re: Score layout in a separate file
Date: Tue, 3 Apr 2012 15:59:06 +0200

On 2012.04.03., at 15:46, Thomas Morley wrote:

> Am 3. April 2012 15:17 schrieb Siska Ádám <address@hidden>:
>> Dear List,
>> 
>> 
>> is there a way to put the layout block for a score in a variable that lives 
>> in a separate file? Unfortunately the following won't compile:
>> 
>> %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
>> 
>> myMusic = \relative d' {
>>  d4 d d d
>> }
>> 
>> myLayout = \layout {
>>   \context {
>>    \Staff
>>    \remove "Clef_engraver"
>>  }
>> }
>> 
>> \score {
>>  \myMusic
>>  \myLayout
>> }
>> 
>> %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
>> 
>> I tried several other ways to export the content of the layout block, but 
>> none of them succeeded. I'm writing parts of an orchestral piece and I'd 
>> like to include the layout definition for these scores in a separate file.
>> 
>> 
>> Thanks for any help,
>> Ádám
> 
> Hi,
> 
> try:
> 
> \layout { \myLayout }
> 
> Cheers,
>  Harm

Hi,


thanks a lot, this works! Out of curiosity, could you or somebody on the list 
explain to me why this works? It is a bit weird to me, as I also tried to have 
the variable without the \layout in it (so that it was myLayout = \context { 
etc. } and then I used \layout { \myLayout } ), but that didn't work either. 
I'm just surprised that this solution (which reads at the end \layout { \layout 
{ etc. } } ) will compile...


Thank you,
Ádám




reply via email to

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