1 \documentclass[a4paper, 12pt, oneside]{article}
3 \usepackage{t1enc,isolatin1}
5 %\usepackage{showframe}
7 \def\postMudelaExample{\normalsize}
11 Mudela-book is a script that process your \LaTeX ~file and
12 translates blocks of mudela code it finds inside \verb|mudela|
13 environment to tex or eps graphics. It then creates a new
14 file that can be sent through \LaTeX~ to create a document with
15 lines of music integrated with text.
17 So what does this look like? Well, here is a really
20 \begin{mudela}[fragment, verbatim]
21 \relative c'{c4 d e f | g2 g}
24 As you can see the mudela code is put inside a environment
25 called \verb|mudela|, shouldn't be too difficult to remember.
26 If you have never heard about \LaTeX, Mudela or that stuff
27 about environment, you should probably read some other manuals
30 The code above produces this music:
32 \begin{mudela}[fragment, floating]
33 \relative c' {c4 d e f | g2 g}
37 The parameter \verb|fragment| means that mudela-book will insert
38 some red tape for you. There are one thing to remember. Currently
39 \verb|fragment|s don't know about margins and line width, so if
40 you type more than a few bars and want a line break, you can not
41 use \verb|fragment|. The \verb|verbatim| parameter is used to
42 make mudela-book print the mudela source instead of the
43 music. The parameter will probably not be visible in later versions
46 If you use \verb|\default_paper| as your paper, mudela-book will
47 (I hope) adjust the music to reach from the left to the right margin.
49 \begin{mudela}[verbatim]
51 \notes\relative c'{c d e f | g2 g | a4 a a a | g1 |
52 f4 f f f | e2 e | d4 d d d | c1}
53 \paper{\default_paper}
59 \notes\relative c'{c d e f | g2 g | a4 a a a | g1 |
60 f4 f f f | e2 e | d4 d d d | c1}
61 \paper{\default_paper}
65 On my Debian 2.0 with LilyPond 1.0.17, teTex 0.9,
66 a4 paper and default line widht, the music is printet with
67 7 bars on the first line and 1 bars on the second.
69 This does not look to well, but you can fix it by setting
70 the \verb|linewidth| variable to, let's say 8 cm. The paper
80 \notes\relative c'{c d e f | g2 g | a4 a a a | g1 |
81 f4 f f f | e2 e | d4 d d d | c1}
87 The \verb|linewidth| variable is a LilyPond paper variable.
88 It is not spesific to mudela-book. See LilyPond tutorial and
89 reference manual for other variables.
92 \begin{mudela}[fragment, floating]
93 \relative c'{c c g' g | a a g2}
95 ~include music in the middle of your text. Just give the option
96 \verb|floating| to \verb|\begin{mudela}|
98 Oh, you think the notes are to big to be in the middle of all those
99 small characters, that something like this,
100 \begin{mudela}[fragment, floating, 11pt]
101 \relative c'{c c g' g | a a g2}
103 ~is better? If you have a lot of small music examples like this
104 in the middle of your text, you might get a nicer look by using
105 ``double'' line spacing. Put the \verb|\linespread{1.6}| command
106 into the preamble of your document. Then the line spacing will not
107 be increased between the lines where you have music printed with the
111 To change font size is easy, just give the fontsize as a parameter to
112 \verb|\begin{mudela}|. The last piece of music was created with this
114 \begin{mudela}[fragment, floating, 11pt, verbatim]
115 \relative c'{c c g' g | a a g2}
118 You can use the following font sizes:
121 \begin{mudela}[11pt, fragment, floating]
123 r16 [c d e][f d e c] [g'8 c][b-\prall c] |
124 [d16 g, a b][c a b g][d'8 g f-\prall g]
128 \begin{mudela}[13pt, fragment, floating]
130 r16 [c d e][f d e c] [g'8 c][b-\prall c] |
131 [d16 g, a b][c a b g][d'8 g f-\prall g]
135 \begin{mudela}[16pt, fragment, floating]
137 r16 [c d e][f d e c] [g'8 c][b-\prall c] |
138 [d16 g, a b][c a b g][d'8 g f-\prall g]
142 \begin{mudela}[20pt, fragment, floating]
144 r16 [c d e][f d e c] [g'8 c][b-\prall c] |
145 [d16 g, a b][c a b g][d'8 g f-\prall g]
149 \begin{mudela}[26pt, fragment, floating]
151 r16 [c d e][f d e c] [g'8 c][b-\prall c] |
152 [d16 g, a b][c a b g][d'8 g f-\prall g]
159 \begin{mudela}[11pt, fragment, floating]
160 \relative c''{\key es; r8 [g g g] es2}
163 you can see, \verb|floating| mudela don't know about margins.
164 Remember that to place the music anywhere\footnote{
166 \begin{mudela}[11pt, fragment, floating]
167 \relative c''{\key es; r8 [g g g] es2}
170 else than at the left margin you must use the option \verb|floating|.
172 \twocolumn[\Large The following is written in two columns \normalsize]
173 Sinse the version number is quite low, 0.4.0 last I checked, you
174 should be careful not to mix braces that belongs to mudela-book and
175 \LaTeX ~on the same line. The following code will probably break:
177 \verb|\footnote{\be|\verb|gin{mudela}|
179 \verb|\relative c''{ \key es; r8 [g g g] es2} |
181 \verb|\e|\verb|nd{mudela}}|
183 Mudela-book does know about \verb|\onecolumn| and \verb|\twocolumn|.
184 So the music will be adjusted to the new linewith:
185 \begin{mudela}[verbatim]
187 \notes\relative c'{c d e f | g2 g | a4 a a a | g1 |
188 f4 f f f | e2 e | d4 d d d | c1}
189 \paper{\default_paper}
195 \notes\relative c'{c d e f | g2 g | a4 a a a | g1 |
196 f4 f f f | e2 e | d4 d d d | c1}
197 \paper{\default_paper}
201 As in one column mode, \verb|fragment|s don't know about
203 \begin{mudela}[fragment]
204 \relative c'{[c8 e][d f][e g][f a] | [g b][a c][b d] c4 |
205 [e8 c][d b][c a][b g] | [a f][g e][f d] c4 }
207 Verbatim environments will also ignore the page margins. That is