[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: DrumStaff vs Staff for instrument name
From: |
Caagr98 |
Subject: |
Re: DrumStaff vs Staff for instrument name |
Date: |
Wed, 13 Dec 2017 10:13:31 +0100 |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.5.0 |
In `engraver-init.ly` (line 111 on my version), there is a line saying `\alias
"Staff"`. That line makes the DrumStaff context listen to `\set Staff.*` as
well as `\set DrumStaff.*`. (DrumVoice is similarly aliased to Voice.)
They're both equal, so I'd recommend using `Staff.*` for consistency. If there
happen to be some properties that only exist in DrumStaff/Voice (such as
drumStyleTable), I'd use them explicitly, but generally, I prefer the plain
versions.
On 12/13/17 09:55, Menu Jacques wrote:
> Hello folks,
>
> In the example below, using Staff.instrumentName makes no difference compared
> to DrumStaff.instrumentName.
>
> Are both equivalent, or should DrumStaff.instrumentName clearly be preferred?
>
> Thanks for your help!
>
> JM
>
> —
>
> \version "2.19"
>
>
> P_PTwo_Staff_One_Voice_One = \relative {
> \key c \major
> \numericTimeSignature \time 4/4
> \clef "percussion"
> \once \override NoteHead #'style = #'cross 2. \once \override NoteHead
> #'style = #'cross 4 | % 2
> \once \override NoteHead #'style = #'cross 1 \bar "|." |
> }
>
> \score {
> <<
> \new DrumStaff = "P_PTwo_Staff_One" <<
> \set Staff.instrumentName = "Cymbals"
> \context DrumVoice = "P_PTwo_Staff_One_Voice_One" <<
> \P_PTwo_Staff_One_Voice_One
> >>
> >>
>
> \new DrumStaff = "P_PTwo_Staff_One" <<
> \set DrumStaff.instrumentName = "Cymbals"
> \context DrumVoice = "P_PTwo_Staff_One_Voice_One" <<
> \P_PTwo_Staff_One_Voice_One
> >>
> >>
> >>
>
> \layout {
> }
>
> }
>
>
>
> _______________________________________________
> lilypond-user mailing list
> address@hidden
> https://lists.gnu.org/mailman/listinfo/lilypond-user
>