]> git.donarmstrong.com Git - lilypond.git/blob - Documentation/snippets/volta-text-markup-using-repeatcommands.ly
Run scripts/auxiliar/update-with-convert-ly.sh
[lilypond.git] / Documentation / snippets / volta-text-markup-using-repeatcommands.ly
1 %% DO NOT EDIT this file manually; it is automatically
2 %% generated from LSR http://lsr.dsi.unimi.it
3 %% Make any changes in LSR itself, or in Documentation/snippets/new/ ,
4 %% and then run scripts/auxiliar/makelsr.py
5 %%
6 %% This file is in the public domain.
7 \version "2.16.0"
8
9 \header {
10   lsrtags = "repeats, symbols-and-glyphs, text"
11
12   texidoc = "
13 Though volte are best specified using @code{\\repeat volta}, the
14 context property @code{repeatCommands} must be used in cases where the
15 volta text needs more advanced formatting with @code{\\markup}.
16
17
18 Since @code{repeatCommands} takes a list, the simplest method of
19 including markup is to use an identifier for the text and embed it in
20 the command list using the Scheme syntax @code{#(list (list 'volta
21 textIdentifier))}. Start- and end-repeat commands can be added as
22 separate list elements:
23
24 "
25   doctitle = "Volta text markup using repeatCommands"
26 } % begin verbatim
27
28
29 voltaAdLib = \markup { 1. 2. 3... \text \italic { ad lib. } }
30
31 \relative c'' {
32   c1
33   \set Score.repeatCommands = #(list (list 'volta voltaAdLib) 'start-repeat)
34   c4 b d e
35   \set Score.repeatCommands = #'((volta #f) (volta "4.") end-repeat)
36   f1
37   \set Score.repeatCommands = #'((volta #f))
38 }