From: Han-Wen Nienhuys Date: Mon, 2 Feb 1998 11:05:04 +0000 (+0100) Subject: release: 0.1.43 X-Git-Tag: release/0.1.43 X-Git-Url: https://git.donarmstrong.com/?a=commitdiff_plain;h=5e47fbe9f5a8e10458a9d737d1c35cff2eae6791;p=lilypond.git release: 0.1.43 --- diff --git a/AUTHORS.text b/AUTHORS.text deleted file mode 100644 index b2cc8a8a41..0000000000 --- a/AUTHORS.text +++ /dev/null @@ -1,132 +0,0 @@ - - - -AUTHORS(1) LilyPond documentation AUTHORS(1) - - -NNNNAAAAMMMMEEEE - AUTHORS - who did what on GNU LilyPond? - -DDDDEEEESSSSCCCCRRRRIIIIPPPPTTTTIIIIOOOONNNN - This file lists authors of GNU LilyPond, and what they - wrote. - -AAAAUUUUTTTTHHHHOOOORRRRSSSS - +o Han-Wen Nienhuys , - http://www.stack.nl/~hanwen - - Main author. - - +o Jan Nieuwenhuizen , - http://www.digicash.com/~jan - Main author - -CCCCOOOONNNNTTTTRRRRIIIIBBBBUUUUTTTTOOOORRRRSSSS - +o Mats Bengtsson , parts of clef- - reg.cc, clef-item.cc swedish notenames, testing, - general comments, duration logs/longa/brevis etc - - +o Jan Arne Fagertun , - TeX titling and lytodvi.sh - - +o Shay Rojanski - Some mudela source. - - +o Werner Lemberg , - misc bugfixes, some Beam and Stem code. - - +o Donald Ervin Knuth, http://www.cs.stanford.edu/~? - mf/ital-*.mf (these were taken from the CM fonts) - - +o Alexandre Oliva , - http://sunsite.unicamp.br/? - testing - - +o Anthony Fok , - debian package: debian/* - - +o Franc,ois Pinard , - Documentation/Vocab*, internationalization stuff - - +o Neil Jerram . - Documentation/Vocab* - - +o David R. Linn , - Mailing list maintenance. - - Your name could be here! If you want to help, then take a - look at the SMALLISH PROJECTS section of in the file _T_O_D_O. - Some do not involve coding C++ - - - - -5/Jan/98 LilyPond 0.1.42 1 - - - - - -AUTHORS(1) LilyPond documentation AUTHORS(1) - - - [And of course we sincerely thank J.S.Bach, F.Schubert, T. - Merula and W.A.Mozart for their beautiful music] - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -5/Jan/98 LilyPond 0.1.42 2 - - diff --git a/AUTHORS.txt b/AUTHORS.txt new file mode 100644 index 0000000000..05b01d95ed --- /dev/null +++ b/AUTHORS.txt @@ -0,0 +1,132 @@ + + + +AUTHORS(1) LilyPond documentation AUTHORS(1) + + +NAME + AUTHORS - who did what on GNU LilyPond? + +DESCRIPTION + This file lists authors of GNU LilyPond, and what they + wrote. + +AUTHORS + o Han-Wen Nienhuys , + http://www.stack.nl/~hanwen + Main author. + + o Jan Nieuwenhuizen , + http://www.digicash.com/~jan + Main author + +CONTRIBUTORS + o Mats Bengtsson , + parts of clef-reg.cc, clef-item.cc swedish notenames, + testing, general comments, duration logs/longa/brevis + etc + + o Jan Arne Fagertun , + TeX titling and lytodvi.sh + + o Shay Rojanski + Some mudela source. + + o Werner Lemberg , + misc bugfixes, some Beam and Stem code. + + o Donald Ervin Knuth, http://www.cs.stanford.edu/~? + mf/ital-*.mf (these were taken from the CM fonts) + + o Alexandre Oliva , + http://sunsite.unicamp.br/? + testing + + o Anthony Fok , + debian package: debian/* + + o Franc,ois Pinard , + Documentation/Vocab*, internationalization stuff + + o Neil Jerram . + Documentation/Vocab* + + o David R. Linn , + Mailing list maintenance. + + Your name could be here! If you want to help, then take a + look at the SMALLISH PROJECTS section of in the file TODO. + Some do not involve coding C++ + + + + +2/Feb/98 LilyPond 0.1.43 1 + + + + + +AUTHORS(1) LilyPond documentation AUTHORS(1) + + + [And of course we sincerely thank J.S.Bach, F.Schubert, T. + Merula and W.A.Mozart for their beautiful music] + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +2/Feb/98 LilyPond 0.1.43 2 + + diff --git a/Documentation/AUTHORS.pod b/Documentation/AUTHORS.pod index e922f5c3d3..ef6370c88a 100644 --- a/Documentation/AUTHORS.pod +++ b/Documentation/AUTHORS.pod @@ -10,9 +10,7 @@ This file lists authors of GNU LilyPond, and what they wrote. =over 4 -=item * - -Han-Wen Nienhuys , http://www.stack.nl/~hanwen +=item * Han-Wen Nienhuys , http://www.stack.nl/~hanwen Main author. @@ -26,11 +24,10 @@ Main author =over 4 -=item * +=item * Mats Bengtsson , -Mats Bengtsson , parts of clef-reg.cc, clef-item.cc -swedish notenames, testing, general comments, duration -logs/longa/brevis etc +parts of clef-reg.cc, clef-item.cc swedish notenames, testing, general +comments, duration logs/longa/brevis etc =item * Jan Arne Fagertun , diff --git a/Documentation/INSTALL.pod b/Documentation/INSTALL.pod index bca2cc23f9..d724945a9a 100644 --- a/Documentation/INSTALL.pod +++ b/Documentation/INSTALL.pod @@ -24,8 +24,8 @@ For compilation you need. =item * -A GNU system: GNU LilyPond is known to run on these GNU systems: -Linux, FreeBSD, AIX, Digital Unix and Solaris. +A GNU system: GNU LilyPond is known to run on these GNU systems: Linux +(PPC, intel), FreeBSD, AIX, NeXTStep, Digital Unix and Solaris. If you have the Cygnus WINDOWS32 port of the GNU utils, it will even work in Windows NT/95, but we don't promise to support it. diff --git a/Documentation/Makefile b/Documentation/Makefile index 132c161c0b..48df92b09d 100644 --- a/Documentation/Makefile +++ b/Documentation/Makefile @@ -23,7 +23,7 @@ include ./Rules.make # DOCFILES = $(wildcard *.doc) OUTPODFILES = $(addprefix $(outdir)/,$(PODFILES)) -TEXTFILES = $(OUTPODFILES:.pod=.text) +TEXTFILES = $(OUTPODFILES:.pod=.txt) GROFFFILES = $(OUTPODFILES:.pod=.1) HTMLFILES = $(OUTPODFILES:.pod=.html) DVIFILES = $(addprefix $(outdir)/, $(DOCFILES:.doc=.dvi)) @@ -58,9 +58,9 @@ include $(depth)/make/Rules.make # localclean: - rm -f $(TEXTFILES) $(HTMLFILES) $(GROFFFILES) - rm -f $(outdir)/* # clean the make-website stuff - rm -f $(outdir)/docxx/* # clean the make-website stuff + rm -f `find $(outdir)` + + MAN1FILES = lilypond convert-mudela mi2mu mudela-book MAN1GROFF = $(addprefix $(outdir)/, $(addsuffix .1,$(MAN1FILES))) diff --git a/Documentation/Rules.make b/Documentation/Rules.make index eac8dfc8f2..88ab6fb34a 100644 --- a/Documentation/Rules.make +++ b/Documentation/Rules.make @@ -1,7 +1,7 @@ # special rules for the documentation section. # There are too many to add to the general rules -.SUFFIXES: .pod .text .1 .html +.SUFFIXES: .pod .txt .1 .html $(outdir)/%.gif: %.xpm @@ -18,10 +18,10 @@ $(outdir)/%.dvi: $(outdir)/%.mudtex $(outdir)/%.mudtex: %.doc $(binout)/mudela-book --outdir=$(outdir)/ --outname=$(notdir $@) $< -$(outdir)/%.text: $(outdir)/%.1 - groff -man -Tascii $< > $@ +$(outdir)/%.txt: $(outdir)/%.1 + troff -man -Tascii $< | grotty -b -u -o > $@ -$(depth)/%.text: $(outdir)/%.text +$(depth)/%.txt: $(outdir)/%.txt cp $< $@ do_pod2html=$(pod2html) $< diff --git a/Documentation/index.pod b/Documentation/index.pod index 595170662b..865b5e2dcf 100644 --- a/Documentation/index.pod +++ b/Documentation/index.pod @@ -29,12 +29,20 @@ and the ftp site. =head2 Examples - -examples of what LilyPond can do: MIDI, PS, .gif and input. +short examples of what LilyPond can do: MIDI, PS, .gif and input. + +examples of what LilyPond can do +with real music: MIDI, PS, .gif and input + + + =head2 NEWS! This is what the latest version brings: diff --git a/Documentation/links.pod b/Documentation/links.pod index 80757ffed3..5caa99294d 100644 --- a/Documentation/links.pod +++ b/Documentation/links.pod @@ -25,6 +25,10 @@ LilyPond sources. An enormous collection of music related URLs +=item http://www.ram.org/ramblings/philosophy/fmp.html + +Musings on free music, plus hints how to record your own (free) music. + =back =head2 Ftp @@ -88,9 +92,11 @@ mailing list have been setup: A moderated list for information on the GNU Music project, to subscribe: send mail with subject "subscribe" to -info-gnu-music-request@gnu.org. As this list is moderated, normal -people should ask to drl@gnu.org or hanwen@stack.nl to forward -announces instead of sending it to info-gnu-music@gnu.org +info-gnu-music-request@gnu.org. + +As this list is moderated, normal people should ask to drl@gnu.org or +hanwen@stack.nl to forward announces instead of sending it to +info-gnu-music@gnu.org =item help-gnu-music@gnu.org diff --git a/INSTALL.text b/INSTALL.text deleted file mode 100644 index 53587f1d31..0000000000 --- a/INSTALL.text +++ /dev/null @@ -1,396 +0,0 @@ - - - -INSTALL(1) LilyPond documentation INSTALL(1) - - -NNNNAAAAMMMMEEEE - INSTALL - installing GNU LilyPond - -DDDDEEEESSSSCCCCRRRRIIIIPPPPTTTTIIIIOOOONNNN - This page documents installation and compilation of GNU - LilyPond - -AAAABBBBSSSSTTTTRRRRAAAACCCCTTTT - You do something which looks remotely like - - configure - make - make install - - The detailed instructions follow here. - -PPPPRRRREEEERRRREEEEQQQQUUUUIIIISSSSIIIITTTTEEEESSSS - For compilation you need. - - +o A GNU system: GNU LilyPond is known to run on these - GNU systems: Linux, FreeBSD, AIX, Digital Unix and - Solaris. - - If you have the Cygnus WINDOWS32 port of the GNU - utils, it will even work in Windows NT/95, but we - don't promise to support it. - - +o GNU C++ v2.7 or better, with libg++ installed. - Version 2.7.2 or better recommended. - - +o GNU make. - - +o Flex (2.5.1 or better). - - +o Bison. (Version 1.25 or better) - -RRRRUUUUNNNNNNNNIIIINNNNGGGG - GNU LilyPond does use a lot of resources. For operation - you need the following: - - +o TeX - - +o A PostScript printer and/or viewer (such as - Ghostscript) is strongly recommended. Xdvi will show - all embedded PostScript too if you have Ghostscript - installed. - -RRRREEEECCCCOOOOMMMMMMMMEEEENNNNDDDDEEEEDDDD - Although not strictly necessary, these are recommended to - have. - - +o Perl-5. Most documentation was created with the - perl's Plain Old Documentation. (I use 5.003) - - - - -11/Jan/98 LilyPond 0.1.42 1 - - - - - -INSTALL(1) LilyPond documentation INSTALL(1) - - - +o Python. Although perl is nice, python is better. We - will shift towards python for build scripts - - +o GNU find - - +o A fast computer (a full page of music typically takes - 1 minute on my 486/133, using the --------eeeennnnaaaabbbblllleeee----cccchhhheeeecccckkkkiiiinnnngggg - compile. It's lot slower than most MusiXTeX - preprocessors) - -CCCCOOOONNNNFFFFIIIIGGGGUUUURRRRIIIINNNNGGGG aaaannnndddd CCCCOOOOMMMMPPPPIIIILLLLIIIINNNNGGGG - to install GNU LilyPond, simply type: - - configure - make install - - This will install the following files: - - /usr/local/man/man1/mi2mu.1 - /usr/local/man/man1/convert-mudela.1 - /usr/local/man/man1/mudela-book.1 - /usr/local/man/man1/lilypond.1 - /usr/local/lib/libflower.{so,a} - /usr/local/bin/lilypond - /usr/local/bin/mi2mu - /usr/local/share/lilypond/* - /usr/lib/texmf/texmf/tex/lilypond/* - - The TeX include directory is detected dynamically, but it - can be adjusted with --------eeeennnnaaaabbbblllleeee----tttteeeexxxx----pppprrrreeeeffffiiiixxxx and --------eeeennnnaaaabbbblllleeee----tttteeeexxxx---- - ddddiiiirrrr. The above assumes that you are root and have the GNU - development tools, and your make is GNU make. If this is - not the case, you can adjust your environment variables to - your taste: - - export CPPFLAGS="-I /home/me/my_include -DWEIRD_FOOBAR" - configure - - CPPFLAGS are the preprocessor flags. - - the configure script is Cygnus configure, and it will - accept --------hhhheeeellllpppp. If you are not root, you will probably have - to make it with - - configure --prefix=/home/me_myself_and_I/ - - In this case, you will have to set MFINPUTS, and TEXINPUTS - accordingly. - - If you want to install GNU LilyPond in _/_u_s_r_/_l_o_c_a_l, and - your TeX has no default hooks for local stuff (mine is - broken too), you can do: - - configure --prefix=/usr/local --enable-tex-prefix=/usr/lib/texmf - - - -11/Jan/98 LilyPond 0.1.42 2 - - - - - -INSTALL(1) LilyPond documentation INSTALL(1) - - - Since GNU LilyPond currently is beta, you are advised to - also use - - --enable-debugging - --enable-checking - - other options include: - - --------eeeennnnaaaabbbblllleeee----sssshhhhaaaarrrreeeedddd - Make a shared library (gnu/linux, solaris (?) only ) - - --------eeeennnnaaaabbbblllleeee----pppprrrriiiinnnnttttiiiinnnngggg - Enable debugging print routines (lilypond ----dddd option) - - --------eeeennnnaaaabbbblllleeee----ooooppppttttiiiimmmmiiiisssseeee - Set maximum optimisation: compile with ----OOOO2222 - - --------eeeennnnaaaabbbblllleeee----pppprrrrooooffffiiiilllliiiinnnngggg - Compile with support for profiling - - --------eeeennnnaaaabbbblllleeee----tttteeeexxxx----pppprrrreeeeffffiiiixxxx - Set the directory where TeX and Metafont live - - --------eeeennnnaaaabbbblllleeee----tttteeeexxxx----ddddiiiirrrr - Set then directory TeX input is in (detected as a - subdir of tex-prefix) - - --------eeeennnnaaaabbbblllleeee----mmmmffff----ddddiiiirrrr - Set the directory mf input is in (idem) - - --------eeeennnnaaaabbbblllleeee----oooouuuutttt----ddddiiiirrrr - Set the directory for machine generated output. - - All options are documented in the _c_o_n_f_i_g_u_r_e help The - option --------eeeennnnaaaabbbblllleeee----ooooppppttttiiiimmmmiiiisssseeee is recommended for Real Life - usage. - - If you do - - make all - - everything will be compiled, but nothing will be - installed. The resulting binaries can be found in the - subdirectories _o_u_t_/ (which contain all files generated - during compilation). - - BBBBuuuuiiiillllddddiiiinnnngggg ffffoooorrrr mmmmuuuullllttttiiiipppplllleeee hhhhoooossssttttssss - - LilyPond does not follow the GNU standards when it comes - to configuring and making Makefiles. In LilyPond, _m_a_k_e - generates _a_l_l output in output directories (called _o_u_t_/, - by default). You can have multiple compiles from the same - source-tree, by overriding the setting for the output - directory. - - - -11/Jan/98 LilyPond 0.1.42 3 - - - - - -INSTALL(1) LilyPond documentation INSTALL(1) - - - Example: on my system, I do debugging and lots compiling. - For this I use the configuration as follows: - - configure --prefix=~ --enable-debugging --enable-printing --enable-checking - make all - - and I want to do profiling. For that I use - - configure --prefix=~ --enable-debugging --disable-printing\ - --disable-checking --enable-profiling --enable-optimise\ - --enable-out-dir=out-profile - - make OUTDIR_NAME=out-profile all - - These two commands build two entirely separate versions of - LilyPond. In Real Life, you would probably also want to - have two different prefixes. On my machine this is no - problem; I never do make install. My prefix dirs are - linked back to my source directory. - -IIIINNNNSSSSTTTTAAAALLLLLLLLIIIINNNNGGGG - If you have done a successful make, then a simple - - make install - - should do the trick. - - If you are doing an upgrade, please remember to remove - obsolete .pk and .tfm files of the fonts. A script has - been provided to do the work, see _b_i_n_/_c_l_e_a_n_-_f_o_n_t_s_._s_h. - -CCCCAAAAVVVVEEEEAAAATTTTSSSS - +o The -O2 option to gcc triggers a gcc bug on DEC Alpha - in dstream.cc. You should turn off this flag for this - file. - - +o Perl5.003 and Perl5.004 use different syntax for - pod2html. - -EEEEXXXXAAAAMMMMPPPPLLLLEEEE - This is what I type in my xterm: - - lilypond someinput.ly - tex someinput.tex - xdvi someinput& - - This is what the output looks like over here: - - - - - - - - - - -11/Jan/98 LilyPond 0.1.42 4 - - - - - -INSTALL(1) LilyPond documentation INSTALL(1) - - - GNU LilyPond 0.0.78 #4/FlowerLib 1.1.24 #0 - Parsing ... [/home/hw/share/lilypond/init// - <..etc..> - init//performer.ly]]][input/kortjakje.ly] - Creating elements ...[8][16][24][25] - Preprocessing elements... - Calculating column positions ... [14][25] - Postprocessing elements... - TeX output to someinput.tex ... - Creating MIDI elements ...MIDI output to someinput.midi ... - - hw:~/musix/spacer$ xdvi someinput& - [1] 855 - - Check out the input files, some of them have comments - Please refer to the man page for more information. - -RRRREEEEDDDDHHHHAAAATTTT LLLLIIIINNNNUUUUXXXX - RedHat Linux users should be able to get a RPM. A spec - file is in _m_a_k_e_/_o_u_t_/_l_i_l_y_p_o_n_d_._s_p_e_c. You should be able to - create an rpm as a normal user. Be sure you have a - _~_/_._r_p_m_r_c, and edit the RPM-dir in _V_a_r_i_a_b_l_e_s_._m_a_k_e. (If you - create the RPM as a normal user the permissions will not - be set correctly, unfortunately) - -DDDDEEEEBBBBIIIIAAAANNNN GGGGNNNNUUUU////LLLLIIIINNNNUUUUXXXX - A Debian package is also available; contact Anthony Fok - . The build scripts are in the - subdirectory debian/ - -WWWWIIIINNNNDDDDOOOOWWWWSSSS NNNNTTTT////99995555 - So, you're stuck with Windows, eh? Well, don't worry, you - just need (to get) Cygnus' windows32 port of gnu - development stuff; have a look at - http://www.cygnus.com/gnu-win32. - - To make GNU LilyPond under, brr, aargh, shudder... - windows32, well, simply type: - - bash configure - make - - NNNNooootttteeee If you rely on broken DOS/Windows tools such as - pkzip/WinZIP to unpack the distribution, make sure the - eeeennnnttttiiiirrrreeee source tree is unpacked correctly, in particular - the empty out directories (_f_l_o_w_e_r_/_o_u_t, _l_i_b_/_o_u_t et. al.) - -MMMMUUUUSSSSIIIIXXXXTTTTEEEEXXXX - Previous versions (before 0.1.39) used fonts from the TeX - macro package "MusixTeX". You can still use these, but - they are not supported. Since LilyPond's Feta font is - much prettier, you'd be seriously misguided if you used - them, but anyway, here are the installation instructions - for those deprecated fonts. - - - -11/Jan/98 LilyPond 0.1.42 5 - - - - - -INSTALL(1) LilyPond documentation INSTALL(1) - - - [obsolete] I use the MusixTeX fonts those found in - MusixTeX T.73. Beware, the clef symbol seems to have - changed its position in some versions, (notably Egler's, - a.k.a. OpusTeX). The MusixTeX fonts are included in - MusixTeX (T73 or better), which can be had from any CTAN - site, e.g. at - - ftp://ftp.shsu.edu/tex-archive/macros/musixtex/taupin - - ftp://ftp.tex.ac.uk/tex-archive/macros/musixtex/taupin - - ftp://ftp.dante.de/tex-archive/macros/musixtex/taupin - - You only need the contents of the _m_f_/ subdirectory of the - package. The primary site of the Taupin version is - ftp://hprib.lps.u-psud.fr/pub/music_zips/musixtex.zip - - Install the musixtex fonts in a directory which TeX and MF - knows (if you are root, look for a directory which - contains the directories with AMS and CM source (*.mf) - files. Create a subdir lilypond or musixtex and copy the - fonts into that). Do not forget to rehash TeX (if - applicable) - - Example: my fonts are in - _/_u_s_r_/_l_o_c_a_l_/_l_i_b_/_t_e_x_f_o_n_t_s_/_m_u_s_i_x_t_e_x_/, and I have a symlink - pointing to that in - _/_u_s_r_/_l_i_b_/_t_e_x_m_f_/_t_e_x_m_f_/_f_o_n_t_s_/_s_o_u_r_c_e_/_p_u_b_l_i_c_/. After I copied - the files, I ran "texhash" - - Andreas Egler's version of MusixTeX, now called OpusTeX, - will also work. Andreas moved some characters around in - the fonts, so you have to edit the definitions in - _t_e_x_/_e_g_l_e_r_d_e_f_s_._t_e_x. - -AAAAUUUUTTTTHHHHOOOORRRRSSSS - Han-Wen Nienhuys - - Jan Nieuwenhuizen - - Have fun! - - - - - - - - - - - - - - - - -11/Jan/98 LilyPond 0.1.42 6 - - diff --git a/INSTALL.txt b/INSTALL.txt new file mode 100644 index 0000000000..4e5b681528 --- /dev/null +++ b/INSTALL.txt @@ -0,0 +1,396 @@ + + + +INSTALL(1) LilyPond documentation INSTALL(1) + + +NAME + INSTALL - installing GNU LilyPond + +DESCRIPTION + This page documents installation and compilation of GNU + LilyPond + +ABSTRACT + You do something which looks remotely like + + configure + make + make install + + The detailed instructions follow here. + +PREREQUISITES + For compilation you need. + + o A GNU system: GNU LilyPond is known to run on these + GNU systems: Linux (PPC, intel), FreeBSD, AIX, + NeXTStep, Digital Unix and Solaris. + + If you have the Cygnus WINDOWS32 port of the GNU + utils, it will even work in Windows NT/95, but we + don't promise to support it. + + o GNU C++ v2.7 or better, with libg++ installed. + Version 2.7.2 or better recommended. + + o GNU make. + + o Flex (2.5.1 or better). + + o Bison. (Version 1.25 or better) + +RUNNING + GNU LilyPond does use a lot of resources. For operation + you need the following: + + o TeX + + o A PostScript printer and/or viewer (such as + Ghostscript) is strongly recommended. Xdvi will show + all embedded PostScript too if you have Ghostscript + installed. + +RECOMMENDED + Although not strictly necessary, these are recommended to + have. + + o Perl-5. Most documentation was created with the + perl's Plain Old Documentation. (I use 5.003) + + + + +2/Feb/98 LilyPond 0.1.43 1 + + + + + +INSTALL(1) LilyPond documentation INSTALL(1) + + + o Python. Although perl is nice, python is better. We + will shift towards python for build scripts + + o GNU find + + o A fast computer (a full page of music typically takes + 1 minute on my 486/133, using the --enable-checking + compile. It's lot slower than most MusiXTeX + preprocessors) + +CONFIGURING and COMPILING + to install GNU LilyPond, simply type: + + configure + make install + + This will install the following files: + + /usr/local/man/man1/mi2mu.1 + /usr/local/man/man1/convert-mudela.1 + /usr/local/man/man1/mudela-book.1 + /usr/local/man/man1/lilypond.1 + /usr/local/lib/libflower.{so,a} + /usr/local/bin/lilypond + /usr/local/bin/mi2mu + /usr/local/share/lilypond/* + /usr/lib/texmf/texmf/tex/lilypond/* + + The TeX include directory is detected dynamically, but it + can be adjusted with --enable-tex-prefix and --enable-tex- + dir. The above assumes that you are root and have the GNU + development tools, and your make is GNU make. If this is + not the case, you can adjust your environment variables to + your taste: + + export CPPFLAGS="-I /home/me/my_include -DWEIRD_FOOBAR" + configure + + CPPFLAGS are the preprocessor flags. + + the configure script is Cygnus configure, and it will + accept --help. If you are not root, you will probably have + to make it with + + configure --prefix=/home/me_myself_and_I/ + + In this case, you will have to set MFINPUTS, and TEXINPUTS + accordingly. + + If you want to install GNU LilyPond in /usr/local, and + your TeX has no default hooks for local stuff (mine is + broken too), you can do: + + configure --prefix=/usr/local --enable-tex-prefix=/usr/lib/texmf + + + +2/Feb/98 LilyPond 0.1.43 2 + + + + + +INSTALL(1) LilyPond documentation INSTALL(1) + + + Since GNU LilyPond currently is beta, you are advised to + also use + + --enable-debugging + --enable-checking + + other options include: + + --enable-shared + Make a shared library (gnu/linux, solaris (?) only ) + + --enable-printing + Enable debugging print routines (lilypond -d option) + + --enable-optimise + Set maximum optimisation: compile with -O2 + + --enable-profiling + Compile with support for profiling + + --enable-tex-prefix + Set the directory where TeX and Metafont live + + --enable-tex-dir + Set then directory TeX input is in (detected as a + subdir of tex-prefix) + + --enable-mf-dir + Set the directory mf input is in (idem) + + --enable-out-dir + Set the directory for machine generated output. + + All options are documented in the configure help The + option --enable-optimise is recommended for Real Life + usage. + + If you do + + make all + + everything will be compiled, but nothing will be + installed. The resulting binaries can be found in the + subdirectories out/ (which contain all files generated + during compilation). + + Building for multiple hosts + + LilyPond does not follow the GNU standards when it comes + to configuring and making Makefiles. In LilyPond, make + generates all output in output directories (called out/, + by default). You can have multiple compiles from the same + source-tree, by overriding the setting for the output + directory. + + + +2/Feb/98 LilyPond 0.1.43 3 + + + + + +INSTALL(1) LilyPond documentation INSTALL(1) + + + Example: on my system, I do debugging and lots compiling. + For this I use the configuration as follows: + + configure --prefix=~ --enable-debugging --enable-printing --enable-checking + make all + + and I want to do profiling. For that I use + + configure --prefix=~ --enable-debugging --disable-printing\ + --disable-checking --enable-profiling --enable-optimise\ + --enable-out-dir=out-profile + + make OUTDIR_NAME=out-profile all + + These two commands build two entirely separate versions of + LilyPond. In Real Life, you would probably also want to + have two different prefixes. On my machine this is no + problem; I never do make install. My prefix dirs are + linked back to my source directory. + +INSTALLING + If you have done a successful make, then a simple + + make install + + should do the trick. + + If you are doing an upgrade, please remember to remove + obsolete .pk and .tfm files of the fonts. A script has + been provided to do the work, see bin/clean-fonts.sh. + +CAVEATS + o The -O2 option to gcc triggers a gcc bug on DEC Alpha + in dstream.cc. You should turn off this flag for this + file. + + o Perl5.003 and Perl5.004 use different syntax for + pod2html. + +EXAMPLE + This is what I type in my xterm: + + lilypond someinput.ly + tex someinput.tex + xdvi someinput& + + This is what the output looks like over here: + + + + + + + + + + +2/Feb/98 LilyPond 0.1.43 4 + + + + + +INSTALL(1) LilyPond documentation INSTALL(1) + + + GNU LilyPond 0.0.78 #4/FlowerLib 1.1.24 #0 + Parsing ... [/home/hw/share/lilypond/init// + <..etc..> + init//performer.ly]]][input/kortjakje.ly] + Creating elements ...[8][16][24][25] + Preprocessing elements... + Calculating column positions ... [14][25] + Postprocessing elements... + TeX output to someinput.tex ... + Creating MIDI elements ...MIDI output to someinput.midi ... + + hw:~/musix/spacer$ xdvi someinput& + [1] 855 + + Check out the input files, some of them have comments + Please refer to the man page for more information. + +REDHAT LINUX + RedHat Linux users should be able to get a RPM. A spec + file is in make/out/lilypond.spec. You should be able to + create an rpm as a normal user. Be sure you have a + ~/.rpmrc, and edit the RPM-dir in Variables.make. (If you + create the RPM as a normal user the permissions will not + be set correctly, unfortunately) + +DEBIAN GNU/LINUX + A Debian package is also available; contact Anthony Fok + . The build scripts are in the + subdirectory debian/ + +WINDOWS NT/95 + So, you're stuck with Windows, eh? Well, don't worry, you + just need (to get) Cygnus' windows32 port of gnu + development stuff; have a look at + http://www.cygnus.com/gnu-win32. + + To make GNU LilyPond under, brr, aargh, shudder... + windows32, well, simply type: + + bash configure + make + + Note If you rely on broken DOS/Windows tools such as + pkzip/WinZIP to unpack the distribution, make sure the + entire source tree is unpacked correctly, in particular + the empty out directories (flower/out, lib/out et. al.) + +MUSIXTEX + Previous versions (before 0.1.39) used fonts from the TeX + macro package "MusixTeX". You can still use these, but + they are not supported. Since LilyPond's Feta font is + much prettier, you'd be seriously misguided if you used + them, but anyway, here are the installation instructions + for those deprecated fonts. + + + +2/Feb/98 LilyPond 0.1.43 5 + + + + + +INSTALL(1) LilyPond documentation INSTALL(1) + + + [obsolete] I use the MusixTeX fonts those found in + MusixTeX T.73. Beware, the clef symbol seems to have + changed its position in some versions, (notably Egler's, + a.k.a. OpusTeX). The MusixTeX fonts are included in + MusixTeX (T73 or better), which can be had from any CTAN + site, e.g. at + + ftp://ftp.shsu.edu/tex-archive/macros/musixtex/taupin + + ftp://ftp.tex.ac.uk/tex-archive/macros/musixtex/taupin + + ftp://ftp.dante.de/tex-archive/macros/musixtex/taupin + + You only need the contents of the mf/ subdirectory of the + package. The primary site of the Taupin version is + ftp://hprib.lps.u-psud.fr/pub/music_zips/musixtex.zip + + Install the musixtex fonts in a directory which TeX and MF + knows (if you are root, look for a directory which + contains the directories with AMS and CM source (*.mf) + files. Create a subdir lilypond or musixtex and copy the + fonts into that). Do not forget to rehash TeX (if + applicable) + + Example: my fonts are in + /usr/local/lib/texfonts/musixtex/, and I have a symlink + pointing to that in + /usr/lib/texmf/texmf/fonts/source/public/. After I copied + the files, I ran "texhash" + + Andreas Egler's version of MusixTeX, now called OpusTeX, + will also work. Andreas moved some characters around in + the fonts, so you have to edit the definitions in + tex/eglerdefs.tex. + +AUTHORS + Han-Wen Nienhuys + + Jan Nieuwenhuizen + + Have fun! + + + + + + + + + + + + + + + + +2/Feb/98 LilyPond 0.1.43 6 + + diff --git a/NEWS b/NEWS index a9c9c7c770..107512ee2d 100644 --- a/NEWS +++ b/NEWS @@ -1,3 +1,26 @@ +pl 43 + - bf: broken Plet_spanners + - more GNITting + - avoid some more global ctors, for NeXTstep + - some NeXTStep patches from tiggr + - don't do overstrike/bold chars in textfiles + +pl 42.jcn2 + - bit hesitating start of mutopia + - bf: don't try to typeset unterminated plet + - separately sticky plet durations: "c4 c4*2/3 c8 c4*1/1", ok Mats? + - denneboom.ly (half-baked version) + - indent and shape, see ^ + +pl 42.jcn1 + - bf: memmem revisited + - bf: ps: draw_plet vertical endings + - renamed stem_start to stem_begin + - bf: plet bracket placing on differently orientated stems + - more standje.ly and fixes +****** +jan 28 + pl 42 - ly2dvi 0.5 (JAF) - italian.ly (thanks, Paolo) diff --git a/TODO b/TODO index 3219d2897d..8f1ce7fa1d 100644 --- a/TODO +++ b/TODO @@ -31,8 +31,6 @@ grep for TODO and ugh/ugr * fix stdin input - * LILYSOURCEDIR - * documentation - info? - LaTeX? @@ -91,6 +89,8 @@ STUFF * GS: /undefined in draw_beam after XDVI magnification. + * Rational global static var. + PROJECTS * Unicode support? @@ -318,8 +318,6 @@ SMALLISH PROJECTS * midi esp.: use I32 iso int where 32 bits are needed (or assumed...) - * parshape - * Flower types: - A decent scalar type - String hash diff --git a/VERSION b/VERSION index 5617d6b5ef..901ee9191c 100644 --- a/VERSION +++ b/VERSION @@ -1,6 +1,6 @@ TOPLEVEL_MAJOR_VERSION = 0 TOPLEVEL_MINOR_VERSION = 1 -TOPLEVEL_PATCH_LEVEL = 42 +TOPLEVEL_PATCH_LEVEL = 43 TOPLEVEL_MY_PATCH_LEVEL = # use the above to send patches, always empty for released version: diff --git a/bin/clean-fonts.sh b/bin/clean-fonts.sh index fc72545334..202a873584 100644 --- a/bin/clean-fonts.sh +++ b/bin/clean-fonts.sh @@ -17,10 +17,6 @@ else TEXDIR=/var/ fi -#if [ -f $LILYPOND_SOURCEDIR/config.status ]; then -#TEXDIR=`awk -F % '/TEXPREFIX/ {print $3}' $LILYPOND_SOURCEDIR/config.status` - - # remove possibly stale .pk/.tfm files echo> /tmp/cleaning-font-dummy FILES=`find $TEXDIR -name "feta*$WHAT*tfm" -or -name "feta*$WHAT*pk"` diff --git a/bin/conflily.sh b/bin/conflily.sh index de2ce672f9..520af8b24c 100644 --- a/bin/conflily.sh +++ b/bin/conflily.sh @@ -27,7 +27,7 @@ ln -sf $lelie/current/mi2mu/out/mi2mu bin/out/mi2mu if [ "x$LILYINCLUDE" = "x" ]; then echo you should make add the following to your login script - echo "export LILYINCLUDE=$lelie/current/init" + echo "export LILYINCLUDE=$lelie/current/init:$lelie/current/input:$lelie/current/mutopia:$lelie/current/mutopia/j.s.bach" echo "export PATH=$PATH:$lelie/current/bin/out/" echo "export MFINPUTS=$MFINPUTS:$lelie/current/mf" fi diff --git a/bin/make-patch.py b/bin/make-patch.py index 360d5d70a4..207066d31a 100644 --- a/bin/make-patch.py +++ b/bin/make-patch.py @@ -99,7 +99,7 @@ def multiple_find(pats, dirnames): l = l + my_find(pats, d) return l -pats = ['*.lsm', 'configure', '*.text', 'lilypond.spec'] +pats = ['*.lsm', 'configure', '*.txt', 'lilypond.spec'] def remove_automatic(dirnames): files = [] files = files + multiple_find(pats, dirnames) diff --git a/bin/make-website.py b/bin/make-website.py index 8effeebe40..8604c5c892 100644 --- a/bin/make-website.py +++ b/bin/make-website.py @@ -41,7 +41,8 @@ lilyversion= '' def set_vars(): __main__.lilyversion = version_tuple_to_str(lilydirs.version_tuple()) os.environ["TEXINPUTS"] = os.environ["TEXINPUTS"] + ":%s/input/:" % depth; - os.environ["LILYINCLUDE"] = "%s/input/" % depth; + os.environ["LILYINCLUDE"] = "%s/input/:%s/mutopia/:%s/mutopia/J.S.Bach" \ + % ((depth, ) *3); os.environ["LILYTOP"] = depth; __main__.mailaddress= os.environ['MAILADDRESS'] pw = pwd.getpwuid (os.getuid()); @@ -52,7 +53,7 @@ backstr = '\n
Please take me back to the index\n\ of LilyPond -- The GNU Project Music typesetter\n\
\n\ This page was built using %s from lilypond-%s by

