]> git.donarmstrong.com Git - lilypond.git/blob - Documentation/changes.tely
Add Changes entry for -dstrokeadjust and "Usage" entry.
[lilypond.git] / Documentation / changes.tely
1 \input texinfo @c -*- coding: utf-8; mode: texinfo; -*-
2 @setfilename lilypond-changes.info
3 @settitle LilyPond Changes
4
5 @include macros.itexi
6
7 @ifhtml
8 @macro inputfileref{DIR,NAME}
9 @uref{../../\DIR\/collated-files.html#\NAME\,@file{\DIR\/\NAME\}}@c
10 @end macro
11 @macro usermanref{NAME}
12 @inforef{\NAME\,,../user/lilypond/lilypond}@c
13 @end macro
14 @end ifhtml
15
16 @ifnothtml
17 @macro inputfileref{DIR,NAME}
18 @file{\DIR\/\NAME\}@c
19 @end macro
20 @macro usermanref{NAME}
21 See user manual, \NAME\
22 @end macro
23 @end ifnothtml
24
25 @macro textanchor{NAME}
26 @html
27 <a name="\NAME\"></a>
28 @end html
29 @end macro
30
31
32 @documentencoding utf-8
33 @documentlanguage en
34 @afourpaper
35
36 @finalout
37
38 @node Top
39 @top New features in 2.18 since 2.16
40
41 @allowcodebreaks false
42
43 @itemize
44
45 @ignore
46
47 HINTS
48
49 * add new items at the top
50
51 * only show verbatim input for syntax/input changes
52
53 * try to be as brief possible in those cases
54
55 * don't try to provide real-world examples, they often get too big,
56 which scares away people.
57
58 * Write complete sentences.
59
60 * only show user-visible changes.
61
62 @end ignore
63
64 @item
65 The PostScript functionality of stroke adjustment is no longer
66 applied automatically but left to the discretion of the PostScript
67 device (by default, Ghostscript uses it for resolutions up to
68 150dpi when generating raster images).  When it is enabled, a more
69 complex drawing algorithm designed to benefit from stroke
70 adjustment is employed mostly for stems and bar lines.
71
72 Stroke adjustment can be forced by specifying the command line
73 option @samp{-dstrokeadjust} to LilyPond.  When generating
74 @code{PDF} files, this will usually result in markedly better
75 looking @code{PDF} previews but significantly larger file size.
76 Print quality at high resolutions will be unaffected.
77
78 @item
79 There is now a new context type called @code{NullVoice} which, while not
80 appearing in the printed output, can be used to align lyrics.  This can
81 be particularly convenient when used in parallel with a
82 @code{\partcombine} construct.
83
84 @lilypond[verbatim,quote]
85 soprano = \relative c' { c e g c }
86 alto = \relative c' { a c e g }
87 verse = \lyricmode { This is my song }
88
89 \score {
90   \new Staff <<
91     \partcombine \soprano \alto
92     \new NullVoice = "aligner" \soprano
93     \new Lyrics \lyricsto "aligner" \verse
94   >>
95   \layout {}
96 }
97 @end lilypond
98
99
100 @item
101 Several articulations can be put into a single variable or
102 returned from an event function:
103
104 @lilypond[verbatim,quote]
105 sempreStacc = -. ^\markup \italic sempre
106 \relative { c''4\sempreStacc c c c }
107 @end lilypond
108
109 @item
110 The baseline of score markups is now taken from the reference
111 point (usually the middle of the staff) of the first bottom system
112 rather than the top of the bounding rectangle.  The following
113 @lilypond[verbatim,quote]
114 \markup {
115   violin: \score { \new Staff { <g d' a' e''>1 }
116                    \layout { indent=0 } } ,
117   cello: \score { \new Staff { \clef "bass" <c, g, d a> }
118                   \layout { indent=0 } }
119 }
120 @end lilypond
121 previously looked like
122 @lilypond[quote]
123 \markup {
124   violin: \general-align #Y #UP
125           \score { \new Staff { <g d' a' e''>1 }
126                    \layout { indent=0 } } ,
127   cello:  \general-align #Y #UP
128           \score { \new Staff { \clef "bass" <c, g, d a> }
129                   \layout { indent=0 } }
130 }
131 @end lilypond
132 without a reliable way to get both scores to line up.
133
134 @item
135 LilyPond no longer automatically infers a @samp{\defaultchild}
136 context in a context definition with @samp{\accepts} clauses.  Any
137 context definition without an explicit or inherited
138 @samp{\defaultchild} definition counts as a @samp{Bottom} context
139 and will be eligible for rhythmic events and overrides without
140 causing the implicit creation of other contexts.  Be sure to
141 specify a @samp{\defaultchild} for non-@samp{Bottom} contexts when
142 defining them from scratch.
143
144 @item
145 There is now extensive support for both discant and bass accordion
146 register symbols in the @samp{scm accreg} module, see
147 @ruser{Accordion Registers}.
148 @lilypond[verbatim,quote]
149 #(use-modules (scm accreg))
150 \new PianoStaff
151 <<
152   \new Staff \relative
153   { \clef "treble"  \discant "10"
154     r8 s32 f'[ bes f] s e[ a e] s d[ g d] s16 e32[ a]
155     \discant "121"
156     << { r16 <f bes> r <e a> r <d g> } \\
157        { d r a r bes r } >> |
158     <cis e a>1
159   }
160   \new Staff \relative
161   { \clef "treble"  \freeBass "1"
162     r8 d'32 s16. c32 s16. bes32 s16. a32[ cis] s16
163     \clef "bass"  \stdBass "Master"
164     << { r16 <f, bes d>^"b" r <e a c>^"am" r <d g bes>^"gm" |
165          <e a cis>1^"a" } \\
166        { d8_"D" c_"C" bes_"B" | a1_"A" }
167     >>
168   }
169 >>
170 @end lilypond
171
172 @item
173 New commands @code{markLengthOn} and @code{markLengthOff} control
174 the allowance of horizontal space for tempo and rehearsal marks.
175
176 @lilypond[quote,relative=2]
177 \markLengthOn
178 \compressFullBarRests
179 \tempo "Molto vivace" c2 c'
180 \mark\default
181 \tempo "Meno mosso" R1*16
182 \mark\default
183 g,2 g
184 \bar "||"
185 \markLengthOff
186 \tempo "Molto vivace" c2 c'
187 \mark#1
188 \tempo "Meno mosso" R1*16
189 \mark\default
190 g,2 g
191 @end lilypond
192
193 @item
194 Rehearsal marks at the beginning of a line are now placed to the right
195 of the clef and key signature by default.  As in previous versions, the
196 @code{break-alignable-interface} controls the behavior.
197
198 @lilypond[quote,relative=2]
199 \set Score.barNumberVisibility = #all-bar-numbers-visible
200 \set Timing.currentBarNumber = #72
201 \bar"||" \time 3/4 \key e\major \mark#10 \tempo "Adagio" b2.
202 @end lilypond
203
204 @item
205 Decimal numbers can now be written directly in music,
206 without a hash sign.  Together with the previous change
207 in the way object properties are specified, the code to
208 change the length of stems has changed from this:
209 @example
210 \override Stem #'length = #5.6
211 e' f' g' a'
212 @end example
213 to this:
214 @example
215 \override Stem.length = 5.6
216 e' f' g' a'
217 @end example
218
219 One has to write a digit on both sides of the dot -- values like
220 @code{4.} or @code{-.3} are not allowed.
221
222 Decimal fractions are also not accepted in @code{\chordmode}.
223
224 @item
225 A number of shorthands like @code{(}, @code{)}, @code{|},
226 @code{[}, @code{]}, @code{~}, @code{\(}, @code{\)} and others can
227 now freely be redefined like normal commands.  An example would be
228 @lilypond[verbatim,quote]
229 "\\{" = (
230 "\\}" = )
231 "(" = \melisma
232 ")" = \melismaEnd
233
234 \new Staff <<
235   \relative c' {
236     c8 \{ d e f \} % slurred
237     g ( a b c ) % no slur, but with melisma
238     c,1 \bar "|."
239    }
240    \addlyrics { Li -- ly -- pond. }
241 >>
242 @end lilypond
243
244 @item
245 The articulation shorthand for @code{\staccatissimo} has been
246 renamed from @code{-|} to@tie{}@code{-!}.
247
248 @item
249 Tempo change ranges are now written as @code{\tempo 4 = 60 - 68}
250 rather than @code{\tempo 4 = 60 ~ 68}.
251
252 @item
253 Grob @code{OctavateEight} was renamed to @code{ClefModifier}.
254 Related context properties were renamed from @code{xxxOctavationyyy}
255 to @code{xxxTranspositionyyy}.
256
257 @item
258 There is a new @code{\absolute} command explicitly marking music
259 as being entered in absolute pitch.  While this has been the
260 default previously, an explicit @code{\absolute} also prevents
261 reinterpretation when the passage is placed inside of
262 @code{\relative}:
263 @lilypond[verbatim,quote]
264 \relative c { c'4 \absolute { f'' g'' } c }
265 @end lilypond
266
267 @item
268 When @code{\relative} is used without an explicit reference pitch,
269 the reference pitch now is the middle of the first octave, making
270 the first entered pitch indistinguishable from absolute pitch.
271 Previously, omitting the reference pitch would have lead to a
272 default of @code{c'}.  Since that choice was somewhat arbitrary,
273 recommended usage was to always specify the reference pitch.
274
275 @item
276 A new command @code{\single} can be used for converting a property
277 override into a tweak to be applied on a single music expression:
278
279 @lilypond[quote,verbatim,relative=2]
280 <a \single\voiceTwoStyle e' a>1
281 @end lilypond
282
283 @item
284 Two ways of letting graphical objects not appear in the output are
285 overriding its @code{transparent} property with @code{#t}
286 (retaining the original spacing) or overriding its @code{stencil}
287 property with @code{#f} (not using any space at all).  Those two
288 operations now have the shorthands @code{\hide} and @code{\omit},
289 respectively.  They can either be given a music expression to
290 tweak, or the name of a graphical object for which an override
291 should be created (for specifying both, use @code{\single} on the
292 override form):
293
294 @lilypond[quote,verbatim]
295 \new Staff \with { \omit Clef }
296 \relative c'' <a e' \hide a>1
297 @end lilypond
298
299 @item
300 A new command @code{\temporary} can be applied to overrides in
301 order to not have them replace previous property settings.  If a
302 @code{\revert} is applied to the same property subsequently, the
303 previous setting reappears:
304
305 @lilypond[quote,verbatim,relative=2]
306 \override NoteHead.color = #red c4
307 \override NoteHead.color = #green d
308 \revert NoteHead.color e2
309 \override NoteHead.color = #red c4
310 \temporary\override NoteHead.color = #green d
311 \revert NoteHead.color e
312 \revert NoteHead.color c
313 @end lilypond
314
315 This is mainly useful for writing music functions that need to
316 have some property changed just for the duration of the function.
317
318 @item
319 @code{\tag}, @code{\removeWithTag}, and @code{\keepWithTag} can
320 now accept a list of symbols rather than just a single symbol for
321 marking, removing, and keeping music with any of multiple tags.
322 This is particularly important for @code{\keepWithTag} since one
323 cannot achieve the same effect by using multiple consecutive
324 @code{\keepWithTag} commands.
325
326 @item
327 The @samp{-d old-relative} option has been removed.  Not actually
328 accessible from the command line any more, its remaining use was
329 for interpretating @code{\relative} in LilyPond files converted
330 automatically from version@tie{}1.8 or older.  It is unclear how
331 much of this was actually still operative.
332
333 @item
334 The meaning of @code{instrumentTransposition} has been reversed.
335 After
336 @example
337 \set instrumentTransposition = #@{ b #@}
338 @end example
339 a written @code{c'} now sounds like @code{b}.  Previously, this
340 would have been the other way round.  This and the following change
341 should make dealing with transposing instruments more
342 straightforward.
343
344 @item
345 The music generated by @code{\set} and @code{\override} commands
346 is no longer affected by @code{\transpose}.  The main consequence
347 is that @code{\transpose} will transpose audible/@/concert pitch and
348 printed pitch by the same amount even when the transposed music
349 contains @code{\transposition}.  Previously,
350 @example
351 \transpose c' f' \transposition bes'
352 @end example
353 was equivalent to @code{\transposition f'}.  Now it stays
354 equivalent to @code{\transposition bes'}.
355
356 @item
357 When checking for collisions, LilyPond no longer treats objects as
358 rectangles.  Instead, the actual shape of objects is approximated
359 using an integral-like approach.  This generally results in more
360 even and snug positioning of objects and systems:
361
362 @lilypond[relative=1]
363 #(ly:set-option 'debug-skylines #t)
364 \dynamicUp
365 c'4\f a4\f d\f( f)
366 a,4\< c c c\!
367 d4-.\downbow a4^"r'venu..." c \tempo "T1" e
368 @end lilypond
369
370 Previously, the above snippet looked like this:
371
372 @lilypond[relative=1]
373 #(ly:set-option 'debug-skylines #t)
374 \override Hairpin #'vertical-skylines = #'()
375 \override DynamicText #'vertical-skylines = #'()
376 \override TextScript #'vertical-skylines = #'()
377 \override Score.MetronomeMark #'vertical-skylines = #'()
378 \override Staff.Clef #'vertical-skylines = #'()
379 \dynamicUp
380 c'4\f a4\f d\f( f)
381 a,4\< c c c\!
382 d4-.\downbow a4^"r'venu..." c \tempo "T1" e
383 @end lilypond
384
385 Affected objects include @code{Accidentals}, @code{Beams}, @code{Clefs},
386 @code{Dynamics}, @code{FiguredBass}, @code{Flags}, @code{Glissandos},
387 @code{Lyrics}, @code{MetronomeMarks}, @code{OttavaBrackets},
388 @code{Pedals}, @code{RehearsalMarks}, @code{Rests}, @code{Scripts},
389 @code{TextScripts}, @code{Ties}, @code{Tuplets} and @code{VoltaBrackets}.
390
391 @item
392 Tuplets are now created with the @code{\tuplet} command, which
393 takes a fraction @code{@var{t}/@var{n}} to specify that @var{t}
394 notes are played in the time usually allowed for @var{n}. One
395 @code{\tuplet} command can create several tuplet groups if their
396 duration is typed after the fraction.
397 @lilypond[quote,verbatim,relative=2]
398 \tuplet 3/2 { c8 d e } \tuplet 3/2 { f e d } c2
399 \tuplet 3/2 4 { c8 d e f e d } c2
400 @end lilypond
401 The @code{\times} command with its inverted fraction order
402 @code{@var{n}/@var{t}} is still available.
403
404 @item
405 Introducing two new markup-commands; @code{\draw-dashed-line} and
406 @code{\draw-dotted-line}.
407
408 @noindent
409 The dashed-line extends to the whole length given by @var{dest}, if
410 @code{full-length} is set to @code{#t} (this is the default) without any
411 space at the beginning or end.  @code{off} will then be altered to fit.
412 To insist on the given (or default) values of @code{on}, @code{off} use
413 @code{\override #'(full-length . #f)}.  Manual settings for @code{on},
414 @code{off} and @code{phase} are possible.
415
416 @noindent
417 The dotted-line always extends to the whole length given by @var{dest},
418 without any space at the beginning or end.  Manual settings for
419 @code{off} are possible to get larger or smaller space between the dots.
420 The given (or default) value of @code{off} will be altered to fit the
421 line-length.
422
423 @lilypond[verbatim,quote]
424 \markup {
425   \draw-dashed-line #'(5.1 . 2.3)
426   \override #'(on . 0.3)
427   \override #'(off . 0.5)
428   \draw-dashed-line #'(5.1 . 2.3)
429   \draw-dotted-line #'(5.1 . 2.3)
430   \override #'(thickness . 2)
431   \override #'(off . 0.2)
432   \draw-dotted-line #'(5.1 . 2.3)
433 }
434 @end lilypond
435
436 @item
437 Starting with version@tie{}2.17.10, error messages or the
438 @code{textedit} @acronym{URI} used for point-and-click
439 functionality specify column numbers starting with@tie{}1 rather
440 than@tie{}0.  The byte offset (also part of @code{textedit}
441 @acronym{URI}s) still starts at@tie{}0.
442
443 @item
444 The @code{\clef} command supports optional transposition:
445 @lilypond[verbatim,quote,relative=1]
446 \clef "treble_(8)"
447 c2 c
448 \clef "bass^[15]"
449 c2 c
450 @end lilypond
451
452 @item
453 The LilyPond syntax of dot-separated words @code{Voice.Accidental}
454 has been made interchangeable with @code{#'(Voice Accidental)}, a
455 Scheme list of symbols.  As one result, code like
456 @example
457 \override Voice.TextSpanner #'(bound-details left text) = "rit."
458 @end example
459 is now equivalent to
460 @example
461 \override Voice.TextSpanner bound-details.left.text = "rit."
462 @end example
463 or even
464 @example
465 \override #'(Voice TextSpanner) bound-details.left.text = "rit."
466 @end example
467
468 @item
469 Grob and grob property path no longer need to be specified as two
470 separate arguments to commands like @samp{\override} and
471 @code{\revert}, allowing for the syntax
472 @example
473 \override Voice.TextSpanner.bound-details.left.text = "rit."
474 @end example
475 Since complementary music functions like @samp{\overrideProperty}
476 cannot support forms with and without separating space at the same
477 time, using a single dotted path is now the preferred form.
478 Specifying grob path and grob property path separately, currently
479 still supported with @samp{\override} and @samp{\revert} for
480 compatibility reasons, is deprecated.
481
482 @item
483 Due to words now being accepted as symbol function arguments, the
484 interfaces of @samp{\accidentalStyle}, @samp{\alterBroken},
485 @samp{\footnote} and @samp{\tweak} had to be redesigned where
486 optional symbol arguments were involved.  Please check the
487 respective music function documentation for details.
488
489 @item
490 Several commands now accept symbol lists (conveniently entered as
491 dot-separated words) for various kinds of arguments.  These
492 include @samp{\accidentalStyle}, @samp{\alterBroken},
493 @samp{\footnote}, @samp{\hide}, @samp{\omit},
494 @samp{\overrideProperty}, @samp{\shape}, and @samp{\tweak}.
495
496 @item
497 The bar line user interface has changed. Bar glyphs now resemble the
498 appearance of the bar line, so a left repeat sign has to be coded
499 as @code{.|:}. The command @code{\defineBarLine} provides an easy way
500 to define additional bar line styles.
501
502 @item
503 Accidentals in the key signature may be printed in octaves other
504 than their traditional positions, or in multiple octaves.
505 @lilypond[quote,relative=0]
506 \override Staff.KeySignature #'flat-positions = #'((-5 . 5))
507 \override Staff.KeyCancellation #'flat-positions = #'((-5 . 5))
508 \clef bass \key es \major es g bes d
509 \clef treble \bar "||" \key es \major es g bes d
510 \override Staff.KeySignature #'sharp-positions = #'(2)
511 \bar "||" \key d \major b fis b2
512 @end lilypond
513
514 @end itemize
515
516 @ifhtml
517 For older news, go to
518 @uref{http://lilypond.org/doc/v2.16/Documentation/changes/},
519 @uref{http://lilypond.org/doc/v2.14/Documentation/changes/},
520 or @uref{../,go back} to the Documentation index.
521
522
523 @end ifhtml
524
525 @bye