]> git.donarmstrong.com Git - lilypond.git/commitdiff
Remove documentation for \instrumentSwitch
authorKeith OHara <k-ohara5a5a@oco.net>
Sun, 31 Aug 2014 06:44:48 +0000 (23:44 -0700)
committerKeith OHara <k-ohara5a5a@oco.net>
Sun, 18 Jan 2015 05:22:54 +0000 (21:22 -0800)
in favor of \set to set properties, and Textscripts for markup

Documentation/notation/staff.itely
Documentation/notation/vocal.itely

index d2bb608d3208c8c0b690e05ac9bd029e7eb86bdc..bb59664769fd0a5e1b406e71f8016482eb4f521e 100644 (file)
@@ -963,67 +963,49 @@ that context.  For details, see @ref{Modifying context plug-ins}.
 @cindex instrument names, changing
 @cindex changing instrument names
 
-The @code{shortInstrumentName} may be changed in the middle of a piece.
+The @code{shortInstrumentName} may be changed in the middle of a piece,
+along with other settings as needed for the new instrument.
 However, only the first instance of @code{instrumentName} will be
 printed and subsequent changes will be ignored:
 
-@lilypond[verbatim,quote,ragged-right,relative=1]
-\new Staff \with {
-  instrumentName = #"Flute"
-  shortInstrumentName = #"Flt."
-}
-{
-  c1 c c c \break
-  c1 c c c \break
-  \set Staff.instrumentName = #"Clarinet"
-  \set Staff.shortInstrumentName = #"Clt."
-  c1 c c c \break
-  c1 c c c \break
+@lilypond[verbatim,quote,ragged-right]
+prepPiccolo = <>^\markup \italic { muta in Piccolo }
+
+setPiccolo = {
+  \set Staff.instrumentName = #"Piccolo"
+  \set Staff.shortInstrumentName = #"Picc."
+  \set Staff.midiInstrument = #"piccolo"
+  <>^\markup \bold { Piccolo }
+  \transposition c''
 }
-@end lilypond
-
-@cindex instrument switch
-@cindex switching instruments
 
-@funindex \addInstrumentDefinition
-@funindex addInstrumentDefinition
-@funindex \instrumentSwitch
-@funindex instrumentSwitch
+prepFlute = <>^\markup \italic { muta in Flauto }
 
-If an instrument @emph{switch} is needed,
-@code{\addInstrumentDefinition} may be used in combination with
-@code{\instrumentSwitch} to create a detailed list of the
-necessary changes for the switch.  The
-@code{\addInstrumentDefinition} command has two arguments: an
-identifying string, and an association list of context properties
-and values to be used for the instrument.  It must be placed in
-the toplevel scope.  @code{\instrumentSwitch} is used in the music
-expression to declare the instrument switch:
-
-@lilypond[verbatim,quote,ragged-right]
-\addInstrumentDefinition #"contrabassoon"
-  #`((instrumentTransposition . ,(ly:make-pitch -1 0 0))
-     (shortInstrumentName . "Cbsn.")
-     (clefGlyph . "clefs.F")
-     (middleCPosition . 6)
-     (clefPosition . 2)
-     (instrumentCueName . ,(make-bold-markup "cbsn."))
-     (midiInstrument . "bassoon"))
+setFlute = {
+  \set Staff.instrumentName = #"Flute"
+  \set Staff.shortInstrumentName = #"Flt."
+  \set Staff.midiInstrument = #"flute"
+  <>^\markup \bold { Flute }
+  \transposition c'
+}
 
 \new Staff \with {
-  instrumentName = #"Bassoon"
+  instrumentName = #"Flute"
+  shortInstrumentName = #"Flt."
+  midiInstrument = #"flute"
 }
-\relative c' {
-  \clef tenor
-  \compressFullBarRests
-  c2 g'
-  R1*16
-  \instrumentSwitch "contrabassoon"
-  c,,2 g \break
-  c,1 ~ | 1
+\relative c'' {
+  g1 g g g \break
+  g1 g \prepPiccolo R R \break
+  \setPiccolo
+  g1 g g g \break
+  g1 g \prepFlute R R \break
+  \setFlute
+  g1 g g g
 }
 @end lilypond
 
+
 @seealso
 Notation Reference:
 @ref{paper variables for shifts and indents,,@code{@bs{}paper} variables for shifts and indents},