\n\ -


%s ><%s>
\n\ +

%s <%s>
\n\

' @@ -80,15 +81,8 @@ def my_system(cmds): base="lilypond/"; examples=["twinkle-pop", - "wtk1-fugue2", - "standchen-16", - "standchen-20", - "standje", - "wtk1-prelude1", "toccata-fuga-E", - "scsii-menuetto", "cadenza", - "gallina", "twinkle", "collisions", "font16", @@ -97,44 +91,29 @@ examples=["twinkle-pop", "rhythm", "multi"] +mutopia_examples = [ "wtk1-fugue2", + "standchen-16", + "standchen-20", + "standje", + "wtk1-prelude1", + "gallina", + "scsii-menuetto"] + + def gen_html(): print 'generating HTML' my_system (["make -kC .. html"]); -def gen_examples(): +def gen_examples(inputs): print 'generating examples:\n' - list = map(lambda x: 'out/%s.ps.gz out/%s.gif out/%s.ly.txt' % (x,x,x), examples) + list = map(lambda x: 'out/%s.ps.gz out/%s.gif out/%s.ly.txt' % (x,x,x), inputs) my_system (['make -C .. ' + join(' ', list)]) -texstuff = ["mudela-man", "mudela-course"] - -def gen_manuals(): - print 'generating TeX doco manuals' - list = open('tex_manuals.html', 'w') - list.write( "PostScript Manuals\n" - "

LilyPond manuals (in PostScript)

" - "
    \n") - todo='' - for stuff in texstuff: - todo = todo + ' out/' + stuff + '.ps.gz' - list.write("
  • %s.ps.gz" % (stuff, stuff)) - list.write('
') - list.close () - - my_system (['make -C .. ' + todo]) - -def file_exist_b(name): - try: - f = open(name) - except IOError: - return 0 - f.close () - return 1 -def gen_list(): - print "generating HTML list\n"; - list = open('example_output.html', 'w') +def gen_list(inputs, filename): + print "generating HTML list %s\n" % filename; + list = open(filename, 'w') list.write ('Rendered Examples\n' 'These example files are taken from the LilyPond distribution.\n' 'LilyPond currently only outputs TeX and MIDI. The pictures and\n' @@ -142,7 +121,7 @@ def gen_list(): 'graphics tools. The papersize used for these examples is A4. The GIF\n' 'files have been scaled to eliminate aliasing.\n'); - for ex in examples: + for ex in inputs: header = read_mudela_header(ex + '.ly.txt') def read_dict(s, default, h =header): try: @@ -177,6 +156,30 @@ def gen_list(): list.write( ""); list.close() +texstuff = ["mudela-man", "mudela-course"] + +def gen_manuals(): + print 'generating TeX doco manuals' + list = open('tex_manuals.html', 'w') + list.write( "PostScript Manuals\n" + "

LilyPond manuals (in PostScript)

" + "
    \n") + todo='' + for stuff in texstuff: + todo = todo + ' out/' + stuff + '.ps.gz' + list.write("
  • %s.ps.gz" % (stuff, stuff)) + list.write('
