]> git.donarmstrong.com Git - lilypond.git/blob - Documentation/snippets/changing-the-default-text-font-family.ly
LSR Update
[lilypond.git] / Documentation / snippets / changing-the-default-text-font-family.ly
1 % DO NOT EDIT this file manually; it is automatically
2 % generated from Documentation/snippets/new
3 % Make any changes in Documentation/snippets/new/
4 % and then run scripts/auxiliar/makelsr.py
5 %
6 % This file is in the public domain.
7 %% Note: this file works from version 2.18.0
8 \version "2.18.0"
9
10 \header {
11   lsrtags = "text, tweaks-and-overrides"
12
13   texidoc = "
14 The default font families for text can be overridden with
15 @code{make-pango-font-tree}.
16
17 "
18   doctitle = "Changing the default text font family"
19 } % begin verbatim
20
21 \paper {
22   % change for other default global staff size.
23   myStaffSize = #20
24   %{
25      run
26          lilypond -dshow-available-fonts blabla
27      to show all fonts available in the process log.
28   %} % begin verbatim
29
30
31   #(define fonts
32     (make-pango-font-tree "Times New Roman"
33                           "Nimbus Sans,Nimbus Sans L"
34                           "Luxi Mono"
35 ;;                        "Helvetica"
36 ;;                        "Courier"
37      (/ myStaffSize 20)))
38 }
39
40 \relative c'' {
41   c4^\markup {
42     roman: foo \bold bla \italic bar \italic \bold baz
43   }
44   c'4_\markup {
45     \override #'(font-family . sans)
46     {
47       sans: foo \bold bla \italic bar \italic \bold baz
48     }
49   }
50   c'2^\markup {
51     \override #'(font-family . typewriter)
52     {
53       mono: foo \bold bla \italic bar \italic \bold baz
54     }
55   }
56 }