]> git.donarmstrong.com Git - lilypond.git/blob - Documentation/user/macros.itexi
Organize macros.texi, and make lsr snippets look better in pdf output.
[lilypond.git] / Documentation / user / macros.itexi
1 @c -*- coding: latin-1; mode: texinfo; -*-
2
3 @c **** all formats ****
4
5 @macro refbugs
6 @noindent
7 @subsubheading Bugs
8
9 @end macro
10
11 @macro moreinfo
12 @subheading More information
13
14 @end macro
15
16 @macro seealso
17 @noindent
18 @subsubheading See also
19
20 @end macro
21
22 @macro refcommands
23 @noindent
24 @subsubheading Predefined commands
25
26 @end macro
27
28 @macro context{NAME}
29 @vindex \NAME\
30 @code{\NAME\}@c should use internalsref
31 @end macro
32
33 @macro refcommand{WHAT}
34 @vindex \WHAT\
35 @code{\WHAT\}
36 @end macro
37
38 @macro commonprop
39 @noindent
40 @subsubheading Commonly tweaked properties
41
42 @end macro
43
44 @macro funindex {WORD}
45 @findex \WORD\
46 @kindex \WORD\
47 @end macro
48
49
50
51 @c  *** Macros with variable output ***
52
53 @c usage: @lsr{ancient,custodes.ly}
54 @macro lsr{DIR,NAME}
55 @ifhtml
56   @uref{source/input/lsr/\DIR\/collated-files.html#\NAME\,@file{\DIR\/\NAME\}}
57 @end ifhtml
58 @ifnothtml
59   @file{\DIR\/\NAME\}
60 @end ifnothtml
61 @end macro
62
63 @macro lsrdir{DIR}
64 @ifhtml
65   @uref{source/input/lsr/\DIR\/collated-files.html,@file{\DIR\}}
66 @end ifhtml
67 @ifnothtml
68   @file{\DIR\}
69 @end ifnothtml
70 @end macro
71
72
73
74 @ifnottex
75   @macro texisharp {word}
76   #
77   @end macro
78   @macro texiflat {word}
79   b
80   @end macro
81 @end ifnottex
82
83 @c FIXME, use \fetaaccidentalsXMC?
84 @c \\kern0.15em\\fetachar\\fetaflat
85 @iftex
86  @macro texiflat {word}
87  @tex
88  FIXME: fetaflat
89  @end tex
90  @end macro
91 @c FIXME, use \fetaaccidentalsXC?
92 @c  \\raise0.5ex\\fetachar\\fetasharp
93  @macro texisharp {word}
94   @tex
95   FIXME: fetasharp
96   @end tex
97   @end macro
98 @end iftex
99
100
101 @macro arrow{}
102 @iftex
103 @tex $\\Rightarrow$ @end tex@c
104 @end iftex
105 @ifhtml
106 @html
107 →
108 @end html
109 @end ifhtml
110 @ifinfo
111 -->
112 @end ifinfo
113 @end macro
114
115
116 @c we need this since @q{\} doesn't work with makeinfo 4.8 --
117 @c say @q{@value{backslash}} instead
118 @set backslash \
119
120
121 @ifhtml
122 @c ***** HTML *****
123
124 @c makeinfo-4.7 encodes html names, which means that nodes that
125 @c contain nonalphanum characters will be broken links on the website.
126 @c @uref{../lilypond-internals/\NAME\.html,\NAME\}@c
127 @c @inforef{} adds ``See'' to the sentence, which is annoying, but
128 @c better than a broken link.
129 @c @inforef{\NAME\,,lilypond-internals}@c
130 @c using @ref without punctuation is OK without for formats other than info
131
132 @ifset bigpage
133
134 @macro internalsref{NAME}
135 @vindex \NAME\
136 @ref{\NAME\,,,lilypond-internals-big-page}
137 @end macro
138
139 @macro rglos{NAME}
140 @vindex \NAME\
141 @ref{\NAME\,,,music-glossary-big-page}
142 @end macro
143
144 @end ifset
145
146
147 @ifclear bigpage
148
149 @c annoying parentheses stripped by add-html-footer.py
150 @macro internalsref{NAME}
151 @vindex \NAME\
152 @ref{\NAME\,,,lilypond-internals}
153 @end macro
154
155 @c annoying parentheses stripped by add-html-footer.py
156 @macro rglos{NAME}
157 @vindex \NAME\
158 @ref{\NAME\,,,music-glossary}
159 @end macro
160
161 @end ifclear
162
163
164 @c usage: @inputfileref{input@/regression,FILE@/-NAME.ly}
165 @macro inputfileref{DIR,NAME}
166 @uref{source/\DIR\/collated-files.html#\NAME\,@file{\DIR\/\NAME\}}@c
167 @end macro
168
169 @c to get decent quotes in `foo'
170 @macro q{TEXT}
171 @html
172 ‘\TEXT\’
173 @end html
174 @end macro
175
176 @c to get decent quotes in ``foo''
177 @macro qq{TEXT}
178 @html
179 “\TEXT\”
180 @end html
181 @end macro
182
183 @end ifhtml
184
185
186 @ifdocbook
187 @c ***** DOCBOOK-XML *****
188
189 @macro internalsref{NAME}
190 @vindex \NAME\
191 @ref{\NAME\,,,lilypond-internals}
192 @end macro
193
194 @macro inputfileref{DIR,NAME}
195 @uref{source/\DIR\/collated-files.html#\NAME\,@file{\DIR\/\NAME\}}
196 @end macro
197
198 @macro rglos{NAME}
199 @vindex \NAME\
200 @ref{\NAME\,,,music-glossary}
201 @end macro
202
203 @c to get decent quotes in `foo'
204 @macro q{TEXT}
205 @xml
206 ‘\TEXT\’
207 @end xml
208 @end macro
209
210 @c to get decent quotes in ``foo''
211 @macro qq{TEXT}
212 @xml
213 “\TEXT\”
214 @end xml
215 @end macro
216
217 @end ifdocbook
218
219
220 @ifinfo
221 @c **** INFO ****
222
223 @macro internalsref{NAME}
224 @vindex \NAME\
225 @inforef{\NAME\,,lilypond-internals}
226 @end macro
227
228 @macro inputfileref{DIR,NAME}
229 @file{\DIR\/\NAME\}
230 @end macro
231
232 @macro rglos{NAME}@c
233 @vindex \NAME\
234 @inforef{\NAME\,,,music-glossary}
235 @end macro
236
237 @macro usermanref{NAME}
238 @inforef{\NAME\}
239 @end macro
240
241 @c to get decent quotes in `foo'
242 @macro q{TEXT}
243 `\TEXT\'
244 @end macro
245
246 @c to get decent quotes in ``foo''
247 @macro qq{TEXT}
248 ``\TEXT\''
249 @end macro
250
251 @end ifinfo
252
253
254 @c **** TEX ****
255 @iftex
256
257 @macro internalsref{NAME}
258 @vindex \NAME\
259 @code{\NAME\}
260 @end macro
261
262 @macro inputfileref{DIR,NAME}
263 @file{\DIR\/@/\NAME\}
264 @end macro
265
266 @macro rglos {NAME}
267 @vindex \NAME\
268 @code{\NAME\}
269 @end macro
270
271 @macro seeinternals{NAME}
272 internals document, @internalsref{\NAME\}
273 @end macro
274
275 @macro usermanref{NAME}
276 user manual, @internalsref{\NAME\}
277 @end macro
278
279 @c to get decent quotes in `foo'
280 @macro q{TEXT}
281 `\TEXT\'
282 @end macro
283
284 @c to get decent quotes in ``foo''
285 @macro qq{TEXT}
286 ``\TEXT\''
287 @end macro
288
289 @end iftex
290
291
292 @ifnottex
293 @c **** not TEX ****
294
295 @macro seeinternals{NAME}
296 @internalsref{\NAME\}
297 @end macro
298
299 @ifnotinfo
300 @macro usermanref{NAME}
301 @ref{\NAME\}
302 @end macro
303 @end ifnotinfo
304
305 @end ifnottex
306
307
308 @c EOF