lilypond-user
[Top][All Lists]
Advanced

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

RE: instrumentName in StaffGroup


From: James Lowe
Subject: RE: instrumentName in StaffGroup
Date: Fri, 14 Jan 2011 12:28:33 +0000

Hello,

 

From: lilypond-user-bounces+address@hidden [mailto:lilypond-user-bounces+address@hidden On Behalf Of Patrick Schmidt
Sent: 14 January 2011 12:24
To: Federico Bruni
Cc: James Lowe; address@hidden
Subject: Re: instrumentName in StaffGroup

 

 

Am 14.01.2011 um 13:09 schrieb Federico Bruni:



2011/1/14 James Lowe <address@hidden>

 

http://lilypond.org/doc/v2.13/Documentation/notation/displaying-staves#index-staff-group

 

Scroll down you will see

 

'The PianoStaff is identical to a GrandStaff, except that it supports printing the instrument name directly. For details, see Instrument names. '

 

Is this what you needed?

 

 



Thanks, James.
If you are suggesting to use PianoStaff instead of StaffGroup, unfortunately
it doesn't work because it seems that PianoStaff can group only Staff contexts.
If you include TabStaff an extra (unwanted) Staff group is created. 

You need to set the instrumentName for the StaffGroup. See below.

Try:

\new PianoStaff <<
 \set PianoStaff.instrumentName = #"Guitar 1 "
 \new Staff { R1 }
 \new TabStaff { R1 }
 >>


And that's fine: I don't want to use PianoStaff for a guitar :-)

Many flamenco editions do use a PianoStaff or at least s SystemStartBrace. See below.


So who uses PianoStaff knows how to center the instrument name.
Who uses StaffGroup doesn't know.

 

How about something like this:

 

\new StaffGroup = "Guitar" 

      \with {\consists "Instrument_name_engraver"} 

      <<

      \set StaffGroup.instrumentName = #"Guitar" 

      \set StaffGroup.systemStartDelimiter = #'SystemStartBrace

      \new Staff = "guitar" <<

        \new Voice = "global" {

          \clef "treble_8"

          \global 

        }

        \new Voice = "GuitarVoiceOne" {

          \voiceOne

          \guitarVoiceOne

        }

        \new Voice = "GuitarVoiceTwo" {

          \voiceTwo

          \guitarVoiceTwo

        }

      >>

      \new TabStaff = "GuitarTablature" 

        \with { stringTunings = #'( 3 -2 -5 -11 -16 -21 ) } <<

        \new TabVoice = "global" {

          \global

        }

        \new TabVoice = "TabGuitarVoiceOne" {

          \tabFullNotation

          \voiceOne

          \guitarVoiceOne

        }

        \new TabVoice = "TabGuitarVoiceTwo" {

          \tabFullNotation

          \voiceTwo

          \guitarVoiceTwo

        }

      >>

    >> 

 

HTH

patrick



I think that the page where adding such information is this one:

http://lilypond.org/doc/v2.13/Documentation/notation/writing-parts#instrument-names


[James Lowe]  Could you give me some text you'd like to add as I am not following what you think should be included exactly, I can prepare a patch if necessary for the Notation Reference.

However if you want to include this example (or one like it) then this has to be added as a full snippet because it is effectively using 'tweaks' which are only included as snippets.

This seems too 'advanced' for the Learning Manual though.

Thanks

 

James


reply via email to

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