]> git.donarmstrong.com Git - lilypond.git/blob - input/lsr/tweaking-clef-properties.ly
Merge branch 'master' of ssh://kainhofer@git.sv.gnu.org/srv/git/lilypond into dev...
[lilypond.git] / input / lsr / tweaking-clef-properties.ly
1 %% Do not edit this file; it is auto-generated from LSR http://lsr.dsi.unimi.it
2 %% This file is in the public domain.
3 \version "2.11.38"
4
5 \header {
6   lsrtags = "pitches, staff-notation, tweaks-and-overrides"
7
8   texidoc = "
9 The command @code{\\clef \"treble_8\"} is equivalent to setting
10 @code{clefGlyph}, @code{clefPosition} (which controls the vertical
11 position of the clef), @code{middleCPosition} and
12 @code{clefOctavation}. A clef is printed when any of the properties
13 except @code{middleCPosition} are changed.
14
15
16 Note that changing the glyph, the position of the clef, or the
17 octavation does not in itself change the position of subsequent notes
18 on the staff: the position of middle C must also be specified to do
19 this. The positional parameters are relative to the staff center line,
20 positive numbers displacing upwards, counting one for each line and
21 space. The @code{clefOctavation} value would normally be set to 7, -7,
22 15 or -15, but other values are valid.
23
24
25 When a clef change takes place at a line break the new clef symbol is
26 printed at both the end of the previous line and the beginning of the
27 new line by default. If the warning clef at the end of the previous
28 line is not required it can be suppressed by setting the @code{Staff}
29 property @code{explicitClefVisibility} to the value
30 @code{end-of-line-invisible}. The default behavior can be recovered
31 with  @code{\\unset Staff.explicitClefVisibility}.
32
33 The following examples show the possibilities when setting these
34 properties manually. On the first line, the manual changes preserve the
35 standard relative positioning of clefs and notes, whereas on the second
36 line, they do not. 
37
38 "
39   texidoces = "
40 La instrucción @code{\\clef \"treble_8\"} equivale a un ajuste de
41 @code{clefGlyph}, @code{clefPosition} (que controla la posición vertical
42 de la clave), @code{middleCPosition} y @code{clefOctavation}. Se imprime
43 una clave cada vez que se modifica cualquiera de las propiedades
44 excepto @code{middleCPosition}.
45
46
47 Observe que la modificación del glifo, la posición de la clave
48 o su octavación, no cambian 'per se' la posición de las siguientes notas
49 del pentagrama: para hacer esto también se debe especificar la posición
50 del Do central. Los parámetros posicionales están en relación con la tercera
51 línea del pentagrama, los números positivos desplazan hacia arriba,
52 contando una unidad por cada línea y espacio. El valor de @code{clefOctavation}
53 se estaablecería normalmente a 7, -7, 15 or -15, pero son válidos otros valores.
54
55
56 Cuando se produce un cambio de clave en el salto de línea se
57 imprime la clave nueva tanto al final de la línea anterior como al
58 principio de la nueva, de forma predeterminada.  Si no se necesita
59 la clave de advertencia al final de la línea anterior, se puede
60 quitar estableciendo el valor de la propiedad
61 @code{explicitClefVisibility} de @code{Staff}, a
62 @code{end-of-line-invisible}. El comportamiento predeterminado se
63 puede recuperar con @code{\\unset Staff.explicitClefVisibility}.
64
65 Los siguientes ejemplos muestran las posibilidades cuando se
66 ajustan estas propiedades manualmente.  En la primera línea, los
67 cambios manuales preservan el posicionamiento relativo estándar de
68 las claves y las notas, pero no lo hacen en la segunda línea.
69
70 "
71
72
73
74   doctitle = "Tweaking clef properties"
75 } % begin verbatim
76 {
77   % The default treble clef
78   c'1
79   % The standard bass clef
80   \set Staff.clefGlyph = #"clefs.F"
81   \set Staff.clefPosition = #2
82   \set Staff.middleCPosition = #6
83   c'
84   % The baritone clef
85   \set Staff.clefGlyph = #"clefs.C"
86   \set Staff.clefPosition = #4
87   \set Staff.middleCPosition = #4
88   c'
89   % The standard choral tenor clef
90   \set Staff.clefGlyph = #"clefs.G"
91   \set Staff.clefPosition = #-2
92   \set Staff.clefOctavation = #-7
93   \set Staff.middleCPosition = #1
94   c'
95   % A non-standard clef
96   \set Staff.clefPosition = #0
97   \set Staff.clefOctavation = #0
98   \set Staff.middleCPosition = #-4
99   c' \break
100
101   % The following clef changes do not preserve
102   % the normal relationship between notes and clefs:
103
104   \set Staff.clefGlyph = #"clefs.F"
105   \set Staff.clefPosition = #2
106   c'
107   \set Staff.clefGlyph = #"clefs.G"
108   c'
109   \set Staff.clefGlyph = #"clefs.C"
110   c'
111   \set Staff.clefOctavation = #7
112   c'
113   \set Staff.clefOctavation = #0
114   \set Staff.clefPosition = #0
115   c'
116   
117   % Here we go back to the normal clef:
118
119   \set Staff.middleCPosition = #0
120   c'
121 }