lilypond-devel
[Top][All Lists]
Advanced

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

Re: Allow music with layout instructions in output definitions. (issue 5


From: Janek Warchoł
Subject: Re: Allow music with layout instructions in output definitions. (issue 5701049)
Date: Tue, 28 Feb 2012 08:44:56 +0100

On Tue, Feb 28, 2012 at 2:36 AM,  <address@hidden> wrote:
>> \score {
>>   \new Staff { b b }
>>   \layout { \override NoteHead #'color = #red }
>> }
>
> Totally elusive bug that also afflicted \settingsFrom.  Fixed

i confirm that it works for me.  Thanks!

>> I even hoped that something like this will be possible:
>> \score { <<
>>     \new Voice { b b }
>>     \new Voice = "aa" { b b }
>>   >>
>>   \layout { \override aa.NoteHead #'color = #red }
>> }
>
> It is nonsense since aa is not the type but the id of a context and
> can't be meddled with in a layout definition.

ok...
Out of curiosity, would this be possible to add in a reasonable way or
is it totally wrong?  From a users' perspective, it would be great to
have such overrides in \layout, because then i'd have 3 separate and
independent areas of my file:
- music in variables or \include files
- style decisions in \layout block.
- score structure that doesn't contain any of the above and can be
freely changed.

> Try \new Voice = "aa" \with { \settingsFrom \override NoteHead #'color
> #red } { ...
> instead.

It doesn't work:

\score {
    \new Voice \with { \settingsFrom \override NoteHead #'color = #red } { b b }
  }

produces

../bah.ly:2:37: error: syntax error, unexpected \override
    \new Voice \with { \settingsFrom
                                     \override NoteHead #'color = #red } { b b }

If i add a pair of curly braces, i.e.
\score {
  \new Voice \with { \settingsFrom { \override NoteHead #'color = #red
} } { b b }
  }

then it compiles, but the override isn't applied.

HTH,
Janek



reply via email to

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