Next: Quoting other voices, Previous: Metronome marks, Up: Writing parts
Instrument names can be printed on the left side of staves for the
Staff
and PianoStaff
contexts. The value of
instrumentName
is used for the first staff, and the value
of shortInstrumentName
is used for all succeeding staves.
\set Staff.instrumentName = "Violin " \set Staff.shortInstrumentName = "Vln " c4.. g'16 c4.. g'16 \break c1
Markup mode can be used to create more complicated instrument names:
\set Staff.instrumentName = \markup { \column { "Clarinetti" \line { "in B" \smaller \flat } } } c4 c,16 d e f g2
When two or more staff contexts are grouped together, the
instrument names and short instrument names are centered by
default. To center multi-line instrument names,
\center-column
must be used:
<< \new Staff { \set Staff.instrumentName = "Flute" f2 g4 f } \new Staff { \set Staff.instrumentName = \markup \center-column { Clarinetti \line { "in B" \smaller \flat } } c4 b c2 } >>
However, if the instrument names are longer, the instrument names
in a staff group may not be centered unless the indent
and
short-indent
settings are increased. The indent
and
short-indent
settings are modified in the \layout
block and specify the level of indentation for the first system
and all succeeding systems, respectively.
\layout { indent = 2.5\cm short-indent = 1.5\cm } \relative c'' << \new Staff { \set Staff.instrumentName = "Flute" \set Staff.shortInstrumentName = "Fl." f2 g4 f \break g4 f g2 } \new Staff { \set Staff.instrumentName = "Clarinet" \set Staff.shortInstrumentName = "Clar." c,4 b c2 \break c2 b4 c } >>
To add instrument names to other contexts (such as
GrandStaff
, ChoirStaff
, or StaffGroup
),
Instrument_name_engraver
must be added to that context.
For details, see Modifying context plug-ins.
Instrument names may be changed in the middle of a piece:
\set Staff.instrumentName = "First" \set Staff.shortInstrumentName = "one" c1 c c c \break c1 c c c \break \set Staff.instrumentName = "Second" \set Staff.shortInstrumentName = "two" c1 c c c \break c1 c c c \break
Notation Reference: Modifying context plug-ins.
Snippets: Staff notation.
Internals Reference: InstrumentName, PianoStaff, Staff.
Diese Seite ist für LilyPond-2.11.58 (Entwicklungszweig).
Fehler bitte an http://post.gmane.org/post.php?group=gmane.comp.gnu.lilypond.bugs melden.
Ihre Vorschläge für die Dokumentation sind willkommen.