]> git.donarmstrong.com Git - lilypond.git/blob - Documentation/snippets/aligning-and-centering-instrument-names.ly
Docs: reorganize documentation directory structure
[lilypond.git] / Documentation / snippets / aligning-and-centering-instrument-names.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.13.1"
4
5 \header {
6   lsrtags = "text, paper-and-layout, titles"
7
8 %% Translation of GIT committish: 00e3a8264e138ad61b4f115a173190d5e9dc7533
9   texidoces = "
10 Los nombres de instrumento se imprimen generalmente a la izquierda de
11 los pentagramas.  Para alinear los nombres de varios instrumentos
12 distintos, sitúelos dentro de un bloque @code{\\markup} y utilice una
13 de las siguientes posiblidades:
14
15 *
16     Nombres de instrumento alineados por la derecha: es el
17     comportamiento predeterminado
18   
19 *
20     Nombres de instrumento centrados: la utilización de la instrucción
21     @code{\\hcenter-in #n} sitúa los nombres de instrumento dentro de
22     un rectángulo separado, donde @code{n} es la anchura del
23     rectángulo
24   
25
26     Nombres de instrumento alineados por la izquierda: los nombres se
27     imprimen en la parte superior de un rectángulo vacío, utilizando
28     la instrucción @code{\\combine} con un objeto @code{\\hspace #n}.
29
30 "
31   doctitlees = "Alinear y centrar los nombres de instrumento"
32
33   texidoc = "
34 The horizontal alignment of instrument names is tweaked by changing the
35 @code{Staff.InstrumentName #'self-alignment-X} property. The
36 @code{\\layout} variables @code{indent} and @code{short-indent} define
37 the space in which the instrument names are aligned before the first
38 and the following systems, respectively.
39
40 "
41   doctitle = "Aligning and centering instrument names"
42 } % begin verbatim
43
44 \paper {
45   left-margin = 3\cm
46 }
47
48 \score {
49   \new StaffGroup <<
50     \new Staff {
51       \override Staff.InstrumentName #'self-alignment-X = #LEFT
52       \set Staff.instrumentName = \markup \left-column {
53         "Left aligned"
54         "instrument name"
55       }
56       \set Staff.shortInstrumentName = #"Left"
57       c''1
58       \break
59       c''1
60     }
61     \new Staff {
62       \override Staff.InstrumentName #'self-alignment-X = #CENTER
63       \set Staff.instrumentName = \markup \center-column {
64         Centered
65         "instrument name"
66       }
67       \set Staff.shortInstrumentName = #"Centered"
68       g'1
69       g'1
70     }
71     \new Staff {
72       \override Staff.InstrumentName #'self-alignment-X = #RIGHT
73       \set Staff.instrumentName = \markup \right-column {
74         "Right aligned"
75         "instrument name"
76       }
77       \set Staff.shortInstrumentName = #"Right"
78       e'1
79       e'1
80     }
81   >>
82   \layout {
83     ragged-right = ##t
84     indent = 4\cm
85     short-indent = 2\cm
86   }
87 }