]> git.donarmstrong.com Git - lilypond.git/blob - Documentation/changes.tely
Issue 4421/7: Documentation and Changes 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.20 since 2.18
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 LilyPond functions defined with @code{define-music-function},
66 @code{define-event-function}, @code{define-scheme-function} and
67 @code{define-void-function} can now be directly called from Scheme
68 as if they were genuine Scheme procedures.  Argument checking and
69 matching will still be performed in the same manner as when
70 calling the function through LilyPond input.  This includes the
71 insertion of defaults for optional arguments not matching their
72 predicates.  Instead of using @code{\default} in the actual
73 argument list for explicitly skipping a sequence of optional
74 arguments, @code{*unspecified*} can be employed.
75
76 @item
77 The definition of LilyPond functions with
78 @code{define-music-function}, @code{define-event-function},
79 @code{define-scheme-function} and @code{define-void-function} no
80 longer requires specification of @code{parser} and @code{location}
81 arguments.  Current parser and input location are part of the
82 current dynamic state and can be accessed with the function calls
83 @code{(*parser*)} and @code{(*location*)} when required.
84
85 LilyPond makes a best-faith attempt of recognizing legacy use of
86 @code{parser} and @code{location} arguments and will provide
87 backwards-compatible semantics for some time.
88
89 @item
90 In the "english" notename language, the long notenames for pitches
91 with accidentals now contain a hyphen for better readability.  You
92 now have to write
93 @example
94 \key a-flat \major
95 @end example
96 instead of the previous
97 @example
98 \key aflat \major
99 @end example
100
101 Double accidentals do not get another hyphen, so the Dutch
102 @code{cisis} has the long English notename @code{c-sharpsharp}.
103
104 @item
105 The visual style of tremolo slashes (shape, style and slope)
106 is now more finely controlled.
107 @lilypond[quote,relative=2]
108   a8:32 b: c: d:
109   \override StemTremolo.shape = #'beam-like
110   a: b: c: d:
111   \override StemTremolo.style = #'constant
112   a: b: c: d:
113   g,2
114 @end lilypond
115
116
117 @item
118 Multi-measure rests have length according to their total duration,
119 under the control of @code{MultiMeasureRest.space-increment}.
120 @lilypond[quote]
121 { \compressFullBarRests
122   \override Staff.MultiMeasureRest.space-increment = 3.0
123   R1*2 R1*12 R1*64 }
124 @end lilypond
125
126 @item
127 Page numbers may now be printed in roman numerals, by setting the
128 @code{page-number-type} paper variable.
129
130 @item
131 It is now possible to use @code{\time} and @code{\partial}
132 together to change the time signature in mid measure.
133
134 @lilypond[verbatim,quote,relative=1]
135 \override Score.BarNumber.break-visibility = #end-of-line-invisible
136 \partial 4 \time 3/4 f4 | 2 4 | 2 \bar "||"
137 \time 9/8 \partial 4. f8 8 8 | 2. 8 8 8 |
138 @end lilypond
139
140 @item
141 It is now possible to override the @code{text} property of
142 chord names.
143
144 @lilypond[verbatim,fragment,quote]
145 <<
146 \new ChordNames \chordmode {
147   a' b c:7
148   \once \override ChordName.text = #"foo"
149   d
150 }
151 >>
152 @end lilypond
153
154 @item
155 Improved horizontal alignment when using @code{TextScript},
156 with @code{DynamicText} or @code{LyricText}.
157
158 @item
159 A new command @code{\magnifyStaff} has been added which scales staff
160 sizes, staff lines, bar lines, beamlets and horizontal spacing generally
161 at the @code{Staff} context level.  Staff lines are prevented from being
162 scaled smaller than the default since the thickness of stems, slurs, and
163 the like are all based on the staff line thickness.
164
165 @item
166 @code{InstrumentName} now supports @code{text-interface}.
167
168 @item
169 There is now support for controlling the @q{expression level} of
170 MIDI channels using the @code{Staff.midiExpression} context property.
171 This can be used to alter the perceived volume of even sustained notes
172 (albeit in a very @q{low-level} way) and accepts a number value between
173 @code{0.0} and @code{1.0}.
174
175 @example
176 \score @{
177   \new Staff \with @{
178     midiExpression = #0.6
179     midiInstrument = #"clarinet"
180   @}
181   <<
182     @{ a'1~ a'1 @}
183     @{
184       \set Staff.midiExpression = #0.7 s4\f\<
185       \set Staff.midiExpression = #0.8 s4
186       \set Staff.midiExpression = #0.9 s4
187       \set Staff.midiExpression = #1.0 s4
188
189       \set Staff.midiExpression = #0.9 s4\>
190       \set Staff.midiExpression = #0.8 s4
191       \set Staff.midiExpression = #0.7 s4
192       \set Staff.midiExpression = #0.6 s4\!
193     @}
194   >>
195   \midi @{ @}
196 @}
197 @end example
198
199 @item
200 Support for making it easier to use alternative @q{music} fonts other
201 than the default Emmentaler in LilyPond has been added.  See
202 @uref{http://fonts.openlilylib.org/} for more information.
203
204 @item
205 Grobs and their parents can now be aligned separately allowing
206 more flexibility for grob positions.  For example the @q{left} edge of a
207 grob can now be aligned on the @q{center} of its parent.
208
209 @item
210 Improvements to the @code{\partial} command have been made to
211 avoid problems when using multiple, parallel contexts.
212
213 @item @code{\chordmode} can now use @code{< >} and @code{<< >>}
214 constructs.
215
216 @item
217 The @code{NullVoice} context is now @q{below} @code{Score}.
218
219 @item
220 A new command @code{\tagGroup} has now been added.  This compliments
221 the existing @code{\keepWithTag} and @code{\removeWithTag} commands.
222 For Example:
223
224 @example
225 \tagGroup #'(violinI violinII viola cello)
226 @end example
227
228 declares a list of @q{tags} that belong to a single @q{tag group}.
229
230 @example
231 \keepwithTag#'violinI
232 @end example
233
234 Is now only concerned with @q{tags} from @q{violinI}’s tag group.
235
236 Any element of the included music tagged with one or more tags from the
237 group, but @emph{not} with @var{violinI}, will be removed.
238
239 @item
240 The @code{\addlyrics} function now works with arbitrary contexts
241 incuding @code{Staff}.
242
243 @item
244 String numbers can now also be used to print roman numerals
245 (e.g. for unfretted string instruments).
246 @lilypond[verbatim,quote,relative=2]
247 c2\2
248 \romanStringNumbers
249 c\2
250 \arabicStringNumbers
251 c1\3
252 @end lilypond
253
254 @item
255 The @code{thin-kern} property of the @code{BarLine} grob has been
256 renamed to @code{segno-kern}.
257
258 @item
259 @code{KeyCancellation} grobs now ignore cue clefs (like
260 @code{KeySignature} grobs do).
261
262 @item
263 Add support for @code{\once@tie{}\unset}
264
265 @item
266 It is now possible to individually color both the dots and parentheses
267 in fret diagrams when using the @code{\fret-diagram-verbose} markup
268 command.
269
270 @lilypond[verbatim,quote,relative=1]
271 \new Voice {
272   c1^\markup {
273     \override #'(fret-diagram-details . (
274                  (finger-code . in-dot))) {
275       \fret-diagram-verbose #'((mute 6)
276                                (place-fret 5 3 1 red)
277                                (place-fret 4 5 2 inverted)
278                                (place-fret 3 5 3 green)
279                                (place-fret 2 5 4 blue inverted)
280                                (place-fret 1 3 1 violet)
281                                (barre 5 1 3 ))
282     }
283   }
284   c1^\markup {
285     \override #'(fret-diagram-details . (
286                  (finger-code . below-string))) {
287       \fret-diagram-verbose #'((mute 6)
288                              (place-fret 5 3 1 red parenthesized)
289                              (place-fret 4 5 2 yellow
290                                                default-paren-color
291                                                parenthesized)
292                              (place-fret 3 5 3 green)
293                              (place-fret 2 5 4 blue )
294                              (place-fret 1 3 1)
295                              (barre 5 1 3))
296     }
297   }
298 }
299 @end lilypond
300
301 @item
302 Two new properties have been added for use in
303 @code{fret-diagram-details} when using the @code{\fret-diagram-verbose}
304 markup command; @code{fret-label-horizontal-offset} which affects the
305 @code{fret-label-indication} and @code{paren-padding} which controls the
306 space between the dot and the parentheses surrounding it.
307
308 @lilypond[verbatim,quote,relative=1]
309 \new Voice {
310   c1^\markup {
311     \fret-diagram-verbose #'((mute 6)
312                              (place-fret 5 3 1)
313                              (place-fret 4 5 2)
314                              (place-fret 3 5 3)
315                              (place-fret 1 6 4 parenthesized)
316                              (place-fret 2 3 1)
317                              (barre 5 2 3))
318   }
319   c1^\markup {
320     \override #'(fret-diagram-details . (
321                  (fret-label-horizontal-offset . 2)
322                  (paren-padding . 0.25))) {
323       \fret-diagram-verbose #'((mute 6)
324                                (place-fret 5 3 1)
325                                (place-fret 4 5 2)
326                                (place-fret 3 5 3)
327                                (place-fret 1 6 4 parenthesized)
328                                (place-fret 2 3 1)
329                                (barre 5 2 3))
330     }
331   }
332 }
333 @end lilypond
334
335 @item
336 A new markup command @code{\justify-line} has been added.  Similar to
337 the @code{\fill-line} markup command except that instead of setting
338 @emph{words} in columns, the @code{\justify-line} command balances the
339 whitespace between them ensuring that when there are three or more
340 words in a markup, the whitespace is always consistent.
341
342 @lilypond[quote,verbatim,papersize=a6]
343 \markup \fill-line {oooooo oooooo oooooo oooooo}
344 \markup \fill-line {ooooooooo oooooooo oo ooo}
345 @end lilypond
346
347 @lilypond[quote,verbatim,papersize=a6]
348 \markup \justify-line {oooooo oooooo oooooo oooooo}
349 \markup \justify-line {ooooooooo oooooooo oo ooo}
350 @end lilypond
351
352 @item
353 A new command @code{\magnifyMusic} has been added, which allows
354 the notation size to be changed without changing the staff size,
355 while automatically scaling stems, beams, and horizontal spacing.
356
357 @lilypond[verbatim,quote]
358 \new Staff <<
359   \new Voice \relative {
360     \voiceOne
361     <e' e'>4 <f f'>8. <g g'>16 <f f'>8 <e e'>4 r8
362   }
363   \new Voice \relative {
364     \voiceTwo
365     \magnifyMusic 0.63 {
366       \override Score.SpacingSpanner.spacing-increment = #(* 1.2 0.63)
367       r32 c'' a c a c a c r c a c a c a c
368       r c a c a c a c a c a c a c a c
369     }
370   }
371 >>
372 @end lilypond
373
374 @item
375 A new flexible template suitable for a range of choral music, is now
376 provided.  This may be used to create simple choral music, with or
377 without piano accompaniment, in two or four staves. Unlike other
378 templates, this template is @q{built-in}, which means it does not
379 need to be copied and edited: instead it is simply @code{\include}'d
380 in the input file.  For details, see @rlearning{Built-in templates}.
381
382 @item
383 The positioning of tuplet numbers for kneed beams has been significantly
384 improved.  Previously, tuplet numbers were placed according to the
385 position of the tuplet bracket, even if it was not printed.  This could
386 lead to stranded tuplet numbers.  Now they are now positioned
387 closer to the kneed-beam when an appropriate beam segment exists for its
388 placement and when the the bracket is not drawn.
389
390 Collision detection is also added, offsetting horizontally if too close
391 to an adjoining note column but preserving the number's vertical
392 distance from the kneed beam.  If the number itself is too large to
393 fit in the available space the original, bracket-based, positioning
394 system is used instead; and in the event of a collision (e.g. with an
395 accidental) the tuplet number is moved vertically away instead.
396
397 @lilypond[verbatim,fragment,quote,relative=1]
398 \time 3/4
399 \override Beam.auto-knee-gap = 3
400 \tuplet 3/2 4 {
401   g8 c'' e,
402   c'8 g,, e''
403   g,,8 e''' c,,
404 }
405 @end lilypond
406
407 @noindent
408 The original kneed-beam tuplet behavior is still available through an
409 @code{\override} via a new, @code{knee-to-beam} property.
410
411 @lilypond[verbatim,fragment,quote,relative=1]
412 \time 3/4
413 \override Beam.auto-knee-gap = 3
414 \override TupletNumber.knee-to-beam = ##f
415 \tuplet 3/2 4 {
416   g8 c'' e,
417   c'8 g,, e''
418   g,,8 e''' c,,
419 }
420 @end lilypond
421
422 @item
423 @code{\lyricsto} and @code{\addLyrics} have been @q{harmonized}.  Both
424 now accept the same kind of delimited argument list that @code{\lyrics}
425 and @code{\chords} accept.  Backward compatibility has been added so
426 music identifiers (i.e. @code{\mus}) are permitted as arguments.  A
427 @code{convert-ly} rule has been added that removes redundant uses of
428 @code{\lyricmode} and rearranges combinations with context starters such
429 that @code{\lyricsto} in general is applied last (i.e. like
430 @code{\lyricmode} would be).
431
432 @item
433 Scheme functions and identifiers can now be used as output definitions.
434
435 @item
436 Scheme expressions can now be used as chord constituents.
437
438 @item
439 Improved visual spacing of small and regular @q{MI} Funk and Walker
440 noteheads so they are now the same width as other shaped notes in
441 their respective sets.  @code{SOL} noteheads are also now visually
442 improved when used with both the normal Aiken and Sacred Harp heads, as
443 well as with the thin variants.
444
445 @item
446 @code{LeftEdge} now has a definable @code{Y-extent} (i.e.vertical).  See
447 @rinternals{LeftEdge}.
448
449 @item
450 Added a new @code{make-path-stencil} function that supports all
451 @code{path} commands both relative and absolute:
452
453 @code{lineto}, @code{rlineto}, @code{curveto}, @code{rcurveto},
454 @code{moveto}, @code{rmoveto}, @code{closepath}.  The function also
455 supports @q{single-letter} syntax used in standard SVG path commands:
456
457 @code{L}, @code{l}, @code{C}, @code{c}, @code{M}, @code{m}, @code{Z} and
458 @code{z}.  The new command is also backward-compatible with the original
459 @code{make-connected-path-stencil} function.  Also see
460 @file{scm/stencil.scm}.
461
462 @item
463 Context properties named in the @samp{alternativeRestores} property are
464 restored to their value at the start of the @emph{first} alternative in
465 all subsequent alternatives.
466
467 Currently the default set restores @q{current meter};
468
469 @lilypond[verbatim,fragment,quote,relative=2]
470 \time 3/4
471 \repeat volta 2 { c2 e4 | }
472 \alternative {
473   { \time 4/4 f2 d | }
474   { f2 d4 | }
475 }
476 g2. |
477 @end lilypond
478
479 @noindent
480 @q{measure position};
481
482 @lilypond[verbatim,fragment,quote,relative=2]
483 \time 3/4
484 \repeat volta 2 { c2 e4 | }
485 \alternative {
486   { \time 4/4
487     \set Timing.measurePosition = #(ly:make-moment -1/2)
488     f2 | }
489   { f2 d4 | }
490 }
491 g2. |
492 @end lilypond
493
494 @noindent
495 and @q{chord changes};
496
497 @lilypond[verbatim,fragment,quote]
498 <<
499   \new ChordNames {
500     \set chordChanges = ##t
501     \chordmode { c1:m d:m c:m d:m }
502   }
503   \new Staff {
504     \repeat volta 2 { \chordmode { c1:m } }
505     \alternative {
506       { \chordmode { d:m } }
507       { \chordmode { c:m } }
508     }
509   \chordmode { d:m }
510 }
511 >>
512 @end lilypond
513
514 @item
515 Improved MIDI output for breathe marks.  After tied notes, breaths take
516 time @emph{only} from the last note of the tie; e.g.
517 @code{@{ c4~ c8 \breathe @}} performs as @code{@{ c4~ c16 r @}} instead
518 of @code{@{ c4 r8 @}}.  This is more consistent with articulations and
519 how humans interpret breaths after ties.  It now also makes it easier to
520 align simultaneous breathe marks over multiple parts, all with different
521 note lengths.
522
523 @item
524 A new note head style for Tabulature has been added;
525 @code{TabNoteHead.style = #'slash}.
526
527 @item
528 Four new Clef glyphs have been added @emph{Double G}, @emph{Tenor G},
529 @emph{Varpercussion} and @emph{varC} and their related tessitura.
530 @lilypond[verbatim,quote,fragment]
531   \override Staff.Clef.full-size-change = ##t
532
533   \clef "GG" c c c c
534   \clef "tenorG" c c c c
535   \clef "varC" c c c c
536   \clef "altovarC" c c c c
537   \clef "tenorvarC" c c c c
538   \clef "baritonevarC" c c c c
539   \clef "varpercussion" c c c c
540
541   \break
542   \override Staff.Clef.full-size-change = ##f
543
544   \clef "GG" c c c c
545   \clef "tenorG" c c c c
546   \clef "varC" c c c c
547   \clef "altovarC" c c c c
548   \clef "tenorvarC" c c c c
549   \clef "baritonevarC" c c c
550   \clef "varpercussion" c c c c
551 @end lilypond
552
553 @item
554 Isolated durations in music sequences now stand for unpitched
555 notes.  This may be useful for specifying rhythms to music or
556 scheme functions.  When encountered in the final score, the
557 pitches are provided by the preceding note or chord.  Here are two
558 examples where this makes for readable input:
559
560 @lilypond[verbatim,quote]
561 \new DrumStaff \with { \override StaffSymbol.line-count = 1 }
562 \drummode {
563   \time 3/4
564   tambourine 8 \tuplet 3/2 { 16 16 16 }
565              8 \tuplet 3/2 { 16 16 16 } 8 8 |
566 }
567 @end lilypond
568
569 @lilypond[verbatim,quote]
570 \new Staff { r16 c'16 ~ 8 ~ 4 ~ 2 | }
571 @end lilypond
572
573 @item
574 @code{\displayLilyMusic} and its underlying Scheme functions no
575 longer omit redundant note durations.  This makes it easier to
576 reliably recognize and format standalone durations in expressions
577 like
578 @example
579 @{ c4 d4 8 @}
580 @end example
581
582 @item
583 Beaming exceptions can now be constructed using the
584 @code{\beamExceptions} scheme function.  One can now write
585
586 @lilypond[verbatim,quote,relative=1]
587 \time #'(2 1) 3/16
588 \set Timing.beamExceptions =
589   \beamExceptions { 32[ 32] 32[ 32] 32[ 32] }
590 c16 c c |
591 \repeat unfold 6 { c32 } |
592 @end lilypond
593
594 @noindent
595 with multiple exceptions separated with @code{|} bar checks
596 (writing the exception pattern without pitches is convenient but
597 not mandatory).  Previously, setting the beam exceptions would
598 have required writing
599
600 @example
601 \set Timing.beamExceptions =
602 #'(                         ;start of alist
603    (end .                   ;entry for end of beams
604     (                       ;start of alist of end points
605      ((1 . 32) . (2 2 2))   ;rule for 1/32 beams -- end each 1/16
606     )))
607 @end example
608
609 @item
610 The most common articulations are now reflected in MIDI output.
611 Accent and marcato make notes louder; staccato, staccatissimo and
612 portato make them shorter. Breath marks shorten the previous
613 note.
614
615 This behavior is customizable through the @code{midiLength} and
616 @code{midiExtraVelocity} properties on @code{ArticulationEvent}.
617 See @file{script-init.ly} for examples.
618
619 @item
620 The PostScript functionality of stroke adjustment is no longer
621 applied automatically but left to the discretion of the PostScript
622 device (by default, Ghostscript uses it for resolutions up to
623 150dpi when generating raster images).  When it is enabled, a more
624 complex drawing algorithm designed to benefit from stroke
625 adjustment is employed mostly for stems and bar lines.
626
627 Stroke adjustment can be forced by specifying the command line
628 option @samp{-dstrokeadjust} to LilyPond.  When generating
629 @code{PDF} files, this will usually result in markedly better
630 looking @code{PDF} previews but significantly larger file size.
631 Print quality at high resolutions will be unaffected.
632
633 @end itemize
634
635 @ifhtml
636 For older news, go to
637 @uref{http://lilypond.org/doc/v2.18/Documentation/changes/},
638 @uref{http://lilypond.org/doc/v2.16/Documentation/changes/},
639 or @uref{../,go back} to the Documentation index.
640
641
642 @end ifhtml
643
644 @bye