]> git.donarmstrong.com Git - lilypond.git/blob - Documentation/faq.yo
release: 1.1.42
[lilypond.git] / Documentation / faq.yo
1 article(FAQ - GNU LilyPond FAQs)()()()
2
3 DEFINEMACRO(question)(1)(subsect(ARG1))
4
5 sect(Miscellaneous)
6
7 question(HELP! I'm stuck!)
8
9 Please read this document carefully.  If you are still at loss,
10 send your questions to the bf(mailing list), and not to authors
11 directly.
12
13 Note: relative paths are meant to be relative to the source directory
14
15 sect(Installing)
16
17 question(If I install the .exe file on my DOS/windows 3.11 machine, it
18 doesn't work.)
19
20 The DOS port is done with the cygnus gnu/windows32 port of the GNU utils.
21 It does em(not) work with windows 3.x; you need Windows-NT (95/98?).  This
22 is not a recommendation, however.  We recommend you use Unix, in
23 particular, use GNU/Linux.  For further information see file(README-W32).
24
25 question(Where is guile-config)
26
27 RedHat RPMS don't include guile-config.  You need guile-config as it
28 was produced during the RPM build run.  Build the RPM from source
29 (file(.src.rpm)), and use the guile-config that is in
30 file(/usr/src/redhat/BUILD/guile-1.3/guile-config/).
31
32
33 question(I get all kinds of errors while  compiling file(parser.cc))
34
35 LilyPond uses features of bison version 1.25. Please confirm that
36 you are using a version 1.25 or better, that is bf(GNU) bison
37 bf(1.25). Don't forget to do "make clean" after installing it. Don't
38 forget to remove the stale file(bison.simple) as well.
39
40 If the problem persists, then please send a bug report to the mailing list.
41
42 question(I upgraded by applying a patch, and now my configure/build breaks.)
43
44 Patches don't include automatically generated files, i.e. 
45 file(configure) and files generated by file(configure).  Regenerate them 
46 yourself:
47 verb(
48     autoconf
49     configure
50 )
51 You might need to create some extra "out" directories.  Do this with
52 verb(
53     make outdirs
54 )
55 question(Some of your neat scripts fail, what directories do you use:)
56
57 [This only applies if you don't do code(make install), and develop out
58 of the source directory]
59
60 I have a directory which contains all our development projects
61 verb(
62     ~/usr/
63 )
64
65 which looks like file(/usr/)
66 verb(
67     bin/
68     share
69     lib/
70     share/
71     src/
72
73     etc....
74 )
75
76 The directory  file(~/usr/src/) contains something like
77 includefile(../stepmake/Documentation/layout.yo)
78 )       
79
80 ~/usr/src/bin is in the PATH, and contains symbolic links to the
81 compiled executables.
82
83 question(Is there an emacs mode?)
84
85 Yes.  It is included with the source archive as mudela-mode.el.  If
86 you have an rpm it is in /usr/doc/lilypond-X/.  You have to install it
87 yourself.
88
89 question(How do i create the file(.tfm) files?)
90
91 You don't.  The file(.tfm) files should be generated automatically by
92 Metafont when you run TeX().  Check your TeX() installation, or ask
93 your local TeX() guru.  The supplied file(.afm) files are intended to
94 be used by LilyPond, not by any other programs.
95
96
97 sect(Documentation)
98
99 question(Why is the documentation/website/etc. so lousy?)
100
101 LilyPond development is moving quite fast, documentation will often
102 lag a bit behind.  We must always make a choice between writing more
103 doco, writing more code and answering email.
104
105 If you think you can make a correction, or devised a solution that 
106 should be documented, please do so and send in a patch.
107
108 sect(Language: mudela)
109
110 question(Why can't you type code(#c) in stead of code(cis) ?)
111
112 We think that code(#c) looks as if you are entering the symbols to
113 print (which you are not; remember, you're entering the musical
114 content in Mudela)
115
116
117 question(Why do I have to type the accidentals to the note if I specified them?)
118
119 Take this example
120 verb(
121     cis cis
122 )
123 Independently of how it was written and what the current key was, you
124 would say that you are playing and reading "two C-sharp" notes.  We
125 have tried to make the language somewhat context-free.  Of course
126 sheet music is not context-free.  Unfortunately, sheet music is also 2
127 dimensional, and ASCII is not.
128
129 Technically it would be feasible to have the Interpreting phase do
130 tricky things to add (or leave out) the accidentals, but we think that
131 it is impractical: it hampers the readability and portability of your
132 source, since you need LilyPond to fill in the details and actually
133 make sense of it.
134
135
136 question(What is code(cis) anyway)
137
138 code(cis) is the dutch naming for C-sharp. The notes are named
139 a, b,.., g. The suffix -is means sharp, and -es flat. This system is
140 common in a number of languages (such as swedish, dutch, german.)
141 Certain other languages (such as English, French and Italian) just add
142 the word for "sharp" to the notename.
143
144 We chose the Dutch system, because we're dutch. You are free to chose
145 whatever names you like; they are user definable.
146
147
148 question(Why are [] around the notes, and () inbetween?)
149
150 [] designate beams, a note can only be in one beam at the same
151 time. () is a slur, which connects notes.  You need to be able to 
152 specify
153 verb(
154     a()a()a
155 )
156
157 question(I want to insert some TeX commands.)
158
159 You shouldn't: it's against LilyPond philosophy to have typesetting
160 commands in the mudela source. Moreover, this would be difficult.
161 LilyPond uses TeX like a glorified output engine: the output consists
162 of (x,y) positions and symbols.  You can only sensibly do TeX stuff in
163 the symbol string.  You can access the symbol string easily for some
164 symbols (notably lyrics and code(^"text") commands).
165
166
167 sect(Do you support ...)
168
169 question(Do you support pop songs (chords, single staff, lyrics)?)
170
171 Yes, see the file(twinkle-pop) example.
172
173
174 question(Do you support guitar chord diagrams?)
175
176 No, not yet. We ourselves don't play guitar, and don't know the
177 fine points of this notation.  We would welcome anyone who could give
178 this a try.
179
180 question(Do you support TAB notation?)
181
182 No. The same as for the previous question goes, but TAB is a lot
183 more work than diagrams (TAB needs modification of Parser, Lexer,
184 Staff, Notehead, Stem code and all the code that creates these graphic
185 elements.)
186
187 question(Do you support multiple staff-sizes?)
188
189 Yes.  At this time you can choose between 11, 13, 16, 19, 20, 23 and
190 20 pt staff-size.  Use the staffLineLeading property for setting the
191 size of the staff, and fontSize for setting the size of the glyphs.
192
193 question(Do you support Gregorian chant notation?)
194
195 No.  There is no reason why LilyPond can't be extended to do so, but
196 we haven't done it yet (and there are currently no plans to do it).
197
198 question(Do you support grace notes?)
199
200 No.  But they can kludged.  See file(input/test/grace.ly)
201
202
203 sect(How do I ....)
204
205 question(How do I change the TeX layout?)
206
207 See file(lilyponddefs.tex), it has some comments.  Or use file(ly2dvi).
208
209 question(How do I place lyrics under em(each) of the staves in a
210 score, as choral music. I can work out how to put lyrics for each line
211 all under the top line, or at the bottom but not between!)
212
213 You change the order lyrics and staves.  You have to name all
214 staves (lyric and melodic), otherwise they will end up in the same
215 staff/lyricline
216 verb(   
217         \score {
218                 < \melodic \type Staff = "treble" \trebleMelody
219                   \lyric \type Lyrics = "tlyrics" \trebtext
220                   \type Staff = "bass" \melodic \bassMelody        
221                   \lyric \type Lyrics = "blyrics" \basstext      
222                 >
223                 \paper {  }
224         }
225 )
226
227 question(How do I put more than one marking on a note.)
228
229 You can stack them 
230 verb(
231         c4^"a"^"b"
232 )
233 or use spacing-notes to put markings at different horizontal positions 
234 verb(
235         < c1
236           { s4\ff s4^"text" s4-\marcato s4 }
237         >
238 )
239 This also works for crescendi, eg,
240 verb(
241         < c1
242           { s4\< s2 \! s4 }
243         >
244 )
245
246
247 question(How do I get bar numbers?)
248
249 See file(input/test/bar-scripts.ly).
250
251
252 sect(Development)
253
254 question(Could you implement feature XXXX? It is really easy, just extend
255 the syntax to allow YYYY!)
256
257 If it is reasonable, I'll add XXXX to the TODO list. In general
258 finding a cute syntax (such as YYYY) isn't very hard. The complicated
259 issue how to adapt the internals to do XXXX. The parser is really a
260 simple front end to the complicated internals. 
261
262
263 question(Can I join in on LilyPond development?  How do I do this?)
264
265 LilyPond development is open for anyone who wants to join.  We try
266 to use a Bazaar style development model for LilyPond, see
267 lurl(http://locke.ccil.org/~esr/writings/cathedral.html.)  This means:
268 frequent releases, everyone can send in a patch or do suggestions and
269 all development discussions are public.
270
271 To be precise, discussions take place on the gnu-music-discuss mailing
272 list, which is open for subscription to everyone.
273
274
275 question(I want to implement XXXX!  Should I do this?)
276
277 There might be better ways of doing XXXX, so it's a good thing to
278 ask about this before you start hacking.  If you want to keep in touch
279 with current developments, you should subscribe to the mailing list
280 (see the "links" section of the documentation).
281
282
283 question(Is there a GUI frontend?  Should I start building one?)
284
285 LilyPond currently has no graphical interface.  The authors seriously
286 doubt if a simple-minded approach (dragging and dropping notes) is any
287 easier or quicker to use than mudela.  But for composing a graphical
288 environment probably is indispensable.
289
290 In any case email(Derek Wyatt)(wyatt@scar.utoronto.edu) is working on
291 GTK based editor, but that is still in an embryonal stage (see
292 lurl(http://harmonia.scar.utoronto.ca).  There is also a GUI package
293 RoseGarden that could be extended to output mudela.
294
295 If you want to work on this, please send e-mail to the mailing list
296 email(gnu-music-discuss@gnu.org).
297
298
299 question(I want to implement XXXX!  How should I do this?)
300
301 Your best bet of getting us to include code, is to present it as a
302 "fait accompli", i.e., to send a patch to the mailing list.
303
304
305 question(I made some code, how do I get you to include it?)
306
307 Send in a patch:
308 verb(
309         diff -urN old-file new-file > patch
310 )
311 or 
312 verb(
313         diff -urN old-directory/ new-directory/ > patch 
314 )
315 Alternatively, you can use issue the command
316 verb(
317         make diff
318 )
319
320 Don't forget to put your name and e-mail address
321 in the file(AUTHORS.pod) file, or you won't get credits :-]
322
323
324 question(How do I learn the C++ code?)
325
326 The entry point is in code(main()). Good luck. :-)
327
328 Seriously, read, reread and reread internals and CodingStyle, and
329 just start anywhere. 
330
331 Anywhere? Well, most of the comment doco are in the header files, so
332 your best bet would be code(less lily/include/*.hh). Some of the most
333 important data-structures are to be found in:
334 verb(
335         - *request.hh
336         - engraver.hh
337         - performer.hh
338         - translator.hh
339         - score-elem.hh
340         - music.hh
341         - music-list.hh
342         - music-iterator.hh
343         - item.hh
344         - spanner.hh
345 )
346
347 question(Why GPL?)
348
349 Yes.
350
351
352 question(Your make system does not adhere to GNU coding standards, could you
353 please fix it?)
354
355 No.  We have evaluated the standard GNU combination for compiling
356 programs (autoconf, automake, libtool) and found to be inadequate in
357 several respects.  More detailed argumentation is included with
358 LilyPond's generic make package code(StepMake) 
359 (see file(stepmake-x.x.x/Documentation/automake.urgh))
360
361 LilyPond already compiles into a different directory ((the different
362 directory is called out/, there is one in every source directory).
363 make distclean essentially reduces to file(rm -f out/*) in every directory
364
365 question(gdb crashes when I debug!)
366
367 Upgrade to 4.17.
368
369 question(Why do I need g++ >= 2.8 / EGCS-1.1 ?)
370
371 Supporting more compilers than EGCS/G++ 2.8 is unlikely to make
372 LilyPond run on more platforms.  It would give us an enormous headache
373 in detecting and catering for every variant of every compiler: not
374 having to support other compilers saves us a em(lot) of trouble.
375
376
377 sect(Running)
378
379
380 question(I use dvilj4, and there are lots of warning messages for the
381 printing)
382
383 You should use dvips and ghostscript to print the code(dvi) output:
384 the slurs and beams are PS code(\special) commands.
385
386
387 question(My symbols are all messed up after I upgraded, I get the
388 wrong symbols and dvi-checksum errors!)
389
390 We obviously mucked with the fonts in the upgrade.  Remove em(all)
391 previous fonts, including the file(.pk) and file(.tfm) fonts in
392 file(/var/lib/texmf).  A script automating this has been included, see
393 file(buildscripts/clean-fonts.sh).
394
395 question(all the pk and tfm
396 fonts are created in the directory where the mudela file is, not in
397 "/var/spool/texmf" where I think they should be.)
398
399 Mats Bengtsson <mats.bengtsson@s3.kth.se> writes:
400
401 The simple solution used by Anthony Fok in the Debian distribution of
402 Lilypond is to link the mf/ directory to
403 /usr/lib/texmf/fonts/source/public/lilypond Depending on what
404 distribution of teTeX and Linux you have installed, there might also
405 be other places like /usr/local/lib/texmf/fonts/source/public/lilypond
406 or /var/spool/texmf//fonts/source/public/lilypond
407
408 Wherever you put it, don't forget to run mktexlsr (or texhash for
409 older installations) afterwards, so that TeX will find the files.
410 Also, don't forget to remove all old .tfm and .*pk files when the font
411 is updated (as it will be in version 1.1.40, for example).
412
413 question(How does PS output work?)
414
415 itemize(
416  it()
417 Generate the PostScript Type-3 fonts. In the file(mf/) 
418 subdirectory, issue:
419 verb(
420         make pfa
421 ) in the mf/ subdirectory.  This will also  make file(mfplain) for metapost.
422 it()
423 Run lilypond with option tt(-f ps):
424 verb(
425     lilypond -fps foo.ly
426 )
427 it() To view the file(.ps) output with GhostView, set GS_FONTPATH to the 
428 directory containing the file(pfa)s, and set GS_LIB to the directory containing the file(.ps) library files of LilyPond.  In the source tree, these are file(mf/out/) and file(ps/).
429
430
431 i.e. do something like:
432 verb(
433    export GS_FONTPATH=$HOME/usr/src/lilypond/mf/out
434    export GS_LIB=$HOME/usr/src/lilypond/ps
435    gv foo.ps &
436 )
437 )
438
439 Direct PS output is still experimental.  For creating nice looking ps 
440 output, use TeX() and code(dvips).
441
442   
443 question(The beams and slurs are gone if use the XDvi magnifying glass!?)
444
445 The beams and slurs are done in PostScript.  XDvi doesn't show
446 PostScript in the magnifying glass.  Complain to the XDvi maintainers.
447
448
449 question(I don't get midi-output, even if I use bf(-M)!)
450
451 Your \score should include a \midi block, eg.
452 verb(
453         \score {
454                 \melodic { c4 c g g }
455                 \paper {}       
456                 \midi {
457                         output = "myfile.midi";
458                         \tempo 4=70;
459                 }
460         }
461 )
462 The bf(-M) option was added to LilyPond because processing the \paper
463 block is so slow.
464
465 question(A lot of musical stuff doesn't make it to the MIDI file, eg.
466 dynamics, articulation, etc.)
467
468 The MIDI output was originally put in as a proof that MIDI could be
469 done, and as a method of proof"reading" the input.  The MIDI support
470 is by no means finished.  Patches appreciated.
471
472
473 sect(Copyright)
474
475 question(How does copyright for sheet music work? Can I enter and
476 spread my newly bought Bach urtext?)
477
478 Silas S. Brown <ssb22@hermes.cam.ac.uk>:
479
480 There are several aspects to sheet music copyright:
481
482 1.  The music itself - copyright for the composer's life plus 70 years (so
483 not applicable to Bach).
484
485 2.  If the music is an arrangement, then the arranger holds copyright on
486 that arrangement.  However, you can produce your own arrangement using
487 that arrangement as a reference point.  Obviously your arrangement must be
488 sufficently different to be called your own arrangement - you need to do
489 more than change one note!
490
491 3.  In some countries, the same applies for editions.  This could be
492 relevant to the Bach example.  If a modern person has edited the music,
493 then they hold the copyright on the edition.  This does not stop you from
494 removing the editorial features - remove all editorial slurs, phrasemarks,
495 ornaments etc and only leave those that you know to be original.  You can
496 then add some of your own if you want to be your own editor.
497
498 4.  If there are lyrics, then the lyricist also holds copyright.  This
499 does not stop you from using the music without the lyrics if it is
500 otherwise out of copyright.
501
502 5.  The copyright of the printed page is held by the publisher for 30
503 years after printing (25 in some countries).  This stops you from
504 photocopying (unless it's "fair use" eg. you're partially sighted and need
505 to enlarge the music) or otherwise reproducing the typesetting that is
506 used on it.  But the copyright is only held over the typesetting work, not
507 the music itself.  Since Mudela specifies the notes, independently of any
508 typesetting work that went into your reference copy, you are not
509 duplicating any of the publisher's work.
510
511 6.  If you want to violate copyright, there are two main cases where you
512 may do so: fair use, and with permission.  The former is rather fuzzily
513 defined, but it includes such things as including small extracts of a
514 score in a critique, and making a large print or Braille copy for a blind
515 or partially-sighted performer (many people argue that in this case it
516 should always be kept with the original copy and/or destroyed after it is
517 no longer needed).  The latter is obvious: You can always write to the
518 composer, arranger, editor, lyricist or publisher in question and ask if
519 you can do whatever it is you're trying to do.  Some will respond more
520 readily than others, but anything that they say will override any copying 
521 restrictions imposed on you.
522
523
524 References - best one I know is the UK-based Performing Right Society,
525 lurl(http://www.prs.co.uk/) (especially "membership") and their links to other
526 international equivalents.  
527
528
529
530 Juergen Reuter <reuterj@ira.uka.de>:
531
532 [More information can be had at: ]
533
534 lurl(http://lcweb.loc.gov/copyright/)
535 (USA copyright law)
536
537 lurl(http://fairuse.stanford.edu/)
538 (meta site about copyright with many links to other resources)
539
540 lurl(http://host.mpa.org/crc.html)
541 (copyright from the viewpoint of the USA music publishers' association)
542
543 lurl(http://www.wipo.int)
544 (World Intellectual Property Organization (a UNO agency); with
545 information about international copyright)
546
547
548 John Sankey:
549
550 See lurl(http://www.geocities.com/Vienna/Studio/1714/harpsichord.html)
551 for a summary of copyright relative to old music, also for the
552 expert forum for such questions.
553
554 Werner Lemberg <sx0005@sx2.HRZ.Uni-Dortmund.DE>:
555
556 This is not correct.  Urtext editions per se are em(not) copyrighted
557 -- if you print exactly what the composer has written, how can there
558 some copyright be added?  Copyrighted are usually only the `Critical
559 notes', the foreword, and the cadenzas some editors have added.
560
561 This means that the `Photocopying forbidden' sign in many scores is
562 not always correct for e.g. J.S. Bach -- you are allowed to copy the
563 pages which don't contain editorial stuff which is probably
564 copyrighted.
565
566 A very unfortunate situation for the publishers.
567
568
569
570 sect(Windows32)
571
572 question(I downloaded the windows32 port, and it doesn't match the website!)
573
574 The website is usually made from the latest snapshots.  Binary releases,
575 in particular the windows32 binaries, are only made every once in a while.
576 They may lag several versions behind the latest version. 
577
578 question(But i want a native DOS/Windows-NT/95 port)
579
580 Reconsider.  Try Linux.  It's fun!
581