]> git.donarmstrong.com Git - lilypond.git/blob - Documentation/snippets/book-parts.ly
Run scripts/auxiliar/update-with-convert-ly.sh
[lilypond.git] / Documentation / snippets / book-parts.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 = "paper-and-layout"
11
12   texidoc = "
13 @code{\\bookpart} can be used to split a book into several parts. Each
14 part last page can be affected by @code{ragged-last-bottom}. Header and
15 footer markups can detect a part last page, and make the difference
16 with the book last page.
17
18 "
19   doctitle = "Book parts"
20 } % begin verbatim
21
22
23 #(set-default-paper-size "a6")
24
25 \book {
26   %% book paper, which is inherited by all children bookparts
27   \paper {
28     ragged-last-bottom = ##t
29     %% Page footer: add a different part-tagline at part last page
30     oddFooterMarkup = \markup {
31       \column {
32         \fill-line {
33           %% Copyright header field only on book first page.
34           \on-the-fly #first-page \fromproperty #'header:copyright
35         }
36         \fill-line {
37           %% Part tagline header field only on each part last page.
38           \on-the-fly #part-last-page \fromproperty #'header:parttagline
39         }
40         \fill-line {
41           %% Tagline header field only on book last page.
42           \on-the-fly #last-page \fromproperty #'header:tagline
43         }
44       }
45     }
46   }
47
48   %% book header, which is inherited by the first bookpart
49   \header {
50     title = "Book title"
51     copyright = "Copyright line on book first page"
52     parttagline = "Part tagline"
53     tagline = "Book tagline"
54   }
55
56   \bookpart {
57     %% a different page breaking function may be used on each part
58     \paper { page-breaking = #ly:minimal-breaking }
59     \header { subtitle = "First part" }
60     \markup { The first book part }
61     \markup { a page break }
62     \pageBreak
63     \markup { first part last page }
64     \markup \wordwrap { with ragged-last-bottom (see the space below this text) }
65   }
66
67   \bookpart {
68     \header { subtitle = "Second part" }
69     { c'4 }
70   }
71
72 }