@@ -1300,7 +1282,7 @@ fluteNotes = \relative c'' {
 
 oboeNotes = \relative c'' {
   R1
-  \new CueVoice { \set instrumentCueName = "flute" }
+  <>^\markup \tiny { flute }
   \cueDuring #"flute" #UP { R1 }
   g2 c,
 }
@@ -1343,11 +1325,8 @@ oboeNotes = \relative c'' {
 }
 @end lilypond
 
-The name of the instrument playing the cue can be printed by setting
-the @code{instrumentCueName} property in a temporary @code{CueVoice}
-context.  The placement and style of the @code{instrumentCueName} is
-controlled by the @code{InstrumentSwitch} object, see
-@ref{Instrument names}.  If the cue notes require a change in clef,
+Markup can be used to show the name of the quoted instrument.
+If the cue notes require a change in clef,
 this can be done manually but the original clef should also be
 restored manually at the end of the cue notes.
 
@@ -1360,7 +1339,7 @@ bassoonNotes = \relative c {
   \clef bass
   R1
   \clef treble
-  \new CueVoice { \set instrumentCueName = "flute" }
+  <>^\markup \tiny { flute }
   \cueDuring #"flute" #UP { R1 }
   \clef bass
   g4. b8 d2
@@ -1386,7 +1365,7 @@ fluteNotes = \relative c'' {
 bassoonNotes = \relative c {
   \clef bass
   R1
-  \new CueVoice { \set instrumentCueName = "flute" }
+  <>^\markup { \tiny "flute" }
   \cueDuringWithClef #"flute" #UP #"treble" { R1 }
   g4. b8 d2
 }
@@ -1441,8 +1420,6 @@ bassClarinetNotes = \relative c' {
 
 @funindex \killCues
 @funindex killCues
-@funindex \addInstrumentDefinition
-@funindex addInstrumentDefinition
 
 The @code{\killCues} command removes cue notes from a music
 expression, so the same music expression can be used to produce
@@ -1462,7 +1439,7 @@ bassoonNotes = \relative c {
   R1
   \tag #'part {
     \clef treble
-    \new CueVoice { \set instrumentCueName = "flute" }
+    <>^\markup \tiny { flute }
   }
   \cueDuring #"flute" #UP { R1 }
   \tag #'part \clef bass
index db60c370c64219bcefdaadccccd40572e1d9af84..013fabfd9b17b804d5a3be7d6b058c28f2bfb0ef 100644 (file)
@@ -2650,10 +2650,7 @@ pianoRH = \relative c'' {
   c4. g8
   % position name of cue-ing instrument just before the cue notes,
   % and above the staff
-  \new CueVoice {
-    \override InstrumentSwitch.self-alignment-X = #RIGHT
-    \set instrumentCueName = "Flute"
-  }
+  <>^\markup { \right-align { \tiny "Flute" } }
   \cueDuring "flute" #UP { g4 bes4 }
 }
 pianoLH = \relative c { c4 <c' e> e, <g c> }
@@ -2676,11 +2673,7 @@ specify its key so the conversion of its cue notes will be done
 automatically.  The example below shows this transposition for a
 B-flat clarinet.  The notes in this example are low on the staff so
 @code{DOWN} is specified in @code{\cueDuring} (so the stems are
-down) and the instrument name is positioned below the staff.  Note
-also that the piano right-hand voice is explicitly declared.  This
-is because the cue notes in this example begin at the start of the
-first bar and this would otherwise cause the entire piano right-hand
-notes to be placed in a @code{CueVoice} context.
+down) and the instrument name is positioned below the staff.
 
 @lilypond[quote,verbatim]
 clarinet = \relative c' {
@@ -2692,11 +2685,7 @@ clarinet = \relative c' {
 pianoRH = \relative c'' {
   \transposition c'
   % position name of cue-ing instrument below the staff
-  \new CueVoice {
-    \override InstrumentSwitch.self-alignment-X = #RIGHT
-    \override InstrumentSwitch.direction = #DOWN
-    \set instrumentCueName = "Clar."
-  }
+  <>_\markup { \right-align { \tiny "Clar." } }
   \cueDuring "clarinet" #DOWN { c4. g8 }
   g4 bes4
 }
@@ -2744,7 +2733,6 @@ Snippets:
 @rlsr{Vocal music}.
 
 Internals Reference:
-@rinternals{InstrumentSwitch},
 @rinternals{CueVoice}.
 
 @knownissues