') + list.close () + + my_system (['make -C .. ' + todo]) + +def file_exist_b(name): + try: + f = open(name) + except IOError: + return 0 + f.close () + return 1 def copy_files(): print "copying files\n" @@ -257,8 +260,11 @@ def main(): set_vars(); gen_html(); copy_files(); - gen_examples(); - gen_list(); + gen_examples(examples); + gen_list(examples, 'examples_output.html'); + + gen_examples(mutopia_examples); + gen_list(mutopia_examples, 'mutopiaexamples_output.html'); gen_manuals(); #set_images(); edit_html(); diff --git a/configure b/configure index dc086365e8..eba42b2cda 100755 --- a/configure +++ b/configure @@ -22,15 +22,15 @@ ac_help="$ac_help ac_help="$ac_help enable-profiling compile with gprof support. Default: off" ac_help="$ac_help - mingw-prefix=DIR set the mingw32 directory (standalone windows32 exes)" + enable-mingw-prefix=DIR set the mingw32 directory (standalone windows32 exes)" ac_help="$ac_help - tex-prefix=DIR set the tex-directory to find TeX subdirectories. (default: PREFIX)" + enable-tex-prefix=DIR set the tex-directory to find TeX subdirectories. (default: PREFIX)" ac_help="$ac_help - tex-dir=DIR set the directory to put LilyPond TeX files in. " + enable-tex-dir=DIR set the directory to put LilyPond TeX files in. " ac_help="$ac_help - mf-dir=DIR set the directory to put LilyPond MetaFont files in. " + enable-mf-dir=DIR set the directory to put LilyPond MetaFont files in. " ac_help="$ac_help - out-dir set the directory for machine generated files. Default out or out-HOST" + enable-out-dir set the directory for machine generated files. Default out or out-HOST" # Initialize some variables set by options. # The variables have the same names as the options, with diff --git a/configure.in b/configure.in index a971abbae7..31fb726411 100644 --- a/configure.in +++ b/configure.in @@ -48,27 +48,27 @@ AC_ARG_ENABLE(profiling, [profile_b=$enableval]) AC_ARG_ENABLE(mingw-prefix, - [ mingw-prefix=DIR set the mingw32 directory (standalone windows32 exes)], + [ enable-mingw-prefix=DIR set the mingw32 directory (standalone windows32 exes)], [MINGWPREFIX=$enableval], [MINGWPREFIX=no]) AC_ARG_ENABLE(tex-prefix, - [ tex-prefix=DIR set the tex-directory to find TeX subdirectories. (default: PREFIX)], + [ enable-tex-prefix=DIR set the tex-directory to find TeX subdirectories. (default: PREFIX)], [TEXPREFIX=$enableval], [TEXPREFIX=auto] ) AC_ARG_ENABLE(tex-dir, - [ tex-dir=DIR set the directory to put LilyPond TeX files in. ], + [ enable-tex-dir=DIR set the directory to put LilyPond TeX files in. ], [TEXDIR=$enableval], [TEXDIR=auto] ) AC_ARG_ENABLE(mf-dir, - [ mf-dir=DIR set the directory to put LilyPond MetaFont files in. ], + [ enable-mf-dir=DIR set the directory to put LilyPond MetaFont files in. ], [MFDIR=$enableval], [MFDIR=auto]) AC_ARG_ENABLE(out-dir, - [ out-dir set the directory for machine generated files. Default out or out-HOST], + [ enable-out-dir set the directory for machine generated files. Default out or out-HOST], [OUTDIR_NAME=$enableval] []) diff --git a/debian/out/dummy.dep b/debian/out/dummy.dep new file mode 100644 index 0000000000..e69de29bb2 diff --git a/flower/NEWS b/flower/NEWS index 0629855834..1e795d59c3 100644 --- a/flower/NEWS +++ b/flower/NEWS @@ -1,5 +1,5 @@ -pl 34.jcn2 - - memmem optimise +pl 36 + - memmem fix: bugfree and *really* conforming to /usr/include/string.h pl 35 - bf: libc-extension: memmem diff --git a/flower/VERSION b/flower/VERSION index fb9bbfb6d6..d31b273055 100644 --- a/flower/VERSION +++ b/flower/VERSION @@ -1,6 +1,6 @@ MAJOR_VERSION = 1 MINOR_VERSION = 1 -PATCH_LEVEL = 35 +PATCH_LEVEL = 36 # use to send patches, always empty for released version: MY_PATCH_LEVEL = # include separator: "-1" or ".a" # diff --git a/flower/cpu-timer.cc b/flower/cpu-timer.cc index e10985eee9..c838fe5cc9 100644 --- a/flower/cpu-timer.cc +++ b/flower/cpu-timer.cc @@ -8,6 +8,12 @@ #include "cpu-timer.hh" +// nextstep +#ifndef CLOCKS_PER_SEC +#define CLOCKS_PER_SEC CLK_TCK +#endif + + Cpu_timer::Cpu_timer () { restart (); diff --git a/flower/libc-extension.cc b/flower/libc-extension.cc index d8a9fcd6e4..a18ff61b47 100644 --- a/flower/libc-extension.cc +++ b/flower/libc-extension.cc @@ -43,8 +43,8 @@ strnupr (char* start_l, int n) Manual v1.15, but it is with /usr/include/string.h */ Byte * -memmem (Byte const *needle,int needle_len, - Byte const *haystack, int haystack_len) +memmem (Byte const *haystack, int haystack_len, + Byte const *needle,int needle_len) { Byte const * end_haystack = haystack + haystack_len - needle_len + 1; Byte const * end_needle = needle + needle_len ; @@ -56,16 +56,13 @@ memmem (Byte const *needle,int needle_len, Byte const *subneedle_l = needle; Byte const *subhaystack_l = haystack; while (subneedle_l < end_needle) - { - if (*subneedle_l++ != *subhaystack_l++) - { - haystack ++; - continue; - } - } + if (*subneedle_l++ != *subhaystack_l++) + goto next; // completed the needle. Gotcha. return (Byte *) haystack; + next: + haystack++; } return 0; } diff --git a/init/paper11.ly b/init/paper11.ly index 9eb5614a9f..2d943fd720 100644 --- a/init/paper11.ly +++ b/init/paper11.ly @@ -4,6 +4,7 @@ paper_eleven = \paper { linewidth = 15.0 \cm; + indent = 8.0\mm; rulethickness = 0.25\pt; barsize = 11.0 \pt; interline = 2.75\pt; diff --git a/init/paper13.ly b/init/paper13.ly index e693d20041..892953eb0c 100644 --- a/init/paper13.ly +++ b/init/paper13.ly @@ -4,6 +4,7 @@ paper_thirteen = \paper { linewidth = 15.0 \cm; + indent = 8.0\mm; rulethickness = 0.25\pt; barsize = 13.0 \pt; interline = 3.25\pt; diff --git a/init/paper16.ly b/init/paper16.ly index 06aa523fa2..ecca65ae45 100644 --- a/init/paper16.ly +++ b/init/paper16.ly @@ -13,6 +13,7 @@ paper sizes. %} paper_sixteen = \paper { linewidth = 15.5 \cm; + indent = 5.\mm; rulethickness = 0.4\pt; barsize = 16.0 \pt; interline = 4.\pt; diff --git a/init/paper20.ly b/init/paper20.ly index 8e30c48c1a..62322672de 100644 --- a/init/paper20.ly +++ b/init/paper20.ly @@ -4,6 +4,7 @@ paper_twenty = \paper { linewidth = 15.0 \cm; + indent = 10.\mm; rulethickness = 0.4\pt; barsize = 20.0 \pt; interline = 5.\pt; diff --git a/init/paper26.ly b/init/paper26.ly index 46511883c7..b092ccded2 100644 --- a/init/paper26.ly +++ b/init/paper26.ly @@ -4,6 +4,7 @@ paper_twentysix = \paper { linewidth = 15.0 \cm; + indent = 12.0\mm rulethickness = 0.5\pt; barsize = 26.0 \pt; interline = 6.5\pt; diff --git a/input/Makefile b/input/Makefile index 76a5363cbb..894dba5c00 100644 --- a/input/Makefile +++ b/input/Makefile @@ -16,6 +16,6 @@ include ./$(depth)/make/Include.make # LYFILES = $(wildcard *.ly) TEXFILES = $(wildcard *.tex) -DISTFILES = Makefile $(LYFILES) $(TEXFILES) $(wildcard *.m4) +DISTFILES = Makefile TODO $(LYFILES) $(TEXFILES) $(wildcard *.m4) # diff --git a/input/TODO b/input/TODO new file mode 100644 index 0000000000..94237dfc2d --- /dev/null +++ b/input/TODO @@ -0,0 +1,5 @@ + + - neaten/structure examples + + - rename/split into test/exapmles? + diff --git a/input/denneboom.ly b/input/denneboom.ly new file mode 100644 index 0000000000..1027b2af77 --- /dev/null +++ b/input/denneboom.ly @@ -0,0 +1,68 @@ +\header{ +filename = "denneboom.ly"; +enteredby = "jcn"; +copyright = "public domain"; +TestedFeatures = "This file tests silly line shapes"; +} + +\version "0.1.8"; + +boom = \lyric{ + \meter 1/4; + O4 den- ne- boom, o den- ne- boom. + Wat zijn uw tak- ken won- der- schoon + O den- ne- boom, o den- ne- boom. + Wat zijn uw tak- ken won- der- schoon + Ik heb u laatst in 't bos zien staan + toen zat- en er geen kaarsjes aan. + O, Den- ne- boom, o den- ne- boom. + Wat zijn uw tak- ken wonder- schoon + + O den- ne- boom, o den- ne- boom. + Wat zijn uw tak- ken won- der- schoon + O den- ne- boom, o den- ne- boom. + Wat zijn uw tak- ken won- der- schoon + U gloeit in bar- re winter- tijd, +% ugh +% als sneeuw op aar- de licht ge- spreid. +% O, Den- ne- boom, o den- ne- boom. +% Wat zijn uw tak- ken wonder- schoon +} + +ugh = \melodic{ + \octave c'; + \meter 1/4; + c d e f | c d e f | c d e f | c d e f | + c d e f | c d e f | c d e f | c d e f | + c d e f | c d e f | c d e f | c d e f | + c d e f | c d e f | c d e f | c d e f | + c d e f | c d e f | c d e f | c d e f | + c d e f | c d e f | c d e f | c d e f | + c d e f | c d e f | c d e +} + +\score{ +% < +% \type Lyrics \boom + \ugh +% > + \paper{ + \indent = 20. \mm; + \shape = 72.5 \mm 15. \mm + 65. \mm 30. \mm + 57.5 \mm 45. \mm + 50. \mm 60. \mm + 42.5 \mm 75. \mm + 35. \mm 90. \mm + 27.5 \mm 105. \mm + 20. \mm 120. \mm + 10. \mm 140. \mm + 0. \mm 160. \mm + 72.5 \mm 15. \mm +% 72.5 \mm 15. \mm + 60. \mm 40. \mm + ; + + gourlay_maxmeasures = 30.; + } +} diff --git a/input/gallina.ly b/input/gallina.ly deleted file mode 100644 index a45ce1d52f..0000000000 --- a/input/gallina.ly +++ /dev/null @@ -1,241 +0,0 @@ -\header{ -title = "La Gallina a 2 violini"; -date = "1637"; -source = "the manuscript of Canzoni overo Sonate Concertate " - "libro terzo, opera duodecima "; -composer = "Tarquinio Merula (1594/95-1665)"; -enteredby = "Mats Bengtsson"; -copyright = "Public Domain "; -} - - -%{ -From mats.bengtsson@s3.kth.seThu Aug 14 02:11:19 1997 -Date: Wed, 13 Aug 1997 18:24:53 +0200 -From: Mats Bengtsson -To: Han-Wen Nienhuys -Subject: Re: brevis? - -[snip] - -Hopefully it could be useful input to future improvements. I've entered the -music directly from the 1637 manuscript and intend to publish it public -domain on for example ftp.gmd.de when finished. You could include it as an -example in the distribution, but in that case I could add a LaTeX title file. -There were no beams in the manuscript so I didn't use them in this edition -either. - - /Mats - - -Tested Features: Note placement, multipart score, figured base, \breve - -%} -%{ - -note: the sharp signs hoovering over the bass part are no mistake, but -part of the basso continuo --HWN - -%} - -\version "0.1.8"; - -vi1=\melodic{ - \meter 4/4; - \octave c''; - - d8 d d d d4 A16 B c A | - B8 G G G16 A B8 G G G16 A | - B8 G G A16 B c4 B | - A8 D G2 Fis4 | - G2 r2 | - r1 | - d8 d d d d4 A16 B c A | - B8 G G G16 A B8 G G G16 A | - B8 G G A16 B c8 e d c | - B G c2 B4 | - c2 r | - r1 | - g8 g g g g4 d16 e f d | - e8 c c c16 d e8 c c c16 d | - e8 c c d16 e f4 e | - d8 G c2 B4 | - c8 G G G16 A B4 G | - r8 G G G16 A B4 G | - r8 E16 Fis G8 G Fis! G G Fis! | - G2 r | - r1 | - r16 d c B A G Fis E D8 d d d16 c | - B8 d d d16 c B8 d d d16 e | - fis4 g2 fis!4 | - r16 g f e d c B A G8 g g g16 f | - e8 g g g16 f e8 g g g16 a | - b4 c'2 b4 | - c'8 g g g16 f e4 d | - r8 g g g16 f e4 d | - r8 d16 A B8 B16 c A2 | - B1 | - \meter 3/2; - r4 d d d d d | - e1. | - r4 c c c c c | - d1. | - r4 d8 c B4 c8 d G4 A8 B | - E1. | - r4 e8 d cis4 d8 e A4 B8 cis! | - Fis1. | - r4 d d d d d | - e e8 d c4 d8 e A4 B8 c | - Fis4 fis8 e d4 e8 fis! B4 c8 d | - G4 g g g g g | - a4 c'8 b a4 b8 c' f4 g8 a | - d4 g g g g g | - a d8 c B4 c8 d A2 | - \meter 4/4; - B1 | - d8 d d d d4 A16 B c A | - B8 G G G16 A B8 G G G16 A | - B8 G c2 B4 | - c2 r | - g8 g g g g4 d16 e f d | - e8 G G G16 A B8 d d d16 e | - fis4 g2 fis!4 | - r16 g f e d c B A G8 g g g16 f | - e2 r8 d d d16 e | - fis a g fis e d c B A8 d d d16 e | - fis4 g2 fis!4 | - \cadenza 1; - g\breve - \bar "|."; -} - -vi2=\melodic{ - \meter 4/4; - \octave c''; - - r1 | r | r | - d8 d d d d4 A16 B c A | - B8 G G G16 A B8 G G G16 A | - B8 G G A16 B c4 B | - A8 D G2 Fis4 | - G2 r2 | - r1 | - g8 g g g g4 d16 e f d | - e8 c c c16 d e8 c c c16 d | - e8 c c d16 e f4 e | - d8 G c2 B4 | - c2 r | - r1 | - g8 g g g g4 d16 e f d | - e2 r8 G G G16 A | - B4 G r8 G G A16 B - c4 B A2 | - G r16 d c B A G Fis E | - D8 d d d16 c B8 d d d16 e | - fis4 g g4. fis!8 | - g2 r | - r16 d c B A G Fis E D8 d d d16 c | - B4 c2 B4 | - c d G2 | - r16 g f e d c B A G8 g g g16 f | - e4 d r8 g g g16 f | - e4 d r8 c16 G B8 B16 c | - A4 G2 Fis4 | - G1 | - \meter 3/2; - r1. | - r4 g8 f e4 f8 g c4 d8 e | - A1. | - r4 a8 g fis4 g8 a d4 e8 fis! | - B1. | - r4 g g g g g | - a1. | - r4 a a a a a | - b d8 c B4 c8 d G4 A8 B | - E4 g8 f e4 f8 g c4 d8 e | - A4 a8 g fis4 g8 a d4 e8 fis! | - B4 b8 a g4 a8 b e4 fis8 g | - c4 A A A A A | - B d8 c B4 c8 d D4 E | - Fis2 G Fis! | - \meter 4/4; - G1 | - r1 | r1 | - g8 g g g g4 d16 e f d | - e8 c c c16 d e8 G G G16 A | - B8 G c2 B4 | - c2 r | - r16 d c B A G Fis E D8 d d d16 c | - B4 c2 B4 | - c8 G G G16 A B d c B A G Fis E | - D8 d d d16 e fis16 a g fis e d c B | - A d c B A G Fis E D4 d | - \cadenza 1; - B\breve - \bar "|."; -} - -bc=\melodic{ - \clef "bass"; - \meter 4/4; - \octave c; - - G2 d^"4 3" | G1 | - g2 c4 G | d1^"3 4 3" | - G1 | g2 c4 G | - d1^"3 4 3" | G | - g2 c4 d | G1^"3 4 3" | - c1 | c2 F4 c | - G1^"3 4 3" | c | - c2 F4 c | G1^"3 4 3" | - c2 G | g G | - c4 G d2^"3 4 3" | G g | - fis g | d1^"3 4 3" | - G2 B | d1^"3 4 3" | - G^"3 4 3" | c4 B c2 | - G1^"3 4 3" | c4 B c g | - c B c G | d1^"3 4 3" | - G1 | - \meter 3/2; - g1. | c | - % 30 - f | d^"\\textsharp" | - g | c | - A | d^"\\textsharp" | - G | c | - d^"\\textsharp" | e | - f | g1 B2 | - d1.^"3 4 3" | - \meter 4/4; - G1 | - g2 fis | g G | - g1^"3 4 3" | c | - G^"3 4 3" | c2 G | - d1^"3 4 3" | G^"3 4 3" | - c2 G | d1^"\\textsharp" ( | - ) d^"3 4 3" | - \cadenza 1; - G\breve - \bar "|."; -} - -\score{ - \type Staff_group < - \vi1 - \vi2 - \bc - > - \paper{ - %linewidth=18.\cm; - \output "gallina.out"; - gourlay_maxmeasures=7.; - } - \midi{ - \tempo 4=90; - } -} - - - - - diff --git a/input/gallina.tex b/input/gallina.tex deleted file mode 100644 index 21bbf4dbd4..0000000000 --- a/input/gallina.tex +++ /dev/null @@ -1,24 +0,0 @@ -%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% -% gallina.tex -% Mats Bengtsson, 17/8 1997 -%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% -\documentclass[a4paper]{article} - -\addtolength{\oddsidemargin}{-1cm} -\addtolength{\topmargin}{-1cm} -\setlength{\textwidth}{15cm} -\input lilyponddefs -\input titledefs -\begin{document} - -\title{La Gallina a 2 violini \\ -\normalsize from \textit{Canzoni overo Sonate Concertate - libro terzo, opera duodecima}, 1637} -\composer{Tarquinio Merula (1594/95-1665)} -%\instrument{M\"a\ss ig} % heu -%#%\tempo{M\"a\ss ig} -\makelilytitle -\input{gallina.out} - - -\end{document} diff --git a/input/scsii-menuetto.ly b/input/scsii-menuetto.ly deleted file mode 100644 index 91c488de41..0000000000 --- a/input/scsii-menuetto.ly +++ /dev/null @@ -1,174 +0,0 @@ -\header{ -filename = "scsii-menuetto.ly"; -title = "Cello Suite II"; -subtitle = "Part V"; -instrument = "Menuetto I"; % duh -description = "Cello suite transcribed for Viola"; -source = "?"; -opus = "BWV 1008 no. 5"; -composer = "Johann Sebastian Bach(1685-1750)"; -enteredby = "JCN"; -copyright = "public domain"; -} - -%{ - Tested Features:breaking algorithm, chords, multivoice, accents -%} - -\version "0.1.8"; - -%% Stuff from MPP version -% \lefttitle{Menuetto} -% \tempo{Moderato} -% \metron{4=120} -% -% \key\F % \key is F( f-major ) -% -% \slope{30} % Fool MusiXTeX into 30 / 10 steeper beam -% % because piece is set very tightly - -IImenuetto = \melodic{ -% \property Voice.beamslopedamping = \infinity - \clef"alto"; - \property Staff.instrument = cello - \meter 3/4; - \key bes; - \octave c'; - - \duration 8; - < a2 f2 d2 \f > bes4-. | -%%2 - \textstyle "finger"; % ugh. - - \multi 2 < - { \stemup; [ bes8^"1"( )a8 bes8-. g8-. ] a4-.^"4" } - - { \stemdown; < e8_"2" c8_"4" > } - > | - \stemboth; -%%3 -% \property Voice.beamslopedamping = \normal - < d4 'bes4-. > g4-. [ f8-. e8-. ] | -% \property Voice.beamslopedamping = \infinity -%%4 - \multi 2 < - { \stemup; [ f8( e8 )d8 cis8-. 'b8-. 'a8-. ] } - { \stemdown; 'a } - > | - \stemboth; -%%5 - < a2 f2 d2 > bes!4-. | -%%6 - \multi 2 < - { \stemup; [ bes8 a8 bes8-. g8-. ] } - { \stemdown; e8 } - > - \stemboth; - c'!4-. | -%%7 - < a4-. f4> - < d'4-.-\upbow f4 'bes4 > - < e'4-.-\downbow g4 'g4 > | -%%8 - < cis'2.-\upbow e2. 'a2. > - \bar ":|:"; -%%9 - \clef "violin"; - < e'2 a2 \f > -% \property Voice.beamslopedamping = \normal - [ d'8( e'16 )f'16 ] | -% \property Voice.beamslopedamping = \infinity -%%10 - \multi 2 < - { \stemup; [ e'8( d' cis'_"2" )e' a( )g8 ] } - { \stemdown; g8 } - > | - \stemboth; -%%11 - \multi 2 < - { \stemup; a4( )d'4 cis'4-. } - { \stemdown; f2 e4 } - > | - \stemboth; -%%12 - \multi 2 < - { \stemup; [ g'8^"4"( f' e' )f' d'^"3"( ) c' ] } - { \stemdown; d8 } - > | - \stemboth; -%%13 - \clef "alto"; - \multi 2 < - - { \stemup; bes2 c'4 } - { \stemdown; g4( )f4 e4 }% ugh - > | - \stemboth; -%%14 - \multi 2 < - { \stemup; [ a8 g8 a8 f8 ] } - { \stemdown; f8 } - > - \stemboth; - < d'4-\upbow e4 'bes4 > | -%%15 - < c'4-\downbow f4 'a4 > [ bes8( )a8 g8 a8 ] | -%%16 - [ f( e8 )f a8-. g8-. bes8-. ] | -%%17 - < a2^"0"^\trill fis2_"3" > bes4 | -%%18 - \multi 2 < - { \stemup; [ c'8( )bes8 c' a8 ] } - { \stemdown; es8 } - > - \stemboth; - fis4^\trill | -%%19 - < d'4-\downbow g4 'bes4 > < c'4-\upbow g4 c4 > < [ bes8 d8 > a8 ] | -%%20 - \multi 2 < - { \stemup; [ c'8( bes8 a8 )bes g( )bes8 ] } - { \stemdown; < d8 g8 > } - > | - \stemboth; -%%21 - \multi 2 < - { \stemup; d'4( )cis'4 d'4 } - { \stemdown; g2 f4 } - > | - \stemboth; -%%22 - \multi 2 < - { \stemup; [ g8( )f8 g8 e8 ] f4 } - { \stemdown; cis8 d4 } - > | - \stemboth; -%%23 -% \property Voice.beamslopedamping = \normal - [ 'g8 g8 ] < e4.^\trill 'a4. > d8-\upbow | -% \property Voice.beamslopedamping = \infinity -%%24 - \textstyle "roman"; % ugh - < d2.^"fine" 'a2. 'd2._"3 mins."> - \bar ":|"; -} - -\score{ - \melodic{ - \IImenuetto - } - \paper{ - linewidth= 150.0\mm; - % how does this work? - % why does space not have dim? - arithmetic_basicspace = 3.2; - % how can multiplier have dim? - arithmetic_mulitplier = 9.\pt; - \output "scsii-menuetto.out"; - } - \midi{ - \tempo 4 = 120; - \output "scsii-menuetto.midi"; - } -} diff --git a/input/scsii-menuetto.tex b/input/scsii-menuetto.tex deleted file mode 100644 index d6628ae59f..0000000000 --- a/input/scsii-menuetto.tex +++ /dev/null @@ -1,19 +0,0 @@ -\documentclass{article} %UGH -\usepackage{a4} -\advance\oddsidemargin-15mm -\evensidemargin\oddsidemargin -\advance\textwidth30mm -\begin{document} -\input lilyponddefs -\input titledefs -\def\interscoreline{\vskip6pt} -\title{Solo Cello Suites\normalsize\\[2ex]Suite II} -% \subtitle{Suite II} -\composer{J.\ S.\ Bach} -% \lefttitle{Menuetto} -% \tempo{Moderato} -% \metron{4=120} -\instrument{Menuetto I} % heu -\makelilytitle -\input scsii-menuetto.out -\end{document} diff --git a/input/standchen-16.ly b/input/standchen-16.ly deleted file mode 100644 index 8c0bda8e20..0000000000 --- a/input/standchen-16.ly +++ /dev/null @@ -1,14 +0,0 @@ -\header{ -filename = "standchen.ly"; -title = "St\"andchen (Serenade) \"Leise flehen meine Lieder\""; -opus = "D. 957 No. 4"; -composer = "Franz Schubert (1797-1828)" - "Text by Ludwig Rellstab (1799-1860)"; -enteredby = "JCN"; -description = "A schubert song in 16 pt"; -copyright = "public domain"; -} - -\version "0.1.8"; - -\include "standchen.ly" diff --git a/input/standchen-16.tex b/input/standchen-16.tex deleted file mode 100644 index e22d627ae9..0000000000 --- a/input/standchen-16.tex +++ /dev/null @@ -1,18 +0,0 @@ -\documentclass{article} %UGH -\usepackage{a4} -\advance\oddsidemargin-15mm -\evensidemargin\oddsidemargin -\advance\textwidth30mm - -\input titledefs -%\pagestyle{empty} -\begin{document} -\def\interscoreline{\vskip3mm} -\title{St\"andchen\normalsize\\[2ex](Serenade)} -\composer{Franz Schubert (1797-1828)} -\instrument{M\"a\ss ig} % heu -%#%\tempo{M\"a\ss ig} -\makelilytitle -\input{standchen-16.out} -%\input lelie.tex -\end{document} diff --git a/input/standchen-20.ly b/input/standchen-20.ly deleted file mode 100644 index 0f9dbee368..0000000000 --- a/input/standchen-20.ly +++ /dev/null @@ -1,14 +0,0 @@ -\header{ -filename = "standchen.ly"; -title = "St\"andchen (Serenade) Leise flehen meine Lieder\""; -opus = "D. 957 No. 4"; -composer = "Franz Schubert (1797-1828)" - "Text by Ludwig Rellstab (1799-1860)"; -enteredby = "JCN"; -copyright = "public domain"; -description = "A schubert song in 20 pt"; -} -\version "0.1.8"; - -% fool make-website -% \include "standchen.ly"; diff --git a/input/standchen-20.tex b/input/standchen-20.tex deleted file mode 100644 index d295d2f834..0000000000 --- a/input/standchen-20.tex +++ /dev/null @@ -1,22 +0,0 @@ -\documentclass{article} %UGH -\usepackage{a4} - -% -% UGH UGH -\advance\oddsidemargin-30mm -\evensidemargin\oddsidemargin -\advance\textwidth30mm -\addtolength{\textheight}{20mm} -\pagestyle{empty} -\begin{document} -\input lilyponddefs -\input titledefs -\def\interscoreline{\vskip3mm} -\title{St\"andchen\normalsize\\[2ex](Serenade)} -\composer{Franz Schubert (1797-1828)} -\instrument{M\"a\ss ig} % heu -%#%\tempo{M\"a\ss ig} -\makelilytitle -\input{standchen-20.out} -%\input lelie.tex -\end{document} diff --git a/input/standchen.ly b/input/standchen.ly deleted file mode 100644 index 73792caa2d..0000000000 --- a/input/standchen.ly +++ /dev/null @@ -1,508 +0,0 @@ -\header{ -filename = "standchen.ly"; -title = "St\"andchen (Serenade) \"Leise flehen meine Lieder\""; -opus = "D. 957 No. 4"; -composer = "Franz Schubert (1797-1828)" - "Text by Ludwig Rellstab (1799-1860)"; -enteredby = "JCN"; -copyright = "public domain"; -} - -%{ - Tested Features: multivoice, accents, lyrics, chords, piano music, -multiple \paper{}s in one \score -%} - -\include "paper20.ly" -\version "0.1.8"; - -commands = \melodic{ - \skip 2.*4; - \bar "|:"; - \skip 2.*24; -% volta1 - \skip 2.*8; -% volta2 - \bar ":|"; - \skip 2.*22; - \bar "|."; - } - -melodie = \melodic{ - \meter 3/4; - \clef "violin"; - \key bes; - \octave c'; - \duration 8; - r \pp < [ d 'a-| > f-| < d 'a-| > f-| < d 'a-| ] > | -%%2 - r < [ d 'bes-| > f-| < d 'bes-| > f-| < d 'bes-| ] > | -%%3 - \textstyle "italic"; - r_"simile" < [ d 'bes > e < d 'bes > e < d 'bes ] >| - \textstyle "roman"; - -%%4 - r < [ 'a cis > e < 'a cis > e < 'a cis ] > | -%%5 - [2/3 a() bes a ]1/1 d'4. a | -%%6 - [2/3 g() a g ]1/1 d'4 g r | - -%%7 - a4.^> g [2/3 g() f e ]1/1 | -%%8 - f2 r4 | -%%9 - < { a'4.() g' [2/3 g'( f' )e' ]1/1 } - { cis'4. e'_"dolce" \[2/3 e' \] } > | -%%10 - < f'2. d'2. > | -%%11 - [2/3 a () bes a ]1/1 f'4. a | -%%12 - [2/3 g() a g ]1/1 e'4. d' | -%%13 - c'4. bes [2/3 bes() a g ]1/1 | -%%14 - a2 r - < { d'() c'4. g [2/3 bes a g ]1/1 } - { f \p () e4._"dolce" bes \[2/3 g \] } > | -%%16 - < a2. f2. > | -%%17 - \textstyle "italic"; - [ a8._"cresc." cis'16 ] f'4. e' - \textstyle "roman";| -%%18 - [ d'8. a16 ] f4. d | -%%19 -%#% c'\grace\stemup - [2/3 bes () a bes ]1/1 d'4. bes | -%%20 - a2. | -%%21 -%#% a\grace - [2/3 g() fis g ]1/1 bes4.^> g | -%%22 - f!2. | -%%23 - [ a8. \mf cis'16 ] f'4. e' | -%%24 - [ d'8. a16 ] fis4. d | -%%25 - [2/3 b \mf() ais b ]1/1 d'4. b | -%%26 - < a2. fis2. > | -%%27 - [2/3 e' \f() dis' e' ]1/1 g'4. cis' | -%%28 - < d'2. fis2. > | -%#%\volta1 -%%29 - < { bes2( [ d'8.() )bes16 ] } - { g2 \mf [ bes8. g16 ] } > | -%%30 - < { a4. [ a-. a-. a-. ] } - { fis4. [ fis-.( fis-. )fis-. ] } > | -%%31 - < { a4. [ a-. a-. a-. ] } - { g4. [ cis-.( e-. )g-. ] } > | -%%32 - < a2 fis2 \pp > < a4 fis4 > | -%%33 - < { b2( [ d'8.() )b16 ] } - { g2 [ b8. g16 ] } > | -%%34 - < { a4. [ a-. a-. a-. ] } - { fis4. [ fis-.( fis-. )fis-. ] } > | -%%35 - < { a4. [ a-. a-. a-. ] } - { g4. [ cis-.( e-. )g-. ] } > | -%%36 - < a2. fis2. > | -%#%\volta2 -%%37 - [ a8. a16 ] [ cis'8. cis'16 ] [ e'8. e'16 ] | -%%38 - d'4() cis'4 r4 | -%%39 -%#% > a4. [ cis' e'8. >! d'16 ] | - a4. \> [ cis' e'8. \! d'16 ] | -%%40 - cis'2 r4 | -%%41 - < fis'4. \> cis'4. \f > e' [2/3 e'() d' \! cis' ]1/1 | -%%42 - [ b8. cis'16 ] d'4^> b r | -%%43 - - [ b8. \f cis'16 ] d'4^> b r | -%%44 - [ b8. \> cis'16 ] d'4^> b \! r | -%%45 - [2/3 b \p () ais b ]1/1 d'4. b | -%%46 - | -%%47 - [2/3 e' \f() dis' e' ]1/1 g'4.^> cis' | -%%48 - \textstyle "italic"; - < - { fis2.( - %\group "+1"; - \stemdown )f2. } - { d'2. ( \stemup - ) d'4 r4_"decresc." d'4 } - > - \textstyle "roman"; | -%%50 - < bes2. e2. > | -%%51 - < a2. cis2. > | -%%52 - < fis2 d2 > < a4 fis4 \pp > | -%%53 - - < bes2 g2 > < [ d'8.^> bes8. > < bes16 g16 ] > | -%%54 - < { a4. [ a-. a-. a-. ] } - { fis4. [ fis-.( fis-. )fis-.] } > | -%%55 - < { a4. [ a-. a-. a-. ] } - { g4. [ cis-.( e-. )g-. ] } > | -%%56 - \textstyle "italic"; - < a2. fis2._"dim." > - \textstyle "roman"; | -%%57 - < a2. fis2. > | -%%58 - < a2.^\fermata fis2. > | -%#%\tighten -} - -begeleiding = \melodic{ - \meter 3/4; - \clef"bass"; - \key bes; - \octave c'; - \duration 2; - 'd r4 | -%%2 - ''bes r4 | - -%%3 - ''g r4 | - -%%4 - ''a r4 | -%%5 -\duration 8; - \multi 2 < { \stemup - [ 'f 'a d 'a d 'a ] - [ 'd 'e 'g 'e 'g 'e ] - [ 'cis 'e 'g 'e 'g 'e ] - [ 'd 'a d 'a d 'a ] - } - { \stemdown - 'd2 r4 - ''bes2 r4 - ''a2 r4 - 'd2 r4 - } > -%%9 - \stemboth - [ 'a e g e g e ] | -%%10 - [ 'd 'a d 'a d 'a ] | -%%11 - \multi 2 < - { \stemup - [ 'f 'a d 'a d 'a ] - [ 'd 'e 'g 'e 'g 'e ] - [ 'e 'g 'bes 'g 'bes 'g ] - [ 'a c f c f c ] - } { \stemdown - 'd2 r4 - ''bes2 r4 - 'c2 r4 - 'f2 r4 } - > -%%15 - \stemboth - [ 'c 'g 'bes 'g 'bes 'g ] | -%%16 - [ ''f 'c 'f 'c 'f 'c ] | - \multi 2 < - { \stemup - [ ''a 'e 'g 'e 'g 'e ][ 'd 'a d 'a d 'a ] - [ ''bes 'f 'bes 'f 'bes 'f ][ ''f 'c 'f 'c 'f 'c ] } - { \stemdown - ''a2 r4 - 'd2 r4 - ''bes2 r4 - ''f2 r4 - } > -%%21 - \stemboth - < [ 'e 'c > 'g c 'g c 'g ] | -%%22 - [ 'f 'a c 'a 'f 'c ] | - \multi 2 < { - \stemup - [ ''a 'e 'g 'e 'g 'e ] - [ 'd 'fis 'a 'fis 'a 'fis ] - [ ''g 'd 'b 'd 'b 'd ] - [ 'd 'a d 'a d 'a ] - } - {\stemdown - ''a2 r4 - 'd2 r4 - ''g2 r4 - 'd2 r4 - } - > - \stemboth - < [ 'cis ''a > 'e 'a 'e 'a 'e ] | -%%28 - [ 'd 'a d 'a d 'a ] | -%%29 - [ 'd 'g 'bes 'g 'bes 'g ] | -%#%\volta1 -%%30 - [ 'd 'fis 'a 'fis 'a 'fis ] | -%%31 - [ ''a 'e 'a 'e 'a 'e ] | -%%32 - [ 'd 'fis 'a 'fis 'a 'fis ] | -%%33 - [ 'd 'g 'b 'g 'b 'g ] | -%%34 - [ 'd 'fis 'a 'fis 'a 'fis ] | -%%35 - [ ''a 'e 'a 'e 'a 'e ] | -%%36 - [ 'd 'fis 'a 'fis 'a 'fis ] | -%#%\volta2 -%%37 - [ ''a 'e 'g 'e ''bes^> 'e ] | -%%38 - [ ''a < e cis 'a > < e cis 'a > < e cis 'a > < e cis 'a > < e cis 'a ] > | -%%39 - [ ''a 'e 'g 'e ''bes^> 'e ] | -%%40 - [ ''a < e cis 'a > < e cis 'a > < e cis 'a > < e cis 'a > < e cis 'a ] > | -%%41 - [ ''ais 'e 'fis 'e 'fis 'e ] | -%%42 - < [ 'd ''b > 'fis 'b 'fis 'b 'fis ] | -%%43 - < [ 'e ''b > 'g 'b 'g 'b 'g ] | -%%44 - < [ 'd ''b > 'fis 'b 'fis 'b 'fis ] | -%%45 - \multi 2 < { \stemup - [ ''g 'd 'b 'd 'b 'd ] - [ 'd 'a d 'a d 'a ] - } { - \stemdown - ''g2 r4 - 'd2 r4 - } > - -%%47 - \stemboth - < [ 'cis ''a > 'e 'a 'e 'a 'e ] | -%%48 - [ 'd 'fis 'a 'fis 'a 'fis ] | -%%49 - [ 'd 'a d 'a d 'a ] | -%%50 - [ ''g 'e 'g 'e 'g 'e ] | -%%51 - [ ''a 'e 'g 'e 'g 'e ] | -%%52 - [ ''d 'd 'fis 'd 'fis 'd ] | -%%53 - [ 'd 'g 'bes 'g 'bes 'g ] | -%%54 - [ 'd 'fis 'a 'fis 'a 'fis ] | -%%55 - [ ''a 'e 'g 'e 'g 'e ] | -%%56 - [ ''d ''a 'd ''a 'd ''a ] | -%%57 - [ ''d ''a 'd ''a 'd ''a ] -%%58 - < 'd2.^\fermata ''d2. > | - } - - -tekstI = \lyric{ - \meter 3/4; - \duration 4; - _ _ _ - _ _ _ - _ _ _ - _ _ _ -% 5 - \[2/3 Lei- se8 \] fleh-4. en8 - \[2/3 mei- ne8 \] Lie- der8 _8 - Durch4. die8 \[2/3 Nacht zu8 \] - dir;2 _ - _ _ _ - _ _ _ -% 11 - \[2/3 In den8 \] stil-4. len8 - \[2/3 Hain her-8 \] nie-4. der,8 - Lieb4. chen,8 \[2/3 komm zu8 \] - mir!2 _ - _ _ _ - _ _ _ - -% 17 - Fl\"us-8. ternd16 schlan-4. ke8 - Wip-8. fel16 rau-4. schen8 - \[2/3 In des8 \] Mon-4. des8 - Licht;2. - _ _ _ - _ _ _ - -% 23 - Des8. Ver-16 r\"a-4. ters8 - feind-8. lich16 Lau-4. schen8 - \[2/3 F\"urch- te,8 \] Hol-4. de,8 - nicht.2. - _ _ _ - _ _ _ - -% volta 1 -% 29 - _ _ _ _ _ _ - _ _ _ _ _ _ - _ _ _ _ _ _ - _ _ _ _ _ _ - -% volta 2 -% 37 - La\ss8. auch16 dir8. die16 Brust8. be-16 - we- gen, _ - Lieb-4. chen,8 h\"o-8. re16 - mich!2 _ - Be-8. bend16 harr' ich8 _8 - dir8. ent-16 ge- gen!8 _8 - \[2/3 Komm, be-8 \] gl\"u4. cke8 - mich!2. - _ _ _ _ _ _ -% 47 - _ _ _ _ _ _ - _ _ _ _ _ _ - _ _ _ _ _ _ - _ _ _ _ _ _ - _ _ _ _ _ _ -% 57 - _ _ _ _ _ _ - -} - -tekstII = \lyric{ - \meter 3/4; - \duration 4; - _ _ _ - _ _ _ - _ _ _ - _ _ _ -% 5 - \[2/3 H\"orst die8 \] Nach-4. ti-8 - \[2/3 gal- len8 \] schla- gen?8 _8 - Ach!4. sie8 \[2/3 fleh- en8 \] - dich,2 _ - _ _ _ - _ _ _ - -% 11 - \[2/3 Mit der8 \] T\"o-4. ne8 - \[2/3 s\"u\ss- en8 \] Kla-4. gen8 - Fleh-4. en8 \[2/3 sie f\"ur8 \] - mich.2 _ - _ _ _ - _ _ _ - -% 17 - Sie-8. ver-16 stehn4. des8 - Bus-8. ens16 Seh-4. nen,8 - \[2/3 Ken- nen8 \] Lieb-4. es-8 - schmerz,2. - _ _ _ - _ _ _ - -% 23 - R\"uh-8. ren16 mit4. den8 - Sil-8. ber-16 t\"o-4. nen8 - \[2/3 Jed- es8 \] wei-4. che8 - Herz.2. - _ _ _ - _ _ _ -% volta 1 -% 29 - _ _ _ _ _ _ - _ _ _ _ _ _ - _ _ _ _ _ _ - _ _ _ _ _ _ - -% volta 2 -% 37 - _ _ _ _ _ _ - _ _ _ _ _ _ - _ _ _ _ _ _ - _ _ _ _ _ _ - _ _ _ _ _ _ -% 47 - _ _ _ _ _ _ - _ _ _ _ _ _ - _ _ _ _ _ _ - _ _ _ _ _ _ - _ _ _ _ _ _ -% 57 - _ _ _ _ _ _ - -} - -themusic = - < - \type Lyrics < - \tekstI - \tekstII - > - \type Grandstaff < - \melodic < \melodie \commands > - \melodic < \begeleiding \commands > - > - > - - -\score{ - \themusic - \midi{ - \tempo 4 = 54; - } - \paper{ - \paper_twenty - % 20pt music uses whole pagewidth - % ja Vette Pech. Koop maar een A3 printer - % huh? [jcn] - linewidth= 195.\mm; - arithmetic_multiplier = 7.\pt; - - gourlay_maxmeasures = 9.; - \output "standchen-20.out"; - } - \paper{ - % 16pt mustn't use whole page width - linewidth= 160.\mm; - arithmetic_multiplier = 6.\pt; - gourlay_maxmeasures = 9.; - \output "standchen-16.out"; - } -} diff --git a/input/standje.ly b/input/standje.ly deleted file mode 100644 index e6d29fd994..0000000000 --- a/input/standje.ly +++ /dev/null @@ -1,208 +0,0 @@ -\header{ -filename = "standje.ly"; -title = "St\"andchen (Serenade) \"Leise flehen meine Lieder\""; -opus = "D. 957 No. 4"; -composer = "Franz Schubert (1797-1828)" - "Text by Ludwig Rellstab (1799-1860)"; -enteredby = "JCN"; -copyright = "public domain"; -} - -%{ - Tested Features@ multivoice, accents, lyrics, chords, piano music, -multiple \paper{}s in one \score -%} - -\version "0.1.8"; - -$vocal_verse1 = \melodic{ - \octave c'; - % ugh: treble/bass -% \clef treble; - \clef violin; - [2/3 g8( )as] g \] c'4. g8 | - [2/3 f8( )g] f \] c'4 f8 r | - g4.-> f8 [2/3 f( )es] d \] | - es2 r4 | - % ugh: a whole should be a measure - %r1 | - r2. | - r2. | - [2/3 g8( )as] g \] es'4. g8 | - [2/3 f8( )g] f \] d'4. c'8 | - bes4. as8 [2/3 as( )g] f \] | - g2 r4 | - r2. | - r2. | - g8. b16 es'4. d'8 | - c'8. g16 es4. c8 | - % [as3 2\grace( bes3 2\grace] ) - [2/3 as8( )g] as \] c'4. as8 | - g2. | - %[f3 2\grace( g] ) - [2/3 f8( )e] f \] as4. f8 | - es!2. | - g8. b16 es'4. d'8 | - c'8. g16 e4. c8 | - % [a3 2\grace b] ) - [2/3 a!8( ) gis] a \] c'4. a8 | - g!2. | - [2/3 d'8\f cis'] d \] f'4. b8 | - c'2. | - r2. | - r2. | -} - -$lyric_verse1 = \lyric{ -% 5 - \[2/3 Lei-4 se8 \] fleh-4. en8 | - \[2/3 mei-4 ne8 \] Lie-4 der8 _8 | - Durch4. die8 \[2/3 Nacht4 zu8 \] | - dir;2 _4 | - _4 _ _ | - _ _ _ | -% 11 - \[2/3 In4 den8 \] stil-4. len8 | - \[2/3 Hainr4 her-8 \] nie-4. der,8 | - Lieb4. chen,8 \[2/3 komm4 zu8 \] | - mir!2 _4 | - _4 _ _ | - _ _ _ | -% 17 - Fl\"us-8. ternd16 schlan-4. ke8 | - Wip-8. fel16 rau-4. schen8 | - \[2/3 In4 des8 \] Mon-4. des8 | - Licht;2. | - _4 _ _ | - _4 _ _ | -% 23 - Des8. Ver-16 r\"a-4. ters8 | - feind-8. lich16 Lau-4. schen8 | - \[2/3 F\"urch-4 te,8 \] Hol-4. de,8 | - nicht,2. | - \[2/3 f\"urch-4 te,8 \] Hol-4. de,8 | - nicht.2. | - _4 _ _ - _ _ _ -} - -$treble_intro = \melodic{ - \octave c'; - \clef violin; - % ugh: i'd like to type this! - %r8 [<'g-. c-.> <'g-. c-.> <'g-. c-.>] | - r8 <['g-. c-.> <'g-. c-.> <'g-. c-.]> | - r8 <['as-. c-.> <'as-. c-.> <'as-. c-.]> | - r8 <['as-. c-.> <'as-. c-.> <'as-. c-.]> | - r8 <['g-. 'b-.> <'b-. d-.> <'g-. 'b-.> <'b-. d-.> <'g-. 'b-.]> | - -} - -$treble_verse1 = \melodic{ - \octave c'; - \clef violin; - r8 <['g c> <'g c> <'g c]> | - r8 <['f c> <'f c> <'f c]> | - r8 <['f 'g 'b> <'g 'b d> <'f 'g 'b> <'g 'b d> <'f 'g 'b]> | - r8 <['es 'g c> <'g c es> <'es 'g c> <'g c es> <'es 'g c]> | - <)f'8 d'> <[2/3 f' d'> | - | - r8 <['g c> <'g c> <'g c]> | - r8 <['f c> <'f c> <'f c]> | - r8 <['f 'as 'bes> <'as 'bes d> <'f 'g 'bes> <'g 'bes d> <'f 'g 'bes]> | - r8 <['es 'g 'bes> <'g 'bes es> <'es 'g 'bes> <'g 'bes es]> - <{ es'( | )bes4. as8}{ c'( | )d4.( )f8 } > - < [2/3 f as> | - | - r8 <['f 'g> <'g 'b> <'f 'g> <'g 'b> <'f 'g]> | - r8 <['es 'g> <'g c> <'es 'g> <'g c> <'es 'g]> | - r8\pp <['es 'as c> <'as c es> <'es 'as c> <'as c es> <'es 'as c]> | - r8 <['es 'g 'bes> <'g 'bes 'es> <'es 'g 'bes> <'g 'bes 'es> <'es 'g 'bes]> | - % [as3 2\grace( bes ) - [2/3 as8(( g )as]1/1 c'4.-> ) as8 | - g2. | - r8 <['f 'g> <'g 'b> <'f 'g> <'g 'b> <'f 'g]> | - r8 <['e 'g> <'g c> <'e 'g> <'g c> <'e 'g]> | - r8 <['f 'a c> <'a c f> <'f 'a c> <'a c f> <'f 'a c]> | - r8 <['e 'g c> <'g c e> <'e 'g c> <'g c e> <'e 'g c]> | - <{[2/3 f'8\f( e f']1/1 a'4. )f'8 } {\[2/3 f e f \] a4. f8 } > | - r4 | -% <{as!2\mf( [c'8. )as16]} {f2 as8( )f}> | - as!2\mf( [c'8. )as16] | - <[e8-.( g-.> <)e8-. g-.]> | -} - -$bass_intro = \melodic{ - \octave c; - \clef bass; - <'c2 c> r4 | - <''as2 'as> r4 | - <''f2 'f> r4 | - <''g2 g> r4 | -} - -$bass_verse1 = \melodic{ - \octave c; - \clef bass; - <'c2 c> r4 | - <'as2 as> r4 | - <'g2 g> r4 | - <'c2 c> r4 | - <'g8 g> <[g' d''> | - <'c2 c> r4 | - <'c2 c> r4 | - <'c2 c> r4 | - <'c2 c> r4 | - <'c2 c> r4 | - <'c2 c> r4 | - <'c2 c> r4 | - <'c2 c> r4 | - <'c2 c> r4 | - <'c2 c> r4 | - <'c2 c> r4 | - <'c2 c> r4 | - <'c2 c> r4 | - <'c2 c> r4 | - <'c2 c> r4 | - <'c2 c> r4 | - <'c2 c> r4 | - <'c2 c> r4 | - <'c2 c> r4 | -} - - -global= \melodic {\meter 3 /4; \key bes es as; } - - -\score{ - \melodic< - \type Lyrics { - \meter 3 /4; \skip 4 * 12; \$lyric_verse1 - } - \type Staff { < - \global - { \skip 4 * 12; \$vocal_verse1 } - > } - - % i want a (grand) staff!!! - - \type Grandstaff < - < - \global - { \$treble_intro \$treble_verse1 } - > - < - \global - { \$bass_intro \$bass_verse1 } - > - > - > - \paper{ - % how does this work? - % previously we had the clear 'ideal whole note space' setting? - arithmetic_multiplier = 6.\pt; - % ugh: the *first* (intro) line may only have four measures... - gourlay_maxmeasures = 4.; - } -} - diff --git a/input/wtk1-fugue1.ly b/input/wtk1-fugue1.ly deleted file mode 100644 index e48c55b189..0000000000 --- a/input/wtk1-fugue1.ly +++ /dev/null @@ -1,207 +0,0 @@ -\header{ -filename = "fugue1.ly"; -title = "Fuga a 4"; -description = "Das Wohltemperierte Clavier I, Fuga I (c-major)"; -opus = "BWV 846"; -composer = "Johann Sebastian Bach (1685-1750)"; -enteredby = "Shay Rojansky"; -copyright = "Public Domain"; -} - -%{ - -%} -\version "0.1.8"; - - -global = - \melodic { - \meter 4/4; % should be \meter C - } - -tenor = - \melodic { - \clef "violin"; - \octave c'; - - \stemdown - r8 [c8 d e] [f. g32 f] [e8 a] | - [d g] ~ [g16 a g f] [e f e d] [c d c 'b] | - ['a8 fis] g4 ~ [g8 fis16 e] [f8 d] | - [g f! e d] c r r g ~ | -%% 5 - [g f16 e] f4 ~ [f16 f e8] d4 | - [c8 f] r16 [g f e] [f8 d] g4 ~ | - g4 r4 r2 | - r1 | - r8 [g8 a b] [c'. d'32 c'] [b8 e'] -%% 10 - [a d'] ~ [d'16 e' d' c'] b8 r8 r d | - [e fis] [g. a32 g] [fis8 b e a] ~ | - [a16 b a gis] [fis8 f!] [e d] ~ [d16 e fis gis] | - [a gis a b] [gis fis gis a] b8 r8 r4 | - r8 [c8 d e] \stemup [f. g32 f] [e8 a] | -%% 15 - [d g] ~ [g16 a g f] e8 \stemdown [e fis g] ~ | - [g8 fis] [gis8 a] ~ [a g! a b] | - \stemboth - [c'. d'32 c'] [b8 e'] [a d'] ~ [d'16 e' d' c'] | - [b8 g' cis' d'] [e' cis' d' e' ] | - \stemdown a8 r8 r e [fis g] \stemboth [a. b32 a] | -%% 20 - [g8 c' fis b] ~ [b16 c' b a] \stemdown [g fis e d] \stemboth | - e4 \stemdown d ~ [d16 a g f!] [e g f! a] | - g4 ~ [g16 a bes8] c'4 [d'8 g] | - \stemboth g4. f8 ~ [f e] d4 | - \stemdown e8 a4 g8 ~ [g8 f g a] | -%% 25 - [bes8. c'32 b] [a8 d'] [g c'] ~ [c'16 d' c' bes] | - [a bes a g] [f g f e] d4 ~ [d8. g16] | - a4 r16 [f'16 d'8] e'2 | - } - - -soprane = - \melodic { - \octave c'; - \stemup - r1 | - r2 r8 [g8 a b] | - [c'. d'32 c'] [b8 e'] [a d'] ~ [d'16 e' d' c'] | - [b g a b] [c' b c' d'] [e' d' e' fis'] [g'8 b] | -%% 5 - [c' a] [d'16 c' b a] [g8. g16] [f e f g] | - [a g a b] c'2 b4 | - \octave c''; - r8 [c8 d e] [f. g32 f] [e8 a] | - [d g] ~ [g16 a g f] [e8 a] ~ [a16 b a g] | - f2 [e8. fis16] g4 ~ -%% 10 - g4 fis [g16 f! e d] [c d c 'b] | - ['a16 c 'b 'a] 'g8 r8 r16 [c16 'b 'a] ['gis8 e] | - [d c16 'b16] ['a 'gis 'a 'b] [c 'fis 'a 'gis] ['b8 'a16 'b] - [c8 f e d] ~ [d c16 'b] ['b8. 'a16] | - 'a4 r4 r2 | -%% 15 - r2 r8 ['g8 'a 'b] | - [c8. d32 c] ['b8 c] [d e] [f!. g32 f!] | - [e8 a d g] ~ [g16 a g f] [e8 a] | - [d8 bes] [a g16 f] [g f g e] [f g g f32 g] | - [a16 cis d g] [e8. d16] d8 r8 r4 | -%% 20 - r2 r4 r8 'g | - ['a 'b] [c. d32 c] ['b8 e 'a d] ~ | - [e16 e d c] ['b c d e] [f g a g] [f e d c] | - 'b4 [c8 d] 'g c4 'b8 | - c4 ['b8 'bes8] 'a d4 c8 | -%% 25 - [d8 e] f4 ~ [f16 a g f] [e f e d] | - c2 r16 ['g32 'a 'b!16 c] [d e f8] ~ | - [f32 c d e f16 g] [a8. b16] | - } - -alt = - \melodic { - \clef "bass"; - \octave c; - - \stemup - r1 | - r | - r | - r8 [g8 a b] [c'. d'32 c'] [b8 e'] | -%% 5 - [a d'] ~ [d'16 e' d' c'] [b8 c' ~ c' bes8] | - [a d' g c'] r16 [a16 b c'] d'4 | - g4 r8 g8 [a b] [c'. d'32 c'] | - [b8 e' a d'] ~ [d'16 e' d' c'!] [b!8 e'] ~ | - e'4 d'4 [c'16 b c' a] [e' d' c' b] | -%% 10 - [c'16 a b c'] [d' c' b a] g4 r4 | - r1 | - r8 [e8 fis gis] [a. b32 a] [gis8 c'] | - [fis b] ~ [b16 c' b a] gis8 a4 gis8 | - a4 r8 g8 [a b] c'. [d'32 c'] | -%% 15 - [b8 e' a d'] ~ [d' g] d'4 | - [c'8 a] e'4 d'8 r8 r4 | - r8 [a8 b cis'] [d'. e'32 d'] [c'!8 f'] | - [b8 e'] ~ [e'16 f' e' d'] cis'8 r8 r4 | - r8 [a8 b cis'] [d'. e'32 d'] [c'!8 fis'] | -%% 20 - [b e'] ~ [e'16 fis' e' d'] c'2 ~ | - [c'16 d' c' b] [a g a fis] [g8 b c' d'] | - [e'. f'32 e'] [d'8 g'] [c' f'] ~ [f'16 g' f' e'] | - d'4 [e'8 d'] ~ [d' g] g4 ~ - [g8 c d e] [f. g32 f] [e8 a] | -%% 25 - [d g] ~ [g16 a g f] [e d e f] [g a bes g] | - [a e f g] [a b c' a] b2 | - c'1 | - } - -bass = - \melodic { - \clef "bass"; - \octave c; - - \stemdown - r1 | - r | - r | - r | -%% 5 - r2 r8 [c8 d e] | - [f. g32 f] [e8 a] [d g] ~ [g16 a g f] | - [e f e d] [c d c 'b] ['a8 d a fis] | - [g16 a bes g] [cis8 d] a4 e4 | - [a16 b c' d'] [c' b a g] c'8 r8 r4 | -%% 10 - r2 r8 ['g8 'a 'b] | - [c. d32 c] ['b8 e] ['a d] ~ [d16 e d c] | - 'b8 e4 d8 c f!4 e8 ~ | - e d4 e8 [f! e16 d] e4 | - 'a4 r4 r2 | -%% 15 - r8 ['g8 'a 'b] [c. d32 c] ['b8 e] | - ['a8 d] ~ [d16 e d c] ['b8 'bes 'a g'] | - ['a8 fis g e] d4 [e8 f!] | - [g8. a32 g] [f8 bes] [e a] ~ [a16 bes a g] | - [f e f d] [g8 a] d2 ~ | -%% 20 - [d16 e d c] ['b 'a 'g 'fis] ['e8 e fis g] ~ | - [g a16 g16] [fis8 d] g2 ~ | - g2 a4 [b8 c'] | - [f16 a g f] [e d c 'b] [c d e f] [g8 'g] | - c1 ~ | -%% 25 - c1 ~ | - c1 ~ | - c1 | - } - - -\score { - \melodic \type Grandstaff < - \multi 2 < - \global - \soprane - \tenor - > - \multi 2 < - \global - \alt - \bass - > - > - - \paper{ - gourlay_maxmeasures =5.; -% castingalgorithme = \Wordwrap - } - \midi { - \tempo 4 = 84; - } -} - -% EOF diff --git a/input/wtk1-fugue2.ly b/input/wtk1-fugue2.ly deleted file mode 100644 index 2d90c2ad90..0000000000 --- a/input/wtk1-fugue2.ly +++ /dev/null @@ -1,191 +0,0 @@ -\header{ -filename = "wohltemperirt.ly"; -title = "Fuga a 3"; -description = "Das Wohltemperierte Clavier I, Fuga II (c-minor)"; -opus = "BWV 847-Fuga"; -source = "Henle's Urtext"; -composer = "Johann Sebastian Bach (1685-1750)"; -enteredby = "HWN and Werner Lemberg"; -copyright = "Public Domain"; -} -%{ - Tested Features: stem direction, multivoice, forced accidentals. -%} - -\version "0.1.8"; - - % should add \need{dutch.ini} for - % correct parsing of note names - -global = - \melodic { - \meter 4/4; % should be \meter C - \keyCminor - \skip 1*31; - \bar "|."; | - } - -dux = - \melodic { - \clef "violin"; - \octave c'; - - \stemdown - r8 [c'16 b] [c'8 g] [as c'16 b] [c'8 d'] | - [g c'16 b] [c'8 d'] [f16 g] as4 [g16 f] | - [es c' b a] [g f! es d] [c8 es' d' c'] | - [bes a bes c'] [fis g a fis] | -%% 5 - g4 r16 [c d es] [f g as8~] [as16 d es f] | - [g a bes8~] [bes16 es f g] [as g f es] [d8 c'16 b!] | - % forced accident! - c'4 r4 r8 [f' es' d'] | - r8 [as g f] [g f16 es] [f8 d] | - g4 r8 b [c' c'16 b] [c'8 g] | -%% 10 - as4 r8 a [bes bes16 a] [bes8 f] | - g4 r8 g [as as g f] | - \translator Staff=bass \stemup - \octave c; r8 [as bes c'] r8 [as16 g] [as8 f8] | - [bes8 c' bes as] [bes g f es] | - [f des' c' bes] [c' as g f] | -%% 15 - \translator Staff=treble \stemdown - g8 \octave c'; [g16 fis] [g8 c] [es g16 fis!] [g8 a] | - [d g16 fis] [g8 a!] [c16 d] es4 [d16 c] | - % forced accident! - 'bes8 r8 r16 [d e fis] [g a bes8~] [bes16 e f g] | - [a bes c'8~] [c'16 fis16 g a] [bes8 es!16 d] [es8 'g] | - ['as f16 es] [f8 'a8] ['bes g16 f] [g8 'b] | -%% 20 - [c16 f es d] [c Bes! As G] [F8 as g f] | - [es d es f] [B c d B] | - c4 r8 e8 [f f16 e] [f8 c] | - d4 r8 d8 [es8 es16 d] [es8 Bes] | - c2 ~ [c8 d16 es][ f es f d] | -%% 25 - B8 r8 r B c r r es | - d r r f~ f r r f | - [es as g f] [es d es f] | - [B c d B] [B c] r c | - [f16 d es c]~ [c8 B] c4 r8 e | -%% 30 - f4 r8 f [f es16 d] [es8 | - r r | - } - - -comes = - \melodic { - \octave c''; - \stemup - r1 | - r1 | - r8 [g16 fis] [g8 c] [es g16 fis] [g8 a] | - [d8 g16 fis] [g8 a] [c16 d] es4 [d16 c] | -%% 5 - ['bes8 es16 d] [es8 'g8] ['as f16 es] [f8 'a] - ['bes8 g16 f] [g8 'b] [c8 d16 es] f4~ | - [f8 es16 d] [c16 'bes! 'as 'g] ['f8 as g f] - [es d es f] ['b c d 'b] | - [c g16 fis] [g8 d] es4 r8 e8 | -%% 10 - [f f16 e] [f8 c8] d4 r8 d | - [es8 es16 d] [es8 'bes] [c es16 d] [es8 f] | - ['bes es16 d] [es8 f] ['as16 'bes] c4 ['bes16 'as] | - [G16 Es F G] [As Bes c d] [es d c d] [es f g a] | - [bes F G As] [Bes c d e] [f es d es] [ f g a b] | -%% 15 - [c'8 b16 a] [g f! es d] [c8 es d c] | - [Bes A Bes c] [Fis! G A Fis] | - % forced accident - [G8 d16 c] d8 r8 r8 [e16 d] e8 r8 | - r [fis16 e] fis8 r r [G16 F] G8 r8 | - r8 [A16 G] A8 r r [B16 A] B8 r | -%% 20 - r8 [c16 'b] [c8 'g] [As c16 'b] [c8 d] | - [G c16 B] [c8 d] [F16 G] As4 [G16 F] | - [Es8 c16 B] [c8 G] As4 r8 A | - [Bes8 Bes16 A] [Bes8 F8] 'g4 r8 G~ | - [G As16 Bes] [c B c As] F2~ | -%% 25 - [F8 d16 c] [d8 F] [Es es16 d] [es8 G] | - [F f16 es] [f8 As] [G16 f es d] [c B A G] | - [c8 f es d] r [As G F] | - [G F16 Es] [F8 D] [As G] r A | - [B c] [F16 Es D C] C8 [c16 B] [c8 G] | -%% 30 - [As c16 B] [c8 [G8 c16 B] [c8 d] | - [F16 G] As4 [G16 F] E2 | - } - -bassdux = - \melodic { - \clef "bass"; - \octave c'; - r1 | - r | - r | - r | -%% 5 - r | - r1 | - r8 [c16 B] [c8 G] [As c16 B] [c8 d] | - [G c16 B] [c8 d] [F16 G] As4 [G16 F] | - \octave c; [es c' b a] [g f es d] [c d es d] [c Bes! As! G] | - % -> \classic_accidentals -%% 10 - [F bes as g] [f es d c] [Bes c d c] [Bes As G F] | - [Es as g f] [es des c Bes] [As8 c' bes as] | - [g8 f g as] [d es f d] | - [es as g f] [g es d c] | - [d bes as g] [as f es d!] | -%% 15 - es8 r8 r4 r8 [c Bes A] | - r [es d c] [d c16 Bes] [c8 d] | - [G8 bes16 a] [bes8 d] [es c'16 bes] [c'8 e] | - [f d'16 c'] [d'8 fis] g4 r16 [G A B] | - [c16 d es8~] [es16 A Bes c] [d es f8~] [f16 'b c d] | -%% 20 - es8 r r e [f F Es! D] | % -> \classic_accidentals - r [As G F] [G F16 Es] [F8 G] | - [c16 d es d] [c Bes As G] [F bes as g] [f es d c] | - [Bes c d c] [Bes As G F] [Es as g f] [es d c Bes] | - [As Bes c Bes] [As G F Es] [D g f es] [d c B A] | -%% 25 - G4 r4 r16 [G A B] [c d es f] | - [g f as g] [f es d c] [B8 c16 B] [c8 G] | - [As c16 B] [c8 d] [G c16 B] [c8 d] | - [F16 G] As4 [G16 F] Es4 r8 es | - [d c g G] -%% 30 - \multi 2 < - { \stemup c2~ | c1~ | c1 } - { \stemdown C2~ | C1~ | C1 } - > - } - - -\score { - \melodic \type Grandstaff < - \type Staff=treble < - \global - \dux - \comes - > - \type Staff=bass < - \global - \bassdux - > - > - - \paper{ - gourlay_maxmeasures =5.; - - } - \midi { - \tempo 4 = 84; - } -} - -% EOF diff --git a/input/wtk1-prelude1.ly b/input/wtk1-prelude1.ly deleted file mode 100644 index dea0195fa0..0000000000 --- a/input/wtk1-prelude1.ly +++ /dev/null @@ -1,184 +0,0 @@ -\header{ -filename = "prelude1.ly"; -title = "Preludium"; -description = "Das Wohltemperierte Clavier I, Prelude I (c-major)"; -opus = "BWV 846"; -composer = "Johann Sebastian Bach (1685-1750)"; -enteredby = "Shay Rojansky"; -copyright = "Public Domain"; -} - -\version "0.1.8"; - -global = - \melodic { - \meter 4/4; % should be \meter C - } - - -% should do programmable input. - -soprane = - \melodic { - \clef "violin"; - \octave c'; - - \multi 2 < - % Real soprane - {\stemup - r8 [g16 c'] [e' g c' e'] r8 [g16 c'] [e' g c' e'] | - r8 [a16 d'] [f' a d' f'] r8 [a16 d'] [f' a d' f'] | - r8 [g16 d'] [f' g d' f'] r8 [g16 d'] [f' g d' f'] | - r8 [g16 c'] [e' g c' e'] r8 [g16 c'] [e' g c' e'] | - r8 [a16 e'] [a' a e' a'] r8 [a16 e'] [a' a e' a'] | - r8 [fis16 a] [d' fis a d'] r8 [fis16 a] [d' fis a d'] | - r8 [g16 d'] [g' g d' g'] r8 [g16 d'] [g' g d' g'] | - r8 [e16 g] [c' e g c'] r8 [e16 g] [c' e g c'] | - r8 [e16 g] [c' e g c'] r8 [e16 g] [c' e g c'] |} - % Tenor - {\stemdown - r16 e8. ~ e4 r16 e8. ~ e4 | - r16 d8. ~ d4 r16 d8. ~ d4 | - r16 d8. ~ d4 r16 d8. ~ d4 | - r16 e8. ~ e4 r16 e8. ~ e4 | - r16 e8. ~ e4 r16 e8. ~ e4 | - r16 d8. ~ d4 r16 d8. ~ d4 | - r16 d8. ~ d4 r16 d8. ~ d4 | - r16 c8. ~ c4 r16 c8. ~ c4 | - r16 c8. ~ c4 r16 c8. ~ c4 |}> -%% 10 - r8 [d16 fis] [c' d fis c'] r8 [d16 fis] [c' d fis c'] | - r8 [d16 g] [b d g b] r8 [d16 g] [b d g b] | - r8 [e16 g] [cis' e g cis'] r8 [e16 g] [cis' e g cis'] | - r8 [d16 a] [d' d a d'] r8 [d16 a] [d' d a d'] | - r8 [d16 f] [b d f b] r8 [d16 f] [b d f b] | - r8 [c16 g] [c' c g c'] r8 [c16 g] [c' c g c'] | - r8 ['a16 c] [f 'a c f] r8 ['a16 c] [f 'a c f] | - r8 ['a16 c] [f 'a c f] r8 ['a16 c] [f 'a c f] | - r8 ['g16 'b] [f 'g 'b f] r8 ['g16 'b] [f 'g 'b f] | - r8 ['g16 c] [e 'g c e] r8 ['g16 c] [e 'g c e] | -%% 20 - r8 ['bes16 c] [e 'bes c e] r8 ['bes16 c] [e 'bes c e] | - r8 ['a16 c] [e 'a c e] r8 ['a16 c] [e 'a c e] | - r8 ['a16 c] [ees 'a c ees] r8 ['a16 c] [ees 'a c ees] | - r8 ['b16 c] [d 'b c d] r8 ['b16 c] [d 'b c d] | - r8 ['g16 'b] [d 'g 'b d] r8 ['g16 'b] [d 'g 'b d] | - r8 ['g16 c] [e 'g c e] r8 ['g16 c] [e 'g c e] | - r8 ['g16 c] [f 'g c f] r8 ['g16 c] [f 'g c f] | - r8 ['g16 'b] [f 'g 'b f] r8 ['g16 'b] [f 'g 'b f] | - r8 ['a16 c] [fis 'a c fis] r8 ['a16 c] [fis 'a c fis] | - r8 ['g16 c] [g 'g c g] r8 ['g16 c] [g 'g c g] | -%% 30 - r8 ['g16 c] [f 'g c f] r8 ['g16 c] [f 'g c f] | - r8 ['g16 'b] [f 'g 'b f] r8 ['g16 'b] [f 'g 'b f] | - r8 ['g16 'bes] [e 'g 'bes e] r8 ['g16 'bes] [e 'g 'bes e] | - - r8 ['f16 'a] [c f c 'a] [c 'a 'f 'a] ['f 'd 'f 'd] | - r8 [g16 b] [d' f' d' b] [d' b g b] [d f e d] | - || - } - -bass = - \melodic { - \clef "bass"; - \octave c; - - \stemdown - c'2 c' | - c' c' | - b b | - c' c' | - c' c' | - c' c' | - b b | - b b | - a a | -%% 10 - \multi 2 < - % Alt - {\stemup - r16 a8. ~ a4 r16 a8. ~ a4 | - r16 b8. ~ b4 r16 b8. ~ b4 | - r16 bes8. ~ bes4 r16 bes8. ~ bes4 | - r16 a8. ~ a4 r16 a8. ~ a4 | - r16 aes8. ~ aes4 r16 aes8. ~ aes4 | - r16 g8. ~ g4 r16 g8. ~ g4 | - r16 f8. ~ f4 r16 f8. ~ f4 | - r16 f8. ~ f4 r16 f8. ~ f4 | - r16 d8. ~ d4 r16 d8. ~ d4 | - r16 e8. ~ e4 r16 e8. ~ e4 | -%% 20 - r16 g8. ~ g4 r16 g8. ~ g4 | - r16 f8. ~ f4 r16 f8. ~ f4 | - r16 c8. ~ c4 r16 c8. ~ c4 | - r16 f8. ~ f4 r16 f8. ~ f4 | - r16 f8. ~ f4 r16 f8. ~ f4 | - r16 e8. ~ e4 r16 e8. ~ e4 | - r16 d8. ~ d4 r16 d8. ~ d4 | - r16 d8. ~ d4 r16 d8. ~ d4 | - r16 ees8. ~ ees4 r16 ees8. ~ ees4 | - r16 e!8. ~ e4 r16 e8. ~ e4 | -%% 30 - r16 d8. ~ d4 r16 d8. ~ d4 | - r16 d8. ~ d4 r16 d8. ~ d4 | - r16 c8. ~ c4 r16 c8. ~ c4 | - - r16 c8. ~ c4 ~ c2 | - r16 'b8. ~ 'b4 ~ 'b2 | - c1 ||} - - % Bass - {\stemdown - d2 d | - g g | - g g | - f f | - f f | - e e | - e e | - d d | - 'g 'g | - c c | -%% 20 - c c | - 'f 'f | - 'fis 'fis | - 'aes 'aes | - 'g 'g | - 'g 'g | - 'g 'g | - 'g 'g | - 'g 'g | - 'g 'g | -%% 30 - 'g 'g | - 'g 'g | - 'c 'c | - - 'c 'c | - 'c 'c | - 'c1 }> - } - - -\score { - \melodic \type Grandstaff < - < - \global - \soprane - > - < - \global - \bass - > - > - - \paper{ - gourlay_maxmeasures =5.; - } - \midi { - \tempo 4 = 84; - } -} - -% EOF diff --git a/input/wtk1-prelude2.ly.m4 b/input/wtk1-prelude2.ly.m4 deleted file mode 100644 index 98f6c8a309..0000000000 --- a/input/wtk1-prelude2.ly.m4 +++ /dev/null @@ -1,88 +0,0 @@ -%% under construction - -define(preludepattern, `[' $1 $2 $3 $2 `]') -define(preludehalfmeasure, preludepattern($1, $2, $3) - preludepattern($4, $2, $3)) - -define(intromeasure, - preludehalfmeasure($1, $2, $3, $4) - preludehalfmeasure($1, $2, $3, $4)| -) -define(handymeasure, `intromeasure(translit($*,` ', `,'))') - - - -trebleIntro=\melodic { -\octave c'; -handymeasure(c' es d c) -handymeasure(as f e c) -handymeasure(b f es d) -handymeasure(c g f es) -handymeasure(es' as g es) -handymeasure(d' fis e d) -handymeasure(d' g fis d) -handymeasure(c' e d c) -handymeasure(c' f e c) -handymeasure(bes f es d) -handymeasure(bes g f es) -handymeasure(as g f es) -handymeasure(as d c Bes) -handymeasure(g Bes As es) -handymeasure(f c Bes A) -handymeasure(f d c B) -handymeasure(es c B G) -handymeasure(F es d f) -handymeasure(Fis c b es) -handymeasure(es c B G) -handymeasure(fis c B A) -handymeasure(g c B d) -handymeasure(as c B d) -} - -bassIntro = \melodic { -\octave c; -handymeasure(c g f es) -handymeasure(c as g f) -handymeasure(c as g f) -handymeasure(c es d g) -handymeasure(c c' bes as) -handymeasure(c a g fis) -handymeasure(Bes bes a g) -handymeasure(Bes g f e) -handymeasure(As as g f) -handymeasure(As d c f) -handymeasure(G es d g) -handymeasure(c es d As) -handymeasure(d f es as) -handymeasure(es g f as) -handymeasure(es a g f) -handymeasure(d f es as) -handymeasure(c f e as) -preludehalfmeasure(c, es, d, f) -preludehalfmeasure(bes, es, d, f)| -handymeasure(As c b d) -handymeasure(A es d c) -handymeasure(G es d f) -handymeasure(G es d c) -handymeasure(G es d f) -handymeasure(G es d f) -} - - -middlepiece = \melodic -{ - \octave c; - \stemdown - [G B d] - \stemup f [as f ef] [b f d' b'] [as f e f] | - \stemdown [G c es]] - \stemup g [c' g fis g ] [es' c' g' es'] [c' as g as]| - \stemdown [G A fis] - \translator Staff=treble - \stemsboth \octave c'; - c [es c B c] [fis c a fis] [es c B c] | -} - - - -} diff --git a/lib/binary-source-file.cc b/lib/binary-source-file.cc index 111ee743e6..75d7ce24ca 100644 --- a/lib/binary-source-file.cc +++ b/lib/binary-source-file.cc @@ -17,47 +17,47 @@ #include "binary-source-file.hh" #include "string-convert.hh" -Binary_source_file::Binary_source_file(String& filename_str) - : Source_file(filename_str) +Binary_source_file::Binary_source_file (String& filename_str) + : Source_file (filename_str) { } -Binary_source_file::~Binary_source_file() +Binary_source_file::~Binary_source_file () { } String -Binary_source_file::error_str(char const* pos_ch_c_l) const +Binary_source_file::error_str (char const* pos_ch_c_l) const { - assert(this); - if (!in_b(pos_ch_c_l)) + assert (this); + if (!in_b (pos_ch_c_l)) return ""; - char const* begin_ch_c_l = pos_ch_c_l - 8 >? ch_C(); - char const* end_ch_c_l = pos_ch_c_l + 7 ? ch_C (); + char const* end_ch_c_l = pos_ch_c_l + 7 Duration_convert::dur_array_s; String -Duration_convert::dur2_str(Duration dur) +Duration_convert::dur2_str (Duration dur) { if (dur.ticks_i_) - return String("[") + String(dur.ticks_i_) + "]"; + return String ("[") + String (dur.ticks_i_) + "]"; String str; if (dur.durlog_i_ >= 0) - str = String( type2_i(dur.durlog_i_) ); + str = String ( type2_i (dur.durlog_i_) ); else if (dur.durlog_i_ == -1) str = "\\breve"; else if (dur.durlog_i_ == -2) str = "\\longa"; - str += String('.', dur.dots_i_); - if (dur.plet_b()) - str += String("*") + String(dur.plet_.iso_i_) - + String("/") + String(dur.plet_.type_i_); + str += String ('.', dur.dots_i_); + if (dur.plet_b ()) + str += String ("*") + String (dur.plet_.iso_i_) + + String ("/") + String (dur.plet_.type_i_); return str; } #if 0 int -Duration_convert::dur2_i(Duration dur, int division_1_i) +Duration_convert::dur2_i (Duration dur, int division_1_i) { - return dur2_mom(dur) * Moment(division_1_i); + return dur2_mom (dur) * Moment (division_1_i); } #endif int -Duration_convert::dur2ticks_i(Duration dur) +Duration_convert::dur2ticks_i (Duration dur) { if (dur.ticks_i_) return dur.ticks_i_; - return dur2_mom(dur) * Moment(Duration::division_1_i_s); + return dur2_mom (dur) * Moment (Duration::division_1_i_s); } int -Duration_convert::i2_type(int i) +Duration_convert::i2_type (int i) { int t=0; while (!(i & 1)) { @@ -67,7 +67,7 @@ Duration_convert::i2_type(int i) } int -Duration_convert::type2_i(int type) +Duration_convert::type2_i (int type) { if (type<0) return 0; @@ -76,19 +76,19 @@ Duration_convert::type2_i(int type) } Moment -Duration_convert::dur2_mom(Duration dur) +Duration_convert::dur2_mom (Duration dur) { if (dur.ticks_i_) - return Moment(dur.ticks_i_, Duration::division_1_i_s); + return Moment (dur.ticks_i_, Duration::division_1_i_s); // or simply assert? if (dur.durlog_i_<-10) - return Moment(0); + return Moment (0); Moment mom; if (dur.durlog_i_<0) - mom = Moment(type2_i(-dur.durlog_i_), 1); + mom = Moment (type2_i (-dur.durlog_i_), 1); else - mom = Moment(1 , type2_i(dur.durlog_i_)); + mom = Moment (1 , type2_i (dur.durlog_i_)); Moment delta = mom; while (dur.dots_i_--) @@ -97,66 +97,66 @@ Duration_convert::dur2_mom(Duration dur) mom += delta; } - return mom * plet_factor_mom(dur); + return mom * plet_factor_mom (dur); } #if 0 Moment -Duration_convert::i2_mom(int time_i, int division_1_i) +Duration_convert::i2_mom (int time_i, int division_1_i) { if (!time_i) - return Moment(0); + return Moment (0); if (division_1_i > 0) - return Moment(time_i, division_1_i); + return Moment (time_i, division_1_i); else - return Moment(-division_1_i, time_i); + return Moment (-division_1_i, time_i); } #endif Duration -Duration_convert::mom2_dur(Moment mom) +Duration_convert::mom2_dur (Moment mom) { if (!mom) { Duration dur; - dur.set_plet(0,1); + dur.set_plet (0,1); return dur; } - Duration dur = mom2standardised_dur(mom); - // if (!dur.mom() || (dur.mom() == mom)) - if (!dur.length() || (dur.length() == mom)) + Duration dur = mom2standardised_dur (mom); + // if (!dur.mom () || (dur.mom () == mom)) + if (!dur.length () || (dur.length () == mom)) return dur; - assert(midi_as_plet_b_s); + assert (midi_as_plet_b_s); - // dur.set_plet(type_mom, Duration::division_1_i_s / 4); + // dur.set_plet (type_mom, Duration::division_1_i_s / 4); - // Moment as_plet_mom = mom / dur.mom(); - Moment as_plet_mom = mom / dur.length(); - as_plet_mom *= dur.plet_.mom(); - long num = as_plet_mom.numerator().as_long(); - long den = as_plet_mom.denominator().as_long(); - dur.set_plet(num, den); + // Moment as_plet_mom = mom / dur.mom (); + Moment as_plet_mom = mom / dur.length (); + as_plet_mom *= dur.plet_.mom (); + long num = as_plet_mom.numerator ().as_long (); + long den = as_plet_mom.denominator ().as_long (); + dur.set_plet (num, den); return dur; } Duration -Duration_convert::mom2standardised_dur(Moment mom) +Duration_convert::mom2standardised_dur (Moment mom) { - // if (!dur_array_s.length_i()) - if (!dur_array_s.size()) - set_array(); - assert(dur_array_s.size()); - for (int i = 0; i < dur_array_s.size() - 1; i++) + // if (!dur_array_s.length_i ()) + if (!dur_array_s.size ()) + set_array (); + assert (dur_array_s.size ()); + for (int i = 0; i < dur_array_s.size () - 1; i++) { - Moment lower_mom = dur2_mom(dur_array_s[ i ]); + Moment lower_mom = dur2_mom (dur_array_s[ i ]); if (mom <= lower_mom) { // all arbitrary, but 3/4 will get rid of the noise... // kinda ok - if (i || (mom / lower_mom > Moment(3, 4))) + if (i || (mom / lower_mom > Moment (3, 4))) return dur_array_s[ i ]; else { @@ -165,107 +165,107 @@ Duration_convert::mom2standardised_dur(Moment mom) return d; } } - Moment upper_mom = dur2_mom(dur_array_s[ i + 1 ]); + Moment upper_mom = dur2_mom (dur_array_s[ i + 1 ]); if ((mom < upper_mom) && ((mom - lower_mom) / lower_mom < (upper_mom - mom) / upper_mom)) return dur_array_s[ i ]; } - return dur_array_s[ dur_array_s.size() - 1 ]; + return dur_array_s[ dur_array_s.size () - 1 ]; } void -Duration_convert::set_array() +Duration_convert::set_array () { - dur_array_s.clear(); + dur_array_s.clear (); Duration_iterator iter_dur; - assert(iter_dur); + assert (iter_dur); while (iter_dur) - dur_array_s.push(iter_dur++); + dur_array_s.push (iter_dur++); } Moment -Duration_convert::plet_factor_mom(Duration dur) +Duration_convert::plet_factor_mom (Duration dur) { - return dur.plet_.mom(); + return dur.plet_.mom (); } Real -Duration_convert::sync_f(Duration dur, Moment mom) +Duration_convert::sync_f (Duration dur, Moment mom) { - return mom / dur2_mom(dur); + return mom / dur2_mom (dur); } Duration -Duration_convert::ticks2_dur(int ticks_i) +Duration_convert::ticks2_dur (int ticks_i) { - // Duration dur(4, 0); - // dur.set_plet(ticks_i, Duration::division_1_i_s / 4); + // Duration dur (4, 0); + // dur.set_plet (ticks_i, Duration::division_1_i_s / 4); - Moment mom(ticks_i, Duration::division_1_i_s); + Moment mom (ticks_i, Duration::division_1_i_s); if (midi_as_plet_b_s) - return mom2_dur(mom); + return mom2_dur (mom); - Duration dur = mom2standardised_dur(mom); + Duration dur = mom2standardised_dur (mom); - // if (dur.mom() == mom) - if (dur.length() == mom) + // if (dur.mom () == mom) + if (dur.length () == mom) return dur; // huh? #if 0 dur.durlog_i_ = -100; dur.dots_i_ = 0; - dur.set_ticks(ticks_i); + dur.set_ticks (ticks_i); return dur; #else - return mom2_dur(mom); + return mom2_dur (mom); #endif } Duration -Duration_convert::ticks2standardised_dur(int ticks_i) +Duration_convert::ticks2standardised_dur (int ticks_i) { - Moment mom(ticks_i, Duration::division_1_i_s); - Duration dur = mom2standardised_dur(mom); + Moment mom (ticks_i, Duration::division_1_i_s); + Duration dur = mom2standardised_dur (mom); return dur; } -Duration_iterator::Duration_iterator() +Duration_iterator::Duration_iterator () { cursor_dur_.durlog_i_ = 7; if (Duration_convert::no_smaller_than_i_s) cursor_dur_.durlog_i_ = Duration_convert::no_smaller_than_i_s; - // cursor_dur_.set_plet(1, 1); + // cursor_dur_.set_plet (1, 1); } Duration Duration_iterator::operator ++(int) { - return forward_dur(); + return forward_dur (); } Duration Duration_iterator::operator ()() { - return dur(); + return dur (); } -Duration_iterator::operator bool() +Duration_iterator::operator bool () { - return ok(); + return ok (); } Duration -Duration_iterator::dur() +Duration_iterator::dur () { return cursor_dur_; } Duration -Duration_iterator::forward_dur() +Duration_iterator::forward_dur () { /* should do smart table? guessing: duration wholes @@ -279,63 +279,63 @@ Duration_iterator::forward_dur() 8. 0.1875 */ - assert(ok()); + assert (ok ()); Duration dur = cursor_dur_; - if (!cursor_dur_.dots_i_ && !cursor_dur_.plet_b()) + if (!cursor_dur_.dots_i_ && !cursor_dur_.plet_b ()) { cursor_dur_.durlog_i_ += 1; cursor_dur_.dots_i_ = 2; } else if (cursor_dur_.dots_i_ == 2) { - assert(!cursor_dur_.plet_b()); + assert (!cursor_dur_.plet_b ()); cursor_dur_.dots_i_ = 0; cursor_dur_.durlog_i_ -=2; - cursor_dur_.set_plet(2, 3); + cursor_dur_.set_plet (2, 3); } - else if (cursor_dur_.plet_b() + else if (cursor_dur_.plet_b () && (cursor_dur_.plet_.iso_i_ == 2) && (cursor_dur_.plet_.type_i_ == 3)) { - assert(!cursor_dur_.dots_i_); - cursor_dur_.set_plet(1, 1); + assert (!cursor_dur_.dots_i_); + cursor_dur_.set_plet (1, 1); cursor_dur_.durlog_i_ += 1; cursor_dur_.dots_i_ = 1; } else if (cursor_dur_.dots_i_ == 1) { - assert(!cursor_dur_.plet_b()); + assert (!cursor_dur_.plet_b ()); cursor_dur_.dots_i_ = 0; cursor_dur_.durlog_i_ -= 1; } if (Duration_convert::no_triplets_b_s - && cursor_dur_.plet_b() && ok()) - forward_dur(); + && cursor_dur_.plet_b () && ok ()) + forward_dur (); if (Duration_convert::no_double_dots_b_s - && (cursor_dur_.dots_i_ == 2) && ok()) - forward_dur(); + && (cursor_dur_.dots_i_ == 2) && ok ()) + forward_dur (); if (Duration_convert::no_smaller_than_i_s - && (cursor_dur_.durlog_i_ > Duration_convert::no_smaller_than_i_s) && ok()) - forward_dur(); + && (cursor_dur_.durlog_i_ > Duration_convert::no_smaller_than_i_s) && ok ()) + forward_dur (); if (Duration_convert::no_smaller_than_i_s && cursor_dur_.dots_i_ && (cursor_dur_.durlog_i_ >= Duration_convert::no_smaller_than_i_s) - && ok()) - forward_dur(); + && ok ()) + forward_dur (); if (Duration_convert::no_smaller_than_i_s && (cursor_dur_.dots_i_ == 2) && (cursor_dur_.durlog_i_ >= Duration_convert::no_smaller_than_i_s / 2) - && ok()) - forward_dur(); + && ok ()) + forward_dur (); return dur; } bool -Duration_iterator::ok() +Duration_iterator::ok () { return (cursor_dur_.durlog_i_ && !((cursor_dur_.durlog_i_ == 0) && (cursor_dur_.dots_i_ > 2))); diff --git a/lib/duration.cc b/lib/duration.cc index f04c5e42c0..eca46dd12b 100644 --- a/lib/duration.cc +++ b/lib/duration.cc @@ -21,7 +21,7 @@ int Duration::division_1_i_s = 384 * 4; -Duration::Duration() +Duration::Duration () { durlog_i_ = 0; dots_i_ = 0; @@ -29,53 +29,53 @@ Duration::Duration() } bool -Duration::duration_type_b(int t) +Duration::duration_type_b (int t) { /* ugh. Assuming behavior of conversion funcs on broken input. */ - return t == Duration_convert::type2_i(Duration_convert::i2_type(t)); + return t == Duration_convert::type2_i (Duration_convert::i2_type (t)); } // ugh, what's this? -// i should be called "mom()", ... or at least "length_mom()" +// i should be called "mom ()", ... or at least "length_mom ()" Moment -Duration::length() const +Duration::length () const { - return Duration_convert::dur2_mom(*this); + return Duration_convert::dur2_mom (*this); } void -Duration::set_plet(int i, int t) +Duration::set_plet (int i, int t) { plet_.iso_i_ = i; plet_.type_i_ = t; } void -Duration::set_plet(Duration d) +Duration::set_plet (Duration d) { plet_.iso_i_ = d.plet_.iso_i_; plet_.type_i_ = d.plet_.type_i_; } void -Duration::set_ticks(int ticks_i) +Duration::set_ticks (int ticks_i) { - assert(durlog_i_ <10); - assert(!dots_i_); + assert (durlog_i_ <10); + assert (!dots_i_); ticks_i_ = ticks_i; } String -Duration::str() const +Duration::str () const { - return Duration_convert::dur2_str(*this); + return Duration_convert::dur2_str (*this); } bool -Duration::plet_b() +Duration::plet_b () { - return !plet_.unit_b(); + return !plet_.unit_b (); } diff --git a/lib/includable-lexer.cc b/lib/includable-lexer.cc index ca103a9c9e..3728476203 100644 --- a/lib/includable-lexer.cc +++ b/lib/includable-lexer.cc @@ -13,7 +13,7 @@ #define YY_BUF_SIZE 16384 #endif -Includable_lexer::Includable_lexer() +Includable_lexer::Includable_lexer () { yy_current_buffer = 0; } @@ -21,22 +21,22 @@ Includable_lexer::Includable_lexer() /** set the new input to s, remember old file. */ void -Includable_lexer::new_input(String s, Sources * global_sources) +Includable_lexer::new_input (String s, Sources * global_sources) { - Source_file * sl = global_sources->get_file_l(s); + Source_file * sl = global_sources->get_file_l (s); if (!sl) { - String msg =_("Can't find file `") + s+ "'"; - LexerError(msg.ch_C ()); + String msg =_ ("Can't find file `") + s+ "'"; + LexerError (msg.ch_C ()); return; } - char_count_stack_.push(0); + char_count_stack_.push (0); if (yy_current_buffer) - state_stack_.push(yy_current_buffer); + state_stack_.push (yy_current_buffer); cout << "[" << s<istream_l(), YY_BUF_SIZE)); + yy_switch_to_buffer (yy_create_buffer (sl->istream_l (), YY_BUF_SIZE)); } /** pop the inputstack. conceptually this is a destructor, but it does not destruct the Source_file that Includable_lexer::new_input creates. */ bool -Includable_lexer::close_input() +Includable_lexer::close_input () { - include_stack_.pop(); - char_count_stack_.pop(); + include_stack_.pop (); + char_count_stack_.pop (); cout << "]"<ch_C() + char_count_stack_.top(); + return include_stack_.top ()->ch_C () + char_count_stack_.top (); } -Includable_lexer::~Includable_lexer() +Includable_lexer::~Includable_lexer () { - while (!include_stack_.empty()) + while (!include_stack_.empty ()) { - close_input(); + close_input (); } } /** @@ -89,16 +89,16 @@ Includable_lexer::~Includable_lexer() don't know about the location of the lexer. Add this as a YY_USER_ACTION */ void -Includable_lexer::add_lexed_char(int count) +Includable_lexer::add_lexed_char (int count) { - char_count_stack_.top() += count; + char_count_stack_.top () += count; } Source_file* -Includable_lexer::source_file_l() const +Includable_lexer::source_file_l () const { - if (include_stack_.empty()) + if (include_stack_.empty ()) return 0; else - return include_stack_.top(); + return include_stack_.top (); } diff --git a/lib/include/binary-source-file.hh b/lib/include/binary-source-file.hh index 9733c1b86b..33ee6bd784 100644 --- a/lib/include/binary-source-file.hh +++ b/lib/include/binary-source-file.hh @@ -10,11 +10,11 @@ class Binary_source_file : public Source_file { public: - Binary_source_file(String& filename_str ); - virtual ~Binary_source_file(); + Binary_source_file (String& filename_str ); + virtual ~Binary_source_file (); - virtual String error_str(char const* pos_ch_c_l ) const; - virtual int line_i(char const* pos_ch_c_l ) const; + virtual String error_str (char const* pos_ch_c_l ) const; + virtual int line_i (char const* pos_ch_c_l ) const; }; #endif // BINARY_SOURCE_FILE_HH // diff --git a/lib/include/duration-convert.hh b/lib/include/duration-convert.hh index 3f8bda96a4..e3926f030c 100644 --- a/lib/include/duration-convert.hh +++ b/lib/include/duration-convert.hh @@ -24,11 +24,11 @@ SUGGESTION: currently a moment in time is called moment too; let-s typedef Rational When too, so that we get - When Staff_column::when(), Moment Voice_element::mom(). + When Staff_column::when (), Moment Voice_element::mom (). [todo] move all statics to real members, instantiate Duration_convert - object(s). + object (s). */ struct Duration_convert { @@ -45,77 +45,77 @@ struct Duration_convert { // static int const division_1_c_i = 384; // /// Return (integer, division) representation. -// static int dur2_i(Duration dur, int division_1_i = division_1_c_i ); +// static int dur2_i (Duration dur, int division_1_i = division_1_c_i ); /// Return number of ticks in (ticks, division_1) representation - static int dur2ticks_i(Duration dur ); + static int dur2ticks_i (Duration dur ); /// Return the type_i representation of note length i - static int i2_type(int i); + static int i2_type (int i); /// Return the note length corresponding to the type_i representation /// Return 0 if longer than whole note. - static int type2_i(int type); + static int type2_i (int type); /// Return Moment representation (fraction of whole note). - static Moment dur2_mom(Duration dur ); + static Moment dur2_mom (Duration dur ); /// Return Mudela string representation. - static String dur2_str(Duration dur ); + static String dur2_str (Duration dur ); // /// Return Moment from (integer, division) representation. -// static Moment i2_mom(int i, int division_1_i = division_1_c_i ); +// static Moment i2_mom (int i, int division_1_i = division_1_c_i ); // /// Return Moment (fraction of whole) representation, best guess. -// static Duration mom2_dur(Moment mom ); +// static Duration mom2_dur (Moment mom ); /// Return duration from Moment (fraction of whole) representation. - static Duration mom2_dur(Moment mom ); + static Duration mom2_dur (Moment mom ); /// Return standardised duration, best guess if not exact. - static Duration mom2standardised_dur(Moment mom ); + static Duration mom2standardised_dur (Moment mom ); /// Return plet factor (not a Moment: should use Rational?). - static Moment plet_factor_mom(Duration dur ); + static Moment plet_factor_mom (Duration dur ); - static void set_array(); + static void set_array (); /** Return synchronisation factor for mom, so that - mom2_dur(mom / sync_f ) will return the duration dur. + mom2_dur (mom / sync_f ) will return the duration dur. */ - static Real sync_f(Duration dur, Moment mom ); + static Real sync_f (Duration dur, Moment mom ); /// Return exact duration, in midi-ticks if not-exact. - static Duration ticks2_dur(int ticks_i ); + static Duration ticks2_dur (int ticks_i ); /// Return standardised duration, best guess if not exact. - static Duration ticks2standardised_dur(int ticks_i ); + static Duration ticks2standardised_dur (int ticks_i ); }; /// (iter_dur) struct Duration_iterator { /// start at shortest: 128:2/3 - Duration_iterator(); + Duration_iterator (); // **** what about these three here ? - /// return forward_dur(); + /// return forward_dur (); Duration operator ++(int); - /// return ok() - operator bool(); + /// return ok () + operator bool (); - /// return dur() + /// return dur () Duration operator ()(); // **** /// return current dur - Duration dur(); + Duration dur (); - /// return dur(), step to next - Duration forward_dur(); + /// return dur (), step to next + Duration forward_dur (); /// durations left? - bool ok(); + bool ok (); private: Duration cursor_dur_; diff --git a/lib/include/duration.hh b/lib/include/duration.hh index 49d5819bd9..642701e8d5 100644 --- a/lib/include/duration.hh +++ b/lib/include/duration.hh @@ -28,15 +28,15 @@ struct Duration { /** Ctor of Duration. */ - Duration(); + Duration (); /// is the "plet factor" of this note != 1 ? - bool plet_b(); - String str() const; - void set_plet(int,int ); - void set_plet(Duration ); - static bool duration_type_b(int t); - void set_ticks(int ticks_i ); - Moment length() const ; // zo naai mij + bool plet_b (); + String str () const; + void set_plet (int,int ); + void set_plet (Duration ); + static bool duration_type_b (int t); + void set_ticks (int ticks_i ); + Moment length () const ; // zo naai mij static int division_1_i_s; /// Logarithm of the base duration. diff --git a/lib/include/file-storage.hh b/lib/include/file-storage.hh index 23da07e19f..1ac150f592 100644 --- a/lib/include/file-storage.hh +++ b/lib/include/file-storage.hh @@ -12,51 +12,16 @@ #include "proto.hh" + /** store a file in-memory. */ class File_storage { public: - virtual char const* ch_C() const=0; - virtual int length_i() const=0; - virtual ~File_storage(){} -}; - -/** - Use mmap to "copy" a file into memory - */ -class Mapped_file_storage:public File_storage -{ -public: - Mapped_file_storage(String); -protected: - virtual char const* ch_C() const; - virtual int length_i() const; - virtual ~Mapped_file_storage(); -private: - void open(String name); - void close(); - - void map(); - void unmap(); - int fildes_i_; - off_t size_off_; - caddr_t data_caddr_; + virtual char const* ch_C () const=0; + virtual int length_i () const=0; + virtual ~File_storage (){} }; -/** - read file char by char and copy into a malloc array. - */ -class Simple_file_storage : public File_storage -{ - char * data_p_; - int len_i_; -protected: - virtual char const*ch_C() const; - virtual int length_i() const; - virtual ~Simple_file_storage(); -public: - Simple_file_storage(String); -}; #endif // FILE_STORAGE_HH diff --git a/lib/include/includable-lexer.hh b/lib/include/includable-lexer.hh index fb1a96d0bc..f9dce9696d 100644 --- a/lib/include/includable-lexer.hh +++ b/lib/include/includable-lexer.hh @@ -24,19 +24,19 @@ typedef struct yy_buffer_state *YY_BUFFER_STATE; an yyFlexLexer child with provisions for inclusion. */ class Includable_lexer : public yyFlexLexer { - Array state_stack_; + Array state_stack_; protected: - bool close_input(); - Array include_stack_; - Array char_count_stack_; + bool close_input (); + Array include_stack_; + Array char_count_stack_; public: - Source_file* source_file_l() const; - void new_input(String s,Sources*); - Includable_lexer(); - ~Includable_lexer(); - void add_lexed_char(int); - char const * here_ch_C(); + Source_file* source_file_l () const; + void new_input (String s,Sources*); + Includable_lexer (); + ~Includable_lexer (); + void add_lexed_char (int); + char const * here_ch_C (); }; diff --git a/lib/include/input.hh b/lib/include/input.hh index 579f829c14..f82ba2d224 100644 --- a/lib/include/input.hh +++ b/lib/include/input.hh @@ -20,15 +20,15 @@ class Input { Source_file * source_file_l_; public: - void warning(String) const; // should use member func? - void error(String) const; - void message(String) const; - void set_spot(Input const &); + void warning (String) const; // should use member func? + void error (String) const; + void message (String) const; + void set_spot (Input const &); - String location_str() const; - Input(Source_file*, char const*); - Input(); - Input(Input const& ); + String location_str () const; + Input (Source_file*, char const*); + Input (); + Input (Input const& ); }; #endif // INPUT_HH diff --git a/lib/include/mapped-file-storage.hh b/lib/include/mapped-file-storage.hh new file mode 100644 index 0000000000..4ca29a3006 --- /dev/null +++ b/lib/include/mapped-file-storage.hh @@ -0,0 +1,40 @@ +/* + mapped-file-storage.hh -- declare Mapped_file_storage + + source file of the GNU LilyPond music typesetter + + (c) 1997 Han-Wen Nienhuys + + */ + +#ifndef MAPPED_FILE_STORAGE_HH +#define MAPPED_FILE_STORAGE_HH + + + +#include "file-storage.hh" + +/** + Use mmap to "copy" a file into memory + */ +class Mapped_file_storage:public File_storage +{ +public: + Mapped_file_storage (String); +protected: + virtual char const* ch_C () const; + virtual int length_i () const; + virtual ~Mapped_file_storage (); +private: + void open (String name); + void close (); + + void map (); + void unmap (); + int fildes_i_; + off_t size_off_; + caddr_t data_caddr_; +}; + +#endif /* MAPPED_FILE_STORAGE_HH */ + diff --git a/lib/include/moment.hh b/lib/include/moment.hh index bbd3388e74..f9d234d71f 100644 --- a/lib/include/moment.hh +++ b/lib/include/moment.hh @@ -18,7 +18,7 @@ Can't we name this Saint_jut_mom (Sintjuttemis ?) */ -const infinity_mom = Rational(INT_MAX); +const infinity_mom = Rational (INT_MAX); class String; typedef Rational Moment; diff --git a/lib/include/plet.hh b/lib/include/plet.hh index 2326416716..ecedcc4d43 100644 --- a/lib/include/plet.hh +++ b/lib/include/plet.hh @@ -17,9 +17,9 @@ (plet) */ struct Plet { - Plet(); - Moment mom() const; - bool unit_b() const; + Plet (); + Moment mom () const; + bool unit_b () const; int iso_i_; // 2/3; 2 is not duration, maar of count! int type_i_; }; diff --git a/lib/include/simple-file-storage.hh b/lib/include/simple-file-storage.hh new file mode 100644 index 0000000000..78a00d8651 --- /dev/null +++ b/lib/include/simple-file-storage.hh @@ -0,0 +1,31 @@ +/* + simple-file-storage.hh -- declare + + source file of the GNU LilyPond music typesetter + + (c) 1997 Han-Wen Nienhuys + + */ + +#ifndef SIMPLE_FILE_STORAGE_HH +#define SIMPLE_FILE_STORAGE_HH + +#include "file-storage.hh" + +/** + read file char by char and copy into a malloc array. + */ +class Simple_file_storage : public File_storage +{ + char * data_p_; + int len_i_; +protected: + virtual char const*ch_C () const; + virtual int length_i () const; + virtual ~Simple_file_storage (); +public: + Simple_file_storage (String); +}; + +#endif /* SIMPLE_FILE_STORAGE_HH */ + diff --git a/lib/include/source-file.hh b/lib/include/source-file.hh index 9b084a3280..d5346be5f7 100644 --- a/lib/include/source-file.hh +++ b/lib/include/source-file.hh @@ -16,24 +16,24 @@ class istream; class Source_file { public: - /** Ugh! filename gets changed! The path to the opened file may - change, since it might be searched in multiple directories. */ - Source_file(String filename_str_r ); - virtual ~Source_file(); - - char const* ch_C() const; - virtual String error_str(char const* pos_ch_c_l ) const; - istream * istream_l(); - bool in_b(char const* pos_ch_c_l ) const; - int length_i() const; - virtual int line_i(char const* pos_ch_c_l ) const; - String name_str() const; - String file_line_no_str(char const* ch_c_l ) const; + /** Ugh! filename gets changed! The path to the opened file may + change, since it might be searched in multiple directories. */ + Source_file (String filename_str_r ); + virtual ~Source_file (); + + char const* ch_C () const; + virtual String error_str (char const* pos_ch_c_l ) const; + istream * istream_l (); + bool in_b (char const* pos_ch_c_l ) const; + int length_i () const; + virtual int line_i (char const* pos_ch_c_l ) const; + String name_str () const; + String file_line_no_str (char const* ch_c_l ) const; private: - String name_str_; - istream* istream_p_; - File_storage * storage_p_; + String name_str_; + istream* istream_p_; + File_storage * storage_p_; }; #endif // SOURCE_FILE_HH // diff --git a/lib/include/source.hh b/lib/include/source.hh index 357647b9a1..f6a824fa70 100644 --- a/lib/include/source.hh +++ b/lib/include/source.hh @@ -12,18 +12,18 @@ class Sources { public: - Sources(); + Sources (); - Source_file * get_file_l(String &filename ); - Source_file* sourcefile_l(char const* ch_C ); - void set_path(File_path*p_C); - void set_binary(bool); + Source_file * get_file_l (String &filename ); + Source_file* sourcefile_l (char const* ch_C ); + void set_path (File_path*p_C); + void set_binary (bool); private: - const File_path * path_C_; - void add(Source_file* sourcefile_p ); - Pointer_list sourcefile_p_list_; - bool binary_b_ ; + const File_path * path_C_; + void add (Source_file* sourcefile_p ); + Pointer_list sourcefile_p_list_; + bool binary_b_ ; }; diff --git a/lib/include/warn.hh b/lib/include/warn.hh index 61ab2e6972..45edc4ba40 100644 --- a/lib/include/warn.hh +++ b/lib/include/warn.hh @@ -12,6 +12,6 @@ #include "string.hh" -void warning(String message_str ); -void error(String message_str); +void warning (String message_str ); +void error (String message_str); #endif // WARN_HH diff --git a/lib/include/windhoos-suck-suck-suck-thank-you-cygnus.hh b/lib/include/windhoos-suck-suck-suck-thank-you-cygnus.hh index cabfd3c5c4..95d60bfc33 100644 --- a/lib/include/windhoos-suck-suck-suck-thank-you-cygnus.hh +++ b/lib/include/windhoos-suck-suck-suck-thank-you-cygnus.hh @@ -1,15 +1,15 @@ // // windhoos-suck-suck-suck-thank-you-cygnus.hh // -// mmap() should work now (cygnus beta 18), but let's keep it here +// mmap () should work now (cygnus beta 18), but let's keep it here // for people using old cygnus releases #if 0 //def _WINDOWS32 #ifndef WINDHOOS_SUCK_SUCK_SUCK_HH #define WINDHOOS_SUCK_SUCK_SUCK_HH -caddr_t mmap(caddr_t addr, size_t len, int prot, int flags, int fd, off_t offset); +caddr_t mmap (caddr_t addr, size_t len, int prot, int flags, int fd, off_t offset); -int munmap(caddr_t addr, size_t len); +int munmap (caddr_t addr, size_t len); #endif // WINDHOOS_SUCK_SUCK_SUCK_HH #endif // _WINDOWS32 // diff --git a/lib/input.cc b/lib/input.cc index 7c5fed9720..e9cc3fd007 100644 --- a/lib/input.cc +++ b/lib/input.cc @@ -11,65 +11,65 @@ #include "source.hh" #include "source-file.hh" -Input::Input(Source_file*s, char const *cl) +Input::Input (Source_file*s, char const *cl) { source_file_l_=s; defined_ch_C_=cl; } -Input::Input() +Input::Input () { source_file_l_ = 0; defined_ch_C_ = 0; } -Input::Input(Input const &s) +Input::Input (Input const &s) { source_file_l_ = s.source_file_l_; defined_ch_C_ = s.defined_ch_C_; } void -Input::set_spot(Input const &i) +Input::set_spot (Input const &i) { *this = i; } void -Input::message(String message_str) const +Input::message (String message_str) const { String str = ""; if (source_file_l_) { - str += location_str() + String(": "); + str += location_str () + String (": "); } str += message_str; if (source_file_l_) { str += ":\n"; - str += source_file_l_->error_str(defined_ch_C_); + str += source_file_l_->error_str (defined_ch_C_); } cerr << str << endl; } void -Input::warning(String message_str) const +Input::warning (String message_str) const { - message(_("warning: ") + message_str); + message (_ ("warning: ") + message_str); } void -Input::error(String s) const +Input::error (String s) const { - message(_("error: ")+ s); + message (_ ("error: ")+ s); } String -Input::location_str() const +Input::location_str () const { if (source_file_l_) - return source_file_l_->file_line_no_str(defined_ch_C_); + return source_file_l_->file_line_no_str (defined_ch_C_); else - return _("(location unknown)"); + return _ ("(location unknown)"); } diff --git a/lib/mapped-file-storage.cc b/lib/mapped-file-storage.cc index ad39630b37..c318925b4e 100644 --- a/lib/mapped-file-storage.cc +++ b/lib/mapped-file-storage.cc @@ -1,11 +1,16 @@ +#ifdef HAIRY_STUFF + /* file-storage.cc -- implement Mapped_file_storage source file of the GNU LilyPond music typesetter (c) 1997 Han-Wen Nienhuys - Jan Nieuwenhuizen + Jan Nieuwenhuizen . + + Nextstep fixes by tiggr@ics.ele.tue.nl */ + #include // open, mmap #include // open #include // mmap @@ -18,84 +23,117 @@ +#ifdef __NeXT__ +#include +#include +#include +#endif + #include "string.hh" #include "proto.hh" #include "warn.hh" #include "file-storage.hh" -Mapped_file_storage::Mapped_file_storage(String s) +Mapped_file_storage::Mapped_file_storage (String s) { data_caddr_ = 0; fildes_i_ = 0; size_off_ = 0; - open(s); + open (s); } char const* -Mapped_file_storage::ch_C() const +Mapped_file_storage::ch_C () const { return (char const*)data_caddr_; } void -Mapped_file_storage::map() +Mapped_file_storage::map () { if (fildes_i_ == -1) return; - - data_caddr_ = (caddr_t)mmap((void*)0, size_off_, PROT_READ, MAP_SHARED, fildes_i_, 0); + +#ifdef __NeXT__ + /* Should be #if !HAVE_MMAP && HAVE_MAP_FD... */ + { + vm_offset_t address; + kern_return_t r; + + r = map_fd (fildes_i_, (vm_offset_t) 0, &address, TRUE, size_off_); + if (r != KERN_SUCCESS) + warning (String (_ ("map_fd: ")) + mach_error_string (r)); + else + data_caddr_ = (char *) address; + } +#else + + data_caddr_ = (caddr_t)mmap ((void*)0, size_off_, PROT_READ, MAP_SHARED, fildes_i_, 0); if ((int)data_caddr_ == -1) - warning(String(_("can't map: error no: ")) + strerror(errno)); + warning (String (_ ("can't map: error no: ")) + strerror (errno)); + +#endif } void -Mapped_file_storage::open(String name_str) +Mapped_file_storage::open (String name_str) { - fildes_i_ = ::open(name_str.ch_C (), O_RDONLY); + fildes_i_ = ::open (name_str.ch_C (), O_RDONLY); if (fildes_i_ == -1) { - warning(String(_("can't open: ")) + name_str + String(": ") + strerror(errno)); + warning (String (_ ("can't open: ")) + name_str + String (": ") + strerror (errno)); return; } struct stat file_stat; - fstat(fildes_i_, &file_stat); + fstat (fildes_i_, &file_stat); size_off_ = file_stat.st_size; - map(); + map (); } void -Mapped_file_storage::unmap() +Mapped_file_storage::unmap () { if (data_caddr_) { - munmap(data_caddr_, size_off_); +#ifdef __NeXT__ + kern_return_t r; + + r = vm_deallocate (task_self (), (vm_address_t) data_caddr_, +size_off_); + if (r != KERN_SUCCESS) + warning (String (_ ("vm_deallocate: ")) + mach_error_string (r)); +#else + munmap (data_caddr_, size_off_); +#endif + data_caddr_ = 0; size_off_ = 0; } } void -Mapped_file_storage::close() +Mapped_file_storage::close () { - unmap(); + unmap (); if (fildes_i_) { - ::close(fildes_i_); + ::close (fildes_i_); fildes_i_ = 0; } } int -Mapped_file_storage::length_i() const +Mapped_file_storage::length_i () const { return size_off_; } -Mapped_file_storage::~Mapped_file_storage() +Mapped_file_storage::~Mapped_file_storage () { - close(); + close (); } +#endif diff --git a/lib/moment.cc b/lib/moment.cc index 2557acb2a5..d521b233d3 100644 --- a/lib/moment.cc +++ b/lib/moment.cc @@ -11,9 +11,9 @@ #include "moment.hh" void -printm(Moment const &m) +printm (Moment const &m) { - cout << String(m) << flush; + cout << String (m) << flush; } diff --git a/lib/plet.cc b/lib/plet.cc index 686909382a..84579eca71 100644 --- a/lib/plet.cc +++ b/lib/plet.cc @@ -9,20 +9,20 @@ #include "plet.hh" -Plet::Plet() +Plet::Plet () { type_i_ = 1; iso_i_ = 1; } Moment -Plet::mom() const +Plet::mom () const { - return Moment(iso_i_, type_i_); + return Moment (iso_i_, type_i_); } bool -Plet::unit_b() const +Plet::unit_b () const { return type_i_ == 1 && iso_i_ == 1; } diff --git a/lib/simple-file-storage.cc b/lib/simple-file-storage.cc index e09bb1699a..b80724d987 100644 --- a/lib/simple-file-storage.cc +++ b/lib/simple-file-storage.cc @@ -8,7 +8,7 @@ #include -#include "file-storage.hh" +#include "simple-file-storage.hh" #include "varray.hh" #include "string.hh" #include "warn.hh" @@ -26,7 +26,7 @@ [Some versions later] The crashes aren't caused by the mmap code. But no reason to take it out, is there? */ -Simple_file_storage::Simple_file_storage(String s) +Simple_file_storage::Simple_file_storage (String s) { data_p_ =0; @@ -34,44 +34,44 @@ Simple_file_storage::Simple_file_storage(String s) let's hope that "b" opens anything binary, and does not apply CR/LF translation */ - FILE * f = (s.length_i ()) ? fopen (s.ch_C(), "rb") : stdin; + FILE * f = (s.length_i ()) ? fopen (s.ch_C (), "rb") : stdin; if (!f) { - warning(_("can't open file `") + s + "'"); + warning (_ ("can't open file `") + s + "'"); return ; } - int ret = fseek(f, 0, SEEK_END); - len_i_ = ftell(f); - rewind(f); + int ret = fseek (f, 0, SEEK_END); + len_i_ = ftell (f); + rewind (f); data_p_ = new char[len_i_+1]; data_p_[len_i_] = 0; - ret = fread(data_p_, sizeof(char), len_i_, f); + ret = fread (data_p_, sizeof (char), len_i_, f); if (ret!=len_i_) - warning (_("Huh? got ") + String(ret) + _(", expected ") - + String(len_i_) + _(" characters")); + warning (_ ("Huh? got ") + String (ret) + _ (", expected ") + + String (len_i_) + _ (" characters")); if (f != stdin) - fclose(f); + fclose (f); } char const* -Simple_file_storage::ch_C() const +Simple_file_storage::ch_C () const { return data_p_; } int -Simple_file_storage::length_i() const +Simple_file_storage::length_i () const { return len_i_; } -Simple_file_storage::~Simple_file_storage() +Simple_file_storage::~Simple_file_storage () { delete []data_p_; } diff --git a/lib/source-file.cc b/lib/source-file.cc index 66a13de2bb..b6153c984a 100644 --- a/lib/source-file.cc +++ b/lib/source-file.cc @@ -17,53 +17,53 @@ #include "warn.hh" #include "windhoos-suck-suck-suck-thank-you-cygnus.hh" #include "source-file.hh" -#include "file-storage.hh" +#include "simple-file-storage.hh" -Source_file::Source_file(String filename_str) +Source_file::Source_file (String filename_str) { name_str_ = filename_str; istream_p_ = 0; - storage_p_ = new Simple_file_storage(filename_str); + storage_p_ = new Simple_file_storage (filename_str); } istream* -Source_file::istream_l() +Source_file::istream_l () { /* - if (!name_str_.length_i()) + if (!name_str_.length_i ()) return &cin; */ if (!istream_p_) { - if (length_i()) // can-t this be done without such a hack? - istream_p_ = new istrstream(ch_C(), length_i()); + if (length_i ()) // can-t this be done without such a hack? + istream_p_ = new istrstream (ch_C (), length_i ()); else { - istream_p_ = new istrstream("", 0); - istream_p_->set(ios::eofbit); + istream_p_ = new istrstream ("", 0); + istream_p_->set (ios::eofbit); } } return istream_p_; } String -Source_file::file_line_no_str(char const *context_ch_C) const +Source_file::file_line_no_str (char const *context_ch_C) const { - if (!ch_C()) - return _("(unknown)"); + if (!ch_C ()) + return _ ("(unknown)"); else - return name_str() + ": " - + String(line_i(context_ch_C)); + return name_str () + ": " + + String (line_i (context_ch_C)); } String -Source_file::name_str() const +Source_file::name_str () const { return name_str_; } -Source_file::~Source_file() +Source_file::~Source_file () { delete istream_p_; istream_p_ = 0; @@ -71,12 +71,12 @@ Source_file::~Source_file() } String -Source_file::error_str(char const* pos_ch_C) const +Source_file::error_str (char const* pos_ch_C) const { - char const* data_ch_C = ch_C(); - char const * eof_C_ = data_ch_C + length_i(); - if (!in_b(pos_ch_C)) - return _("(position unknown)"); + char const* data_ch_C = ch_C (); + char const * eof_C_ = data_ch_C + length_i (); + if (!in_b (pos_ch_C)) + return _ ("(position unknown)"); if (pos_ch_C == eof_C_) @@ -97,8 +97,8 @@ Source_file::error_str(char const* pos_ch_C) const break; } - // String(char const* p, int length) is missing!? - String line_str((Byte const*)begin_ch_C, end_ch_C - begin_ch_C); + // String (char const* p, int length) is missing!? + String line_str ((Byte const*)begin_ch_C, end_ch_C - begin_ch_C); int error_col_i = 0; char const* scan_ch_C = begin_ch_C; @@ -108,28 +108,28 @@ Source_file::error_str(char const* pos_ch_C) const else error_col_i++; - String str = line_str.left_str(pos_ch_C - begin_ch_C) - + String('\n') - + String(' ', error_col_i) - + line_str.cut(pos_ch_C - begin_ch_C, INT_MAX); // String::mid should take 0 arg.. + String str = line_str.left_str (pos_ch_C - begin_ch_C) + + String ('\n') + + String (' ', error_col_i) + + line_str.cut (pos_ch_C - begin_ch_C, INT_MAX); // String::mid should take 0 arg.. return str; } bool -Source_file::in_b(char const* pos_ch_C) const +Source_file::in_b (char const* pos_ch_C) const { - return (pos_ch_C && (pos_ch_C >= ch_C()) && (pos_ch_C <= ch_C() + length_i())); + return (pos_ch_C && (pos_ch_C >= ch_C ()) && (pos_ch_C <= ch_C () + length_i ())); } int -Source_file::line_i(char const* pos_ch_C) const +Source_file::line_i (char const* pos_ch_C) const { - if (!in_b(pos_ch_C)) + if (!in_b (pos_ch_C)) return 0; int i = 1; - char const* scan_ch_C = ch_C(); + char const* scan_ch_C = ch_C (); if (!scan_ch_C) return 0; @@ -140,13 +140,13 @@ Source_file::line_i(char const* pos_ch_C) const } int -Source_file::length_i() const +Source_file::length_i () const { - return storage_p_->length_i(); + return storage_p_->length_i (); } char const * -Source_file::ch_C() const +Source_file::ch_C () const { - return storage_p_->ch_C(); + return storage_p_->ch_C (); } diff --git a/lib/source.cc b/lib/source.cc index 3f2daf6a23..d350b487ca 100644 --- a/lib/source.cc +++ b/lib/source.cc @@ -17,20 +17,20 @@ #include "source.hh" #include "path.hh" -Sources::Sources() +Sources::Sources () { path_C_= 0; binary_b_ = false; } void -Sources::set_binary(bool bo) +Sources::set_binary (bool bo) { binary_b_ = bo; } void -Sources::set_path(File_path *f_C) +Sources::set_path (File_path *f_C) { path_C_ = f_C; } @@ -44,25 +44,25 @@ Sources::set_path(File_path *f_C) @return 0 if no file found */ Source_file* -Sources::get_file_l(String &file_str) //UGH +Sources::get_file_l (String &file_str) //UGH { if (path_C_) { - String file_str_o = path_C_->find(file_str); + String file_str_o = path_C_->find (file_str); if ((file_str_o == "") && (file_str != "")) return 0; file_str = file_str_o; } Source_file * f_p= (!binary_b_) ? - new Source_file(file_str) : new Binary_source_file(file_str); - add(f_p); + new Source_file (file_str) : new Binary_source_file (file_str); + add (f_p); return f_p; } void -Sources::add(Source_file* sourcefile_p) +Sources::add (Source_file* sourcefile_p) { - sourcefile_p_list_.bottom().add(sourcefile_p); + sourcefile_p_list_.bottom ().add (sourcefile_p); } /** @@ -71,11 +71,11 @@ Sources::add(Source_file* sourcefile_p) @return 0 if not found. */ Source_file* -Sources::sourcefile_l(char const* ch_C) +Sources::sourcefile_l (char const* ch_C) { - PCursor sourcefile_l_pcur(sourcefile_p_list_.top()); - for (; sourcefile_l_pcur.ok(); sourcefile_l_pcur++) - if (sourcefile_l_pcur->in_b(ch_C)) + PCursor sourcefile_l_pcur (sourcefile_p_list_.top ()); + for (; sourcefile_l_pcur.ok (); sourcefile_l_pcur++) + if (sourcefile_l_pcur->in_b (ch_C)) return *sourcefile_l_pcur; return 0; } diff --git a/lib/template.cc b/lib/template.cc index 90f9818d85..36cb118232 100644 --- a/lib/template.cc +++ b/lib/template.cc @@ -12,5 +12,5 @@ #include "cursor.tcc" #include "list.tcc" -template LIST_INSTANTIATE(void *); -template POINTERLIST_INSTANTIATE(Source_file); +template LIST_INSTANTIATE (void *); +template POINTERLIST_INSTANTIATE (Source_file); diff --git a/lib/warn.cc b/lib/warn.cc index ade821a64f..743af06d6a 100644 --- a/lib/warn.cc +++ b/lib/warn.cc @@ -2,23 +2,23 @@ #include void -error(String s) +error (String s) { - cerr << _("error: ") << s << "\n"; + cerr << _ ("error: ") << s << "\n"; - exit(1); + exit (1); } void -warning(String m) +warning (String m) { - cerr << _("warning: ") < caddr_t -mmap(caddr_t addr, size_t len, int prot, int flags, int fd, off_t offset) +mmap (caddr_t addr, size_t len, int prot, int flags, int fd, off_t offset) { (void)flags; (void)prot; (void)addr; - HANDLE osf = (HANDLE)_get_osfhandle(fd); - HANDLE file_handle = CreateFileMapping(osf, (void*)0, PAGE_READONLY, + HANDLE osf = (HANDLE)_get_osfhandle (fd); + HANDLE file_handle = CreateFileMapping (osf, (void*)0, PAGE_READONLY, 0, len, 0); - return (caddr_t)MapViewOfFile(file_handle, FILE_MAP_READ, 0, offset, len); + return (caddr_t)MapViewOfFile (file_handle, FILE_MAP_READ, 0, offset, len); } int -munmap(caddr_t addr, size_t len) +munmap (caddr_t addr, size_t len) { (void)len; - return UnmapViewOfFile(addr); + return UnmapViewOfFile (addr); } #else // ! HAVE_GET_OSFHANDLE // caddr_t -mmap(caddr_t addr, size_t len, int prot, int flags, int fd, off_t offset) +mmap (caddr_t addr, size_t len, int prot, int flags, int fd, off_t offset) { (void)flags; (void)prot; @@ -86,13 +86,13 @@ mmap(caddr_t addr, size_t len, int prot, int flags, int fd, off_t offset) (void)offset; char* ch_p = new char[ len ]; if (ch_p) - read(fd, (void*)ch_p, len); + read (fd, (void*)ch_p, len); return ch_p; } int -munmap(caddr_t addr, size_t len) +munmap (caddr_t addr, size_t len) { (void)len; delete (char*)addr; diff --git a/lily/VERSION b/lily/VERSION index e0d3c8cadf..486f034e1b 100644 --- a/lily/VERSION +++ b/lily/VERSION @@ -1,4 +1,4 @@ MAJOR_VERSION = 0 MINOR_VERSION = 1 -PATCH_LEVEL = 42 +PATCH_LEVEL = 43 MY_PATCH_LEVEL = diff --git a/lily/break.cc b/lily/break.cc index 8b6241732b..04b623e883 100644 --- a/lily/break.cc +++ b/lily/break.cc @@ -17,9 +17,9 @@ #include "cpu-timer.hh" String -Col_stats::str() const { +Col_stats::str () const { String s (count_i_); - s += _(" lines"); + s += _ (" lines"); if (count_i_) s += String (Real (cols_i_)/count_i_, _(", (with an average of %.1f columns)")); @@ -30,11 +30,11 @@ void Col_stats::add (Line_of_cols const& line) { count_i_++; - cols_i_ += line.size(); + cols_i_ += line.size (); } -Col_stats::Col_stats() +Col_stats::Col_stats () { count_i_ =0; cols_i_ =0; @@ -43,11 +43,11 @@ Col_stats::Col_stats() /* **************************************************************** */ Line_of_cols -Break_algorithm::all_cols() const +Break_algorithm::all_cols () const { Line_of_cols retval; - for (PCursor c (pscore_l_->col_p_list_.top()); - c.ok(); c++) + for (PCursor c (pscore_l_->col_p_list_.top ()); + c.ok (); c++) { retval.push (c); @@ -56,17 +56,17 @@ Break_algorithm::all_cols() const } Array -Break_algorithm::find_break_indices() const +Break_algorithm::find_break_indices () const { - Line_of_cols all (all_cols()); + Line_of_cols all (all_cols ()); Array retval; - for (int i=0; i < all.size(); i++) + for (int i=0; i < all.size (); i++) if (all[i]->breakable_b_) retval.push (i); if (linelength <=0) - while (retval.size() >2) + while (retval.size () >2) retval.del (1); return retval; @@ -74,18 +74,18 @@ Break_algorithm::find_break_indices() const /// return all breakable columns Line_of_cols -Break_algorithm::find_breaks() const +Break_algorithm::find_breaks () const { - Line_of_cols all (all_cols()); + Line_of_cols all (all_cols ()); Line_of_cols retval; - for (int i=0; i < all.size(); i++) + for (int i=0; i < all.size (); i++) if (all[i]->breakable_b_) retval.push (all[i]); if (linelength <=0) - while (retval.size() >2) + while (retval.size () >2) retval.del (1); return retval; @@ -96,25 +96,25 @@ Break_algorithm::find_breaks() const Line_spacer* -Break_algorithm::generate_spacing_problem (Line_of_cols curline) const +Break_algorithm::generate_spacing_problem (Line_of_cols curline, Interval line) const { - Line_spacer * sp= (*get_line_spacer)(); + Line_spacer * sp= (*get_line_spacer) (); sp->paper_l_ = pscore_l_->paper_l_; - sp->add_column (curline[0], true, 0.0); - for (int i=1; i< curline.size()-1; i++) + sp->add_column (curline[0], true, line.min ()); + for (int i=1; i< curline.size ()-1; i++) sp->add_column (curline[i]); - if (linelength > 0) - sp->add_column (curline.top(), true, linelength); + if (line.length () > 0) + sp->add_column (curline.top (), true, line.max ()); else - sp->add_column (curline.top()); + sp->add_column (curline.top ()); - sp->prepare(); + sp->prepare (); return sp; } -Break_algorithm::Break_algorithm() +Break_algorithm::Break_algorithm () { pscore_l_ = 0; get_line_spacer =0; @@ -125,8 +125,8 @@ void Break_algorithm::set_pscore (Paper_score*s) { pscore_l_ = s; - linelength = s->paper_l_->linewidth_f(); - do_set_pscore(); + linelength = s->paper_l_->linewidth_f (); + do_set_pscore (); } bool @@ -136,25 +136,25 @@ Break_algorithm::feasible (Line_of_cols curline) const return true; Real l =0; - for (int i=0; i < curline.size(); i++) - l +=curline[i]->width().length (); + for (int i=0; i < curline.size (); i++) + l +=curline[i]->width ().length (); return l < linelength; } void -Break_algorithm::problem_OK() const +Break_algorithm::problem_OK () const { - if (!pscore_l_->col_p_list_.size()) + if (!pscore_l_->col_p_list_.size ()) error (_("Score does not have any columns")); - OK(); + OK (); } void -Break_algorithm::OK() const +Break_algorithm::OK () const { #ifndef NDEBUG iter_top (pscore_l_->col_p_list_,start); - PCursor end (pscore_l_->col_p_list_.bottom()); + PCursor end (pscore_l_->col_p_list_.bottom ()); assert (start->breakable_b_); assert (end->breakable_b_); @@ -162,23 +162,23 @@ Break_algorithm::OK() const } Array -Break_algorithm::solve() const +Break_algorithm::solve () const { Cpu_timer timer; - Array h= do_solve(); + Array h= do_solve (); if (approx_stats_.count_i_) - *mlog << _("\nApproximated: ") << approx_stats_.str() << "\n"; + *mlog << _ ("\nApproximated: ") << approx_stats_.str () << "\n"; if (exact_stats_.count_i_) - *mlog << _("Calculated exactly: ") << exact_stats_.str() << "\n"; - *mlog << _("Time: ") << String(timer.read (), "%.2f") << _(" seconds\n"); + *mlog << _ ("Calculated exactly: ") << exact_stats_.str () << "\n"; + *mlog << _ ("Time: ") << String (timer.read (), "%.2f") << _ (" seconds\n"); return h; } void -Break_algorithm::do_set_pscore() +Break_algorithm::do_set_pscore () { } diff --git a/lily/debug.cc b/lily/debug.cc index 39b40c7764..c369f070ee 100644 --- a/lily/debug.cc +++ b/lily/debug.cc @@ -6,7 +6,6 @@ (c) 1996,98 Han-Wen Nienhuys */ -#include #include #include #include @@ -75,8 +74,6 @@ bool check_malloc_b = false; // #define MEMORY_PARANOID #ifdef MEMORY_PARANOID - - void * operator new (size_t size) { diff --git a/lily/gourlay-breaking.cc b/lily/gourlay-breaking.cc index 3daa4ab12e..05c2a722b3 100644 --- a/lily/gourlay-breaking.cc +++ b/lily/gourlay-breaking.cc @@ -25,11 +25,13 @@ struct Break_node { */ int prev_break_i_; + int line_i_; Real energy_f_; Col_hpositions line_config_; - Break_node() + Break_node () { prev_break_i_ = -1; + line_i_ = 0; } }; @@ -38,23 +40,24 @@ struct Break_node { */ Array -Gourlay_breaking::do_solve() const +Gourlay_breaking::do_solve () const { Array optimal_paths; - Line_of_cols all = all_cols(); - Array breaks = find_break_indices(); + Line_of_cols all = all_cols (); + Array breaks = find_break_indices (); - optimal_paths.set_size (breaks.size()); + optimal_paths.set_size (breaks.size ()); Break_node first_node ; first_node.prev_break_i_ = -1; first_node.line_config_.energy_f_ = 0; + first_node.line_i_ = 0; optimal_paths[0] = first_node; int break_idx=1; - for (; break_idx< breaks.size(); break_idx++) + for (; break_idx< breaks.size (); break_idx++) { Array candidates; Array candidate_lines; @@ -75,9 +78,9 @@ Gourlay_breaking::do_solve() const continue; Line_of_cols line = all.slice (breaks[start_idx], breaks[break_idx]+1); - - line[0] = line[0]->postbreak_l(); - line.top() = line.top ()->prebreak_l(); + + line[0] = line[0]->postbreak_l (); + line.top () = line.top ()->prebreak_l (); if (!feasible (line)) break; @@ -85,11 +88,12 @@ Gourlay_breaking::do_solve() const Col_hpositions approx; approx.cols = line; - approx.spacer_l_ = generate_spacing_problem (line); - spacer_p_list.bottom().add (approx.spacer_l_); + approx.spacer_l_ = generate_spacing_problem (line, + pscore_l_->paper_l_->line_dimensions_int (optimal_paths[start_idx].line_i_)); + spacer_p_list.bottom ().add (approx.spacer_l_); - ((Break_algorithm*)this)->approx_stats_.add (approx.cols); - approx.approximate_solve_line(); + ( (Break_algorithm*)this)->approx_stats_.add (approx.cols); + approx.approximate_solve_line (); if (approx.energy_f_ > energy_bound_f_) { @@ -105,7 +109,7 @@ Gourlay_breaking::do_solve() const int minimal_j = -1; Real minimal_energy = infinity_f; - for (int j=0; j < candidates.size(); j++) + for (int j=0; j < candidates.size (); j++) { int start = candidates[j]; if (optimal_paths[start].line_config_.energy_f_ @@ -115,8 +119,8 @@ Gourlay_breaking::do_solve() const if (!candidate_lines[j].satisfies_constraints_b_) { - candidate_lines[j].solve_line(); - ((Break_algorithm*)this)->exact_stats_.add (candidate_lines[j].cols); + candidate_lines[j].solve_line (); + ( (Break_algorithm*)this)->exact_stats_.add (candidate_lines[j].cols); } Real this_energy @@ -139,9 +143,11 @@ Gourlay_breaking::do_solve() const { optimal_paths[break_idx].prev_break_i_ = candidates[minimal_j]; optimal_paths[break_idx].line_config_ = candidate_lines[minimal_j]; + optimal_paths[break_idx].line_i_ = + optimal_paths[optimal_paths[break_idx].prev_break_i_].line_i_ + 1; } - if (!(break_idx % HAPPY_DOTS_I)) + if (! (break_idx % HAPPY_DOTS_I)) *mlog << "[" << break_idx << "]"< lines; /* skip 0-th element, since it is a "dummy" elt*/ - for (int i = optimal_paths.size()-1; i> 0;) + for (int i = optimal_paths.size ()-1; i> 0;) { final_breaks.push (i); assert (i > optimal_paths[i].prev_break_i_); // there was no "feasible path" - if (!optimal_paths[i].line_config_.config.size()) { + if (!optimal_paths[i].line_config_.config.size ()) { final_breaks.set_size (0); break; } @@ -167,14 +173,14 @@ Gourlay_breaking::do_solve() const } - for (int i= final_breaks.size(); i--;) + for (int i= final_breaks.size (); i--;) lines.push (optimal_paths[final_breaks[i]].line_config_); return lines; } -Gourlay_breaking::Gourlay_breaking() +Gourlay_breaking::Gourlay_breaking () { get_line_spacer = Spring_spacer::constructor; energy_bound_f_ = infinity_f; @@ -182,7 +188,7 @@ Gourlay_breaking::Gourlay_breaking() } void -Gourlay_breaking::do_set_pscore() +Gourlay_breaking::do_set_pscore () { energy_bound_f_ = pscore_l_->paper_l_->get_var ("gourlay_energybound"); max_measures_i_ =int (rint (pscore_l_->paper_l_->get_var ("gourlay_maxmeasures"))); diff --git a/lily/include/break.hh b/lily/include/break.hh index dcc3f63908..c6c9058e51 100644 --- a/lily/include/break.hh +++ b/lily/include/break.hh @@ -10,11 +10,10 @@ #ifndef BREAK_HH #define BREAK_HH #include "varray.hh" +#include "interval.hh" #include "lily-proto.hh" #include "colhpos.hh" - - /** Statistics for the number of columns calced. */ @@ -57,10 +56,11 @@ protected: bool feasible (Line_of_cols) const; - Line_spacer* generate_spacing_problem (Line_of_cols) const; + Line_spacer* generate_spacing_problem (Line_of_cols, Interval) const; virtual Array do_solve() const=0; - virtual void do_set_pscore(); + virtual void do_set_pscore(); + public: Col_stats approx_stats_; Col_stats exact_stats_; diff --git a/lily/include/main.hh b/lily/include/main.hh index 1a95d9d203..5ca8f5ad8c 100644 --- a/lily/include/main.hh +++ b/lily/include/main.hh @@ -18,6 +18,7 @@ void set_default_output (String s); String find_file (String); String get_version_str(); String get_version_number_str(); +void call_constructors (); extern Sources* source_global_l; extern bool no_paper_global_b; extern int exit_status_i_; diff --git a/lily/include/paper-def.hh b/lily/include/paper-def.hh index 162bb656e6..4bf3b9589c 100644 --- a/lily/include/paper-def.hh +++ b/lily/include/paper-def.hh @@ -14,6 +14,8 @@ #include "real.hh" #include "moment.hh" +#include "varray.hh" +#include "interval.hh" #include "music-output-def.hh" /** @@ -39,9 +41,11 @@ class Paper_def : public Music_output_def { protected: VIRTUAL_COPY_CONS(Paper_def,Music_output_def); public: - virtual ~Paper_def(); + virtual ~Paper_def (); DECLARE_MY_RUNTIME_TYPEINFO; + Array shape_int_a_; + /** Set or overwrite a variable */ @@ -50,39 +54,40 @@ public: Read a variable. Crash if it doesn't exist. */ Real get_var (String) const; - void reinit(); - Paper_def(); + void reinit (); + Paper_def (); void set (Lookup*); Paper_def (Paper_def const&); /// The distance between beams - Real interbeam_f() const; + Real interbeam_f () const; /** The distance between lines */ - Real interline_f() const; + Real interline_f () const; /// half the distance between lines - Real internote_f() const; + Real internote_f () const; /// thickness of the standard line - Real rule_thickness() const; - Real linewidth_f() const; + Real rule_thickness () const; + Interval line_dimensions_int (int) const; + Real linewidth_f () const; /// height of the staff - Real standard_height() const; + Real standard_height () const; /// width of a crotchet ball - Real note_width() const; - void print() const; + Real note_width () const; + void print () const; - Lookup const * lookup_l(); // TODO naming + Lookup const * lookup_l (); // TODO naming /** convert a duration to an idealspacing influence using the geometric_ and parameters. */ Real duration_to_dist (Moment, Real) const; - Real geometric_spacing(Moment) const; - Real arithmetic_constant(Moment minimal_mom) const; - Real arithmetic_spacing( Moment mom,Real constant) const; + Real geometric_spacing (Moment) const; + Real arithmetic_constant (Moment minimal_mom) const; + Real arithmetic_spacing (Moment mom,Real constant) const; virtual int get_next_default_count () const; String TeX_output_settings_str () const; }; diff --git a/lily/include/plet-spanner.hh b/lily/include/plet-spanner.hh index cae64729d5..4f2fa66eab 100644 --- a/lily/include/plet-spanner.hh +++ b/lily/include/plet-spanner.hh @@ -26,11 +26,6 @@ public: protected: virtual Molecule* brew_molecule_p () const; -private: - - -protected: - DECLARE_MY_RUNTIME_TYPEINFO; SCORE_ELEM_CLONE(Plet_spanner); @@ -38,6 +33,7 @@ protected: virtual void do_post_processing (); virtual void set_default_dir (); virtual void do_substitute_dependency (Score_elem*,Score_elem*); + Plet_spanner (Plet_spanner const&); }; #endif // PLET_SPANNER_HH diff --git a/lily/include/stem.hh b/lily/include/stem.hh index d150eb1e76..8020d14f72 100644 --- a/lily/include/stem.hh +++ b/lily/include/stem.hh @@ -86,6 +86,7 @@ public: void do_print() const; void set_stemend (Real); Direction get_default_dir(); + Direction get_dir (); int get_center_distance(Direction); void set_default_dir(); @@ -95,7 +96,7 @@ public: Real stem_length_f() const; Real stem_end_f() const; - Real stem_start_f() const; + Real stem_begin_f() const; Real note_delta_f () const; bool invisible_b() const; diff --git a/lily/include/translator.hh b/lily/include/translator.hh index baa0718366..c2ddcb131a 100644 --- a/lily/include/translator.hh +++ b/lily/include/translator.hh @@ -101,15 +101,22 @@ protected: */ #define ADD_THIS_TRANSLATOR(c) \ struct c ## init { \ - c ## init() { \ - Translator *t = new c;\ + static Translator *ctor ()\ + {\ + Translator *t = new c;\ t-> type_str_ = c::static_name ();\ - add_translator (t);\ + return t;\ + }\ + c ## init() { \ + add_constructor (ctor);\ } \ } _ ## c ## init; +typedef Translator *(*Translator_ctor) (); + extern Dictionary *global_translator_dict_p; void add_translator (Translator*trans_p); +void add_constructor (Translator_ctor ctor); Translator*get_translator_l (String s); diff --git a/lily/lexer.l b/lily/lexer.l index 851e21c2e1..ab97828bc1 100644 --- a/lily/lexer.l +++ b/lily/lexer.l @@ -28,6 +28,7 @@ #include "string-convert.hh" #include "my-lily-lexer.hh" #include "varray.hh" +#include "interval.hh" #include "parser.hh" #include "debug.hh" #include "parseconstruct.hh" diff --git a/lily/main.cc b/lily/main.cc index 17d1997dc5..85968ddb14 100644 --- a/lily/main.cc +++ b/lily/main.cc @@ -45,7 +45,7 @@ Long_option_init theopts[] = { }; void -usage() +usage () { cout << _("Usage: lilypond [options] [mudela-files]\n" @@ -83,7 +83,7 @@ usage() } void -notice() +notice () { cout << _("\n" @@ -132,7 +132,7 @@ do_one_file (String init_str, String file_str) parser.set_version_check (version_ignore_b); parser.parse_file (init_str, file_str); - if (file_str.length_i() && file_str[0] != '-') + if (file_str.length_i () && file_str[0] != '-') { String a,b,c,d; split_path (file_str, a, b, c, d); @@ -146,7 +146,7 @@ do_one_file (String init_str, String file_str) exit_status_i_ = 1; } else - do_scores(); + do_scores (); clear_scores (); } source_global_l = 0; @@ -155,14 +155,15 @@ do_one_file (String init_str, String file_str) void identify () { - cout << get_version_str() << endl; + cout << get_version_str () << endl; } int main (int argc, char **argv) { identify (); - debug_init(); // should be first + call_constructors (); + debug_init (); // should be first // must override (come before) "/usr/local/share/lilypond"! @@ -178,7 +179,7 @@ main (int argc, char **argv) Getopt_long oparser (argc, argv,theopts); String init_str ("lily-init.ly"); - while (Long_option_init const * opt = oparser()) + while (Long_option_init const * opt = oparser ()) { switch (opt->shortname) { @@ -189,7 +190,7 @@ main (int argc, char **argv) default_outname_base_global = oparser.optional_argument_ch_C_; break; case 'w': - notice(); + notice (); exit (0); break; case 'I': @@ -199,7 +200,7 @@ main (int argc, char **argv) init_str = oparser.optional_argument_ch_C_; break; case 'h': - usage(); + usage (); exit (0); break; case 'V': @@ -222,7 +223,7 @@ main (int argc, char **argv) int p=0; const char *arg ; - while ((arg= oparser.get_next_arg())) + while ((arg= oparser.get_next_arg ())) { String f (arg); destill_inname (f); @@ -241,7 +242,7 @@ main (int argc, char **argv) void destill_inname (String &name_str_r) { - if (name_str_r.length_i()) + if (name_str_r.length_i ()) { if (name_str_r[ 0 ] != '-') { diff --git a/lily/my-lily-lexer.cc b/lily/my-lily-lexer.cc index 2a8760ee52..1aa7bb77e9 100644 --- a/lily/my-lily-lexer.cc +++ b/lily/my-lily-lexer.cc @@ -52,6 +52,7 @@ static Keyword_ent the_key_tab[]={ {"pt", PT_T}, {"score", SCORE}, {"script", SCRIPT}, + {"shape", SHAPE}, {"skip", SKIP}, {"staff", STAFF}, {"table", TABLE}, diff --git a/lily/paper-def.cc b/lily/paper-def.cc index c3568f1b4d..92b126428c 100644 --- a/lily/paper-def.cc +++ b/lily/paper-def.cc @@ -54,8 +54,23 @@ Paper_def::get_var (String s) const return real_vars_p_->elem (s); } +Interval +Paper_def::line_dimensions_int (int n) const +{ + if (!shape_int_a_.size ()) + if (n) + return Interval (0, linewidth_f ()); + else + return Interval (get_var ("indent"), linewidth_f ()); + + if (n >= shape_int_a_.size ()) + n = shape_int_a_.size () -1; + + return shape_int_a_[n]; +} + Real -Paper_def::linewidth_f() const +Paper_def::linewidth_f () const { return get_var ("linewidth"); } diff --git a/lily/parser.y b/lily/parser.y index 8dea7f982a..2480a041e6 100644 --- a/lily/parser.y +++ b/lily/parser.y @@ -56,6 +56,7 @@ %union { + Array* intarr; Array *melreqvec;/* should clean up naming */ Array * strvec; Array *intvec; @@ -147,6 +148,7 @@ yylex (YYSTYPE *s, void * v_l) %token PT_T %token SCORE %token SCRIPT +%token SHAPE %token SKIP %token SPANDYNAMIC %token STAFF @@ -223,6 +225,7 @@ yylex (YYSTYPE *s, void * v_l) %type post_request command_req verbose_command_req %type script_req dynamic_req %type score_block score_body +%type shape_array %type