]> git.donarmstrong.com Git - lilypond.git/commitdiff
lilypond-0.1.39
authorfred <fred>
Sun, 24 Mar 2002 20:04:28 +0000 (20:04 +0000)
committerfred <fred>
Sun, 24 Mar 2002 20:04:28 +0000 (20:04 +0000)
122 files changed:
.dstreamrc
ANNOUNCE
ANNOUNCE-0.1 [new file with mode: 0644]
Documentation/AUTHORS.pod
Documentation/INSTALL.pod
Documentation/MANIFESTO.pod
Documentation/Rules.make
Documentation/index.pod
Documentation/language.pod
Documentation/lilypond.pod
Documentation/links.pod
Documentation/mutopia.pod
NEWS
TODO
VERSION
bin/clean-diaper.sh
bin/lilypython.py
bin/make-examples.sh [new file with mode: 0644]
bin/make-website.py [new file with mode: 0644]
bin/mudela-book.pl
bin/ps-to-gifs.sh [new file with mode: 0644]
configure.in
debian/Makefile
debian/README.Debian [new file with mode: 0644]
flower/NEWS
flower/VERSION
flower/dstream.cc
flower/include/dstream.hh
flower/include/path.hh
flower/include/string.hh
flower/path.cc
flower/string-convert.cc
flower/string.cc
init/engraver.ly
init/lily-init.ly
init/paper16.ly
init/paper20.ly
init/property.ly [new file with mode: 0644]
init/script.ly
init/table20.ly
input/beams.ly
input/collisions.ly
input/font.ly
input/font20.ly
input/rhythm.ly
input/scsii-menuetto.ly
input/spacing.ly [new file with mode: 0644]
input/standchen-16.ly
input/standchen-20.ly
input/standchen-20.tex
input/standchen.ly
input/toccata-fuga-E.ly
input/wtk1-fugue2.ly
lib/binary-source-file.cc
lib/source-file.cc
lily/VERSION
lily/atom.cc
lily/axis.cc
lily/beam-grav.cc
lily/beam.cc
lily/bow.cc
lily/colhpos.cc
lily/crescendo.cc
lily/include/atom.hh
lily/include/beam.hh
lily/include/bow.hh
lily/include/colhpos.hh
lily/include/lookup.hh
lily/include/main.hh
lily/include/midi-def.hh
lily/include/music-output-def.hh
lily/include/paper-def.hh
lily/include/spring-spacer.hh
lily/include/text-spanner.hh
lily/lexer.l
lily/lookup.cc
lily/main.cc
lily/midi-def.cc
lily/midi-stream.cc
lily/music-output-def.cc
lily/musical-request.cc
lily/my-lily-parser.cc
lily/p-score.cc
lily/paper-def.cc
lily/performance.cc
lily/score-grav.cc
lily/score.cc
lily/scores.cc
lily/slur.cc
lily/spring-spacer.cc
lily/stem.cc
lily/tex-beam.cc
lily/tex-slur.cc
lily/text-spanner.cc
lily/tie.cc
make/Toplevel.make.in
make/lilypond.lsm.in
make/lilypond.spec.in
mf/TODO
mf/feta-autometric.mf [new file with mode: 0644]
mf/feta-beugel.mf
mf/feta-din10.mf
mf/feta-ital-f.mf [new file with mode: 0644]
mf/feta-ital-m.mf [new file with mode: 0644]
mf/feta-ital-p.mf [new file with mode: 0644]
mf/feta-ital-r.mf [new file with mode: 0644]
mf/feta-ital-s.mf [new file with mode: 0644]
mf/feta-ital-z.mf [new file with mode: 0644]
mf/feta-klef.mf
mf/feta-nummer-generic.mf
mf/feta-schrift.mf
mf/feta-test16.mf
mf/feta-test20.mf
mf/feta16.mf
mf/feta20.mf
mi2mu/TODO
mi2mu/main.cc
mi2mu/mudela-stream.cc
tex/fetdefs.tex
tex/lily-ps-defs.tex [new file with mode: 0644]
tex/lilyponddefs.tex
tex/taupindefs.tex

index 636a2a37df66f0586d4a1ea3dc11f86eedaab0c8..69b2d30c72fec7f835ec71e93d8227f570d29a7d 100644 (file)
@@ -13,6 +13,8 @@ InitLexer             1
 Lexer                  1
 
 
+walking                1
+
 # flower lib
 File_path              1
 Matrix                 1
index 9f7d6e2e37180202b7390af6079bdac7d69244f8..6bdaf16333ced9ebd2dd66e71e3656ff1e5a2bb9 100644 (file)
--- a/ANNOUNCE
+++ b/ANNOUNCE
@@ -1,45 +1,14 @@
-Keywords: midi notation music typesetting gnu
-Subject: LilyPond 0.1 released - The GNU Project music typesetter
-
-       BORN
-
-       August 1, 1997
-
-               Lily
-
-               (GNU LilyPond 0.1)
-
-       daughter to Jan 'Janneke' Nieuwenhuizen and Han-Wen 'Wendy' Nienhuys
-
-Lily is a healthy, bouncing baby weighing 345 kilobytes
-
-Visiting hours: 24 hours a day at
-
-       ftp://pcnov095.win.tue.nl/pub/lilypond/lilypond-0.1.0.tar.gz (Europe)
-       ftp://alpha.gnu.ai.mit.edu/gnu/lilypond-0.1.0.tar.gz (US)
-
-You can see some babyfood, diapers and pictures at
-
-       http://www.stack.nl/~hanwen/lilypond/index.html
-
-You can send your congratulations to Janneke (jan@digicash.com) and
-Wendy (hanwen@stack.nl)
-
+Keywords: midi notation music typesetting gnu font
+Subject: LilyPond 0.2 released - The GNU Project music typesetter
 
 GNU LilyPond - The GNU Project Music Typesetter
 
 
-
 ``WHAT IS GNU LilyPond?''
 
-Well Mike, GNU LilyPond is a program which converts music definition
-files into visual or auditive output: it can typeset formatted sheet
-music to a TeX file and (mechanical) performances to MIDI files.
-
-
-We have been working very hard on this system for the past year, and
-we finally think that it is ready to be used and hacked at by a larger
-public than us. 
+GNU LilyPond is the GNU Project Music typesetter: it reads a music
+definition file and outputs formatted sheet music to a TeX file or
+(mechanical) performances to MIDI files.
 
 
 WHY ?
@@ -48,48 +17,31 @@ We want to create tools to produce production quality scores and parts
 of public domain music.
 
 
-BUT ..
-
-We haven't yet reached that goal:
-
-* The quality of the output isn't good enough yet due to some
-unsophisticated algorithms
-
-* Some features haven't been implemented, due to lack of time; most of
-them can be done quite simply
+WHAT'S NEW
 
-This is why we don't consider this software stable yet. It generally
-does what it is supposed to, but we reserve the right to make
-(incompatible) changes to the input format.  We consider it
-of BETA quality.
+* LilyPond now includes a completely rewritten font: the Feta font.
+We did our best to copy the best symbol designs available and We're
+proud of the result.  We hope you agree, so go check it out!
 
+* More elegant output due to 
 
-WE WANT YOU!
+       * better spacing
+       * better breaking
+       * better font design
+       * PostScript output for variable symbols.
 
-You can become a user, but we'd really appreciate it if you would start 
-hacking at Lily, and help us advance our project more quickly.
+* Lots of bugfixes
 
+* More robust, flexible, tweakable design
 
-``YES, IT IS FANTASTIC! WHAT DO I NEED?''
+* Better MIDI importing
 
-For compilation you need
+* Easier to use due to better scripts and input format enhancements.
 
-       Unix. (windows32 is known to work, too)
-       GNU C++ v2.7 or better, with libg++ installed.
-       GNU make. 
-       Flex (2.5.1 or better). 
-       Bison. (1.25 or better)
+* MusixTeX not needed anymore
 
-For running you need
 
-       TeX
-       MusiXTeX fonts
-
-The MusiXTeX fonts are part of the MusiXTeX package version T.73,
-available at any CTAN mirror, or http://www.gmd.de/Misc/Music/ 
-
-
-``WHAT CAN LILYPOND DO?''
+WHAT CAN LILYPOND DO?
 
 ASCII script input (mudela), with identifiers (for music reuse),
 customizable notenames.
@@ -110,56 +62,14 @@ changes, cadenza-mode, key changes, repeat bars.
 Integration with LaTeX through Perl scripts.
 
 
-``WHERE CAN I FIND MORE INFO?''
+MORE INFO
 
 Sources for this project are on
 
        ftp://pcnov095.win.tue.nl/pub/lilypond/ (Europe)
-       ftp://alpha.gnu.ai.mit.edu/gnu/ (US)
+       ftp://alpha.gnu.org/gnu/ (US)
 
 More detailed info and examples can be found on the webpage at
 
        http://www.stack.nl/~hanwen/lilypond/index.html
 
-
-THANK YOU,
-
-Thanks go out to Mats Bengtsson, Werner Lemberg and Richard Stallman
-for comments and contributions.
-
-
-****   NOTE
-
-LilyPond might have a minor bug if  you use glibc-2; we will look into it
-If you use glibc-2, please try 0.1.0 to see if it works and, download 0.1.1
-when it's available.  
-
-LilyPond might exhibit a g++ bug on Solaris 1.5 (The stack frame gets corrupted
-by a constructor) if you compile with -O2. We don't know workarounds.  
-
-                             --- * ---
-
-    We would like to dedicate this program to all the friends that we
-                        met through music. 
-
-
-       Those deserving special mention (in no particular order):
-Esther, Marijke, Heike, Inge, Judith, Hannah, Auke, Ilse, Evelyn,
-Maartje, Suzanne, Ilse (gee, again?) and last (but certainly not least)
-Janneke!
-
-       HWN
-
-       That's a nice thought, Wendy.  I've got a few too, to spread
-the credits a bit (Again, no particular order) Michelle, Illushka, 
-Ruth, Eva, Fro/ydis, Monique, Noor, Sascha, Monique, Ilse, Monique, 
-Eva, Roos, Judith, Tim and, of course, Wendy!
-
-       JCN
-
-Of course, our other friends in the `Eindhovens Jongeren Ensemble'
-(http://www.stack.nl/~hanwen/eje.html) cannot go unmentioned either.
-
-
-                              --- * ---
diff --git a/ANNOUNCE-0.1 b/ANNOUNCE-0.1
new file mode 100644 (file)
index 0000000..9f7d6e2
--- /dev/null
@@ -0,0 +1,165 @@
+Keywords: midi notation music typesetting gnu
+Subject: LilyPond 0.1 released - The GNU Project music typesetter
+
+       BORN
+
+       August 1, 1997
+
+               Lily
+
+               (GNU LilyPond 0.1)
+
+       daughter to Jan 'Janneke' Nieuwenhuizen and Han-Wen 'Wendy' Nienhuys
+
+Lily is a healthy, bouncing baby weighing 345 kilobytes
+
+Visiting hours: 24 hours a day at
+
+       ftp://pcnov095.win.tue.nl/pub/lilypond/lilypond-0.1.0.tar.gz (Europe)
+       ftp://alpha.gnu.ai.mit.edu/gnu/lilypond-0.1.0.tar.gz (US)
+
+You can see some babyfood, diapers and pictures at
+
+       http://www.stack.nl/~hanwen/lilypond/index.html
+
+You can send your congratulations to Janneke (jan@digicash.com) and
+Wendy (hanwen@stack.nl)
+
+
+GNU LilyPond - The GNU Project Music Typesetter
+
+
+
+``WHAT IS GNU LilyPond?''
+
+Well Mike, GNU LilyPond is a program which converts music definition
+files into visual or auditive output: it can typeset formatted sheet
+music to a TeX file and (mechanical) performances to MIDI files.
+
+
+We have been working very hard on this system for the past year, and
+we finally think that it is ready to be used and hacked at by a larger
+public than us. 
+
+
+WHY ?
+
+We want to create tools to produce production quality scores and parts
+of public domain music.
+
+
+BUT ..
+
+We haven't yet reached that goal:
+
+* The quality of the output isn't good enough yet due to some
+unsophisticated algorithms
+
+* Some features haven't been implemented, due to lack of time; most of
+them can be done quite simply
+
+This is why we don't consider this software stable yet. It generally
+does what it is supposed to, but we reserve the right to make
+(incompatible) changes to the input format.  We consider it
+of BETA quality.
+
+
+WE WANT YOU!
+
+You can become a user, but we'd really appreciate it if you would start 
+hacking at Lily, and help us advance our project more quickly.
+
+
+``YES, IT IS FANTASTIC! WHAT DO I NEED?''
+
+For compilation you need
+
+       Unix. (windows32 is known to work, too)
+       GNU C++ v2.7 or better, with libg++ installed.
+       GNU make. 
+       Flex (2.5.1 or better). 
+       Bison. (1.25 or better)
+
+For running you need
+
+       TeX
+       MusiXTeX fonts
+
+The MusiXTeX fonts are part of the MusiXTeX package version T.73,
+available at any CTAN mirror, or http://www.gmd.de/Misc/Music/ 
+
+
+``WHAT CAN LILYPOND DO?''
+
+ASCII script input (mudela), with identifiers (for music reuse),
+customizable notenames.
+
+MIDI output lets you check if you have entered the correct notes.
+MIDI to Mudela conversion through the mi2mu program.
+
+Multiple staffs in one score. Each staff can have a different meters.
+Multiple voices within one staff (up to four handled graciously);
+beams optionally shared between voices.  Multiple scores within one
+input file. Each score is output to a different file.
+
+Beams, slurs, chords, super/subscripts (accents and text), 
+general n-plet (triplet, quadruplets, etc.), lyrics, transposition,
+dynamics (both absolute and hairpin style), clef changes, meter
+changes, cadenza-mode, key changes, repeat bars.
+
+Integration with LaTeX through Perl scripts.
+
+
+``WHERE CAN I FIND MORE INFO?''
+
+Sources for this project are on
+
+       ftp://pcnov095.win.tue.nl/pub/lilypond/ (Europe)
+       ftp://alpha.gnu.ai.mit.edu/gnu/ (US)
+
+More detailed info and examples can be found on the webpage at
+
+       http://www.stack.nl/~hanwen/lilypond/index.html
+
+
+THANK YOU,
+
+Thanks go out to Mats Bengtsson, Werner Lemberg and Richard Stallman
+for comments and contributions.
+
+
+****   NOTE
+
+LilyPond might have a minor bug if  you use glibc-2; we will look into it
+If you use glibc-2, please try 0.1.0 to see if it works and, download 0.1.1
+when it's available.  
+
+LilyPond might exhibit a g++ bug on Solaris 1.5 (The stack frame gets corrupted
+by a constructor) if you compile with -O2. We don't know workarounds.  
+
+                             --- * ---
+
+    We would like to dedicate this program to all the friends that we
+                        met through music. 
+
+
+       Those deserving special mention (in no particular order):
+Esther, Marijke, Heike, Inge, Judith, Hannah, Auke, Ilse, Evelyn,
+Maartje, Suzanne, Ilse (gee, again?) and last (but certainly not least)
+Janneke!
+
+       HWN
+
+       That's a nice thought, Wendy.  I've got a few too, to spread
+the credits a bit (Again, no particular order) Michelle, Illushka, 
+Ruth, Eva, Fro/ydis, Monique, Noor, Sascha, Monique, Ilse, Monique, 
+Eva, Roos, Judith, Tim and, of course, Wendy!
+
+       JCN
+
+Of course, our other friends in the `Eindhovens Jongeren Ensemble'
+(http://www.stack.nl/~hanwen/eje.html) cannot go unmentioned either.
+
+
+                              --- * ---
index c6fedeb9b0704d83827018b450a54c3ba923e036..e922f5c3d3a3c3c0c4926333a362156ddb4dc595 100644 (file)
@@ -36,16 +36,19 @@ logs/longa/brevis etc
 
 TeX titling and lytodvi.sh
 
+=item * Shay Rojanski
+
+Some mudela source.
+
 =item * Werner Lemberg <xlwy01@uxp1.hrz.uni-dortmund.de>,
 
-misc bugfixes, some
-Beam and Stem code. 
+misc bugfixes, some Beam and Stem code. 
 
 =item * Donald Ervin Knuth, http://www.cs.stanford.edu/~?
 
 mf/ital-*.mf (these were taken from the CM fonts)
 
-=item * Alexandre Oliva <oliva@dcc.unicamp.br>, http://?.unicamp.br/
+=item * Alexandre Oliva <oliva@dcc.unicamp.br>, http://sunsite.unicamp.br/?
 
 testing
 
@@ -61,6 +64,10 @@ Documentation/Vocab*, internationalization stuff
 
 Documentation/Vocab*
 
+=item * David R. Linn <drl@vuse.vanderbilt.edu>,
+
+Mailing list maintenance.
+
 =back
 
 Your name could be here! If you want to help, then take a look at the
index b9580ea831972fc7c002020ab2d6f8c20bfe8cc9..c15658f9176cd572bb4a16468c33bf5c7bcbd665 100644 (file)
@@ -13,8 +13,7 @@ You do something which looks remotely like
        configure
        make
        make install
-       tar -C /usr/lib/texmf/fonts/source/ -zxf musixtex-T73.tgz 'mf/*'
-       
+
 The detailed instructions follow here.
 
 =head1 PREREQUISITES
@@ -63,29 +62,10 @@ TeX
 
 =item *
 
-The MusixTeX fonts (I included 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
-
-=over 4
-
-=item ftp://ftp.shsu.edu/tex-archive/macros/musixtex/taupin
-
-=item ftp://ftp.tex.ac.uk/tex-archive/macros/musixtex/taupin
-
-=item ftp://ftp.dante.de/tex-archive/macros/musixtex/taupin
+A PostScript printer and/or viewer (such as Ghostscript). 
 
 =back
 
-You only need the contents of the F<mf/> subdirectory of the
-package. The primary site of the Taupin version is
-ftp://hprib.lps.u-psud.fr/pub/music_zips/musixtex.zip
-
-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 (patch appreciated)
-
 
 =head1 RECOMMENDED
 
@@ -167,35 +147,35 @@ other options include:
 
 =over 4
 
-=item --enable-shared
+=item B<--enable-shared>
 
 Make a shared library (gnu/linux, solaris (?) only ) 
 
-=item --enable-printing
+=item B<--enable-printing>
 
 Enable debugging print routines (lilypond B<-d> option)
 
-=item --enable-optimise
+=item B<--enable-optimise>
 
 Set maximum optimisation: compile with B<-O2>
 
-=item --enable-profiling
+=item B<--enable-profiling>
 
 Compile with support for profiling
 
-=item --enable-tex-prefix
+=item B<--enable-tex-prefix>
 
 Set the directory where TeX and Metafont live
 
-=item --enable-tex-dir
+=item B<--enable-tex-dir>
 
 Set then directory TeX input is in (detected as a subdir of tex-prefix)
 
-=item --enable-mf-dir
+=item B<--enable-mf-dir>
 
 Set the directory mf input is in (idem)
 
-=item --enable-out-dir
+=item B<--enable-out-dir>
 
 Set the directory for machine generated output.
 
@@ -248,17 +228,6 @@ If you have done a successful C<make>, then a simple
 
 should do the trick. 
 
-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 F</usr/local/lib/texfonts/musixtex/>, and I
-have a symlink pointing to that in
-F</usr/lib/texmf/texmf/fonts/source/public/>. After I copied the
-files, I ran "texhash"
-
 =head1 CAVEATS
 
 =over 5
@@ -268,9 +237,9 @@ files, I ran "texhash"
 The -O2 option to gcc triggers a gcc bug on DEC Alpha in dstream.cc. You
 should turn off this flag for this file.
 
-=item * 
+=item *
 
-Perl5.003 and Perl5.004 use different syntax for pod2html:
+Perl5.003 and Perl5.004 use different syntax for pod2html.
 
 =back
 
@@ -279,8 +248,8 @@ Perl5.003 and Perl5.004 use different syntax for pod2html:
 This is what I type in my xterm:
 
        lilypond someinput.ly
-       tex lelie.tex
-       xdvi test&
+       tex someinput.tex
+       xdvi someinput&
 
 This is what the output looks like over here:
 
@@ -292,11 +261,11 @@ This is what the output looks like over here:
        Preprocessing elements... 
        Calculating column positions ... [14][25]
        Postprocessing elements...
-       TeX output to lelie.tex ...
-       Creating MIDI elements ...MIDI output to lelie.midi ...
+       TeX output to someinput.tex ...
+       Creating MIDI elements ...MIDI output to someinput.midi ...
 
 
-       hw:~/musix/spacer$ xdvi lelie&
+       hw:~/musix/spacer$ xdvi someinput&
        [1] 855
 
 Check out the input files, some of them have comments
@@ -305,15 +274,16 @@ Please refer to the man page for more information.
 =head1 REDHAT LINUX
 
 RedHat Linux users should be able to get a RPM. A spec file is in
-F<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
+F<make/out/lilypond.spec>. You should be able to create an rpm as a
+normal user. Be sure you have a F<~/.rpmrc>, and edit the RPM-dir in
 F<Variables.make>. (If you create the RPM as a normal user the
 permissions will not be set correctly, unfortunately)
 
 
 =head1 DEBIAN GNU/LINUX
 
-A Debian package is in the works
+A Debian package is also available; contact Anthony Fok
+<foka@debian.org>.  The build scripts are in the subdirectory debian/
 
 
 =head1 WINDOWS NT/95
@@ -333,6 +303,52 @@ to unpack the distribution, make sure the B<entire> source tree
 is unpacked correctly, in particular the empty out directories 
 (F<flower/out>, F<lib/out> et. al.)
 
+=head1 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
+stupid to use them, but anyway, here are the installation instructions
+for those deprecated fonts.
+
+
+[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
+
+=over 4
+
+=item ftp://ftp.shsu.edu/tex-archive/macros/musixtex/taupin
+
+=item ftp://ftp.tex.ac.uk/tex-archive/macros/musixtex/taupin
+
+=item ftp://ftp.dante.de/tex-archive/macros/musixtex/taupin
+
+=back 
+
+You only need the contents of the F<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 F</usr/local/lib/texfonts/musixtex/>, and I
+have a symlink pointing to that in
+F</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 F<tex/eglerdefs.tex>.
+
+
+
 =head1 AUTHORS
 
 Han-Wen Nienhuys <hanwen@stack.nl>
index 9f28246c030b6cdc8b5cc387bf065e5b2ba60b0b..58847a4d842c659ab75d8ca4997a2ac75c2a1572 100644 (file)
@@ -47,9 +47,9 @@ Further considerations while doing the programming
 
 =item *
 
-GNU LilyPond uses MusiXTeX fonts and TeX for its output. This is not a key
-issue: in a future version, GNU LilyPond might bypass TeX, but at the moment
-TeX is convenient for producing output.
+GNU LilyPond uses TeX for its output. This is not a key issue: in a
+future version, GNU LilyPond might bypass TeX, but at the moment TeX
+is convenient for producing output.
 
 =item *
 
index 3eaf8cd967e652d002709e53f0d5952f8c6ed476..eac8dfc8f26cfdcb672d88770f615a34110f2f1d 100644 (file)
@@ -45,7 +45,7 @@ $(outdir)/%.gz: $(outdir)/%
 name-stem= $(notdir $(basename $<))
 $(outdir)/%.dvi: $(depth)/input/%.ly $(depth)/VERSION
        (cd $(outdir); \
-       lilypond -I. -o  $(name-stem)  ../$< )
+       lilypond -I/  ../$< )
        (cd $(outdir); \
        if [ -f ../$(basename $< ).tex ]; \
        then \
@@ -55,9 +55,11 @@ $(outdir)/%.dvi: $(depth)/input/%.ly $(depth)/VERSION
        fi)
 
 
-# generate the pixmap at twice the size, then rescale (for antialiasing)
+
 $(outdir)/%.gif: $(outdir)/%.ps
-       gs  -q -sDEVICE=ppmraw -sOutputFile=- -r200 -dNOPAUSE  $< -c quit |pnmscale 0.5| ppmtogif > $@
+       sh $(depth)/bin/ps-to-gifs.sh $<
+       mv $(name-stem)-page*.gif $(outdir)/
+       touch $@
 
 $(outdir)/%.ly.txt: $(depth)/input/%.ly
        ln -f $< $@
index 3f862dc841ca423d577ace7174b5de52059a85aa..595170662b8328621dba963bbfdceb01714d5a94 100644 (file)
@@ -46,7 +46,7 @@ top_of_NEWS
 =over 4
 
 =item *
-<a href=ANNOUNCE.txt
+<a href=ANNOUNCE-0.1.txt
 >
 The announce of 0.1
 </a
index 8e46a662f0762535f8eb0b85f5fbc4e15911e97f..f56947f09b90e8662408d7819c612055bc36079e 100644 (file)
@@ -8,15 +8,6 @@ language.pod -- state of the art mudela-vapourware.
 implementation progresses. If you want to see our previous musings,
 take out an old version of lilypond]
 
-here are some thoughts on the language. Most of the examples are in
-pseudo current mudela.  Some stuff gratuitously taken from your mails.
-
-
-=head1 NOTE
-
-I dislike vapourware. That's why I oppose to concrete plans on how to
-do input for features we don't know how to produce on paper 
-
 =head1 REQUIREMENTS
 
 =head1 CONCRETE PROPOSALS
@@ -24,40 +15,11 @@ do input for features we don't know how to produce on paper
 
 =head1 Decisions (Sat 1997-3-15, dommelpijpje no21)
 
-=over 4
-
-=item *
-
-abbrev: [c2 c2]\noplet{1/2} (wat bout [c2 c2]1/2\noplet?),
-
-=item *
-
-abbrev: c4=16 (heu, =?),
-
-=item *
-
-plet === midi-note: c4*2/3; c4*385/384,
-
-=item *
-
-drop \music,
-
-=item *
 
-\meter compulsory in Simple mudela,
 
-=item *
-
-C<+> is  merge
-
-
-=item *
 
        \extract{ \from 2:3*4 \to 5 oboe }
 
-=back
-
-
 
 =head1 THOUGHTS
 
@@ -101,14 +63,6 @@ As simple fix, we might do key declarations:
 
 
 
-[LOOSE THOUGHT]
-
-We might drop this {} argument altogether, by merely enforcing
-that each "statement" (music,score,staff,chord) takes a LIST as
-argument, and use the {} to group lists. This is admittedly perl. This
-is very sketchy.
-
-
 =head2 Requests
 
 I want to give the user some access to the internals. Technically,
@@ -125,25 +79,6 @@ portability. Suppose some commercial systems want to read mudela too.
 
 =head2 Command placement:
 
-Mats is an arduous fan of having the commands inside music. I am
-not. I see the Mudela music as something which can be plugged into
-different staffs, transposed, translated in time, copied, quoted,
-etc. Encouraging "inline" commands would be bad since they hinder this
-reuse of typed music.
-
-The way I figure it, the bad part is essentially counting
-bars/wholes. Maybe we can get rid of it, by reinstalling the "mark"
-commands.
-
-I definitely want  to avoid complicated logic  ("Hey there is  another
-bar request, should we merge this bar with another staff's", this kind
-of "smartness" makes a  lot M$ software inconsistent) inside LilyPond,
-by making the input unambiguous in this respect.
-
-There is another complication: some symbols (bars) sometimes are
-linked across staffs. I should first think of a way to do this in
-LilyPond, before even considering a syntax.
-
 
 =head2 Volta
 
@@ -192,7 +127,6 @@ editions:
 Just ideas:
 
        || && !         filter syntax 
-       +               merging of voices
 
 =head2 Quoting
 
index fdee2203875e88b8ad0c517a2227bad8418b73aa..26a6664150d5a40b5ac11abe29d02cd75d1bfd72 100644 (file)
@@ -175,7 +175,7 @@ compile/configure options please).
 Send a description of the bug itself.
 
 =item *
-Send it to bug-gnu-music@vuse.vanderbilt.edu.
+Send it to bug-gnu-music@gnu.org.
 
 =back
 
@@ -256,29 +256,29 @@ mailing list have been setup:
 
 =over 4
 
-=item info-gnu-music@vuse.vanderbilt.edu
+=item info-gnu-music@gnu.org
 
 For information on the GNU Music project, to subscribe: send mail with
-subject "subscribe" to info-gnu-music-request@vuse.vanderbilt.edu
+subject "subscribe" to info-gnu-music-request@gnu.org
 
-=item help-gnu-music@vuse.vanderbilt.edu
+=item help-gnu-music@gnu.org
 
 For help with programs from the GNU music project.  To subscribe: send
 mail with subject "subscribe" to
-help-gnu-music-request@vuse.vanderbilt.edu
+help-gnu-music-request@gnu.org
 
-=item bug-gnu-music@vuse.vanderbilt.edu
+=item bug-gnu-music@gnu.org
 
 If you have bugreports, you should send them to this list.  If you want
 to read all bugreports, you should subscribe to this list.  To
 subscribe: send mail with subject "subscribe" to
-bug-gnu-music-request@vuse.vanderbilt.edu
+bug-gnu-music-request@gnu.org
 
-=item gnu-music-discuss@vuse.vanderbilt.edu,
+=item gnu-music-discuss@gnu.org,
 
 For discussions concerning the GNU Music project, to subscribe: send
 mail with subject "subscribe" to
-gnu-music-discuss-request@vuse.vanderbilt.edu,
+gnu-music-discuss-request@gnu.org,
 
 
 =back
index dc1d9d80041a2059aedbd3bf7005510099db321b..26a0026b5c7ba513430d6f83363676271fc77839 100644 (file)
@@ -65,13 +65,13 @@ The following newsgroups all contain material relevant to LilyPond
 
 =over 4
 
-=item news:comp.music.research
+=item news://comp.music.research
 
-=item news:rec.music.compose
+=item news://rec.music.compose
 
-=item news:gnu.announce
+=item news://gnu.announce
 
-=item news:comp.os.linux.announce
+=item news://comp.os.linux.announce
 
 =back
 
@@ -82,30 +82,30 @@ mailing list have been setup:
 
 =over 4
 
-=item info-gnu-music@vuse.vanderbilt.edu
+=item info-gnu-music@gnu.org
 
 A moderated list for information on the GNU Music project, to
 subscribe: send mail with subject "subscribe" to
-info-gnu-music-request@vuse.vanderbilt.edu
+info-gnu-music-request@gnu.org
 
-=item help-gnu-music@vuse.vanderbilt.edu
+=item help-gnu-music@gnu.org
 
 For help with programs from the GNU music project. To subscribe: send
 mail with subject "subscribe" to
-help-gnu-music-request@vuse.vanderbilt.edu
+help-gnu-music-request@gnu.org
 
-=item bug-gnu-music@vuse.vanderbilt.edu
+=item bug-gnu-music@gnu.org
 
 If you have bugreports, you should send them to this list. If you want
 to read all bugreports, you should subscribe to this list.  To
 subscribe: send mail with subject "subscribe" to
-bug-gnu-music-request@vuse.vanderbilt.edu
+bug-gnu-music-request@gnu.org
        
-=item gnu-music-discuss@vuse.vanderbilt.edu,
+=item gnu-music-discuss@gnu.org,
 
 For discussions concerning the GNU Music project, to subscribe: send
 mail with subject "subscribe" to
-gnu-music-discuss-request@vuse.vanderbilt.edu
+gnu-music-discuss-request@gnu.org
 
 =back
 
index 783d5bd74a48ec52446aec93f814e1567cd495a7..ed95d6ff0b2ce6a9a75cb9665ee96cc42e6b61fb 100644 (file)
@@ -50,11 +50,11 @@ Just as an aside, the LilyPond package includes the following music:
 J.S. Bach, Das Wohltemperierte Clavier I: C major Prelude & Fugue, C
 minor fugue.  Solo cello suites: suite II, menuetto (alto version).
 
-=item * 
+=item *
 
 F. Schubert, St\"andchen (Serenade) "Leise flehen meine Lieder"
 
-=item * 
+=item *
 
 Tarquinio Merula, La Gallina a 2 violini
 
diff --git a/NEWS b/NEWS
index 650f5ba4dbff8d300f8bedac077c7541e129cdb0..bb0e37a02ddda0a0a69fb287f47ad90cf22cf8be 100644 (file)
--- a/NEWS
+++ b/NEWS
@@ -1,3 +1,45 @@
+pl 39
+       - 0.2 ANNOUNCE sketch
+       - unix style paths for LILYINCLUDE env
+       - show all output pages on website
+       - ps-to-gifs.sh
+       - bf: wtk1-fugue2
+       - python make-website
+       - higher brace resolution 
+       - phased out musixtex stuff
+       - bf: rhythm.ly
+       - PS slurs
+       - PS beams
+       - Bow units
+       - turn on PS by default
+       - turn off barnumbers by default.
+       - bf: halfbeam size.
+       - bf: -M bug
+       - stafflinethick in PS (crescendi)
+       - continued (de)crescendi (in PS)
+       - bf: spurious beam reqs
+       - handle unfeasible spacing cleanly. 
+       - ML-address change
+       - output naming: default to basename[-serialnumber].{midi,tex}
+       - bf: clef width
+
+pl 39.jcn2
+       - make-examples.sh
+       - leftright repeat sign + repeatbar dims
+       - smaller minimum sized rod at end of bar
+       - bf: spacing.ly 
+       - less space at begin of bar
+       - experimental whitespace fixes at begin and end of bar
+       - added to beams.ly
+       - open-up beam spacing for mult > 3
+       - fixed hang/sit to overlap iso aligne with staffline
+       - fixed inter beam spacing, paper*.ly
+       - scsii-menuetto.ly fixes
+       - init/property.ly
+       - property settings for beam quantiseing and damping
+       - provisionary multiple-beam fix
+
+******
 pl 38
        - bf: \> \! \ff (crescendo overlap)
        - misc feta-fixes, flageolet sign.
diff --git a/TODO b/TODO
index 02e8452ce5f6cc259f13d338018c677f2cd22303..a9b64f1dd997fedd30a03bd079ff674c391982e3 100644 (file)
--- a/TODO
+++ b/TODO
@@ -7,20 +7,16 @@ Most of the items are marked in the code as well, with full explanation.
 grep for TODO and ugh/ugr
 
 0.2:
-       * -M bug
 
-       * unended beam: [c4
+       * beam quanting
 
-       * continued hairpins
+       * disable spaces in TeX stuff
 
        * height of dyns.
        
-       * output naming:
-       - default to basename[-serialnumber].{midi,tex}
-       
        * handle ^C for tmp/file creation.
 
-       * PS for beams.
+       * WWW mirror/archive for the mailing lists.
 
        * dots & rest collisions.
 
@@ -32,18 +28,12 @@ grep for TODO and ugh/ugr
        
        * documentation
 
-       * spurious "Junk beam" warnings
-
-       * standchen: warning: Excentric column (Meter dims?)
-
        * naming Mozarella, Madeira, Muella?
 
        * versioning for Feta
 
        * bf: abbrevs over whole note
 
-       * bf: wtk1-fug2 ending
-
 STUFF
 
        * give Items/Spanners access to unbroken originals      
@@ -71,7 +61,10 @@ STUFF
        - MIDI instrument
        - staff title
 
-       * optimal pagebreaking.
+       * page handling:
+       - papersizes
+       - PS output
+       - optimal pagebreaking.
 
        * put errorlevel in Input class
 
@@ -79,6 +72,8 @@ STUFF
 
 3RD PARTY BUGS:
 
+       * xdvi: PS magnifying glass.
+
        * Rational infty(HUGE_VAL) on glibc / w32
 
        * Fix profiling. gprof bugreport?
@@ -93,14 +88,11 @@ PROJECTS
 
        * Spring_spacer:
        - write a faster Spring_spacer (without matrices if possible)
-       - use straight QP to find minimal "fitting force"
+       - use straight LP to find minimal "fitting force"
        - relate energybound to linelen unitspace fontsize etc.
        - used fixed point fp
 
        * \header
-       - write perl/python script for handling it into databases
-       - write TeX macros to generate titles
-       - adapt make-website to use \header info.
        - output header info to MIDI too.
 
 
@@ -297,8 +289,6 @@ SMALLISH PROJECTS
 
        * adaptive accidental spacing.
 
-       * unix style paths for LILYINCLUDE env
-
        * handle EOF graciously in error messages.
 
        * caching Item/spanner dimensions.
diff --git a/VERSION b/VERSION
index 1cd375d59355e0ef21f3cb1e38bc5579792bfe5e..1cb7a136d909c97250e67f527ad7788239b1777f 100644 (file)
--- a/VERSION
+++ b/VERSION
@@ -1,6 +1,6 @@
 TOPLEVEL_MAJOR_VERSION = 0
 TOPLEVEL_MINOR_VERSION = 1
-TOPLEVEL_PATCH_LEVEL = 38
+TOPLEVEL_PATCH_LEVEL = 39
 TOPLEVEL_MY_PATCH_LEVEL = 
 
 # use the above to send patches, always empty for released version:
index dc25ffeaca7419f54b40bcb9ca80c74302cb7fcd..e02b17ddf9a490f2eb2af23f24916452b47c98df 100644 (file)
@@ -1,14 +1,17 @@
 #!/bin/sh
 
 # unclobber current dir.
-rm -vf *.aux *.log `grep -li "^% Creator: GNU LilyPond" *.out` *.orig *~
+rm -vf *.aux *.log *.orig *~
+rm -vf `grep -li "^% Creator: GNU LilyPond" *.out *.tex` 
 rm -vf `grep -li "Creator: mi2mu" *.midi.ly`
+rm -vf `grep -li "%Creator: dvipsk" *.ps`
 rm -vf `grep -li "Creator: GNU LilyPond" *.midi`
 rm -vf `grep -li "Creator: ly2dvi" *.tex`
 rm -vf `find -name 'core'`
 rm -vf `find -name *.orig`
 rm -vf `find -name *.rej`
 
+    
 # docxx mess
 rm -vf *dvi
 rm -vf *.class  HIER*.html dxxgifs.tex gifs.db icon?.gif logo.gif down.gif \
index fb6f1a51f5695111a2756a541b59b96447271751..5b68b9773928fbf3afdcc82fd17f6823269572d0 100644 (file)
@@ -117,6 +117,7 @@ class Lilydirs:
        return v
 
 
+
 lilydirs = Lilydirs()
 
 if __name__ == '__main__':
@@ -127,3 +128,56 @@ if __name__ == '__main__':
     print version_tuple_to_str(pv), prev_version(pv), next_version(pv)
     print version_tuple_to_str((0,1,1,''))    
     print mv, version_str_to_tuple(mv)
+
+
+    
+def dump_file(f, s):
+    i = open(f, 'w')
+    i.write(s)
+    i.close ()
+
+def gulp_file(f):
+    i = open(f)
+    i.seek (0, 2)
+    len = i.tell ()
+    i.seek (0,0)
+    return i.read (len)
+
+
+header_regex = regex.compile('\\header[ \t\n]*{\([^}]*\)}')
+header_entry_regex = regex.compile('[\n\t ]*\([^\n\t ]+\)[\n\t ]*=[\n \t]*\([^;]+\)[\n \t]*;')
+
+#
+# FIXME breaks on multiple strings.
+#
+def read_mudela_header (fn):
+    s = gulp_file(fn)
+    s = regsub.gsub('%.*$', '', s)
+    s = regsub.gsub('\n', ' ', s)    
+
+    dict = {}
+    if header_regex.search(s) <> -1:
+       h = header_regex.group(1)
+    else:
+       return dict
+
+    while regex.search('=', h) <> -1: 
+
+       if header_entry_regex.search (h) == -1:
+
+           raise 'format error'
+
+       h = regsub.sub(header_entry_regex, '', h)
+       left = header_entry_regex.group(1)
+       right = header_entry_regex.group(2)
+
+       right = regsub.gsub('\([^\\]\)\"', '\\1', right)
+       right = regsub.gsub('^"', '', right)    
+       left = regsub.gsub('\([^\\]\)\"', '', left)
+       left = regsub.gsub('^"', '', left)
+
+       dict[left] = right
+
+    return dict
+   
+       
diff --git a/bin/make-examples.sh b/bin/make-examples.sh
new file mode 100644 (file)
index 0000000..620a28a
--- /dev/null
@@ -0,0 +1,9 @@
+#!/bin/sh
+# make-examples
+
+examples="twinkle-pop wtk1-fugue2 standchen-16 standchen-20 wtk1-prelude1 toccata-fuga-E scsii-menuetto cadenza gallina twinkle collisions font font20 scales rhythm multi spacing beams stem"
+pss=$(echo $examples | sed "s/[^ ][^ ]*/out\\/&.ps/g")
+
+# cd ~/lelie/current/Documentation/out
+cd ~/lelie/current/input
+make -C ../Documentation $pss
diff --git a/bin/make-website.py b/bin/make-website.py
new file mode 100644 (file)
index 0000000..52bc149
--- /dev/null
@@ -0,0 +1,261 @@
+#!@PYTHON@
+# 
+# make-website.py --  implement The lilypond WWW site
+# 
+# source file of the GNU LilyPond music typesetter
+# 
+# (c) 1997 Han-Wen Nienhuys <hanwen@stack.nl>
+# 
+
+""" 
+ stupid script to generate WWW site.  
+
+ The WWW site is my test-suite for LilyPond, I usually don't
+ distribute versions that fail to complete this script """
+
+from lilypython import *
+import __main__
+import glob
+
+depth = ''
+makewebsite_id = "<!make_website!>";
+id_str = "make-website 0.6";
+tar = "tar";
+make = "make";
+mailaddress = "unknown"
+fullname = "unknown"
+footstr = ""
+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["LILYTOP"] = depth;
+    __main__.mailaddress= os.environ['MAILADDRESS']
+    pw = pwd.getpwuid (os.getuid());
+
+    __main__.fullname= pw[4];
+
+backstr = '\n<hr>Please take me <a href=%s>back to the index</a>\n\
+of LilyPond -- The GNU Project Music typesetter\n\
+<hr><font size=-1>\n\
+This page was built using <code>%s</code> from lilypond-%s by <p>\n\
+<address><br>%s <a href=mailto:%s&>>&lt<!bla>%s</a>&gt</address>\n\
+<p></font>' 
+
+    
+def footstr(index):
+     return backstr % (index, id_str, lilyversion, fullname, mailaddress, mailaddress)
+
+    
+
+# do something, check return status
+def my_system(cmds):
+    for cmd in cmds:
+       ignoreret=0;
+       if cmd[0] == '-':
+           ignoreret = 1
+           cmd = cmd[1:]
+       
+       ret = os.system (cmd)
+       if ret:
+           if ignoreret: 
+               sys.stderr.write( "ignoring failed command \`%s\' (status %d)\n" % (cmd, ret))
+           else:
+               sys.stderr.write( 'make-website: failed on command %s (status %d)\n' % (cmd, ret))
+               sys.exit (2)
+
+base="lilypond/";
+
+examples=["twinkle-pop", 
+                "wtk1-fugue2",
+                "standchen-16", 
+                "standchen-20", 
+                "wtk1-prelude1",
+                "toccata-fuga-E", 
+                "scsii-menuetto",
+                "cadenza", 
+                "gallina",
+                "twinkle", 
+                "collisions",
+                "font",
+                "font20",
+                #"scales", 
+                "rhythm", 
+                "multi"]
+
+def gen_html():
+    print 'generating HTML'
+    my_system (["make -kC .. html"]);
+    
+
+def gen_examples():
+    print 'generating examples:\n'
+    list = map(lambda x: 'out/%s.ps.gz out/%s.gif out/%s.ly.txt' % (x,x,x), examples)
+    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( "<HTML><TITLE>PostScript Manuals</TITLE>\n" 
+     "<BODY><h1>LilyPond manuals (in PostScript)</h1>"
+     "<ul>\n")
+    todo='' 
+    for stuff in texstuff:
+       todo = todo + ' out/' + stuff + '.ps.gz'
+       list.write("<li><a href=%s.ps.gz>%s.ps.gz</a>" % (stuff, stuff))
+    list.write('</ul></BODY></HTML>')
+    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')
+    list.write ('<html><TITLE>Rendered Examples</TITLE>\n'
+     '<body>These example files are taken from the LilyPond distribution.\n'
+     'LilyPond currently only outputs TeX and MIDI. The pictures and\n'
+     'PostScript files were generated using TeX, Ghostscript and some\n'
+     '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:
+       header  = read_mudela_header(ex + '.ly.txt')
+       def read_dict(s, default, h =header):
+               try:
+                   ret = h[s]
+               except KeyError:
+                   ret = default
+               return ret
+       head = read_dict('title', ex)
+       composer = read_dict('composer', '')
+       desc = read_dict('description', '')
+       list.write('<hr>')
+       list.write('<h1>example file: %s</h1>' % head);
+       if composer <> '':
+           list.write('<h2>%s</h2>\n' % composer)
+       if desc <> '':
+           list.write('%s<p>' % desc)
+       list.write ('<ul>')
+       def list_item(filename, desc, l = list):
+           if file_exist_b(filename):
+               l.write ('<li><a href=%s>%s</a>\n' % (filename, desc))
+           
+       list_item(ex + '.ly.txt', 'The input')
+       for pageno in range(1,10):
+           f  = ex + '-page%d.gif' % pageno
+           if not file_exist_b (f):
+               break
+           list_item(f, 'The output (picture, page %d)' % pageno)
+       list_item(ex + '.ps.gz', 'The output (gzipped PostScript)')
+       list_item(ex + '.midi', 'The output (MIDI)')
+       list.write ("</ul>");
+
+    list.write( "</BODY></HTML>");
+    list.close()
+
+def copy_files():
+    print "copying files\n"
+    
+#    my_system ("ln -s depth/out ./docxx" )
+    my_system([ "cp %s/TODO ./TODO.txt" % depth,
+    "cp %s/ANNOUNCE-0.1 ./ANNOUNCE.txt" % depth,
+    "cp %s/NEWS ./NEWS.txt" % depth,
+    "cp %s/DEDICATION ./DEDICATION.txt" % depth]);
+    my_system([ "make -C .. gifs"]);
+    
+def docxx_update():
+    print 'docxx.. \n'
+    banner= open('/tmp/lilybanner.html', 'w');
+    banner.write (footstr('../index.html'))
+    banner.close ()
+    my_system(['BANNEROPT=\"-B /tmp/lilybanner.html\" %s/bin/out/make-docxx' % depth]);
+#    os.unlink( "/tmp/lilybanner.html");
+
+def get_glob(exts):
+    result = []
+    for a in exts:
+       result = result + glob.glob1('./', '*.' + a)
+
+    return result
+
+def join(inter, list):
+    return reduce (lambda x,y, i=inter: x + i + y, list)
+
+def do_tar():
+     print "tarring.\n";
+     list = get_glob( ['html', 'gif', 'ps.gz' , 'txt', 'midi']) 
+     files = join (' ', list)
+     print files
+     my_system( ['-tar zvhcf website.tar.gz ' + files + ' docxx/*'])
+
+
+def identify():
+    print 'This is %s\n' % id_str
+    
+def clean_tmp():
+    my_system(['rm -f /tmp/gs*'])
+    
+def get_top_of_NEWS():
+    i = open('NEWS.txt')
+    lines = i.readlines()
+    i.close ()
+    s = ''
+    for l in lines:
+       if regex.search('^\*\*\*\*\*\*', l) <> -1:
+           return s;
+       s = s + l
+    return s
+
+def edit_index():
+    s = gulp_file('index.html')
+    s = regsub.sub ('top_of_NEWS', '<XMP>\n' + get_top_of_NEWS () + '\n</XMP>', s)
+    dump_file ('index.html', s)
+
+def edit_html():
+    files = get_glob(['html'])
+    for f in files:
+
+       s = gulp_file(f)
+       if regex.search(makewebsite_id, s) <> -1:
+           continue;
+
+       s = regsub.sub ('</BODY>', footstr('index.html') + makewebsite_id + '</BODY>', s)
+       s = regsub.sub('<TITLE>\(.*\)</TITLE>$', 
+                      '<TITLE>LilyPond WWW: \\1</TITLE>', s)
+       dump_file (f,s)
+
+def main():
+    identify();
+
+    os.chdir (lilydirs.topdir + 'Documentation/out')
+    __main__.depth = "../../";
+
+    set_vars();
+    gen_html();
+    copy_files();
+    gen_examples();
+    gen_list();
+    gen_manuals();
+    #set_images();
+    edit_html();
+    edit_index();
+    docxx_update()
+    do_tar()
+    clean_tmp();
+
+
+main()
+
+
index 9aec75cb60a40c9ca6f870a8557e25b2b970b8ea..37206c3c810b9b85131404577219d32e8c8dc64e 100644 (file)
@@ -34,9 +34,13 @@ sub gen_mufile
     return "$outdir/$outname$mudcount.ly";
 }
 
+sub gen_texbase
+{
+    return "$outname$mudcount.tex";
+}
 sub gen_texfile
 {
-    return "$outdir/$outname$mudcount.tex";
+    return "$outdir/" . gen_texbase;
 }
 
 sub close_mudela
@@ -64,7 +68,7 @@ sub close_mudela
     
     if ( ! -f gen_texfile) {
        my_system "lilypond ". gen_mufile;
-       rename "lelie.tex", gen_texfile;
+       rename gen_texbase, gen_texfile;
     }
     print BOOK "\\preexample\\input " . gen_texfile . "\n\\postexample\n";
        
diff --git a/bin/ps-to-gifs.sh b/bin/ps-to-gifs.sh
new file mode 100644 (file)
index 0000000..dc51988
--- /dev/null
@@ -0,0 +1,24 @@
+#!/bin/bash
+  
+usage()
+{
+    echo 'ps-to-gifs.sh FILE.ps'
+    exit 2;
+}
+
+case $# in
+1)
+    FILE=`basename $1 .ps`
+    ;;
+*)
+    usage
+    ;;
+esac
+
+# generate the pixmap at twice the size, then rescale (for antialiasing)
+cat $1 | gs  -q -sDEVICE=ppmraw \
+    -sOutputFile="|pnmscale 0.5|ppmtogif > $FILE-page%d.gif" \
+    -r200 -dNOPAUSE - -c quit
+
+
+
index ee5bc6a4f7374a709dfcda8ec0dde947832c3d70..a971abbae7edf93832efb125821e2a568a1730f1 100644 (file)
@@ -63,7 +63,7 @@ AC_ARG_ENABLE(tex-dir,
     [TEXDIR=auto] )
 
 AC_ARG_ENABLE(mf-dir,
-     [  mf-dir=DIR             set the directory to put LilyPond MetaFont files in. (obsolete)],
+     [  mf-dir=DIR             set the directory to put LilyPond MetaFont files in. ],
      [MFDIR=$enableval],
      [MFDIR=auto])
 
index 6bb008a5cd0a8be97d0cb7b94da2ad31e3b424ca..7f35925fb61c07c1cb4e91f161598ec71f3cb8fd 100644 (file)
@@ -15,5 +15,5 @@ include ./$(depth)/make/Rules.make
 #
 
 
-EXTRA_DISTFILES = README.debian TODO changelog control copyright \
+EXTRA_DISTFILES = README.Debian TODO changelog control copyright \
        info.ex menu.ex postinst postinst.old.sh postrm preinst rules watch
diff --git a/debian/README.Debian b/debian/README.Debian
new file mode 100644 (file)
index 0000000..ba5d98e
--- /dev/null
@@ -0,0 +1,22 @@
+lilypond for DEBIAN
+-------------------
+
+Starting with version 0.1.12, LilyPond comes with some new MF fonts.
+These fonts are not currently listed in /usr/lib/texmf/fontname/special.map
+(from the teTeX package), therefore the fonts will be created in a
+non-standard directory somewhere under /var/spool/texmf.  The problem is
+usually only aesthetic.  TeTeX can create and find the *.tfm and *.pk files
+without any problems.
+
+However, if you experience any font problems (such as the note heads
+not showing up, characters in the wrong places, error messages from
+TeX), especially after upgrading to a new version of LilyPond, you may
+need to delete the relevant *.tfm and *.pk files under the directory
+/var/spool/texmf.  You may also file a bug report about this if you
+like.
+
+LilyPond is still in active development, and many things may still change.
+When it is stablized in the future, these new fonts will probably be
+added into the standard special.map file.
+
+Anthony Fok <foka@debian.org>, Thu, 23 Oct 1997 16:59:32 -0600
index 5610f02a099e3a45e0740a031a5dc7cce32edcae..f7db23a49c5d9d0984ec8f8080b6a1339342d6d2 100644 (file)
@@ -1,3 +1,7 @@
+pl 33
+       - String naming
+       - unix style paths
+
 pl 32
        - Assoc::clear
        - bf: Assoc[PreviouslyUsedAndDeletedKey] = foo
index 942ef5290575573c8621ace1fe3244b493608969..636df4b25f7e370a0076cc4fdd6938eb4e328c13 100644 (file)
@@ -1,6 +1,6 @@
 MAJOR_VERSION = 1
 MINOR_VERSION = 1
-PATCH_LEVEL = 32
+PATCH_LEVEL = 33
 # use to send patches, always empty for released version:
 MY_PATCH_LEVEL = # include separator: "-1" or ".a"
 #
index 4d7ec7e7a95be012c8b6c57374c7bb6d71ca8b5a..f22365bf551f520c8a26a114b187bc35f3df1f46 100644 (file)
@@ -71,7 +71,7 @@ Dstream::identify_as (String name)
 }
 
 bool
-Dstream::silence (String s)
+Dstream::silent_b (String s) const
 {
   if (!silent_assoc_p_->elt_b (s))
     return false;
index 4d14ae34ec01558a13f9fbb8ef5e16cb050503a5..752b78bca485d0717758345fb214fc25b46fc257 100644 (file)
@@ -42,7 +42,7 @@ class Dstream
     Assoc<String, bool> *silent_assoc_p_;
 public:
     void clear_silence();
-    bool silence (String);
+    bool silent_b (String) const;
     
     /**
       if rcfile == 0, then do not read any rc file.
index 1f3a5eb97ad80b0885c5a82a672f8dea1e848466..caa6bbb752e159560d0183e58c1d2c4a7d624f7a 100644 (file)
 class File_path : private Array<String>
 {
 public:
-    /// locate a file in the search path
-    String find (String nm) const;
+  /// locate a file in the search path
+  String find (String nm) const;
 
-    /// add to end of path.
-    Array<String>::push;
-    void add (String str) { push (str); }
+  /// add to end of path.
+  Array<String>::push;
+  void add (String str) { push (str); }
+  void parse_path (String);
 };
 
 /** split a path into its components.
index 91342a1de368bfb288669783decfeacd93de41bf..067ea3358e029d1e11a455502d2eeb03a01714ec 100644 (file)
@@ -130,7 +130,7 @@ public:
 
 
   /// return a piece starting at index_i (first char = index_i 0), length n
-  String mid_str (int index_i, int n) const;
+  String cut (int index_i, int n) const;
 
   /// cut out a middle piece, return remainder
   String nomid_str (int index_i, int n) const;
@@ -141,10 +141,14 @@ public:
   /// index of rightmost c 
   int index_last_i (char c) const;
 
-  /// index of rightmost element of string 
+  /// index of rightmost element of string  (???)
   int index_last_i (char const* string) const;
 
+  /// index of leftmost #c#
   int index_i (char c) const;
+
+
+  /// index of leftmost occurance of STRING
   int index_i (String) const;
   int index_any_i (String) const;
 
index b69d85d77a499515b7b5f709cbc8f6fca662ee85..a499d0abf4ee3d6572dffb8dbc145a8bf9d44c03 100644 (file)
@@ -5,8 +5,12 @@
 #include "path.hh"
 #include "flower-debug.hh"
 
+#ifndef DIRSEP
+#define DIRSEP '/'
+#endif
+
 #ifndef PATHSEP
-#define PATHSEP '/'
+#define PATHSEP ':'
 #endif
 
 /**
 */
 void
 split_path (String path,
-          String &drive, String &dirs, String &filebase, String &extension)
+           String &drive, String &dirs, String &filebase, String &extension)
 {
   // peel off components, one by one.
   int di = path.index_i (':');
   if (di >= 0)
-       {
-       drive = path.left_str (di + 1);
-       path = path.right_str (path.len() - di -1);
-         }
+    {
+      drive = path.left_str (di + 1);
+      path = path.right_str (path.len() - di -1);
+    }
   else
-       drive = "";
+    drive = "";
 
-  di = path.index_last_i (PATHSEP);
+  di = path.index_last_i (DIRSEP);
   if (di >=0)
-       {
-       dirs = path.left_str (di + 1);
-       path = path.right_str (path.len()-di -1);
-         }
+    {
+      dirs = path.left_str (di + 1);
+      path = path.right_str (path.len()-di -1);
+    }
   else
-       dirs = "";
+    dirs = "";
 
   di = path.index_last_i ('.');
   if (di >= 0)
-       {
-       filebase = path.left_str (di);
-       extension =path.right_str (path.len()-di);
-         }
+    {
+      filebase = path.left_str (di);
+      extension =path.right_str (path.len()-di);
+    }
   else
-       {
-       extension = "";
-       filebase = path;
-         }
+    {
+      extension = "";
+      filebase = path;
+    }
 }
 
+void
+File_path::parse_path (String p)
+{
+  int l;
+  
+  while ( (l = p.length_i ()) )
+    {
+      int i = p.index_i(PATHSEP);
+      if (i <0) 
+       i = l;
+      add (p.left_str(i));
+      p = p.right_str (l- i - 1);
+    }
+}
+
+
+
+
 /** find a file.
   It will search in the current dir, in the construction-arg, and
   in any other added path, in this order.
@@ -59,25 +81,24 @@ File_path::find (String nm) const
 {
   fdebug << _("looking for ") << nm << ": ";
   if (!nm.length_i() || (nm == "-") )
-       return nm;
+    return nm;
   for (int i=0; i < size(); i++)
     {
+      String path  = elem(i);
+      if (path.length_i() )
+       path += "/";
 
-        String path  = elem(i);
-        if (path.length_i() )
-            path += "/";
+      path += nm;
 
-        path += nm;
-
-        fdebug << path << "? ";
-        FILE *f = fopen (path.ch_C(), "r"); // ugh!
-        if (f)
-          {
-            fdebug << _("found\n");
-            fclose (f);
-            return path;
-          }
-     }
+      fdebug << path << "? ";
+      FILE *f = fopen (path.ch_C(), "r"); // ugh!
+      if (f)
+       {
+         fdebug << _("found\n");
+         fclose (f);
+         return path;
+       }
+    }
   fdebug << "\n";
   return "";
 }
index ab7c6ab3e666bcdfb3ef2e95dbf244689e392e5e..a8f661904890af4daa967368a604fc8565f96c2f 100644 (file)
@@ -31,8 +31,8 @@ String_convert::bin2hex_str (String bin_str)
   Byte const* byte_C = bin_str.byte_C();
   for (int i = 0; i < bin_str.length_i(); i++) 
     {
-       str += (char)nibble2hex_byte (*byte_C >> 4);
-       str += (char)nibble2hex_byte (*byte_C++);
+      str += (char)nibble2hex_byte (*byte_C >> 4);
+      str += (char)nibble2hex_byte (*byte_C++);
     }
   return str;
 }
@@ -51,8 +51,8 @@ String_convert::bin2_u (String bin_str)
   unsigned result_u = 0;
   for (int i = 0; i < bin_str.length_i(); i++) 
     {
-       result_u <<= 8;
-       result_u += (Byte)bin_str[ i ];
+      result_u <<= 8;
+      result_u += (Byte)bin_str[ i ];
     }
   return result_u;
 }
@@ -62,7 +62,7 @@ int
 String_convert::dec2_i (String dec_str)
 {
   if (!dec_str.length_i())
-       return 0;
+    return 0;
 
   long l = 0;
   int conv = sscanf (dec_str.ch_C(), "%ld", &l);
@@ -76,7 +76,7 @@ String_convert::i64_str (I64 i64, char const* fmt)
 {
   char buffer[STRING_BUFFER_LEN];
   snprintf (buffer, STRING_BUFFER_LEN,
-            (fmt ? fmt : "%Ld"), i64);     // assume radix 10
+           (fmt ? fmt : "%Ld"), i64);     // assume radix 10
   return String (buffer);
 
 }
@@ -85,7 +85,7 @@ double
 String_convert::dec2_f (String dec_str)
 {
   if (!dec_str.length_i())
-       return 0;
+    return 0;
   double d = 0;
   int conv = sscanf (dec_str.ch_C(), "%lf", &d);
   assert (conv);
@@ -96,7 +96,7 @@ int
 String_convert::hex2bin_i (String hex_str, String& bin_str_r)
 {
   if (hex_str.length_i() % 2)
-      hex_str = "0" + hex_str;
+    hex_str = "0" + hex_str;
 
   bin_str_r = "";
   Byte const* byte_C= hex_str.byte_C();
@@ -106,7 +106,7 @@ String_convert::hex2bin_i (String hex_str, String& bin_str_r)
       int high_i = hex2nibble_i (*byte_C++);
       int low_i = hex2nibble_i (*byte_C++);
       if (high_i < 0 || low_i < 0)
-          return 1; // illegal char
+       return 1; // illegal char
       bin_str_r += String ((char)(high_i << 4 | low_i), 1 );
       i += 2;
     }
@@ -117,8 +117,8 @@ String
 String_convert::hex2bin_str (String hex_str)
 {
   String str;
-//  silly, asserts should alway be "on"!
-//    assert (!hex2bin_i (hex_str, str) );
+  //  silly, asserts should alway be "on"!
+  //    assert (!hex2bin_i (hex_str, str) );
   int error_i = hex2bin_i (hex_str, str);
   assert (!error_i);
   return str;
@@ -128,11 +128,11 @@ int
 String_convert::hex2nibble_i (Byte byte)
 {
   if (byte >= '0' && byte <= '9')
-      return byte - '0';
+    return byte - '0';
   if (byte >= 'A' && byte <= 'F')
-      return byte - 'A' + 10;
+    return byte - 'A' + 10;
   if (byte >= 'a' && byte <= 'f')
-      return byte - 'a' + 10;
+    return byte - 'a' + 10;
   return -1;
 }
 
@@ -142,7 +142,7 @@ String_convert::i2dec_str (int i, int length_i, char ch)
 {
   char fill_ch = ch;
   if (fill_ch)
-      fill_ch = '0';
+    fill_ch = '0';
 
   // ugh
   String dec_str (i);
@@ -158,13 +158,13 @@ String_convert::u2hex_str (unsigned u, int length_i, char fill_ch)
 {
   String str;
   if (!u)
-       str = "0";
+    str = "0";
 
 #if 1 // both go...
   while (u) 
     {
-       str = String ((char)((u % 16)["0123456789abcdef"] ) ) + str;
-       u /= 16;
+      str = String ((char)((u % 16)["0123456789abcdef"] ) ) + str;
+      u /= 16;
     }
 #else
   str += int_str (u, "%x");    // hmm. %lx vs. %x -> portability?
@@ -172,7 +172,7 @@ String_convert::u2hex_str (unsigned u, int length_i, char fill_ch)
 
   str = String (fill_ch, length_i - str.length_i()) + str;
   while ((str.length_i() > length_i) &&  (str[ 0 ] == 'f' ) )
-       str = str.mid_str (2, INT_MAX);
+    str = str.cut (2, INT_MAX);
 
   return str;
 }
@@ -187,9 +187,9 @@ Byte
 String_convert::nibble2hex_byte (Byte byte)
 {
   if ((byte & 0x0f) <= 9 )
-       return (byte & 0x0f) + '0';
+    return (byte & 0x0f) + '0';
   else
-       return (byte & 0x0f) - 10 + 'a';
+    return (byte & 0x0f) - 10 + 'a';
 }
 /**
   Convert an integer to a string
@@ -202,7 +202,7 @@ String_convert::int_str (int i, char const* fmt)
 {
   char buffer[STRING_BUFFER_LEN];
   snprintf (buffer, STRING_BUFFER_LEN,
-            (fmt ? fmt : "%d"), i);     // assume radix 10
+           (fmt ? fmt : "%d"), i);     // assume radix 10
   return String (buffer);
 }
 
@@ -245,12 +245,12 @@ String_convert::rational_str (Rational r)
   String s = n;
   if (r.denominator() != 1) 
     {
-       char * d = Itoa (r.denominator());
-       s +=  String ('/') + String (d);
-       //delete d;
+      char * d = Itoa (r.denominator());
+      s +=  String ('/') + String (d);
+      //delete d;
     }
-/*    delete n;
-  */
+  /*    delete n;
+   */
   return s;
 }
 
index 74ae9a7865b3e8c553422acdb5078f24c0e8f94c..2076a2a19b52886b71ccb95d57bada8b4dadf8aa 100644 (file)
@@ -34,10 +34,10 @@ void
 String::print_on (ostream& os) const
 {
   if (!strh_.is_binary_bo())
-      os << ch_C();
+    os << ch_C();
   else
-       for (int i = 0; i < length_i(); i++)
-           os << (Byte)(*this)[ i ];
+    for (int i = 0; i < length_i(); i++)
+      os << (Byte)(*this)[ i ];
 }
 \f
 /*
@@ -153,7 +153,7 @@ String::compare_i (String const& s1, String const& s2)
   Byte const* p1 = s1.byte_C();
   Byte const* p2 = s2.byte_C();
   if (p1 == p2)
-       return 0;
+    return 0;
 
   int i1 = s1.length_i();
   int i2 = s2.length_i();
@@ -167,12 +167,12 @@ int
 String::index_last_i (char const c) const
 {
   if (!length_i()) 
-       return -1;
+    return -1;
 
   char const* me = strh_.ch_C();
   char const* p = memrchr (me, length_i(), c);
   if (p)
-       return p - me;
+    return p - me;
   return -1;
 }
 
@@ -182,17 +182,17 @@ String::index_last_i (char const* string) const // UGK!
   assert (false);              // broken
   int length = strlen (string); // ugrh
   if (!length_i() || !length) 
-       return -1;
+    return -1;
   
   int next_i = index_i (string);
   if (next_i == -1)
-       return -1;
+    return -1;
   
   int index_i = 0;
   while (next_i >= 0) 
     {
-       index_i += next_i;
-       next_i = right_str (length_i() - index_i - length).index_i (string );
+      index_i += next_i;
+      next_i = right_str (length_i() - index_i - length).index_i (string );
     }
   return index_i;
 }
@@ -211,7 +211,7 @@ String::index_i (char c) const
   char const* me = strh_.ch_C();
   char const* p = (char const *) memchr (me,c,  length_i());
   if (p)
-       return p - me;
+    return p - me;
   return -1;
 }
 
@@ -226,12 +226,12 @@ String::index_i (String searchfor) const
 {
   char const* me = strh_.ch_C();
   char const* p = (char const *) memmem (
-       me, length_i(), searchfor.ch_C(), searchfor.length_i ());
+                                        me, length_i(), searchfor.ch_C(), searchfor.length_i ());
   
   if (p)
-       return p - me;
+    return p - me;
   else
-       return -1;
+    return -1;
 }
 
 /** find chars of a set.
@@ -244,16 +244,16 @@ String::index_any_i (String set) const
 {
   int n = length_i();
   if (!n)
-       return -1;
+    return -1;
 
   void const * me_l = (void const *) strh_.ch_C();
   for (int i=0; i  < set.length_i(); i++) 
     {
-       char * found=(char*) memchr (me_l, set[i], n );
-       if (found) 
-         {
-           return found - me_l;
-         }
+      char * found=(char*) memchr (me_l, set[i], n );
+      if (found) 
+       {
+         return found - me_l;
+       }
     }
   return -1;
 }
@@ -262,11 +262,11 @@ String
 String::left_str (int n) const
 {
   if (n >= length_i())
-       return *this;
+    return *this;
 
   String retval;       
   if (n < 1)
-      return retval;
+    return retval;
   
   retval = *this;
   retval.strh_.trunc (n);
@@ -277,10 +277,10 @@ String
 String::right_str (int n) const
 {
   if (n > length_i())
-       return *this;
+    return *this;
   
   if (n < 1)
-      return "";
+    return "";
   
   return String (strh_.byte_C() + length_i() - n, n); 
 }
@@ -291,34 +291,31 @@ String::nomid_str (int index_i, int n) const
 {
   if (index_i < 0) 
     {
-       n += index_i;
-       index_i = 0;
+      n += index_i;
+      index_i = 0;
     }
   if (n <= 0)
-       return *this;
+    return *this;
   
   return
-       left_str (index_i)   +
-       right_str (length_i() - index_i - n) ;
+    left_str (index_i)   +
+    right_str (length_i() - index_i - n) ;
 }
 
-/*
-  proposal: change to "cut()"
- */
 String
-String::mid_str (int index_i, int n) const
+String::cut (int index_i, int n) const
 {
   if (index_i <0) 
     {
-       n += index_i;
-       index_i=0;
+      n += index_i;
+      index_i=0;
     }
   
   if (!length_i() || (index_i < 0) || (index_i >= length_i () ) || (n < 1 ) )
-       return String();
+    return String();
 
   if ((n > length_i()) ||  (index_i + n > length_i () ) )
-       n = length_i() - index_i;
+    n = length_i() - index_i;
 
   return String (byte_C() + index_i, n);
 }
index eebafed3fdbc7e91bef3924e6400742dc3810fc4..e8869c0de93cd3740fd23cfb30ad638bf152668f 100644 (file)
@@ -81,8 +81,8 @@ Score = \translator {
        \type Score_engraver;
 
        \consists "Timing_engraver";
-       \consists "Bar_column_engraver";
-       \consists "Bar_number_engraver";
+       %\consists "Bar_column_engraver";
+       %\consists "Bar_number_engraver";
 
        \consists "Span_score_bar_engraver";
        \consists "Score_priority_engraver";
index c1753b3263510b23723f67fdd1f68603630d0b37..b47910ac6984743041d96a2175248e2ac2d21aa1 100644 (file)
@@ -16,7 +16,6 @@ Wordwrap = 0.0
 \include "paper16.ly"
 \include "paper20.ly"
 
-
 default_paper = \paper{
        \paper_sixteen
 }
@@ -29,21 +28,8 @@ left = -1
 right = 1
 up = 1
 down = -1
+% zillie spellink?
 center=0
 
-
-stemup = {
-       \skip 1*0;
-       % Stupid hack to make < { \stemup } > work
-       \property Voice.ydirection = \up 
-       }
-stemboth= {
-       \skip 1*0;
-       \property Voice.ydirection = \center
-}
-stemdown = {   
-       \skip 1*0;
-       \property Voice.ydirection = \down
-}
-
+\include "property.ly"
 
index 854324b424cc20491a612063815c57775b0dc055..98ee62688de10b0728ac4a71b4ea97936d09f601 100644 (file)
@@ -26,8 +26,13 @@ paper_sixteen = \paper {
        arithmetic_basicspace = 2.;
         arithmetic_multiplier = 4.8\pt;
    
-       %
-       interbeam = 2.667\pt;
+       % three beams span two interlines, including stafflines:
+       % 2 interbeam + beam_thickness = 2 interline - staffline_thickness
+       % ( beam_thickness = 0.48 interline for now...)
+       % interbeam = interline - (beam_thickness + staffline_thickness) / 2
+       % interbeam = 2.84;
+       % ugh: interline *in fact* is rule_thickness + "interline"?
+       interbeam = 3.14;
 
        gourlay_energybound = 100000.;
        gourlay_maxmeasures = 14.;
index fdfee8404b7128d3ced1daa9af09b348280cdef2..e4bd6bfb00c8fbf46b32e9a7849e6b9f87831bce 100644 (file)
@@ -19,7 +19,14 @@ paper_twenty = \paper {
         arithmetic_multiplier = 6.\pt;
        
        %
-       interbeam = 3.333\pt;
+       % three beams span two interlines, including stafflines:
+       % 2 interbeam + beam_thickness = 2 interline - staffline_thickness
+       % ( beam_thickness = 0.48 interline for now...)
+       % interbeam = interline - (beam_thickness + staffline_thickness) / 2
+       % interbeam = 3.6;
+       % ugh: interline *in fact* is rule_thickness + "interline"?
+       interbeam = 3.9;
+
        gourlay_energybound = 100000.;
        gourlay_maxmeasures = 12.;
        
diff --git a/init/property.ly b/init/property.ly
new file mode 100644 (file)
index 0000000..4faeb4c
--- /dev/null
@@ -0,0 +1,94 @@
+% property.ly
+% list of properties that lily recognises
+% and some shorthands (ugh)
+
+%{
+
+PROPERTIES
+
+name                   value   effect                  shorthand
+
+[Voice]
+ydirection             -1      force stem down         \stemdown
+ydirection             0       stem direction free     \stemboth
+ydirection             1       force stem up           \stemup
+
+[Score?]
+beamslopedamping       0       no damping              \beamslopeproportional  
+beamslopedamping       1       damping1)               \beamslopedamped
+beamslopedamping       100000  zero slope              \beamslopezero
+
+[Score?]
+beamquantisation       0       no quantisations        \beamposfree
+beamquantisation       1       quantise pos and slope  \beamposnormal
+beamquantisation       2       quantise avoide wedge2) \beampostraditional
+
+
+[Staff?]
+instrument             ascii   midi instrument table lookup
+
+
+1) after beam slope damping table suggested in [Wanske]
+2) [Wanske] as well as [Ross] suggests that beams sloped upward must not 
+   start sitting on a staffline, and beams sloped downward must not hang 
+   from a staffline (similar for beam-ends).  This would create a wedge
+   that is traditionally being avoided because it could easily be filled-up 
+   with ink.
+   However, avoiding these wedges restricts the freedom of beams quite a lot 
+   while they don't seem to be a problem in modern printing.
+   In no piece of sheetmusic engraved after 1953 (Baerenreiter) i've seen 
+   these wedges being avoided.
+
+%}
+
+%hmm, (these) abbrevs suck, imo
+% i guess they're meant as some form of doco
+% that's what i use them for...
+% should compile a list with recognised properties!
+stemup = {
+       \skip 1*0;
+       % Stupid hack to make < { \stemup } > work
+       \property Voice.ydirection = \up 
+       }
+stemboth= {
+       \skip 1*0;
+       \property Voice.ydirection = \center
+}
+stemdown = {   
+       \skip 1*0;
+       \property Voice.ydirection = \down
+}
+
+% ugh, cluttering global namespace...
+none=0
+free=0
+normal=1
+traditional=2
+infinity=10000
+
+beamslopeproportional = {
+       \property Score.beamslopedamping = \none
+}
+
+beamslopedamped = {
+       \property Score.beamslopedamping = \normal
+}
+
+beamslopezero = {
+       \property Score.beamslopedamping = \infinity
+}
+
+% this sucks, you'd want to pass an array, at least
+% (or embedded code: you still can't dictate the slope / stemlength)
+beamposfree = {
+       \property Score.beamquantisation = \none
+}
+
+beamposnormal = {
+       \property Score.beamquantisation = \normal
+}
+
+beampostraditional = {
+       \property Score.beamquantisation = \traditional
+}
+
index 3ccbb82b2e9c6a6f12afa9d481d25ea4195bdd30..8db8016258fda467ded4ca4a73939e512263b868 100644 (file)
@@ -51,4 +51,6 @@ rftoe = \script { "ftoe" 0 0 1 0 0 }
 back = \script { "back" 0 -1 -1  0 0 }
 front = \script { "front" 0 -1 1 0 0 }
 
-trill =\script { "trill" 0 0 1 0 0 }
+trill =\script { "trill" 0 0 1 0 
+       2000   % be above text. 
+}
index 7015bf914ab727881a478bc636d314d9f1a9b82c..6742e056301caef27b0fd2db93aad31ce47d68bf 100644 (file)
@@ -51,12 +51,12 @@ table_twenty =
        "empty" "\emptybar"
        ""      ""                      0.0\pt  0.0\pt  0.0\pt  16.0\pt
        "|"     "\maatstreep{%}"        0.0\pt  0.64\pt         0.0\pt  20.0\pt
-       "||"    "\doublebar{%}"         0.0\pt  4.0\pt  0.0\pt  20.0\pt
-       "|."    "\finishbar{%}"         0.0\pt  2.0\pt  0.0\pt  20.0\pt
+       "||"    "\doublebar{%}"         0.0\pt  5.0\pt  0.0\pt  20.0\pt
+       "|."    "\finishbar{%}"         -5.0\pt 0.0\pt  0.0\pt  20.0\pt
        ".|"    "\startbar{%}"          0.0\pt  4.0\pt  0.0\pt  20.0\pt
-       ":|"    "\repeatbar"            -8.0\pt 0.0\pt  0.0\pt  20.0\pt
-       "|:"    "\startrepeat"          0.0\pt  8.0\pt  0.0\pt  20.0\pt
-       ":|:"   "\repeatbarstartrepeat" 0.0\pt  16.0\pt 0.0\pt  20.0\pt
+       ":|"    "\repeatbar"            -10.0\pt        0.0\pt  0.0\pt  20.0\pt
+       "|:"    "\startrepeat"          0.0\pt  10.0\pt 0.0\pt  20.0\pt
+       ":|:"   "\repeatbarstartrepeat" 0.0\pt 20.0\pt  0.0\pt  20.0\pt
     }
 
     "meters" = \table {
index 6e897a84751b40a90d1eb9126ecb570ed02b37ca..64db731f8ee575d73c0a10fda9e7a97071396c07 100644 (file)
@@ -10,7 +10,7 @@ TestedFeatures =       "beams and beamflags";
 \version "0.1.7";
 
 \score{
-       \melodic \multi 3 < 
+       \melodic \multi 3 < 
                { \octave c'; 
                        \meter 8/4;
                        \duration8;
@@ -23,6 +23,7 @@ TestedFeatures =       "beams and beamflags";
                        \stemup [c c'' a' f']
                        \duration128;
                        \stemup [c c'' a' f']
+                       r32
 
                        \duration 8;
                        \stemup ['g 'g 'g 'g]
@@ -34,9 +35,10 @@ TestedFeatures =      "beams and beamflags";
                        \stemup ['g 'g 'g 'g]
                        \duration 128;
                        \stemup ['g 'g 'g 'g]
+                       r32
                }
        
-       { \octave c'; 
+       { \octave c';  
                        \meter 8/4;
                        \duration8;
                        \stemdown [a' 'a c e]
@@ -48,6 +50,7 @@ TestedFeatures =       "beams and beamflags";
                        \stemdown [a' 'a c e]
                        \duration128;
                        \stemdown [a' 'a c e]
+                       r32
 
                        \octave c;
                        \duration 8;
@@ -60,7 +63,34 @@ TestedFeatures =      "beams and beamflags";
                        \stemdown [d'' d'' d'' d'']
                        \duration 128;
                        \stemdown [d'' d'' d'' d'']
+                       r32
+
+               } >
+               
+               {\duration "last";
+                       % ugh, "duration mode"
+                       
+                       [g8 g] [a a] [b b] [c' c']
+                       
+                       [g16 g ] [a a] [b b] [c' c']
+                       [g32 g] [a a] [b b] [c' c']
+                       
+                       [g64 g ] [c' c' ]
+               }
+               {
+                       \transpose d {
+                       \octave c''';
+                       | [g8 g] [a a] [b b] [c' c']
+                       [g16 g ] [a a] [b b] [c' c']
+                       [g32 g] [a a] [b b] [c' c']
+                       [g64 g]
+                       [c' c']
+                       }
                }
-       >}
+       }
+       \paper{
+               gourlay_maxmeasures = 1.;
+       }
+}
 
 
index 861ec2d936c88b6e54f9c026b7163204957de7e2..cf6c5ad39db9eedf0a24700a54f57b339941fc62 100644 (file)
@@ -81,6 +81,7 @@ restsII = \melodic {
        \two_voice_steminvert 
        \three_voice  
        \rests 
+       % UGH ! bug!
        %\restsII 
        }
        
index 1ba29f30b2a30445e049af14a930f42090065e01..f1f1e8a00690a94f8bf0e4a716d6e2c2307bb5c2 100644 (file)
@@ -1,10 +1,10 @@
 \header{
-title= "The Feta font";
+title= "The Feta Font";
 subtitle = "proofsheet"; 
-enteredby =     "jcn";
+enteredby =     "jcn & hwn";
 copyright =     "public domain";
-TestedFeatures =        "This file tests the Feta music-font"
-        "(Feta definitively is not an abbreviation of Font-En-TjA)";
+description = "This file tests the Feta music font";
+% "(Feta definitively is not an abbreviation of Font-En-TjA)";
 }
 
 \version "0.1.7";
index a0c2192c45389a7170d9790bf242dcff3eb0ccc0..c83989e8e0762b0de4350df550011b4a06476773 100644 (file)
@@ -1,7 +1,16 @@
+%       "This file is a stub to fool make-website"
+
 \header{
-TestedFeatures =        "This file is a stub to fool make-website"
-       "this will display the 20pt version of the proofsheet";
+title= "The Feta font";
+subtitle = "proofsheet"; 
+enteredby =     "jcn";
+copyright =     "public domain";
+description = "This file tests the Feta music-font";
+TestedFeatures =        
+        "(Feta definitively is not an abbreviation of Font-En-TjA)";
 }
 
 
 
+
+
index 897770ad637aa3ff6e47ea99170f2d59857f323c..8b6ecb031a5104e708c7d95890df04296d1de92e 100644 (file)
@@ -61,20 +61,21 @@ yanother =
        Score = \translator {
        \type Score_engraver;
 
-       \consists "Bar_align_engraver";
-       \consists "Clef_align_engraver";
-       \consists "Key_align_engraver";
-       \consists "Meter_align_engraver";
-       \consists "Score_horizontal_align_engraver";
-       \consists "Vertical_align_engraver";
+       %\consists "Timing_engraver";
+       %\consists "Bar_column_engraver";
+       %\consists "Bar_number_engraver";
+
        \consists "Span_score_bar_engraver";
+       \consists "Score_priority_engraver";
+       \consists "Priority_horizontal_align_engraver";
+       \consists "Vertical_align_engraver";
 
 
        \accepts "Staff_group";
        \accepts "Staff";
        \accepts "Lyrics";
        \accepts "Grandstaff";
-       }
+}
 
        %% add Timing_engraver to the staff
        Staff = \translator {
index 889c56e12454630cb0f6949b08187bfa5afd51de..febd0720e60f75d64a8de632a845be94f957cc9b 100644 (file)
@@ -28,6 +28,7 @@ copyright =    "public domain";
 %              % because piece is set very tightly
 
 IImenuetto = \melodic{
+       \property Voice.beamslopedamping = \infinity
        \clef"alto";
        \property Staff.instrument = cello
        \meter 3/4;
@@ -39,13 +40,15 @@ IImenuetto = \melodic{
 %%2
        \textstyle "finger";            % ugh.
        
-       < [ bes8^"1" e8 c8_"2"_"4" >
-               a8 bes8-. g8-. ] a4-.^"4" |
+       < [ bes8^"1"( e8 c8_"2"_"4" >
+               )a8 bes8-. g8-. ] a4-.^"4" |
 
 %%3
+       \property Voice.beamslopedamping = \normal
        < d4 'bes4-. > g4-. [ f8-. e8-. ] |
+       \property Voice.beamslopedamping = \infinity
 %%4
-       < [ f8 'a > e8 d8 cis8-. 'b8-. 'a8-. ]
+       < [ f8( 'a > e8 )d8 cis8-. 'b8-. 'a8-. ]
 %%5
        < a2 f2 d2 > bes!4-. |
 %%6
@@ -61,16 +64,21 @@ IImenuetto = \melodic{
 %%9
        \clef "violin";
        < e'2 a2 \f >
+       \property Voice.beamslopedamping = \normal
        [ d'8( e'16 )f'16 ] |
+       \property Voice.beamslopedamping = \infinity
 %%10
-       < [ e'8 g8 > d' cis'_"2" e' a ()  g8 ] |
+       < [ e'8( g8 > d' cis'_"2" )e' a ()  g8 ] |
 %%11
        \multi 2 <  
                {\stemup a4()  d'4 cis'4-. }
                { \stemdown f2 e4 } > |
        \stemboth
 %%12
-       < [ g'8^"4" d8 > f' e' f' d'^"3"()   c' ] |
+       % oeps: slur gets attached at d8 iso g'8!
+%      < [ g'8^"4"( d8 > f' e' )f' d'^"3"()   c' ] |
+       % wrong still...
+       < { [ g'8^"4"( f' e' )f' d'^"3"()   c' ] } { [ d8 ] } > |
 %%13
        \clef "alto";
        \multi 2 <
@@ -85,9 +93,9 @@ IImenuetto = \melodic{
 %%16
        [ f( e8 )f a8-. g8-. bes8-. ] |
 %%17
-       < a2^"0" fis2_"3" > bes4 |
+       < a2^"0"^\trill fis2_"3" > bes4 |
 %%18
-       < { [ c'8 ()  bes8 c' a8 ] } es8 > fis4 |
+       < { [ c'8 ()  bes8 c' a8 ] } es8 > fis4^\trill |
 %%19
        < d'4-\downbow g4 'bes4 > < c'4-\upbow g4 c4 > < [ bes8 d8 > a8 ] |
 %%20
@@ -101,7 +109,9 @@ IImenuetto = \melodic{
 %%22
        < { [ g8 ()  f8 g8 e8 ] }  cis8  > < f4 d4 > |
 %%23
-       [ 'g8 g8 ] < e4. 'a4. > d8-\upbow |
+       \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."> 
diff --git a/input/spacing.ly b/input/spacing.ly
new file mode 100644 (file)
index 0000000..10bb206
--- /dev/null
@@ -0,0 +1,70 @@
+\header{
+title= "Spacing";
+subtitle = "proofsheet"; 
+enteredby =     "jcn";
+copyright =     "public domain";
+TestedFeatures =        "This file tests various spacings";
+}
+
+\version "0.1.7";
+
+multipart = \melodic{ 
+    \multi 3 < 
+                { 
+                   c4
+                   c 
+                   c c 
+                }
+                { 
+                   [c8 c] 
+                   [c c] 
+                   [c c] [c c] 
+                }
+                { 
+                   [2/3 c8 c c]1/1 
+                   [2/3 c c c]1/1 
+                   [2/3c c c]1/1 [2/3c c c]1/1 
+                }
+                { 
+                   [2/4 c8 c c c]1/1
+                   [2/4 c c c c]1/1 
+                   [2/4c c c c]1/1 [2/4c c c c]1/1 
+                }
+                { 
+                   [2/5 c8 c c c c]1/1 
+                   [2/5 c c c c c]1/1 
+                   [2/5c c c c c]1/1 [2/5c c c c c]1/1 
+                }
+                { 
+                   [2/6c8 c c c c c]1/1 
+                   [2/6c  c c c c c]1/1 
+                   [2/6c c c c c c]1/1 [2/6c c c c c c]1/1 
+                }
+                { 
+                   [2/7c8 c c c c c c]1/1 
+                   [2/7c c  c c c c c]1/1 
+                   [2/7c c c c c c c]1/1 [2/7c c c c c c c]1/1 
+                }
+            >
+       }
+
+singlepart = \melodic{ 
+       c4 d e f
+       c4 d e [f8 f]
+       c4 d e f8 [f16 f]
+       c4 d e f8 f16 [f32 f]
+       c4 d e f8 f16 f32 [f64 f]
+       c4 c4 c4 c4
+       
+    }
+    
+    \score{
+    \melodic { 
+       \singlepart 
+       \multipart 
+    }
+    \paper {
+%    linewidth= 18.\cm;
+%      gourlay_maxmeasures = 4.0
+    }
+}
index 412c202ca24286e1f2e891fd49fb5e958e7e04a4..d8966dfbde1151f3b12ecf82cbcc1bf008d6b074 100644 (file)
@@ -5,6 +5,7 @@ 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";
 } 
 
index cb13ab64d66dc0ad5f741fa95f9e959a19495101..ba4a3a043a6f1bbc0808e710764a0e75995f8c3a 100644 (file)
@@ -6,6 +6,7 @@ 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.7";
 
index f7af3f51510426c9064cf6536950fa14cfef4d19..9d0f09b67d7ba0dd13dcbb9218240c4a0adb3183 100644 (file)
@@ -3,7 +3,7 @@
 
 %
 % UGH UGH
-\advance\oddsidemargin-25mm
+\advance\oddsidemargin-30mm
 \evensidemargin\oddsidemargin
 \advance\textwidth30mm
 \addtolength{\textheight}{20mm}
index b2a00d2996c8a510bef14d87b319a49359ed0daa..739d06d3bee98a90e33673cc1630e6067eeb55f0 100644 (file)
@@ -493,8 +493,9 @@ themusic =
        \paper{
                \paper_twenty
                % 20pt music uses whole pagewidth
-               % ja Vette Pech.  Koop maar aan A4 printer
-               linewidth= 185.\mm;
+               % ja Vette Pech.  Koop maar een A3 printer
+               % huh? [jcn]
+               linewidth= 195.\mm;
                arithmetic_multiplier = 7.\pt;
                
                gourlay_maxmeasures = 9.;
index 0d5cb37007cb783921c233b2074bc8eb281185b1..1bb3e31ba6408c28ab541f3e84555ed0ddf29323 100644 (file)
@@ -1,8 +1,8 @@
 \header{
 filename =      "toccata-fuga-E.ly";
 title =         "toccata and fuga in E-major ";
-opus =  "BWV 566"
-        "toccata               3 bar excerpt"
+opus =  "BWV 566";
+description = "toccata 3 bar excerpt, "
         "2nd fuga      transposed subject --- 4 bar excerpt";
 
 composer =      "Johann Sebastian Bach (1685-1750)";
index 3c9e2f93912d61663a763cfad681271258a47930..50a2166a0028d5e0a5b96217d782cc0602f76f6c 100644 (file)
@@ -21,7 +21,7 @@ global =
     \melodic {
          \meter 4/4;                % should be \meter C
          \keyCminor 
-        \skip 1*32;
+        \skip 1*31;
         \bar "|."; |
     }
   
index 306ca9785547dd62495d86e6c10c1e734fc257d2..111ee743e641147d2cdac8ec63846555ace3be10 100644 (file)
@@ -39,11 +39,11 @@ Binary_source_file::error_str(char const* pos_ch_c_l) const
     String pre_str((Byte const*)begin_ch_c_l, pos_ch_c_l - begin_ch_c_l);
     pre_str = String_convert::bin2hex_str(pre_str);
     for (int i = 2; i < pre_str.length_i(); i += 3)
-       pre_str = pre_str.left_str(i) + " " + pre_str.mid_str(i, INT_MAX);
+       pre_str = pre_str.left_str(i) + " " + pre_str.cut(i, INT_MAX);
     String post_str((Byte const*)pos_ch_c_l, end_ch_c_l - pos_ch_c_l);
     post_str = String_convert::bin2hex_str(post_str);
     for (int i = 2; i < post_str.length_i(); i += 3)
-       post_str = post_str.left_str(i) + " " + post_str.mid_str(i, INT_MAX);
+       post_str = post_str.left_str(i) + " " + post_str.cut(i, INT_MAX);
 
     String str = pre_str
        + String('\n')
index 8ad4784259b34517826c05af6b97ee754085dc94..66a13de2bb336ace16c86a31686dd350de105aa1 100644 (file)
@@ -111,7 +111,7 @@ Source_file::error_str(char const* pos_ch_C) const
   String str = line_str.left_str(pos_ch_C - begin_ch_C)
     + String('\n')
     + String(' ', error_col_i)
-    + line_str.mid_str(pos_ch_C - begin_ch_C, INT_MAX); // String::mid should take 0 arg..
+    + line_str.cut(pos_ch_C - begin_ch_C, INT_MAX); // String::mid should take 0 arg..
   return str;
 }
 
index 45c0a9da44c2c8267b306bbddecec81bce307990..15ba649ddb43b0684be87010433fca8c335a70ce 100644 (file)
@@ -1,4 +1,4 @@
 MAJOR_VERSION = 0
 MINOR_VERSION = 1
-PATCH_LEVEL = 38
+PATCH_LEVEL = 39
 MY_PATCH_LEVEL =
index 090cad2b19d520904d032749143cfa1147baf826..68d85f8e0e2cf695aabb980cce6c9aef338b0b7b 100644 (file)
@@ -56,28 +56,39 @@ Atom::str() const
     + dim_.y ().str () + "))";
 }
 
-String
-Atom::TeX_string() const
-{
-  String tex_str = tex_;
-  Offset off = off_;
 
+bool
+Atom::check_infinity_b ()const
+{
+  bool ridiculous = false;
+#ifndef NDEBUG
+  
   /* infinity checks. */
   for (int a = X_AXIS; a < NO_AXES; a++)
     {
       Axis ax = (Axis)a;
-      if (abs (off[ax]) >= 100 CM)
+      if (abs (off_[ax]) >= 100 CM)
        {
          warning (_("ridiculous dimension ") + axis_name_str (ax)  + ", "
-                  +print_dimen(off[ax]));
-         off[ax] = 0.0;
-         tex_str += "\errormark";
+                  +print_dimen(off_[ax]));
+         ((Atom*)this)->off_[ax] = 0.0;
+         ridiculous = true;
        }
     }
-  // whugh.. Hard coded...
+#endif
+  return ridiculous;
+}
+String
+Atom::TeX_string() const
+{
+  String tex_str = tex_;
+  if (check_infinity_b ())
+    tex_str += "\errormark";
+  
+   // whugh.. Hard coded...
   String s ("\\placebox{");
-  s += print_dimen (off[Y_AXIS])+"}{";
-  s += print_dimen (off[X_AXIS]) + "}{";
+  s += print_dimen (off_[Y_AXIS])+"}{";
+  s += print_dimen (off_[X_AXIS]) + "}{";
   s += tex_str + "}";
   return s;
 }
@@ -86,10 +97,12 @@ void
 Atom::translate_axis (Real r, Axis a)
 {
   off_[a] += r;
+  check_infinity_b ();
 }
 
 void
 Atom::translate (Offset o)
 {
   off_ += o;
+  check_infinity_b ();
 }
index 8689e1c1fe67e4ac7dbf2a0781cf0f3f49335d71..ff8566988dafe928bcb80209d3d800c4bee22629 100644 (file)
@@ -14,7 +14,7 @@
 String
 axis_name_str (Axis a)
 {
-  return String (a + 'x');
+  return String (char(a + 'x'));
 }
 
 /*
index c86597b17ee769ee151409b8daf3734c1baa406c..2d931e150fd1a8481c41a2357ffd7fc7b56c68d9 100644 (file)
@@ -50,26 +50,37 @@ Beam_engraver::do_try_request(Request*r)
 void
 Beam_engraver::do_process_requests()
 {
-  if ( !beam_p_ && span_reqs_drul_[LEFT]) {
-    current_grouping_p_ = new Rhythmic_grouping;
-    beam_p_ = new Beam;
-    if (span_reqs_drul_[LEFT]->nplet)
-      {
-       plet_spanner_p_ = new Text_spanner();
-       Text_def *defp = new Text_def;
-       plet_spanner_p_->set_support (beam_p_);
-
-       // ugh
-       plet_spanner_p_->set_bounds (LEFT, get_staff_info ().command_pcol_l ());
+  if ( !beam_p_ && span_reqs_drul_[LEFT])
+    {
+      current_grouping_p_ = new Rhythmic_grouping;
+      beam_p_ = new Beam;
+      if (span_reqs_drul_[LEFT]->nplet)
+       {
+         plet_spanner_p_ = new Text_spanner;
+         Text_def *defp = new Text_def;
+         plet_spanner_p_->set_support (beam_p_);
        
-       defp->align_i_ = 0;
-       defp->text_str_ = span_reqs_drul_[LEFT]->nplet;
-       defp->style_str_="italic";
-       plet_spanner_p_->spec_p_  = defp;
-       announce_element (Score_elem_info(plet_spanner_p_,0));
-      }
-    announce_element (Score_elem_info (beam_p_, span_reqs_drul_[LEFT]));
-  }
+         defp->align_i_ = 0;
+         defp->text_str_ = span_reqs_drul_[LEFT]->nplet;
+         defp->style_str_="italic";
+         plet_spanner_p_->spec_p_  = defp;
+         announce_element (Score_elem_info(plet_spanner_p_,0));
+       }
+
+      Scalar prop = get_property ("beamslopedamping");
+      if (prop.isnum_b ()) 
+       {
+         beam_p_->damping_i_ = prop;
+       }
+
+      prop = get_property ("beamquantisaton");
+      if (prop.isnum_b ()) 
+       {
+         beam_p_->quantisation_ = (Beam::Quantise)(int)prop;
+       }
+     
+      announce_element (Score_elem_info (beam_p_, span_reqs_drul_[LEFT]));
+    }
 }
 
 void
index bde4ae2711ceded429fd89ffd85b4ea4fe504394..450c12db14a1e75758bf77c692e14b196574103e 100644 (file)
 
 IMPLEMENT_IS_TYPE_B1 (Beam, Spanner);
 
-const int MINIMUM_STEMLEN = 5;
+// ugh, hardcoded
+const int MINIMUM_STEMLEN[] = {
+  0, // just in case
+  5, 
+  4,
+  3,
+  2,
+  2,
+};
 
 Beam::Beam ()
 {
-  slope_f = 0;
-  left_y = 0.0;
+  slope_f_ = 0;
+  left_y_ = 0.0;
+  damping_i_ = 1;
+  quantisation_ = NORMAL;
+  multiple_i_ = 0;
 }
 
 void
 Beam::add (Stem*s)
 {
-  stems.push (s);
+  stems_.push (s);
   s->add_dependency (this);
   s->beam_l_ = this;
 
@@ -60,16 +71,16 @@ Beam::brew_molecule_p () const
 {
   Molecule *mol_p = new Molecule;
   Real inter_f = paper ()->internote_f ();
-  Real x0 = stems[0]->hpos_f ();
-  for (int j=0; j <stems.size (); j++)
+  Real x0 = stems_[0]->hpos_f ();
+  for (int j=0; j <stems_.size (); j++)
     {
-      Stem *i = stems[j];
-      Stem * prev = (j > 0)? stems[j-1] : 0;
-      Stem * next = (j < stems.size ()-1) ? stems[j+1] :0;
+      Stem *i = stems_[j];
+      Stem * prev = (j > 0)? stems_[j-1] : 0;
+      Stem * next = (j < stems_.size ()-1) ? stems_[j+1] :0;
 
       Molecule sb = stem_beams (i, next, prev);
       Real  x = i->hpos_f ()-x0;
-      sb.translate (Offset (x, (x * slope_f  + left_y)* inter_f));
+      sb.translate (Offset (x, (x * slope_f_  + left_y_)* inter_f));
       mol_p->add (sb);
     }
   mol_p->translate_axis (x0 - spanned_drul_[LEFT]->absolute_coordinate (X_AXIS), X_AXIS);
@@ -80,7 +91,7 @@ Offset
 Beam::center () const
 {
   Real w= (paper ()->note_width () + width ().length ())/2.0;
-  return Offset (w, (left_y + w* slope_f)*paper ()->internote_f ());
+  return Offset (w, (left_y_ + w* slope_f_)*paper ()->internote_f ());
 }
 
 void
@@ -94,7 +105,7 @@ void
 Beam::do_print () const
 {
 #ifndef NPRINT
-  DOUT << "slope_f " <<slope_f << "left ypos " << left_y;
+  DOUT << "slope_f_ " <<slope_f_ << "left ypos " << left_y_;
   Spanner::do_print ();
 #endif
 }
@@ -102,7 +113,7 @@ Beam::do_print () const
 void
 Beam::do_post_processing ()
 {
-  if (stems.size () < 2)
+  if (stems_.size () < 2)
     {
       warning (_ ("Beam with less than 2 stems"));
       transparent_b_ = true;
@@ -116,14 +127,14 @@ void
 Beam::do_substitute_dependent (Score_elem*o,Score_elem*n)
 {
   if (o->is_type_b (Stem::static_name ()))
-      stems.substitute ((Stem*)o->item (),  n? (Stem*) n->item ():0);
+      stems_.substitute ((Stem*)o->item (),  n? (Stem*) n->item ():0);
 }
 
 Interval
 Beam::do_width () const
 {
-  return Interval (stems[0]->hpos_f (),
-                  stems.top ()->hpos_f ());
+  return Interval (stems_[0]->hpos_f (),
+                  stems_.top ()->hpos_f ());
 }
 
 void
@@ -135,9 +146,9 @@ Beam::set_default_dir ()
   count[UP]  = count[DOWN] = 0;
   Direction d = DOWN;
   
-  for (int i=0; i <stems.size (); i++)
+  for (int i=0; i <stems_.size (); i++)
     do {
-      Stem *s = stems[i];
+      Stem *s = stems_[i];
       int current = s->dir_ 
        ? (1 + d * s->dir_)/2
        : s->get_center_distance (Direction (-d));
@@ -155,29 +166,30 @@ Beam::set_default_dir ()
       count[d] = 1;
   } while ((d *= -1) != DOWN);
   
-  /* the following relation is equal to
-          up / up_count > down / down_count
-         */
-  dir_ = (total[UP] * count[DOWN] > total[DOWN] * count[UP]) ? UP : DOWN;
+  /* 
+
+     [Ross] states that the majority of the notes dictates the
+     direction (and not the mean of "center distance")
+  */
+  dir_ = (total[UP] > total[DOWN]) ? UP : DOWN;
 
-  for (int i=0; i <stems.size (); i++)
+  for (int i=0; i <stems_.size (); i++)
     {
-      Stem *sl = stems[i];
+      Stem *sl = stems_[i];
       sl->dir_ = dir_;
     }
 }
 
 /*
   should use minimum energy formulation (cf linespacing)
-
 */
 void
 Beam::solve_slope ()
 {
   Array<Stem_info> sinfo;
-  for (int j=0; j <stems.size (); j++)
+  for (int j=0; j <stems_.size (); j++)
     {
-      Stem *i = stems[j];
+      Stem *i = stems_[j];
 
       i->set_default_extents ();
       if (i->invisible_b ())
@@ -187,11 +199,11 @@ Beam::solve_slope ()
       sinfo.push (info);
     }
   if (! sinfo.size ())
-    slope_f = left_y = 0;
+    slope_f_ = left_y_ = 0;
   else if (sinfo.size () == 1)
     {
-      slope_f = 0;
-      left_y = sinfo[0].idealy_f_;
+      slope_f_ = 0;
+      left_y_ = sinfo[0].idealy_f_;
     }
   else
     {
@@ -204,37 +216,38 @@ Beam::solve_slope ()
          l.input.push (Offset (sinfo[i].x, sinfo[i].idealy_f_));
        }
 
-      l.minimise (slope_f, left_y);
+      l.minimise (slope_f_, left_y_);
     }
 
   Real dy = 0.0;
   for (int i=0; i < sinfo.size (); i++)
     {
-      Real y = sinfo[i].x * slope_f + left_y;
+      Real y = sinfo[i].x * slope_f_ + left_y_;
       Real my = sinfo[i].miny_f_;
 
       if (my - y > dy)
        dy = my -y;
     }
-  left_y += dy;
-  left_y *= dir_;
+  left_y_ += dy;
+  left_y_ *= dir_;
 
-  slope_f *= dir_;
+  slope_f_ *= dir_;
 
   /*
-    This neat trick is by Werner Lemberg, damped = tanh (slope_f) corresponds
+    This neat trick is by Werner Lemberg, damped = tanh (slope_f_) corresponds
     with some tables in [Wanske]
     */
-  slope_f = 0.6 * tanh (slope_f);
+  if (damping_i_)
+    slope_f_ = 0.6 * tanh (slope_f_) / damping_i_;
 
   quantise_yspan ();
 
   // y-values traditionally use internote dimension: therefore slope = (y/in)/x
   // but mf and beam-lookup use PT dimension for y (as used for x-values)
   // ugh --- there goes our simplified but careful quantisation
-  Real sl = slope_f * paper ()->internote_f ();
-  paper ()->lookup_l ()->beam (sl, 20 PT);
-  slope_f = sl / paper ()->internote_f ();
+  Real sl = slope_f_ * paper ()->internote_f ();
+  paper ()->lookup_l ()->beam (sl, 20 PT, 1 PT);
+  slope_f_ = sl / paper ()->internote_f ();
 }
 
 void
@@ -242,12 +255,16 @@ Beam::quantise_yspan ()
 {
   /*
     [Ross] (simplification of)
-    Try to set slope_f complying with y-span of:
+    Try to set slope_f_ complying with y-span of:
       - zero
       - beam_thickness / 2 + staffline_thickness / 2
       - beam_thickness + staffline_thickness
     + n * interline
     */
+
+  if (!quantisation_)
+    return;
+
   Real interline_f = paper ()->interline_f ();
   Real internote_f = interline_f / 2;
   Real staffline_thickness = paper ()->rule_thickness ();
@@ -260,9 +277,9 @@ Beam::quantise_yspan ()
     beam_thickness + staffline_thickness
   };
 
-  Real xspan_f = stems.top ()->hpos_f () - stems[0]->hpos_f ();
+  Real xspan_f = stems_.top ()->hpos_f () - stems_[0]->hpos_f ();
   // y-values traditionally use internote dimension: therefore slope = (y/in)/x
-  Real yspan_f = xspan_f * abs (slope_f * internote_f);
+  Real yspan_f = xspan_f * abs (slope_f_ * internote_f);
   int yspan_i = (int)(yspan_f / interline_f);
   Real q = (yspan_f / interline_f - yspan_i) * interline_f;
   int i = 0;
@@ -281,7 +298,7 @@ Beam::quantise_yspan ()
 
   yspan_f = (Real)yspan_i * interline_f + q;
   // y-values traditionally use internote dimension: therefore slope = (y/in)/x
-  slope_f = yspan_f / xspan_f / internote_f * sign (slope_f);
+  slope_f_ = yspan_f / xspan_f / internote_f * sign (slope_f_);
 }
 
 void
@@ -292,6 +309,9 @@ Beam::quantise_left_y (Beam::Pos pos, bool extend_b)
    if extend then stems must not get shorter
    */
 
+  if (!quantisation_)
+    return;
+
   Real interline_f = paper ()->interline_f ();
   Real internote_f = interline_f / 2;
   Real staffline_thickness = paper ()->rule_thickness ();
@@ -299,11 +319,11 @@ Beam::quantise_left_y (Beam::Pos pos, bool extend_b)
 
   const int QUANTS = 6;
   Real qy[QUANTS] = {
-    -staffline_thickness,
+    0,
     beam_thickness / 2,
-    beam_thickness + staffline_thickness / 2,
+    beam_thickness,
     interline_f / 2 + beam_thickness / 2 + staffline_thickness / 2,
-    interline_f - staffline_thickness,
+    interline_f,
     interline_f + beam_thickness / 2,
   };
   /* 
@@ -322,7 +342,7 @@ Beam::quantise_left_y (Beam::Pos pos, bool extend_b)
   };
 
   // y-values traditionally use internote dimension
-  Real y = left_y * internote_f;
+  Real y = left_y_ * internote_f;
   int y_i = (int)floor(y / interline_f);
   y = (y / interline_f - y_i) * interline_f;
 
@@ -362,34 +382,37 @@ Beam::quantise_left_y (Beam::Pos pos, bool extend_b)
   Real lower_y = (qy[lower_i] + interline_f * y_i) / internote_f;
 
   if (extend_b)
-    left_y = (dir_ > 0 ? upper_y : lower_y);
+    left_y_ = (dir_ > 0 ? upper_y : lower_y);
   else
-    left_y = (upper_y - left_y < y - lower_y ? upper_y : lower_y);
+    left_y_ = (upper_y - left_y_ < y - lower_y ? upper_y : lower_y);
 }
 
 void
 Beam::set_stemlens ()
 {
-  Real x0 = stems[0]->hpos_f ();
+  Real x0 = stems_[0]->hpos_f ();
   Real dy = 0;
 
   Real interline_f = paper ()->interline_f ();
   Real internote_f = interline_f / 2;
   Real staffline_thickness = paper ()->rule_thickness ();
   Real beam_thickness = 0.48 * (interline_f - staffline_thickness);
-  Real xspan_f = stems.top ()->hpos_f () - stems[0]->hpos_f ();
+  Real interbeam_f = paper ()->interbeam_f ();
+  if (multiple_i_ > 3)
+    interbeam_f += 2.0 * staffline_thickness / 4;
+  Real xspan_f = stems_.top ()->hpos_f () - stems_[0]->hpos_f ();
   /*
    ugh, y values are in "internote" dimension
    */
-  Real yspan_f = xspan_f * abs (slope_f * internote_f);
+  Real yspan_f = xspan_f * abs (slope_f_ * internote_f);
   int yspan_i = (int)(yspan_f / interline_f);
 
   Pos left_pos = NONE;
 
-  if (yspan_f < staffline_thickness / 2)
+  if ((yspan_f < staffline_thickness / 2) || (quantisation_ == NORMAL))
     left_pos = (Pos)(STRADDLE | SIT | HANG);
   else
-    left_pos = (Pos) (sign (slope_f) > 0 ? STRADDLE | HANG 
+    left_pos = (Pos) (sign (slope_f_) > 0 ? STRADDLE | HANG 
       : SIT | STRADDLE);
 
   /* 
@@ -400,25 +423,29 @@ Beam::set_stemlens ()
   if (q < interline_f / 3 - beam_thickness / 2)
     left_pos = (Pos) (left_pos | INTER);
 
-  if (stems[0]->beams_right_i_ > 1)
-    left_pos = (Pos)(left_pos & (STRADDLE | INTER));
+  if (multiple_i_ > 1)
+    left_pos = (Pos) (dir_ > 0 ? HANG : SIT);
 
   // ugh, rounding problems!
   const Real EPSILON = interline_f / 10;
   do
     { 
-      left_y += dy * dir_;
+      left_y_ += dy * dir_;
       quantise_left_y (left_pos, dy);
       dy = 0;
-      for (int j=0; j < stems.size (); j++)
+      for (int j=0; j < stems_.size (); j++)
        {
-         Stem *s = stems[j];
+         Stem *s = stems_[j];
 
          Real x = s->hpos_f () - x0;
-         s->set_stemend (left_y + slope_f * x);
+         s->set_stemend (left_y_ + slope_f_ * x);
          Real y = s->stem_length_f ();
-         if (y < MINIMUM_STEMLEN)
-           dy = dy >? (MINIMUM_STEMLEN - y);
+         int mult = max (stems_[j]->beams_left_i_, stems_[j]->beams_right_i_);
+         if (mult > 1)
+             // dim(y) = internote
+             y -= (mult - 1) * interbeam_f / internote_f;
+         if (y < MINIMUM_STEMLEN[mult])
+           dy = dy >? (MINIMUM_STEMLEN[mult] - y);
        }
     } while (abs (dy) > EPSILON);
 }
@@ -428,16 +455,16 @@ Beam::set_grouping (Rhythmic_grouping def, Rhythmic_grouping cur)
 {
   def.OK ();
   cur.OK ();
-  assert (cur.children.size () == stems.size ());
+  assert (cur.children.size () == stems_.size ());
 
   cur.split (def);
 
   Array<int> b;
   {
     Array<int> flags;
-    for (int j=0; j <stems.size (); j++)
+    for (int j=0; j <stems_.size (); j++)
       {
-       Stem *s = stems[j];
+       Stem *s = stems_[j];
 
        int f = s->flag_i_ - 2;
        assert (f>0);
@@ -447,14 +474,15 @@ Beam::set_grouping (Rhythmic_grouping def, Rhythmic_grouping cur)
     b= cur.generate_beams (flags, fi);
     b.insert (0,0);
     b.push (0);
-    assert (stems.size () == b.size ()/2);
+    assert (stems_.size () == b.size ()/2);
   }
 
-  for (int j=0, i=0; i < b.size () && j <stems.size (); i+= 2, j++)
+  for (int j=0, i=0; i < b.size () && j <stems_.size (); i+= 2, j++)
     {
-      Stem *s = stems[j];
+      Stem *s = stems_[j];
       s->beams_left_i_ = b[i];
       s->beams_right_i_ = b[i+1];
+      multiple_i_ = multiple_i_ >? (b[i] >? b[i+1]);
     }
 }
 
@@ -466,11 +494,18 @@ Beam::stem_beams (Stem *here, Stem *next, Stem *prev) const
 {
   assert (!next || next->hpos_f () > here->hpos_f ());
   assert (!prev || prev->hpos_f () < here->hpos_f ());
-  //    Real dy=paper ()->internote_f ()*2;
-  Real dy = paper ()->interbeam_f ();
-  Real stemdx = paper ()->rule_thickness ();
-  Real sl = slope_f*paper ()->internote_f ();
-  paper ()->lookup_l ()->beam (sl, 20 PT);
+
+  Real staffline_thickness = paper ()->rule_thickness ();
+  Real interbeam_f = paper ()->interbeam_f ();
+  Real internote_f =paper ()->internote_f (); 
+  Real interline_f = 2 * internote_f;
+  Real beamheight_f = 0.48 * (interline_f - staffline_thickness);
+  if (multiple_i_ > 3)
+    interbeam_f += 2.0 * staffline_thickness / 4;
+  Real dy = interbeam_f;
+  Real stemdx = staffline_thickness;
+  Real sl = slope_f_* internote_f;
+  paper ()->lookup_l ()->beam (sl, 20 PT, 1 PT);
 
   Molecule leftbeams;
   Molecule rightbeams;
@@ -480,10 +515,10 @@ Beam::stem_beams (Stem *here, Stem *next, Stem *prev) const
     {
       int lhalfs= lhalfs = here->beams_left_i_ - prev->beams_right_i_ ;
       int lwholebeams= here->beams_left_i_ <? prev->beams_right_i_ ;
-      Real w = (here->hpos_f () - prev->hpos_f ())/4;
+      Real w = (here->hpos_f () - prev->hpos_f ())/4 <? paper ()->note_width ();;
       Atom a;
       if (lhalfs)              // generates warnings if not
-       a =  paper ()->lookup_l ()->beam (sl, w);
+       a =  paper ()->lookup_l ()->beam (sl, w, beamheight_f);
       a.translate (Offset (-w, -w * sl));
       for (int j = 0; j  < lhalfs; j++)
        {
@@ -499,8 +534,8 @@ Beam::stem_beams (Stem *here, Stem *next, Stem *prev) const
       int rwholebeams = here->beams_right_i_ <? next->beams_left_i_;
 
       Real w = next->hpos_f () - here->hpos_f ();
-      Atom a = paper ()->lookup_l ()->beam (sl, w + stemdx);
-
+      Atom a = paper ()->lookup_l ()->beam (sl, w + stemdx, beamheight_f);
+      a.translate_axis( - stemdx/2, X_AXIS);
       int j = 0;
       Real gap_f = 0;
       if (here->beam_gap_i_)
@@ -515,7 +550,7 @@ Beam::stem_beams (Stem *here, Stem *next, Stem *prev) const
          // TODO: notehead widths differ for different types
          gap_f = paper ()->note_width () / 2;
          w -= 2 * gap_f;
-         a = paper ()->lookup_l ()->beam (sl, w + stemdx);
+         a = paper ()->lookup_l ()->beam (sl, w + stemdx, beamheight_f);
        }
 
       for (; j  < rwholebeams; j++)
@@ -525,9 +560,9 @@ Beam::stem_beams (Stem *here, Stem *next, Stem *prev) const
          rightbeams.add (b);
        }
 
-      w /= 4;
+      w = w/4 <? paper ()->note_width ();
       if (rhalfs)
-       a = paper ()->lookup_l ()->beam (sl, w);
+       a = paper ()->lookup_l ()->beam (sl, w, beamheight_f);
 
       for (; j  < rwholebeams + rhalfs; j++)
        {
@@ -538,5 +573,12 @@ Beam::stem_beams (Stem *here, Stem *next, Stem *prev) const
 
     }
   leftbeams.add (rightbeams);
+
+  /*
+    Does beam quanting think  of the asymetry of beams? 
+    Refpoint is on bottom of symbol. (FIXTHAT) --hwn.
+   */
+  if (experimental_features_global_b && dir_ < 0)
+    leftbeams.translate_axis (-beamheight_f, Y_AXIS);
   return leftbeams;
 }
index 918d4c503a6c44b44768b75ee26bfa985186cdc4..1f75bba5dea4cb432b934f0bbd15b4ede98a053b 100644 (file)
@@ -13,7 +13,7 @@
 
 Bow::Bow()
 {
-  pos_i_drul_[LEFT] = pos_i_drul_[RIGHT] = 0;
+  dy_f_drul_[LEFT] = dy_f_drul_[RIGHT] = 0;
   dx_f_drul_[LEFT] = dx_f_drul_[RIGHT] = 0.0;
 }
 
@@ -21,11 +21,11 @@ Bow::Bow()
 Offset
 Bow::center() const
 {
-  int dy =  pos_i_drul_[RIGHT]-pos_i_drul_[LEFT];
+  Real dy =  dy_f_drul_[RIGHT]-dy_f_drul_[LEFT];
 
   Real w = width().length ();
 
-  return Offset (w/2,dy * paper()->internote_f ());
+  return Offset (w/2,dy );
 }
 
 
@@ -35,19 +35,20 @@ Bow::brew_molecule_p() const
   Molecule*output = new Molecule;
   Real w = width().length ();
   
-  int dy = pos_i_drul_[RIGHT] - pos_i_drul_[LEFT];
+  Real dy_f = dy_f_drul_[RIGHT] - dy_f_drul_[LEFT];
   
   Real nw_f = paper()->note_width ();
   Real nh_f = paper()->internote_f ();
   
-  w+= (dx_f_drul_[RIGHT] - dx_f_drul_[LEFT]) * nw_f ;
+  w+= (dx_f_drul_[RIGHT] - dx_f_drul_[LEFT]);
   Real round_w = w;            // slur lookup rounds the slurwidth .
   
-  Atom a = paper()->lookup_l ()->slur (dy , round_w, dir_);
+  Atom a = paper()->lookup_l ()->slur (dy_f, round_w, dir_);
 
   Real error = w-round_w;
-    a.translate (Offset ((dx_f_drul_[LEFT] + 0.5)*nw_f + error/2,
-                      pos_i_drul_[LEFT] * nh_f));
+  a.translate (Offset ((dx_f_drul_[LEFT] + 0.5*nw_f)
+                      + error/2,
+                      dy_f_drul_[LEFT]));
   output->add (a);
   return output;
 }
index 62cc881bdebe42ea1aceaa27f46329e2c6818513..a220298777d8868f21a0577ff342a512dddc01dc 100644 (file)
@@ -51,11 +51,17 @@ Col_hpositions::OK() const
 }
 
 void
-Col_hpositions::stupid_solution()
+Col_hpositions::set_stupid_solution(Vector v)
 {
   energy_f_ = infinity_f;
   ugh_b_ = true;
-  config = spacer_l_->default_solution();
+  config = v;
+}
+
+void
+Col_hpositions::stupid_solution()
+{
+  set_stupid_solution (spacer_l_->default_solution());
 }
 
 void
index ffe6648c531067a18b47ac658642fea48965e2c8..22920506ec5759aaf4d231c4736e616ee05dc13b 100644 (file)
 #include "lookup.hh"
 #include "paper-def.hh"
 #include "debug.hh"
+#include "score-column.hh"
 
 Crescendo::Crescendo()
 {
   grow_dir_ =0;
-  dir_ = DOWN ;
+  dir_ = DOWN;
   dyn_b_drul_[LEFT] = dyn_b_drul_[RIGHT] =false;
 }
 
@@ -47,7 +48,16 @@ Crescendo::get_symbol() const
       w_dim = 0;
     }
 
-  return Atom (paper()->lookup_l ()->hairpin (w_dim, grow_dir_ < 0));
+  Drul_array<bool> broken;
+  Direction d = LEFT;
+  do {
+    Score_column* s = (Score_column* )spanned_drul_[d] ; // UGH
+    broken[d] = (!s->musical_b());
+  } while ((d *= -1) != LEFT);
+  
+
+  bool continued = broken[(Direction)-grow_dir_];
+  return Atom (paper()->lookup_l ()->hairpin (w_dim, grow_dir_ < 0, continued));
 }
 
 Molecule*
index 22b4cec9726bf09fa4e441a8008ed2973306ec9a..4b76e4018cff2d61b6876d5b905df74a0a5ff1e4 100644 (file)
 
 
 /// a symbol which can be translated, and freely copied
-struct Atom {
+class Atom {
+  Offset off_;
+public:
   String tex_;
   Box dim_;
-  Offset off_;
 
   String str() const;          // for printing.
   Atom (String, Box);
@@ -29,5 +30,6 @@ struct Atom {
   Box extent() const;
   void print() const;
   String TeX_string() const;
+  bool check_infinity_b () const;
 };
 #endif
index 130df73d5d41f1a8e1933f867c3d6979a08fdc92..1b9710034c06b92664e819b6c5ae6fac121ecc40 100644 (file)
 #include "directional-spanner.hh"
 #include "plist.hh"
 
-/** a beam connects multiple stems Beam adjusts the stems its owns to
-  make sure that they reach the beam and that point in the correct
-  direction */
+/** a beam connects multiple stems.
+
+  Beam adjusts the stems its owns to make sure that they reach the
+  beam and that point in the correct direction */
 class Beam:  public Directional_spanner {
 public:
   enum Pos { NONE, SIT = 1, STRADDLE = 2, HANG = 4, INTER = 8 };
+  // ugh, silly C++
+  enum Quantise { NUN, NORMAL, TRADITIONAL };
 
-  Link_array<Stem> stems;
+  Link_array<Stem> stems_;
   /// the slope of the beam in posns / point (dimension)   
-  Real slope_f;
+  Real slope_f_;
 
   /// position of leftmost end of beam  
-  Real left_y;
-   
+  Real left_y_;
+  /// should beam slope be damped? 0: no, 1: yes, 100000: horizontal beams
+  int damping_i_;
+  /// should beam pos / slope be quantised? 0: no, 1: yes, 2: traditional
+  Quantise quantisation_;
+  /// maximum number of beams (for opening-up of beam-spacing)
+  int multiple_i_;
+
 
-  /* *************** */
   DECLARE_MY_RUNTIME_TYPEINFO;
   Beam();
   void add (Stem*);
index 1ef139c60ee980d3e67c5458f78abf2c1b022273..558315674336a428f5dec869f11eb6c031c2bcd4 100644 (file)
@@ -17,9 +17,9 @@
   */
 class Bow : public Directional_spanner {
 protected:
-  Drul_array<int> pos_i_drul_;
+  Drul_array<Real> dy_f_drul_;
   Drul_array<Real> dx_f_drul_;
-    
+
   Molecule*brew_molecule_p() const;
 public:
   Bow();
index 56f70c8506672a2bc45bb966337fb1c6cc8d5bc5..3c42dd98cbdc5ed040b453df627603d9f3b3a89a 100644 (file)
 typedef Array<Paper_column*>  Line_of_cols;
 
 struct Col_hpositions {
-    Line_spacer * spacer_l_;
-    bool ugh_b_;
-    Line_of_cols error_col_l_arr_;
-    Line_of_cols cols;
-    Array<Real> config;
-    Real energy_f_;
-    bool satisfies_constraints_b_;
-
-    /* ************** */
-    void OK() const;
-    ~Col_hpositions();
-    void solve_line();
-    void approximate_solve_line();
-    /** generate a solution with no regard to idealspacings or
-      constraints.  should always work */
-    void stupid_solution();
-    Col_hpositions();
-    void add (Paper_column*c);
-    void print() const;
+  Line_spacer * spacer_l_;
+  bool ugh_b_;
+  Line_of_cols error_col_l_arr_;
+  Line_of_cols cols;
+  Array<Real> config;
+  Real energy_f_;
+  bool satisfies_constraints_b_;
+
+  /* ************** */
+  void OK() const;
+  ~Col_hpositions();
+  void solve_line();
+  void approximate_solve_line();
+  /** generate a solution with no regard to idealspacings or
+    constraints.  should always work */
+  void stupid_solution();
+  void set_stupid_solution (Vector);
+  Col_hpositions();
+  void add (Paper_column*c);
+  void print() const;
 };
 
 
index 31f496a4b428f173a36f220d537f92b425ee4e2c..39dc5ae9b05b559717da761a36864662ac904a09 100644 (file)
@@ -32,7 +32,9 @@ struct Lookup {
   Atom beam_element (int,int,Real=0) const;
 
   /// round slope to closest TeXslope
-  Atom beam (Real&,Real) const;
+  Atom beam (Real&,Real, Real) const;
+  Atom ps_beam (Real, Real, Real)const;
+  Atom tex_beam (Real&, Real) const;
 
   Atom streepje (int type) const;
 
@@ -48,13 +50,15 @@ struct Lookup {
   Atom bar (String, Real height) const;
     
   Atom dots () const;
-  Atom slur (int dy, Real &dx, Direction dir) const;
+  Atom slur (Real &dy, Real &dx, Direction dir) const;
+  Atom tex_slur (int dy, Real &dx, Direction dir) const;
+  Atom ps_slur (Real dy, Real dx, Real dir) const;
   Atom half_slur (int dy, Real &dx, Direction dir, int xpart) const;
   Atom half_slur_middlepart (Real &dx, Direction dir) const;
   Atom big_slur (int dy, Real &dx, Direction dir) const;
   Atom text (String style, String text, int align = 1) const;
   Atom script (String idx) const;
-  Atom hairpin (Real & width, bool decresc) const;
+  Atom hairpin (Real & width, bool decresc, bool continued) const;
   Atom dynamic (String) const;
 };
 
index 13f3c8fb7baa3e7616c22d843fe51a502791c60b..1a95d9d203b95a41bdb901c98088fc0a3224534d 100644 (file)
@@ -18,12 +18,13 @@ void set_default_output (String s);
 String find_file (String);
 String get_version_str();
 String get_version_number_str();
-extern Sources* source_l_g;
-extern bool only_midi;
+extern Sources* source_global_l;
+extern bool no_paper_global_b;
 extern int exit_status_i_;
 extern bool experimental_features_global_b;
 extern bool postscript_global_b;
 
-extern String default_out_fn;
-
+extern String default_outname_base_global;
+extern String default_outname_suffix_global;
+extern int default_count_global;
 #endif
index dbdcead0ffdce695fac37df00130ba8a770b7dd3..9d58a1b311ad72225dc2e289a2423555aa950328 100644 (file)
@@ -20,6 +20,7 @@
   definitions for midi output. Rather empty
  */
 class Midi_def : public Music_output_def {
+  static int default_count_i_;
 public:
   VIRTUAL_COPY_CONS(Midi_def, Music_output_def);
   DECLARE_MY_RUNTIME_TYPEINFO;
@@ -34,6 +35,7 @@ public:
   int get_tempo_i (Moment moment);
   void print() const;
   void set_tempo (Moment moment, int count_per_minute_i);
+  virtual int get_next_default_count () const;
 };
 
 #endif // MIDI_DEF_HH
index 26dacffa31f17ae9a81400246664e90fca46cebd..2c8fa3093a8b5a95255cceb2d3d2f59bab26b257 100644 (file)
@@ -37,6 +37,7 @@ public:
   void assign_translator (String, Translator*);
   String outfile_str_;
   Translator * find_translator_l (String) const;
+  virtual int get_next_default_count () const;
 };
 
 #endif // Music_output_DEF_HH
index 826918fa2f7efca4426faa24440dead24fb68e4b..162bb656e6e0ae444930321d9bf34a561a0cbfd1 100644 (file)
@@ -35,7 +35,7 @@
 class Paper_def : public Music_output_def {
   Lookup *lookup_p_;
   Dictionary<Real> *real_vars_p_;
-
+  static int default_count_i_;
 protected:
   VIRTUAL_COPY_CONS(Paper_def,Music_output_def);
 public:    
@@ -83,6 +83,7 @@ public:
   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;
 };
 
index f5a40b63da6db4c5f45c9fa79b3d4650cd359b59..7d30e4493ada5904609b0365de048fd72ec700dd 100644 (file)
@@ -56,9 +56,6 @@ class Spring_spacer : public Line_spacer {
   /// generate an (nonoptimal) solution
   Vector find_initial_solution() const;
 
-  /// check if problem is too tight
-  bool check_feasible() const;
-
   /// does #this# contain the column #w#? 
   bool contains (Paper_column const *w);
 
index c5c9cae052809a4a38cb95d6af34686c62429dd4..9a6665625aa7fcf2bf680a22f59145e7263dca39 100644 (file)
   triplets, eentweetjes, ottava, etc.  */
 class Text_spanner : public Spanner {
 public:
-    Directional_spanner * support_span_l_;
-    General_script_def * spec_p_;
-    Offset text_off_;
-    DECLARE_MY_RUNTIME_TYPEINFO;
+  Directional_spanner * support_span_l_;
+  General_script_def * spec_p_;
+  Offset text_off_;
+  DECLARE_MY_RUNTIME_TYPEINFO;
 
-    void set_support (Directional_spanner*);
-    Text_spanner();
-    Text_spanner (Text_spanner const&);
+  void set_support (Directional_spanner*);
+  Text_spanner();
+  Text_spanner (Text_spanner const&);
 protected:
-    SCORE_ELEM_CLONE(Text_spanner);
-    ~Text_spanner();
-    virtual void do_substitute_dependency (Score_elem*,Score_elem*);
-    virtual void do_pre_processing();
-    virtual void do_post_processing();
-    virtual Interval height() const ;
-    virtual Molecule* brew_molecule_p() const;
-    virtual void do_print() const;
+  SCORE_ELEM_CLONE(Text_spanner);
+  ~Text_spanner();
+  virtual void do_add_processing ();
+  virtual void do_substitute_dependency (Score_elem*,Score_elem*);
+  virtual void do_pre_processing();
+  virtual void do_post_processing();
+  virtual Interval height() const ;
+  virtual Molecule* brew_molecule_p() const;
+  virtual void do_print() const;
 };
 #endif // TEXTSPANNER_HH
 
index 840e2b31ce67212d1d01f5884cacf7b52e28ce9c..f2d6c9214e3a699ab344ff417555878fc4c1f86a 100644 (file)
@@ -132,7 +132,7 @@ ESCAPED             [nt\\'"]
        String s (YYText ()+1);
        s = s.left_str (s.length_i ()-1);
        DOUT << "#include `" << s << "\'\n";
-       new_input (s,source_l_g);
+       new_input (s,source_global_l);
        yy_pop_state ();
 }
 <incl>\"[^"]*   { // backup rule
index 319b038bad1a0d6396edc5a8e5781f700de5f247..a4dc393ec06729e51e19ef24024f711a060460b6 100644 (file)
@@ -8,7 +8,7 @@
   TODO
   This doth suck. We should have PS output, and read spacing info from TFMs
 
-  Glissando, bracket
+  Glissando, 
 
 */
 
@@ -157,7 +157,7 @@ Lookup::streepje (int type) const
 }
 
 Atom
-Lookup::hairpin (Real &wid, bool decresc) const
+Lookup::hairpin (Real &wid, bool decresc, bool continued) const
 {
   bool embedded_b = postscript_global_b;
   String embed;
@@ -167,7 +167,8 @@ Lookup::hairpin (Real &wid, bool decresc) const
       Real height = 2 PT;
       embed = "\\embeddedps{\n" ;
       embed += String (wid) + " " 
-       + String (height)
+       + String (height) + " " 
+       + String (continued ? height/2 : 0) + 
        + " draw_"  + String(decresc ? "de" : "") + "cresc}\n";
       ret.tex_ = embed;
     }
@@ -237,7 +238,7 @@ Lookup::vbrace (Real &y) const
   Interval ydims = brace.dim_[Y_AXIS];
   Real min_y = ydims[LEFT];
   Real max_y = ydims[RIGHT];
-  Real step = 2.0 PT;
+  Real step = 1.0 PT;
  
   if (y < min_y)
     {
index 897c84daaa20dca1b4ebadfe3d720d996831b4e8..4bed727ec5f7809b5b79642e53dcf969f2afb92e 100644 (file)
 #include "my-lily-parser.hh"
 
 static bool version_ignore_b = false;
-Sources* source_l_g = 0;
-bool only_midi = false;
+Sources* source_global_l = 0;
+bool no_paper_global_b = false;
+
 bool experimental_features_global_b = false;
-bool postscript_global_b = false;
+bool postscript_global_b = true;
 int exit_status_i_;
 
 void destill_inname (String &name_str_r);
@@ -37,8 +38,8 @@ Long_option_init theopts[] = {
   {0, "debug", 'd'},
   {1, "init", 'i'},
   {1, "include", 'I'},
-  {0, "midi", 'M'},
-  {0, "postscript", 'p'},
+  {0, "no-midi", 'M'},
+  {0, "no-postscript", 'P'},
   {0, "ignore-version", 'V'},
   {0,0,0}
 };
@@ -47,7 +48,7 @@ void
 usage()
 {
   cout <<
-    _("Usage: lilypond [options] [mudela-file]\n"
+    _("Usage: lilypond [options] [mudela-files]\n"
     "Typeset and or produce midi output from mudela-file or stdin\n"
     "\n"
     "Options:\n"
@@ -58,9 +59,9 @@ usage()
     "  -w, --warranty         show warranty and copyright\n"
     "  -o, --output=FILE      set FILE as default output\n"
     "  -t, --test             switch on experimental features\n"
-    "  -M, --midi             produce midi output only\n"
+    "  -M, --no-paper         produce midi output only\n"
     "  -V, --ignore-version   ignore mudela version\n"
-    "  -p, --postscript       try to use PostScript\n"
+    "  -P, --no-postscript    don't use PostScript\n"
     "\n"
     "GNU LilyPond was compiled with the following settings:\n")
 #ifdef NDEBUG
@@ -87,7 +88,7 @@ notice()
   cout <<
     _("\n"
     "GNU LilyPond -- The GNU Project music typesetter.\n"
-    "Copyright 1996,97 by\n"
+    "Copyright 1996, 97, 98 by\n"
     "  Han-Wen Nienhuys <hanwen@stack.nl>\n"
     "  Jan Nieuwenhuizen <jan@digicash.com>\n"
     "\n"
@@ -124,13 +125,22 @@ do_one_file (String init_str, String file_str)
     }
 
   Sources sources;
-  source_l_g = &sources;
-  source_l_g->set_path (&path);
+  source_global_l = &sources;
+  source_global_l->set_path (&path);
   {
-    My_lily_parser parser (source_l_g);
+    My_lily_parser parser (source_global_l);
     parser.set_version_check (version_ignore_b);
     parser.parse_file (init_str, file_str);
-
+    
+    if (file_str.length_i() && file_str[0] != '-')
+      {
+       String a,b,c,d;
+       split_path (file_str, a, b, c, d);
+       default_outname_base_global = c;
+      }
+    else
+      default_outname_base_global = "lelie";
+  
     if (parser.error_level_i_)
       {
        exit_status_i_  = 1;
@@ -139,28 +149,33 @@ do_one_file (String init_str, String file_str)
       do_scores();
     clear_scores ();
   }
-  source_l_g = 0;
+  source_global_l = 0;
+}
+
+void
+identify ()
+{
+  cout << get_version_str() << endl;
 }
 
 int
 main (int argc, char **argv)
 {
+  identify ();
   debug_init();                // should be first
 
 
   // must override (come before) "/usr/local/share/lilypond"!
-  char const * env_l=getenv ("LILYINCLUDE");
-  if (env_l)
-    {
-      path.add (env_l);
-    }
+  char const *env_sz = getenv ("LILYINCLUDE");
+  if (env_sz)
+    path.parse_path (env_sz);
+
   path.add ("");
   path.add (String (DIR_DATADIR) + "/init/");
 
   path.push (DIR_DATADIR);
 
   Getopt_long oparser (argc, argv,theopts);
-  cout << get_version_str() << endl;
   String init_str ("lily-init.ly");
 
   while (Long_option_init const * opt = oparser())
@@ -171,7 +186,7 @@ main (int argc, char **argv)
          experimental_features_global_b = true;
          break;
        case 'o':
-         set_default_output (oparser.optional_argument_ch_C_);
+         default_outname_base_global = oparser.optional_argument_ch_C_;
          break;
        case 'w':
          notice();
@@ -190,14 +205,14 @@ main (int argc, char **argv)
        case 'V':
          version_ignore_b = true;
          break;
-       case 'p':
-         postscript_global_b = true;
+       case 'P':
+         postscript_global_b = false;
          break;
        case 'd':
          set_debug (true);
          break;
        case 'M':
-         only_midi = true;
+         no_paper_global_b = true;
          break;
        default:
          assert (false);
index 1415298439c1fc7d6da9c0d4a727dee4f3d1415c..480e0a7969576ac21bd8192e81da1fe48f7f5359 100644 (file)
@@ -23,7 +23,6 @@
 
 Midi_def::Midi_def()
 {
-  outfile_str_ = ""; 
   // ugh
   set_tempo (Moment (1, 4), 60);
 }
@@ -61,12 +60,19 @@ void
 Midi_def::print() const
 {
 #ifndef NPRINT
+  Music_output_def::print ();
   DOUT << "Midi {";
   DOUT << "4/min: " << Real (60) / (whole_in_seconds_mom_ * 4);
-  DOUT << "out: " << outfile_str_;
   DOUT << "}\n";
 #endif
 }
 
 
 IMPLEMENT_IS_TYPE_B1(Midi_def, Music_output_def);
+
+int Midi_def::default_count_i_=0;
+int
+Midi_def::get_next_default_count () const
+{
+  return default_count_i_++;
+}
index 6d2cb2699a61097f4313e8e69d45c3542446a6ba..34833fb24b877381d1b89ed18bbd33c5cea0962c 100644 (file)
@@ -36,12 +36,12 @@ Midi_stream::~Midi_stream()
 Midi_stream&
 Midi_stream::operator <<(String str)
 {
-  if (check_debug && !monitor->silence("Midistrings"))
+  if (check_debug && !monitor->silent_b("Midistrings"))
     str = String_convert::bin2hex_str (str);
 
   *os_p_ << str;
 
-  if (check_debug && !monitor->silence("Midistrings"))
+  if (check_debug && !monitor->silent_b ("Midistrings"))
     *os_p_ << "\n";
 
   return *this;
@@ -52,7 +52,7 @@ Midi_stream::operator <<(Midi_item const& mitem_c_r)
 {
   //    *this << mitem_c_r.str();
   mitem_c_r.output (this);
-  if (check_debug && !monitor->silence("Midistrings"))
+  if (check_debug && !monitor->silent_b("Midistrings"))
     *os_p_ << "\n";
   return *this;
 }
index 0c93fb55ab8dac9176a6a71914e1c0d7a9641e6c..297584d539bdccd0949f0868e458ebafe827565f 100644 (file)
 #include "global-translator.hh"
 #include "dictionary-iter.hh"
 
+int
+Music_output_def::get_next_default_count () const
+{
+  return 0;
+}
+
 IMPLEMENT_IS_TYPE_B(Music_output_def);
 
 Music_output_def::Music_output_def ()
@@ -25,6 +31,7 @@ Music_output_def::~Music_output_def ()
 
 Music_output_def::Music_output_def (Music_output_def const &s)
 {
+  outfile_str_ = s.outfile_str_;
   for (Dictionary_iter<Translator*> i (s.translator_p_dict_); i.ok (); i++)
     assign_translator (i.key (), i.val ()->clone ());
 }
@@ -58,6 +65,7 @@ Music_output_def::assign_translator (String s, Translator*t)
 {
   t->type_str_ = s;
   t->output_def_l_ = this;
+  
   if (translator_p_dict_.elt_b (s))
     delete translator_p_dict_[s];
   translator_p_dict_[s] = t;
@@ -72,5 +80,6 @@ Music_output_def::print () const
       DOUT << i.key () << " = ";
       i.val ()->print ();
     }
+  DOUT << "output: " << outfile_str_;
 #endif
 }
index d24721587661cea36a26773704d7904d8b199e30..0e3dd06ce8ab1289d11ead88df9a8b878bcf40fd 100644 (file)
@@ -298,7 +298,7 @@ bool
 Span_req:: do_equal_b (Request*r) const
 {
   Span_req * s = r->span();
-  return spantype - s->spantype;
+  return spantype == s->spantype;
 }
 
 Span_req::Span_req()
index e323034c0e3b57c4538d7e5284f109a190d8428c..1c1f31860bb89e33b89f6a5d1fcfbe4a55634112 100644 (file)
@@ -57,8 +57,8 @@ My_lily_parser::set_debug()
   String s = "";
   if (init_parse_b_)
     s = "Init";
-  set_yydebug (!monitor->silence (s+"Parser") && check_debug);
-  lexer_p_->set_debug (!monitor->silence (s+"Lexer") && check_debug);
+  set_yydebug (!monitor->silent_b (s+"Parser") && check_debug);
+  lexer_p_->set_debug (!monitor->silent_b (s+"Lexer") && check_debug);
 #endif
 }
 
@@ -70,7 +70,7 @@ My_lily_parser::print_declarations()
 
   if (init_parse_b_)
     s = "Init";
-  if (!monitor->silence (s+"Declarations") && check_debug)
+  if (!monitor->silent_b (s+"Declarations") && check_debug)
     {
       lexer_p_->print_declarations (init_parse_b_);
     }
index 4ca78c5993b9cba8cc81d9c278e4c5537dd9758e..d38fb8f2c0a5151c67d448db22d8365224931272 100644 (file)
@@ -192,8 +192,15 @@ Paper_score::tex_output ()
   // output
   String outname = paper_l_->outfile_str_ ;
   if (outname.empty_b ())
-    outname = default_out_str_+ ".tex";
-
+    {
+      outname = default_outname_base_global;
+      int def = paper_l_->get_next_default_count ();
+      if (def)
+       {
+         outname += "-" + String(def);
+       }
+      outname += ".tex";
+    }
   *mlog << _("TeX output to ") <<  outname << " ...\n";
 
   Tex_stream tex_out (outname);
index 0f9ee0f4d0fdd9bd52cbc50f3d6d9dde9f303188..052f0c48d926b373a7b1510dd189bd6aafda0758 100644 (file)
@@ -38,7 +38,6 @@ Paper_def::Paper_def (Paper_def const&s)
   lookup_p_ = s.lookup_p_? new Lookup (*s.lookup_p_) : 0;
   lookup_p_->paper_l_ = this;
   real_vars_p_ = new Dictionary<Real> (*s.real_vars_p_);
-  outfile_str_ = s.outfile_str_;
 }
 
 void
@@ -143,7 +142,6 @@ Paper_def::print() const
 #ifndef NPRINT
   Music_output_def::print ();
   DOUT << "Paper {";
-  DOUT << "out: " <<outfile_str_;
   lookup_p_->print();
   for (Assoc_iter<String,Real> i (*real_vars_p_); i.ok(); i++)
     {
@@ -165,10 +163,17 @@ IMPLEMENT_IS_TYPE_B1(Paper_def, Music_output_def);
 String
 Paper_def::TeX_output_settings_str () const
 {
-  
   String s("\n ");
   s +=  lookup_p_->texsetting + "%(Tex id)\n";
   for (Assoc_iter<String,Real> i (*real_vars_p_); i.ok(); i++)
     s += String ("\\def\\mudelapaper") + i.key () + "{" + i.val () + "}\n";
   return s;
 }
+
+int Paper_def::default_count_i_ = 0;
+
+int
+Paper_def::get_next_default_count () const
+{
+  return default_count_i_ ++;
+}
index 8d05ec325dd45efa914ca5b81767110463a687f4..aaf926965fe23b07d779a40bd3239bd1a204cf3b 100644 (file)
@@ -115,8 +115,18 @@ Performance::process()
 
   String out=midi_l_->outfile_str_;
   if (out.empty_b ())
-    out = default_out_str_ + ".midi";
-
+    {
+      
+      out = default_outname_base_global;
+      int def = midi_l_->get_next_default_count ();
+      if (def)
+       {
+         out += "-" + String(def);
+       }
+
+      out += ".midi";
+    }
+  
   Midi_stream midi_stream (out);
   *mlog << _("MIDI output to ") << out<< " ..." << endl;
 
index e624ac88fec042fcea72efc91d9b8a20255c3fe4..03947306a1b6bee9cba296bf53317cf47dd9557e 100644 (file)
@@ -131,16 +131,20 @@ Score_engraver::typeset_all()
          Spanner *s = elem_p->spanner ();
          pscore_p_->typeset_unbroken_spanner (s);
 
-         /*
+
+
+                 /*
            do something sensible if spanner not 
            spanned on 2 items.
           */
          Direction d = LEFT;
          do {
            if (!s->spanned_drul_[d])
-             s->set_bounds(d, command_column_l_);
+             {
+               s->set_bounds(d, command_column_l_);
+               warning ("Unbound spanner");
+             }
          } while ((d *= -1) != LEFT);
-         
        }
       else 
        {
index 135ebf9821ec3590f69f810f35afd3653997c89e..a32773e433ff667968fcafc0d7125b97c759a1d8 100644 (file)
@@ -17,8 +17,9 @@
 #include "global-translator.hh"
 #include "header.hh"
 #include "cpu-timer.hh"
+#include "main.hh"
+#include "paper-def.hh"
 
-extern String default_out_fn;
 
 Score::Score()
 {
@@ -75,11 +76,14 @@ Score::run_translator (Music_output_def *odef_l)
        {
          w = iter->next_moment();
          DOUT << "proccing: " << w <<"\n";
-         iter->print();
+         if (!monitor->silent_b ("walking"))
+           iter->print();
        }
+      
       trans_p->modify_next (w);
       trans_p->prepare (w);
-      trans_p->print();
+      if (!monitor->silent_b ("walking"))
+       trans_p->print();
 
       iter->process_and_next (w);
       trans_p->process();
@@ -100,7 +104,6 @@ Score::run_translator (Music_output_def *odef_l)
 
 
   output->header_l_ = header_p_;
-  output->default_out_str_ = default_out_fn;
   output->origin_str_ =  location_str();
 
   *mlog << endl;
@@ -116,12 +119,16 @@ Score::process()
 
   print();
   for (int i=0; i < def_p_arr_.size (); i++)
-    run_translator (def_p_arr_[i]);
+    {
+      if (no_paper_global_b 
+         && def_p_arr_[i]->is_type_b (Paper_def::static_name ()))
+       continue;
+      run_translator (def_p_arr_[i]);
+    }
 }
 
 
 
-
 void
 Score::print() const
 {
index edb4bbec801b5668cfbfe79f6d9748cefbd4030b..a5081a25b3e17ee5db4558a330e453b4a7bb9f94 100644 (file)
 #include "parray.hh"
 
 static Link_array<Score> global_score_array;
-String default_out_fn = "lelie";
+String default_outname_suffix_global = "";
+String default_outname_base_global =  "lelie";
+int default_count_global;
+
 
 void
 do_scores()
@@ -26,6 +29,7 @@ do_scores()
       if (!is_p->header_p_)
        is_p->header_p_ = new Header;
       
+                
       is_p->header_p_->lily_id_str_ = "Lily was here, " +
        get_version_number_str();
       if (is_p->errorlevel_i_)
@@ -56,8 +60,3 @@ add_score (Score * s)
   global_score_array.push (s);
 }
 
-void
-set_default_output (String s)
-{
-  default_out_fn = s;
-}
index 2597c5e03212c409b7027e6566bc18451034e70d..c7be481d4ce4005260fa327d50bad95e77be4a67 100644 (file)
@@ -100,13 +100,13 @@ Slur::do_post_processing()
       if  (extrema[d] != spanned_drul_[d]) 
        {
          dx_f_drul_[d] = -d 
-           *(spanned_drul_[d]->width ().length ()/nw_f -0.5);
+           *(spanned_drul_[d]->width ().length () -0.5*nw_f);
        }
       else if (extrema[d]->stem_l_ && !extrema[d]->stem_l_->transparent_b_) 
-       pos_i_drul_[d] = (int)rint (extrema[d]->stem_l_->height()[dir_]/inter_f);
+       dy_f_drul_[d] = (int)rint (extrema[d]->stem_l_->height()[dir_]);
       else 
-       pos_i_drul_[d] = (int)rint (extrema[d]->head_positions_interval()[dir_]);
-      pos_i_drul_[d] += dir_;
+       dy_f_drul_[d] = (int)rint (extrema[d]->head_positions_interval()[dir_])* inter_f;
+      dy_f_drul_[d] += dir_ * inter_f;
     }
   while ((d *= -1) != LEFT);
 }
index 6ae908c2afa2f07cc489dd56f7a710463820d554..3439557f2c3de715a613f840993dbefda4447892 100644 (file)
@@ -20,7 +20,7 @@
 #include "paper-def.hh"
 #include "dimen.hh"
 #include "colhpos.hh"
-
+#include "main.hh"             // experimental_fietsers
 
 Vector
 Spring_spacer::default_solution() const
@@ -175,14 +175,8 @@ Spring_spacer::check_constraints (Vector v) const
   return true;
 }
 
-bool
-Spring_spacer::check_feasible() const
-{
-  Vector sol (try_initial_solution());
-  return check_constraints (sol);
-}
-
-/// generate a solution which obeys the min distances and fixed positions
+/// try to generate a solution which obeys the min distances and fixed
+/// positions
 Vector
 Spring_spacer::try_initial_solution() const
 {
@@ -198,10 +192,7 @@ Spring_spacer::try_initial_solution() const
            {
              Real r =initsol (i-1)  + cols[i-1].width_[RIGHT];
              if (initsol (i) < r)
-               {
-                 warning (_("overriding fixed position"));
                  initsol (i) =r;
-               }
            }
 
        }
@@ -220,14 +211,6 @@ Spring_spacer::try_initial_solution() const
 
 
 
-Vector
-Spring_spacer::find_initial_solution() const
-{
-  Vector v (try_initial_solution());
-  assert (check_constraints (v));
-  return v;
-}
-
 // generate the matrices
 void
 Spring_spacer::make_matrices (Matrix &quad, Vector &lin, Real &c) const
@@ -259,8 +242,6 @@ Spring_spacer::set_fixed_cols (Mixed_qp &qp) const
   for (int j=0; j < cols.size(); j++)
     if (cols[j].fixed())
       qp.add_fixed_var (j,cols[j].fixed_position());
-
-
 }
 
 // put the constraints into the LP problem
@@ -306,6 +287,7 @@ Spring_spacer::lower_bound_solution (Col_hpositions*positions) const
   start.fill (0.0);
   Vector solution_vec (lp.solve (start));
 
+  DOUT << "Lower bound sol: " << solution_vec;
   positions->energy_f_ = calculate_energy_f (solution_vec);
   positions->config = solution_vec;
   positions->satisfies_constraints_b_ = check_constraints (solution_vec);
@@ -314,26 +296,32 @@ Spring_spacer::lower_bound_solution (Col_hpositions*positions) const
 void
 Spring_spacer::solve (Col_hpositions*positions) const
 {
-  assert (check_feasible());
+  Vector solution_try (try_initial_solution());
+  
+  if  (check_constraints (solution_try))
+    {
+      Mixed_qp lp (cols.size());
+      make_matrices (lp.quad,lp.lin, lp.const_term);
+      make_constraints (lp);
+      set_fixed_cols (lp);
 
-  Mixed_qp lp (cols.size());
-  make_matrices (lp.quad,lp.lin, lp.const_term);
-  make_constraints (lp);
-  set_fixed_cols (lp);
-  Vector start=find_initial_solution();
-  Vector solution_vec (lp.solve (start));
+      Vector solution_vec (lp.solve (solution_try));
 
 
-  positions->satisfies_constraints_b_ = check_constraints (solution_vec);
-  if (!positions->satisfies_constraints_b_)
+      positions->satisfies_constraints_b_ = check_constraints (solution_vec);
+      if (!positions->satisfies_constraints_b_)
+       {
+         WARN << _("solution doesn't satisfy constraints.\n") ;
+       }
+      position_loose_cols (solution_vec);
+      positions->energy_f_ = calculate_energy_f (solution_vec);
+      positions->config = solution_vec;
+      positions->error_col_l_arr_ = error_pcol_l_arr();
+    }
+  else
     {
-      WARN << _("solution doesn't satisfy constraints.\n") ;
+      positions->set_stupid_solution (solution_try);
     }
-  position_loose_cols (solution_vec);
-  positions->energy_f_ = calculate_energy_f (solution_vec);
-  positions->config = solution_vec;
-  positions->error_col_l_arr_ = error_pcol_l_arr();
-
 }
 
 /**
@@ -445,8 +433,10 @@ Spring_spacer::get_ruling_durations(Array<Moment> &shortest_playing_arr,
                                    Array<Moment> &context_shortest_arr)
 {
   for (int i=0; i < cols.size(); i++)
-    scol_l (i)->preprocess();
-
+    {
+      scol_l (i)->preprocess();
+      scol_l (i)->print ();
+    }
   int start_context_i=0;
   Moment context_shortest = infinity_mom;
   context_shortest_arr.set_size(cols.size());
@@ -467,6 +457,7 @@ Spring_spacer::get_ruling_durations(Array<Moment> &shortest_playing_arr,
        {
          context_shortest = context_shortest <? scol_l(i)->durations[0];
        }
+      
       // ji was j, but triggered ICE
       for (int ji=i+1; ji --;)
        {
@@ -517,23 +508,26 @@ Spring_spacer::calc_idealspacing()
   Array<Moment> context_shortest_arr;
   get_ruling_durations(shortest_playing_arr, context_shortest_arr);
 
+  Real interline_f = paper_l ()->interline_f ();
 
   Array<Real> ideal_arr_;
   Array<Real> hooke_arr_;
-  for (int i=0; i < cols.size(); i++){
+  for (int i=0; i < cols.size() - 1; i++){
     ideal_arr_.push (-1.0);
     hooke_arr_.push (1.0);
   }
 
+  /* 
+     First do all non-musical columns
+   */
   for (int i=0; i < cols.size(); i++)
     {
-      if (!scol_l (i)->musical_b())
+      if (!scol_l (i)->musical_b() && i+1 < cols.size())
        {
          Real symbol_distance =cols[i].width_[RIGHT] + 2 PT;
          Real durational_distance = 0;
 
-         if (i+1 < cols.size())
-           {
+         
              Moment delta_t =  scol_l (i+1)->when() - scol_l (i)->when () ;
 
              Real k=  paper_l()->arithmetic_constant(context_shortest_arr[i]);
@@ -543,12 +537,16 @@ Spring_spacer::calc_idealspacing()
              if (delta_t)
                durational_distance =  paper_l()->duration_to_dist (delta_t,k);
              symbol_distance += -cols[i+1].width_[LEFT];
-           }
 
          ideal_arr_[i] = symbol_distance >? durational_distance;
-         hooke_arr_[i] = 2.0;
+         hooke_arr_[i] = 1; //2.0;
        }
     }
+
+  /* 
+     Then musicals
+     */
   for (int i=0; i < cols.size(); i++)
     {
       if (scol_l (i)->musical_b())
@@ -572,25 +570,71 @@ Spring_spacer::calc_idealspacing()
          Real dist = paper_l()->duration_to_dist (shortest_playing_len, k);
          dist *= delta_t / shortest_playing_len;
 
-         /* all sorts of ugliness to avoid running into bars/clefs, but not taking
-            extra space if this is not needed */
-         if (!scol_l (i+1)->musical_b())
+         /*
+            According to [Ross] and [Wanske], and from what i've seen:
+            
+            * whitespace at the begin of the bar should be fixed at 
+            (about) one interline.
+            [Ross]:
+            when spacing gets real tight, a smaller fixed value may be 
+            used, so that there are two discrete amounts of whitespace 
+            possible at the begin of a bar; but this is not implemented 
+            right now.
+            
+            * whitespace at the end of the bar is the normal amount of 
+            "hinterfleish" that would have been used, had there been
+            yet another note in the bar.  
+            [Ross]:
+            some editors argue that the bar line should not take any 
+            space, not to hinder the flow of music spaced around a bar 
+            line.  
+            [Ross] and [Wanske] do not suggest this, however.  Further, 
+            it introduces some spacing problems and think that it is ugly 
+            too.
+            [jcn]
+          */
+
+         /* 
+            first musical column of bar
+          */
+         if (i && scol_l (i - 1)->breakable_b_)
            {
-             Real minimum_dist =  - cols[i+1].width_[LEFT] + 2 PT + cols[i].width_[RIGHT];
-             if (ideal_arr_[i+1] + minimum_dist < dist)
-               {
-                 ideal_arr_[i] = dist - ideal_arr_[i+1];
-                 // hooke_arr_[i+1] =1.0;
-               } else {
-                 ideal_arr_[i] = minimum_dist;
-               }
-
-           } else
-             ideal_arr_[i] = dist;
+             // fixed: probably should set minimum (rod/spring)?
+             cols[i-1].width_[RIGHT] += interline_f;
+             // should adjust dist too?
+             ideal_arr_[i-1] = ideal_arr_[i-1] >? interline_f;
+           }
+
+         /* 
+            last musical column of bar
+          */
+         if (i + 1 < cols.size () && scol_l(i+1)->breakable_b_)
+           {
+             // hmm, how bout?
+             dist = dist >? interline_f;
+
+             /*
+               uhuh, this code looks fine, already?
+               someone was junking this last "hinterfleisch" whitespace?!
+
+               but this seems to be fixed now :-)
+              */
+              // set minimum rod 
+             cols[i].width_[RIGHT] += interline_f;
+           }
+
+         // ugh, do we need this?
+         if (i < cols.size () - 1 && !scol_l (i + 1)->musical_b ())
+           {
+             Real minimum = -cols[i + 1].width_[LEFT] + cols[i].width_[RIGHT]
+               + interline_f / 2;
+             dist = dist >? minimum;
+           }
+         ideal_arr_[i] = dist;
        }
     }
 
-  for (int i=0; i < ideal_arr_.size()-1; i++)
+  for (int i=0; i < ideal_arr_.size(); i++)
     {
       assert (ideal_arr_[i] >=0 && hooke_arr_[i] >=0);
       connect (i, i+1, ideal_arr_[i], hooke_arr_[i]);
index 9bdfd99f8029390698dcf58c833d425a63296a90..92e5ca0c510dcdd87d6cecdb5f916582c60f2328 100644 (file)
@@ -269,21 +269,22 @@ Stem::abbrev_mol () const
 {
   Real dy = paper ()->interbeam_f ();
   Real w = 1.5 * paper ()->lookup_l ()->ball (2).dim_.x ().length ();
-  Real beamdy = paper ()->interline_f () / 2;
+  Real interline_f = paper ()->interline_f ();
+  Real beamdy = interline_f/2;
 
   int beams_i = 0;
   Real slope_f = paper ()->internote_f () / 4;
 
   if (beam_l_) {
     // huh?
-      slope_f = 2 * beam_l_->slope_f;
+      slope_f = 2 * beam_l_->slope_f_;
     // ugh, rather calc from Abbreviation_req
       beams_i = beams_right_i_ >? beams_left_i_;
   }
-  paper ()->lookup_l ()->beam (slope_f, 20 PT);
+  paper ()->lookup_l ()->beam (slope_f, 20 PT, 1 PT);
 
   Molecule beams;
-  Atom a (paper ()->lookup_l ()->beam (slope_f, w));
+  Atom a (paper ()->lookup_l ()->beam (slope_f, w, .48 * interline_f));
   a.translate (Offset(- w / 2, stem_end_f () - (w / 2 * slope_f)));
   
   // ugh
index 4380e8911f4a0b2c1e370849fb1713d33834648e..d756461a6ff784f8e979605f3fd3de83fe9d4316 100644 (file)
@@ -19,6 +19,7 @@
 #include "debug.hh"
 #include "lookup.hh"
 #include "misc.hh"
+#include "main.hh"
 
 Atom
 Lookup::beam_element (int sidx, int widx, Real slope) const
@@ -51,8 +52,31 @@ Lookup::rule_symbol (Real height, Real width) const
   return bs;
 }
 
+Atom 
+Lookup::beam(Real &slope, Real width, Real y_thick) const
+{
+  if (postscript_global_b)
+    {
+      return ps_beam (slope, width, y_thick);
+    }
+  else
+    return tex_beam(slope, width);
+}
+
+Atom
+Lookup::ps_beam (Real  slope, Real width, Real y_thickness)const
+{
+  Atom ret;
+  String ps(String (width) + " "+ String(slope) 
+           + " " + String(y_thickness) + " draw_beam");
+  ret.tex_ = String("\\embeddedps{" + ps + "}");
+  ret.dim_[X_AXIS] = Interval(0, width);
+  ret.dim_[Y_AXIS] = Interval(0, slope * width + y_thickness);
+  return ret;
+}
+
 Atom
-Lookup::beam (Real &slope, Real width) const
+Lookup::tex_beam (Real &slope, Real width) const
 {
   const Real MAX_SLOPE = 0.6;
   const Real SLOPES = 20.0;
index cee16dbeb8c5a1df1e61baf7fd342f506c4374d3..eb140c476853b1de5e86a2d232996baef293ecfd 100644 (file)
@@ -134,50 +134,34 @@ Lookup::half_slur (int dy, Real &dx, Direction dir, int xpart) const
 }
 
 Atom
-Lookup::slur (int dy , Real &dx, Direction dir) const
+Lookup::ps_slur (Real dy , Real dx, Real dir) const
 {
-  assert (abs (dir) <= 1);
-  if  (dx < 0)
-    {
-      warning (_("Negative slur/tie length: ") + print_dimen (dx));
-      dx = 4.0 PT;
-    }
+  String ps = "\\embeddedps{\n";
+  
+  ps += String_convert::double_str (dx) + " " 
+    + String_convert::double_str (dy) + " "
+    + String_convert::double_str (dir) +
+    " draw_slur}";
+
+  String mf = "\\embeddedmf{\n";
+  mf += "input feta-sleur;\n";
+  mf += "draw_slur((0,0),";
+  mf += "(" + String_convert::double_str (dx) + "," 
+    + String_convert::double_str (dy) + "),";
+  mf += String_convert::double_str (dir) + ");\n";
+  mf += "end.\n";
+  mf += "}\n";
 
   Atom s;
-  s.dim_[X_AXIS] = Interval (0, dx);
-  s.dim_[Y_AXIS] = Interval (min (0, dy), max (0, dy));
-
-  // duh
-  // let's try the embedded stuff
-  
-  /*  bool embedded_b = experimental_features_global_b;
-      // embedded stuff still sucks for slurs
-   */
-  bool embedded_b = false;
-  String embed;
-  if (embedded_b)
-    {
-      Real fdy = dy*paper_l_->internote_f ();
-      Real fdx = dx;
-      String ps = "\\embeddedps{\n";
-      // ugh, how bout " /draw_slur { ... } def "
-      ps += String_convert::double_str (fdx) + " " 
-       + String_convert::double_str (fdy) + " "
-       + String_convert::double_str (dir) +
-       " draw_slur}";
-
-      String mf = "\\embeddedmf{\n";
-      mf += "input feta-sleur;\n";
-      mf += "draw_slur((0,0),";
-      mf += "(" + String_convert::double_str (fdx) + "," 
-       + String_convert::double_str (fdy) + "),";
-      mf += String_convert::double_str (dir) + ");\n";
-      mf += "end.\n";
-      mf += "}\n";
-
-      embed = ps + mf;
-    }
+  s.tex_ = ps + mf;
+  return s;
+}
 
+Atom
+Lookup::tex_slur (int dy , Real &dx, Direction dir) const
+{
+  assert (abs (dir) <= 1);
+  Atom s;
   Direction y_sign = (Direction) sign (dy);
 
   bool large = abs (dy) > 8;
@@ -192,11 +176,6 @@ Lookup::slur (int dy , Real &dx, Direction dir) const
   if (large)
     {
       s = big_slur (dy, dx, dir);
-      if (embedded_b)
-        {
-         s.tex_ = "\\embeddedtex{\n" + s.tex_ + "\n}\n";
-         s.tex_ += embed;
-        }
       return s;
     }
   Real orig_dx = dx;
@@ -243,12 +222,6 @@ Lookup::slur (int dy , Real &dx, Direction dir) const
   assert (idx < 256);
   f+=String ("{") + String (idx) + "}";
   s.tex_ = f;
-  if (embedded_b)
-    { 
-      s.tex_ = "\\embeddedtex{\n" + s.tex_ + "\n}\n";
-      s.tex_ += embed;
-    }
-
   s.translate_axis (dx/2, X_AXIS);
   return s;
 }
@@ -288,3 +261,30 @@ Lookup::big_slur (int dy , Real &dx, Direction dir) const
   s.dim_ = mol.extent();
   return s;
 }
+
+
+Atom
+Lookup::slur  (Real &dy_f , Real &dx, Direction dir) const
+{
+  if  (dx < 0)
+    {
+      warning (_("Negative slur/tie length: ") + print_dimen (dx));
+      dx = 4.0 PT;
+    }
+  Atom s;
+  
+  if (postscript_global_b)
+    s = ps_slur (dy_f, dx, dir);
+  else
+    {
+      Real nh =  paper_l_->internote_f ();
+      int dy_i = (int) rint(dy_f / nh);
+
+      s = tex_slur (dy_i, dx, dir);
+      dy_f = dy_i *  nh;
+    }
+  
+  s.dim_[X_AXIS] = Interval (0, dx);
+  s.dim_[Y_AXIS] = Interval (0 <? dy_f,  0 >? dy_f);
+  return s;
+}
index c23bb7e645e3ad1d40988579e6a9cca83d95a058..f100b72ae7dd8862245b7b7d47672794c4d2ff80 100644 (file)
@@ -19,11 +19,17 @@ void
 Text_spanner::set_support (Directional_spanner*d)
 {
   if (support_span_l_)
-       remove_dependency (support_span_l_);
+    remove_dependency (support_span_l_);
   
   support_span_l_ =d;
   add_dependency (d);
 }
+void
+Text_spanner::do_add_processing ()
+{
+  set_bounds (LEFT, support_span_l_->spanned_drul_[LEFT]);
+  set_bounds (RIGHT, support_span_l_->spanned_drul_[RIGHT]);
+}
 
 Text_spanner::Text_spanner()
 {
index 9418bfb997d8fe9d8f187bafe1c774f866a6ae24..a181bedde3361eca34c04eb94e19fed8fa749610 100644 (file)
@@ -61,13 +61,16 @@ void
 Tie::do_post_processing()
 {
   Real nw_f = paper()->note_width ();
+  Real space_f = paper()->interline_f ();
   assert (head_l_drul_[LEFT] || head_l_drul_[RIGHT]);
 
   Direction d = LEFT;
   do
     {
-      pos_i_drul_[d] =  (head_l_drul_[d])?
-       head_l_drul_[d]->position_i_ : head_l_drul_[(Direction)-d]->position_i_;
+      dy_f_drul_[d] =  
+       .5 *space_f * (head_l_drul_[d] 
+                      ? head_l_drul_[d]->position_i_
+                      : head_l_drul_[(Direction)-d]->position_i_);
     }
   while ((d *= -1) != LEFT);
 
@@ -75,16 +78,16 @@ Tie::do_post_processing()
     {
       if (head_l_drul_[d] && head_l_drul_[d]->extremal_i_)
        {
-         pos_i_drul_[d] += 2*dir_;
-         dx_f_drul_[d] += d * 0.25;
+         dy_f_drul_[d] += dir_ * space_f;
+         dx_f_drul_[d] += d * 0.25 * nw_f;
        }
       else if (head_l_drul_[d])
-       dx_f_drul_[d] += d*0.5;
+       dx_f_drul_[d] += d*0.5 * nw_f;
       else
        {
-         pos_i_drul_[d] = pos_i_drul_[(Direction) -d];
-         dx_f_drul_[d] = -d
-           *(spanned_drul_[d]->width ().length ()/nw_f -0.5);
+         dy_f_drul_[d] = dy_f_drul_[(Direction) -d];
+         dx_f_drul_[d] = -d *(spanned_drul_[d]->width ().length () 
+                              -0.5* nw_f);
        }
     }
   while ((d *= -1) != LEFT);
index 9493966c26913eee2040c52640cced2c4457a72b..83ed45bd66086161e08db6cef7b0dff23dacd185 100644 (file)
@@ -34,7 +34,7 @@ SUBDIRS = bin flower lib lily mf mi2mu debian\
 # list of distribution files:
 #
 SCRIPTS = configure configure.in install-sh aclocal.m4
-README_FILES = BUGS DEDICATION ANNOUNCE COPYING ONEWS NEWS README TODO \
+README_FILES = BUGS DEDICATION ANNOUNCE-0.1 ANNOUNCE  COPYING ONEWS NEWS README TODO \
        INSTALL.text AUTHORS.text
 EXTRA_DISTFILES = .dstreamrc mudela-mode.el VERSION $(README_FILES) $(SCRIPTS) $(SYMLINKS)
 
index b98fc8e244a43d66f5bc0b97fede0be68aa045a6..603ef5272d0f1f6f30ead68277dba4970897e64f 100644 (file)
@@ -9,13 +9,14 @@ Description: LilyPond is the GNU Project music typesetter.  The program
                MIDI file.  Features include multiple staffs, meters, 
                clefs, keys, lyrics, versatile input-language, 
                cadenzas, beams, slurs, triplets.
-Keywords: music notation typesetting midi
+               It includes a nice font of musical symbols.
+Keywords: music notation typesetting midi fonts
 Author: hanwen@stack.nl (Han-Wen Nienhuys)
        jan@digicash.com (Jan Nieuwenhuizen)
 Maintained-by: hanwen@stack.nl (Han-Wen Nienhuys)
 Primary-site: sunsite.unc.edu /pub/Linux/apps/sound/convert
-       460k lilypond-@TOPLEVEL_VERSION@.tar.gz 
+       470k lilypond-@TOPLEVEL_VERSION@.tar.gz 
 Original-site: pcnov095.win.tue.nl /pub/lilypond/development/
-       460k lilypond-@TOPLEVEL_VERSION@.tar.gz 
+       470k lilypond-@TOPLEVEL_VERSION@.tar.gz 
 Copying-policy: GPL
 End
index 0ac1082b1101e18ffa372c54ddef584fc3f5e085..9f9ac9b447a23baafbc65440448015ac9247afb4 100644 (file)
@@ -19,8 +19,6 @@ MIDI file.  Features include multiple staffs, meters,
 clefs, keys, lyrics, versatile input-language, 
 cadenzas, beams, slurs, triplets.
 
-[you need the musixtex fonts to use LilyPond]
-
 %prep
 %setup
 %build
diff --git a/mf/TODO b/mf/TODO
index ffeed55f4483ba0d51f897d8225b3ee9888c99f7..b1e9c59a826b8c904cbc8b911fb5e13fecc669f0 100644 (file)
--- a/mf/TODO
+++ b/mf/TODO
@@ -1,6 +1,6 @@
-
        - design macro for penstroke with rounded endings
        - design decent macro for bulbed endings
+       - printer dependencies.
        - y-refpoint for rests should be the 4th staffline (gclef: b')
        - versioning    
        - lo-res fixes.
diff --git a/mf/feta-autometric.mf b/mf/feta-autometric.mf
new file mode 100644 (file)
index 0000000..3b1b798
--- /dev/null
@@ -0,0 +1,126 @@
+% 
+% autometric.mf -- administrative MF routines
+% 
+% source file of the Feta (Font-En-Tja) pretty-but-neat music font
+% 
+% (c) 1997 Han-Wen Nienhuys <hanwen@stack.nl>
+%          Jan Nieuwenhuizen <jan@digicash.com>
+% 
+% these macros help create ascii logging output
+% to automate generation of lily tables and tex backend
+% The output should be parsed by the mf-to-table script
+
+% font or database?
+def fet_beginfont(expr name,size) =
+       font_identifier:=name&decimal size;
+       font_size size;
+       message "@{font@:"&name&"@:"&decimal size&"@}";
+       message "";
+       enddef;
+
+def fet_endfont(expr name) =
+       message "@{tnof@:"&name&"@}";
+       message "";
+       enddef;
+
+% group or table?
+def fet_begingroup(expr name) =
+       message "@{group@:"&name&"@}";
+       message "";
+       begingroup
+enddef;
+
+def fet_endgroup(expr name) =
+       endgroup;
+       message "@{puorg@:"&name&"@}";
+       message "";
+enddef;
+
+def autometric_output_char=
+       message "@{char@:"&charnamestr&"@:"&decimal charcode&"@:"&decimal charbp&"@:"&decimal charwd&"@:"&decimal chardp&"@:"&decimal charht&"@:"&idstr&"@:"&texstr&"@}";
+enddef;
+
+def hround_pixels(expr sharped) = hround(sharped * hppp) enddef;
+def vround_pixels(expr sharped) = vround(sharped * vppp) enddef;
+
+
+
+def tand(expr alpha) = 
+       (sind alpha/cosd alpha)
+       enddef;
+
+%breapth, width, depth, height
+%     breapth  x-depth
+def set_char_box(expr b_sharp, w_sharp, d_sharp,h_sharp) = 
+       save scharbp, scharht, scharwd, schardp;
+
+       % some paranoia if someone calls set_char_box(charwd, charbp, .. )
+       scharbp := b_sharp;
+       scharht := h_sharp;
+       schardp := d_sharp;
+       scharwd := w_sharp;
+
+       charbp := scharbp;
+       charht := scharht;
+       chardp := schardp;
+       charwd := scharwd;
+
+       w := hround(w_sharp *hppp);
+       b := hround(b_sharp *hppp);
+       h := hround(h_sharp *vppp);
+       d := hround(d_sharp *vppp);
+enddef;
+
+def no_dimen_beginchar(expr c) =
+       begingroup
+       charcode := if known c: byte c else: 0; fi;
+       charic := 0;
+       clearxy;
+       clearit;
+       clearpen;
+       scantokens extra_beginchar;
+enddef;
+
+code:=-1;
+
+% starts just as plain mf's beginchar:
+%     charcode, 
+% and then adds:
+%     charname see below
+%     id       index in lily's table
+%     texstr   name of tex macro in lily's table and tex backend
+
+% the dims are uninitialised; you should use set_char_box manually.
+def fet_beginchar(expr name, id_lit, texstr_lit) =
+       save texstr, idstr, charnamestr;
+       save charbp;
+       save w,b,h,d;
+       string texstr, idstr, charnamestr;
+       texstr := texstr_lit;
+       charnamestr := name;
+       idstr := id_lit;
+
+       no_dimen_beginchar(incr code) name;
+       enddef;
+
+
+def makebox_with_breapth(text r) = 
+       for y = -d, 0, h: r((-b, y),(w,y)); endfor
+       for x = -b, 0, w: r((x, -d),(x, h)); endfor
+enddef;
+
+%
+% override plain endchar.  We want a different box. 
+%
+def breapth_endchar =
+       scantokens extra_endchar;
+       if proofing > 0: makebox_with_breapth(proofrule); fi
+       chardx := 10*(w + b);
+       shipit;
+       endgroup
+enddef;
+
+def fet_endchar=
+       autometric_output_char;
+       breapth_endchar;
+       enddef;
index df625dc0c3673fda12d081825c373e086aa2f917..7acd1354710add42da09a59bbc73f34a0cdcf728 100644 (file)
@@ -39,6 +39,6 @@ endchar;
 enddef;
 
 
-for h :=  2 staffsize#  step 2 pt# until (6 * staffsize#):
+for h :=  2 staffsize#  step 1 pt# until (6 * staffsize#):
        draw_brace(h, interline# );
 endfor
index af28aa0f13a98653682a15ae9da9b313a95cea52..63ed200622d382d165cb4784fa24e4398ffd01d8 100644 (file)
@@ -112,12 +112,12 @@ flare#:=52/36pt#;    % diameter of bulbs or breadth of terminals
 mode_setup;
 font_setup;
 
-input autometric;
+input feta-autometric;
 fet_beginfont("feta-din", 10);
 
 num=-1;
 xbar:=u;
-input ital-f;
+input feta-ital-f;
 
 bar#:=17/36pt#;      % lowercase bar thickness
 slant:=.38;      % tilt ratio $(\Delta x/\Delta y)$
@@ -125,14 +125,14 @@ stem#:=58/36pt#;    % lowercase stem breadth
 font_setup;
 xbar:=.4u;
 
-input ital-f;
+input feta-ital-f;
 stem#:=54/36pt#;    % lowercase stem breadth
 hair#:=12/36pt#;    % lowercase hairline breadth
 vair#:=7/36pt#;    % vertical diameter of hairlines
 
 font_setup;
 
-input ital-p;
+input feta-ital-p;
 
 slant:=.28;      % tilt ratio $(\Delta x/\Delta y)$
 %stem#:=38/36pt#;    % lowercase stem breadth
@@ -162,10 +162,10 @@ x_height#:=135/36pt#;    % height of lowercase without ascenders
 
 font_setup;
 
-input ital-m;
-input ital-r;
-input ital-s;
-input ital-z;
+input feta-ital-m;
+input feta-ital-r;
+input feta-ital-s;
+input feta-ital-z;
 
 font_slant slant; font_x_height x_height#;
 
diff --git a/mf/feta-ital-f.mf b/mf/feta-ital-f.mf
new file mode 100644 (file)
index 0000000..70faefa
--- /dev/null
@@ -0,0 +1,39 @@
+% ital-f.mf
+% from itall.mf
+%
+% Computer Modern Italic lower case:
+% This lowercase italic alphabet was prepared by D. E. Knuth in December, 1979,
+% inspired by the Monotype faces used in {\sl The Art of Computer Programming}.
+% The programs were revised for the new \MF\ conventions in 1985.
+
+% Character codes \0141 through \0172 are generated.
+% not
+
+% cmchar "Italic letter f";
+% beginchar("f",max(1.5u#,stem#)+max(3.5u#,2flare#),asc_height#,desc_depth#);
+\"Dynamic letter f";
+beginchar(incr num,max(1.5u#,stem#)+max(3.5u#,2flare#),asc_height#,desc_depth#);
+italcorr asc_height#*slant+.75u#;
+adjust_fit(if monospace:u#,u# else: 0,0 fi); pickup fine.nib;
+numeric theta; z88=(.5w-.5u,h); z89=(.5w+.5u,-d); theta=angle(z88-z89);
+pos0(flare,0); pos1(hair,0); pos2(vair,90);
+pos3(.5[hair,stem],180); pos4(stem,theta+90);
+pos5(stem,theta-90); pos6(.5[hair,stem],0);
+pos7(vair,-90); pos8(hair,-180); pos9(flare,-180);
+rt x1r=hround(w+.25u); lft x8r=hround-.35u; x2=.6[x1,x4]; x7=.6[x8,x5];
+y9-.5flare=vround -.85d; y2-y0=y9-y7; top y2r=h+oo; bot y7r=-d-oo;
+% y4=.25[x_height,h]; y5=.5[-d,y4];
+y4=x_height-.5bar; y5=y4;
+z4=whatever[z88,z89]; z5=whatever[z88,z89];
+x3=.8[x2+x4-x88,x88]; x6=.8[x7+x5-x89,x89]; y3=.8[y4,y2]; y6=.8[y5,y7];
+bulb(2,1,0); bulb(7,8,9);  % bulbs
+filldraw stroke z2e{left}...z3e...{z89-z88}z4e;  % upper arc
+filldraw z4r--z5l--z5r--z4l--cycle;  % stem
+filldraw stroke z5e{z89-z88}...z6e...{left}z7e;  % lower arc
+pickup crisp.nib; pos20(bar,90); pos21(bar,90);
+top y20r=top y21r=x_height;
+%lft x20=lft x4r-.5stem-u; rt x21=rt x4l+.5stem+1.5u;
+lft x20=lft x4r-.5stem-xbar; rt x21=rt x4l+.5stem+1.5xbar;
+filldraw stroke z20e--z21e;  %  crossbar
+math_fit(desc_depth#*slant+u#,x_height#*slant);
+penlabels(0,1,2,3,4,5,6,7,8,9,20,21,88,89); endchar;
diff --git a/mf/feta-ital-m.mf b/mf/feta-ital-m.mf
new file mode 100644 (file)
index 0000000..5c39492
--- /dev/null
@@ -0,0 +1,36 @@
+% ital-m.mf
+% from itall.mf
+%
+% Computer Modern Italic lower case:
+% This lowercase italic alphabet was prepared by D. E. Knuth in December, 1979,
+% inspired by the Monotype faces used in {\sl The Art of Computer Programming}.
+% The programs were revised for the new \MF\ conventions in 1985.
+
+% Character codes \0141 through \0172 are generated.
+% not
+
+% cmchar "Italic letter m";
+% beginchar("m",15u#,x_height#,0);
+\"Dynamic letter m";
+% beginchar(incr num,15u#,x_height#,0);
+beginchar(incr num,12u#,x_height#,0);
+italcorr 1/3x_height#*slant+.5hair#+.5u#;
+adjust_fit(if monospace:-1.5u#,-2u# else: 0,0 fi); pickup fine.nib;
+numeric shaved_stem; shaved_stem=mfudged.stem;
+save stem; stem=shaved_stem;
+pos2(stem,0); x1=x2;
+if monospace: pos1(stem,0); lft x1l=hround(2.5u-.5stem); top y1=h;
+else: x0=0; lft x2l=hround(2.5u-.5stem);
+ hook_in(0,a,1); fi  % opening hook
+y2-.5stem=-oo; filldraw circ_stroke z2e--z1e;  % left stem
+x4+.5stem=hround(.5w+.5stem); ital_arch(2,3,4);  % left arch
+pos5(stem,0); y5=y2; x5=x4;
+filldraw circ_stroke z5e--z4e;  % middle stem
+x7+.5stem=hround(w-2.5u+.5stem);
+x8=x7-.25u; ital_arch(5,6,7);  % right arch
+if monospace: pos9(vair,90); x9=good.x .5[x8,w]; bot y9l=0; y8=1/3h;
+ pos8(stem,0); filldraw stroke z8e{-u,-x_height}...{right}z9e; % terminal
+else: x9=w; hook_out(8,b,9)(skewed); fi  % closing hook
+filldraw stroke z7e{down}..{-u,-x_height}z8e;  % right stem
+math_fit(-2/3x_height#*slant+.5hair#+.5u#,ic#);
+penlabels(0,a,1,2,3,4,5,6,7,8,9); endchar;
diff --git a/mf/feta-ital-p.mf b/mf/feta-ital-p.mf
new file mode 100644 (file)
index 0000000..c9e0cdc
--- /dev/null
@@ -0,0 +1,29 @@
+% ital-p.mf
+% from itall.mf
+%
+% Computer Modern Italic lower case:
+% This lowercase italic alphabet was prepared by D. E. Knuth in December, 1979,
+% inspired by the Monotype faces used in {\sl The Art of Computer Programming}.
+% The programs were revised for the new \MF\ conventions in 1985.
+
+% Character codes \0141 through \0172 are generated.
+% not
+
+% cmchar "Italic letter p";
+% beginchar("p",9u#,x_height#,desc_depth#);
+\"Dynamic letter p";
+beginchar(incr num,9u#,x_height#,desc_depth#);
+italcorr .7x_height#*slant+.5curve#-u# if math_fitting:-.5u# fi;
+adjust_fit(0,0); pickup fine.nib;
+x0=0; x2-.5stem=hround(2.5u-.5stem); hook_in(0,1,2);  % opening hook
+pos4(hair,-180); pos5(vair,-90); pos6(curve,0); pos7(vair,90);
+x4=x2; rt x6r=hround(w-1.5u+.5curve); x5=x7=.5[x4,x6];
+bot y5r=-oo; top y7r=h+oo; y4=y6=.5[y5,y7];
+filldraw stroke super_arc.e(4,5) & pulled_arc.e(5,6)
+ & pulled_arc.e(6,7) & super_arc.e(7,4);  % bowl
+pickup tiny.nib; pos2'(stem,0); pos3(stem,0);
+z2=z2'; x3=x2; bot y3=-d; filldraw stroke z2'e--z3e;  % stem
+dish_serif(3,2',a,1/3,.75jut,b,1/3,jut);  % serif
+math_fit(-min(2/3x_height#*slant-.5hair#-.5u#,
+ 2u#-.5stem#-desc_depth#*slant),ic#);
+penlabels(0,1,2,3,4,5,6,7); endchar;
diff --git a/mf/feta-ital-r.mf b/mf/feta-ital-r.mf
new file mode 100644 (file)
index 0000000..607774e
--- /dev/null
@@ -0,0 +1,26 @@
+% ital-r.mf
+% from itall.mf
+%
+% Computer Modern Italic lower case:
+% This lowercase italic alphabet was prepared by D. E. Knuth in December, 1979,
+% inspired by the Monotype faces used in {\sl The Art of Computer Programming}.
+% The programs were revised for the new \MF\ conventions in 1985.
+
+% Character codes \0141 through \0172 are generated.
+% not
+
+% cmchar "Italic letter r";
+% beginchar("r",5.5u#+max(1.75u#,flare#),x_height#,0);
+\"Dynamic letter r";
+beginchar(incr num,5.5u#+max(1.75u#,flare#),x_height#,0);
+italcorr x_height#*slant;
+adjust_fit(if monospace:.25u#,.5u# else: 0,0 fi); pickup fine.nib;
+x0=0; x2=x3; pos3(stem,0); lft x3l=hround(2.5u-.5stem); y3-.5stem=-oo;
+hook_in(0,1,2);  % opening hook
+filldraw circ_stroke z3e--z2e;  % left stem
+pos3'(hair,180); z3'=z3; pos4(vair,90); pos5(hair,0); pos6(flare,0);
+x4=w-.5u-max(1.75u,flare); rt x5r=hround(r-.5u); top y4r=h+oo;
+filldraw stroke z3'e{up}...z4e{right};  % link
+y6+.5flare=vround(bot y4l-.03x_height); bulb(4,5,6);  % bulb
+math_fit(-2/3x_height#*slant+.5hair#+.5u#,ic#-.5u#);
+penlabels(0,1,2,3,4,5,6); endchar;
diff --git a/mf/feta-ital-s.mf b/mf/feta-ital-s.mf
new file mode 100644 (file)
index 0000000..60af94b
--- /dev/null
@@ -0,0 +1,34 @@
+% ital-s.mf
+% from itall.mf
+%
+% Computer Modern Italic lower case:
+% This lowercase italic alphabet was prepared by D. E. Knuth in December, 1979,
+% inspired by the Monotype faces used in {\sl The Art of Computer Programming}.
+% The programs were revised for the new \MF\ conventions in 1985.
+
+% Character codes \0141 through \0172 are generated.
+% not
+
+% cmchar "Italic letter s";
+% beginchar("s",5.25u#+max(1.75u#,flare#),x_height#,0);
+\"Dynamic letter s";
+beginchar(incr num,5.25u#+max(1.75u#,flare#),x_height#,0);
+italcorr x_height#*slant-.5u#;
+adjust_fit(0,0); pickup fine.nib;
+numeric theta; theta=90-angle(40u,h); slope:=-h/40u;  % angle at middle
+pos2(vair,-90); pos0(max(fine.breadth,ess),theta); pos7(vair,-90);
+x2l=x0=x7=.5w; top y2l=h+oo; bot y7r=-oo;
+y0-.5ess=y7l+.55(y2r-y7l-ess);
+lft x3l=hround u-eps; rt x6r=hround(w-.5u)+eps;
+x3r-x3l=x6r-x6l=hround .5[vair,ess]-fine;
+ellipse_set(2l,3l,4l,0l); ellipse_set(2r,3r,4r,0r); y3=y3r;
+ellipse_set(7l,6l,5l,0l); ellipse_set(7r,6r,5r,0r); y6=y6r;
+interim superness:=more_super;
+filldraw stroke super_arc.e(2,3) & z3e{down}
+ ..z4e---z5e..z6e{down} & super_arc.e(6,7);  % main stroke
+pos1(hair,0); pos10(hround .75[hair,flare],0);
+pos2'(vair,90); z2'=z2;
+pos8(hair,-180); pos9(flare,-180);
+rt x10r=hround(w-u)+2eps; lft x9r=hround .5u-2eps; y10=.78h; y9=.25h;
+bulb(2',1,10); bulb(7,8,9);  % bulbs
+math_fit(0,ic#); penlabels(0,1,2,3,4,5,6,7,8,9,10); endchar;
diff --git a/mf/feta-ital-z.mf b/mf/feta-ital-z.mf
new file mode 100644 (file)
index 0000000..6c0f517
--- /dev/null
@@ -0,0 +1,29 @@
+% ital-z.mf
+% from itall.mf
+%
+% Computer Modern Italic lower case:
+% This lowercase italic alphabet was prepared by D. E. Knuth in December, 1979,
+% inspired by the Monotype faces used in {\sl The Art of Computer Programming}.
+% The programs were revised for the new \MF\ conventions in 1985.
+
+% Character codes \0141 through \0172 are generated.
+%not
+
+% cmchar "Italic letter z";
+% beginchar("z",5.5u#+max(1.5u#,stem#),x_height#,0);
+\"Dynamic letter z";
+beginchar(incr num,5.5u#+max(1.5u#,stem#),x_height#,0);
+italcorr x_height#*slant+.5hair#;
+adjust_fit(if monospace:.5u#,.5u# else: 0,0 fi); pickup fine.nib;
+pos1(hair,0); pos2(stem,-90); pos3(vair,-90); pos4(hair,0);
+lft x1l=hround(u-.5hair); x2=2.5u; x3=w-2u; rt x4r=hround(w-.5u);
+top y1=.78h; top y2l=top y4=h+oo; y3=.825h;
+pos5(hair,0); pos6(vair,-90); pos7(stem,-90); pos8(hair,0);
+x5=x1; x6=2.5u; x7=w-2u; x8+.5hair=hround(w+.5hair-eps);
+bot y5=bot y7r=-oo; y6=.175h; bot y8=.31h;
+pair p; p=(z4-z5) yscaled 2;
+filldraw stroke z1e{up}...z2e{right}..z3e{right}...{p}z4e;  % upper bar
+filldraw stroke z5e{p}...z6e{right}..{right}z7e...{up}z8e;  % lower bar
+filldraw stroke z5e{p}..{p}z4e;  % diagonal
+math_fit(0,1/3x_height#*slant+.5hair#+.5u#);
+penlabels(1,2,3,4,5,6,7,8); endchar;
index 3d78d804f42c2c7aab0844a6087b1ca92d1cd662..d65822695ec1212b6c617a3596cdef6efdc54a18 100644 (file)
@@ -215,7 +215,7 @@ def draw_gclef (expr exact_center, reduction)=
        
        set_char_box(
                left_space# +
-               -xpart exact_center + 1.1 * breapth_factor* reduced_il#, 
+               -xpart exact_center + 1.0 * breapth_factor* reduced_il#, 
                right_space# +
                xpart exact_center + .66 breapth_factor* reduced_il#,
                -ypart exact_center + 3 * reduced_il#,
index 141dd70dd044178d91b8c45fb6d17a9d28968e24..fca2c215cc03e6e8c0093b0c4ef7c61a1fb342ce 100644 (file)
@@ -3,7 +3,7 @@
 
 test:=0;
 
-input autometric;
+input feta-autometric;
 fet_beginfont("feta-nummer", size);
 mode_setup;
 
index cec0283fcd79dee419ce84a85a6a18b337aae973..9cc309f3fb4ddb6a16b0e572b08835720685a048 100644 (file)
@@ -372,7 +372,7 @@ fet_beginchar("Trill (`tr')","trill","trill")
        slant = .2;
 
        local_copy(transform)(currenttransform);
-       currenttransform := currenttransform slanted slant;
+       currenttransform := currenttransform slanted slant shifted (- interline, 0)  ;
 
        y1 = ascender;
        x1l = 0;
@@ -438,7 +438,7 @@ fet_beginchar("Trill (`tr')","trill","trill")
                --- z9r{up} 
                ..  z8r{left} ..  z7r{z5-z7} -- cycle;
        fill r_p;
-       set_char_box(0,2 interline#, 0,ascender#);
+       set_char_box(interline# , interline#, 0,ascender#);
 
 
        penpos11(1/4 r_fatness, -20);
index c561ed1d721ac1faad1891d0b0c15989c5dd541b..c7c8db872b5b42620c4c56a499e50de7ae344355 100644 (file)
@@ -4,7 +4,7 @@
 % font_identifier:="font-en-tja16";
 % font_size 16pt#;
 
-input autometric;
+input feta-autometric;
 fet_beginfont("feta-test", 16);
 staffsize#:=16pt#;
 test:=1;
index 4c1a4f80b7ee7babe9f3a0b6f299f8a8ba8e6db5..b70e54a4f6e536232487fde486e6c787d5b457b4 100644 (file)
@@ -4,7 +4,7 @@
 % font_identifier:="font-en-tja20";
 % font_size 20pt#;
 
-input autometric;
+input feta-autometric;
 fet_beginfont("feta-test", 20);
 staffsize#:=20pt#;
 test:=1;
index fa359d51c0864aead053e0f403258b662731521b..bcc8c41c7f47ac781f31c701a41baa027bbb8c48 100644 (file)
@@ -4,7 +4,7 @@
 % font_identifier:="font-en-tja16";
 % font_size 16pt#;
 
-input autometric;
+input feta-autometric;
 fet_beginfont("feta", 16);
 staffsize#:=16pt#;
 test:=0;
index 5364504155adcdb4a9fe66b53b73677b04447fe7..f4cbfaa95f9010a8a8cce9a27c48d9f7bb0a4000 100644 (file)
@@ -3,7 +3,7 @@
 
 staffsize#:=20pt#;
 
-input autometric;
+input feta-autometric;
 fet_beginfont("feta", 20);
 
 % AFBLIJVEN! Gebruik feta-test16/20, anders verneuk je de distributie.
index e5221769554046fdbae1a4416b2f52a10f172a0a..2f0b77f11ef54fae5ab8ff25f758f832485b32cd 100644 (file)
@@ -6,6 +6,8 @@ grep for TODO and ugh/ugr
 
 IMPORTANT
 
+       * if multiple channels per track: output each to separate voice
+
        * get rid of (last few?) midi-specifics in mudela-*
 
        * find / remove trend (tempo) of mudela columns
index 28cf48688a615a73eb416786a2d3db9ea6444efc..623fc816e04e3012e28ada446a0f6f66fabd5312 100644 (file)
@@ -135,7 +135,7 @@ main (int argc_i, char* argv_sz_a[])
            int i = str.index_i (':');
            i = (i >=0 ? i : str.length_i ());
            key.accidentals_i_ = String_convert::dec2_i (str.left_str (i));
-           key.minor_i_ = (int)(bool)String_convert::dec2_i (str.mid_str (i + 1,1));
+           key.minor_i_ = (int)(bool)String_convert::dec2_i (str.cut (i + 1,1));
            break;
          }
        case 'n':
index 73b231d168d76d9ead8f59ea1d60670d09c7cec7..ed1350645bc490a407263fa3c66cd7fba5bd63bd 100644 (file)
@@ -46,7 +46,7 @@ Mudela_stream::operator << (String str)
       if  (!i)
        i = str.length_i();
       String word = str.left_str (i);
-      str = str.mid_str (i, str.length_i());
+      str = str.cut (i, str.length_i());
       output_wrapped (word);
     }
   return *this;
index 2a6385abf4293f4b0050d19d4651555b268a4c50..ab31cb344f4df2d76e45abb21035a9828d014a95 100644 (file)
@@ -8,8 +8,10 @@
         \font\dynfont=feta-din10 scaled \magstep1
         \font\bracefont=feta-braces16
         \font\fingerfont=feta-nummer4
+        \interlinedist=4pt
 }
 \def\fettwentydefs{
+        \interlinedist=5pt
         \font\fontentja=feta20
         \font\vetfont=feta-beams20
         \font\fetanummer=feta-nummer10
@@ -18,6 +20,9 @@
         \font\fingerfont=feta-nummer5
 }
 
+\def\sixteenfonts{\fetsixteendefs\cmrsixteen}
+\def\twentyfonts{\fettwentydefs\cmrtwenty}
+
 \def\fetdef#1#2{\def#1{%
         \hbox{\fetchar{#2}}}}
 
@@ -35,9 +40,9 @@
 % oeps: \meter 12/8;
 \def\generalmeter#1#2{%
         \vbox to 0pt{\vss%
-        \hbox to0.45\balkheight{\hss\fetanummer #1\hss}%
+        \hbox to0.45\staffheight{\hss\fetanummer #1\hss}%
         \nointerlineskip%
-        \hbox to0.45\balkheight{\hss\fetanummer #2\hss}%
+        \hbox to0.45\staffheight{\hss\fetanummer #2\hss}%
         \vss}}
 
 \def\pianobrace#1{{\bracefont\char #1}}
 
 
 
-%
-% WARNING: don't leave blank lines in the PS-code; they are
-% transformed into \par 
-%
-
-
-\def\turnOnPostScript{
-\def\embeddedps##1{
-        %
-        % This sets CTM so that you get to the currentpoint
-        % by executing a 0 0 moveto
-        \special{ps: @beginspecial @setspecial ##1 @endspecial}       
-}
-\special{ps:
-/draw_decresc
-        {
-                /ht exch def
-                /wd exch def
-%
-                0 ht moveto
-                wd ht neg rlineto
-                wd neg ht neg rlineto 
-                stroke
-        }
-        def
-        /draw_cresc
-        {
-                /ht exch def
-                /wd exch def
-%
-                0 0 moveto
-                wd ht rmoveto
-                wd neg ht neg rlineto 
-                wd ht neg rlineto
-                stroke
-        }
-        def
-}
-}
-
-\def\turnOnExperimentalFeatures{
-% draw a slur in embedded postscript
-\special{ps:
-/xbow 1 3 div def
-/ybow 1 4 div def
-/thin 0.2 def
-/thick thin 5 mul def
-/draw_slur { 
-        % up or down?
-        /dir exch def
-%       
-%       for mo*tex shift
-%       exch
-%       1 copy /dx exch def
-%       exch
-%
-        % calc angle alpha
-        2 copy exch atan /alpha exch def
-        % calc len(gth)
-        2 exp exch 2 exp add sqrt /len exch def
-%
-        % add and calc z2, z3
-        len xbow mul
-        len ybow mul dir mul
-        1 xbow sub len mul
-        len ybow mul dir mul
-%       
-        % add z4, z1
-        len 0 
-        0 0
-%
-        % add and calc z5..z8 
-        8 copy
-        thin dir mul sub
-        8 2 roll
-        thin dir mul sub
-        8 2 roll
-        thick dir mul sub
-        8 2 roll
-        thick dir mul sub
-%
-        % reverse order, must be cycle
-        8 6 roll
-        6 2 roll
-        4 2 roll
-        8 6 roll
-%       
-        % set z1..z4
-        16 8 roll
-%
-        alpha rotate
-%       silly mo*tex convention
-%       dx 2 div -1 mul 0 translate
-        % draw z1..z4
-        moveto curveto
-        % draw z5..z8
-        lineto curveto
-        % cycle
-        0 0 lineto
-        fill
-} def }
-}
-
+\input lily-ps-defs
 \def\embeddedtex#1{#1}
 
 \def\embeddedmf#1{
 % dat heb je handig gedaan, lieverd!
 \nometafont
 %\nopostscript
-%\notex
+\notex
 
 \def\EndLilyPondOutput{
         \storeembedcount
diff --git a/tex/lily-ps-defs.tex b/tex/lily-ps-defs.tex
new file mode 100644 (file)
index 0000000..9b0ed42
--- /dev/null
@@ -0,0 +1,148 @@
+%
+% WARNING: don't leave blank lines in the PS-code; they are
+% transformed into \par 
+%
+
+%
+% Should put in a lily-ps.ps header?
+%
+%
+
+%
+% header info (macros/defs, etc) should go into a \special{! ... }, 
+% note the ! sign.  See dvips.info for details.
+%
+
+% Use of 
+% /foo { operatorname } bind def
+%
+% ``compiles'' operatorname binding in the body of foo, making
+% the code faster, and more reliable (less flexible)
+
+
+% transplant a TeX dimension into the PS output.
+\def\PSsetTeXdimen#1{\expandafter\special{! /#1 (\the\csname #1\endcsname) deftexdimen}}
+
+\def\turnOnPostScript{
+\def\embeddedps##1{%
+        % This sets CTM so that you get to the currentpoint
+        % by executing a 0 0 moveto
+        \special{ps: @beginspecial @setspecial ##1 @endspecial}       
+}
+
+%
+% width, slope, height 
+%
+\special{! % round cappings
+1 setlinecap
+/draw_beam
+{
+        /beam_thick exch def
+        /beam_slope exch def
+        /beam_wd exch def
+        beam_slope beam_wd mul /beam_ht exch def
+        0 0 moveto 
+        beam_wd beam_ht rlineto 
+        0 beam_thick rlineto
+        0 beam_thick  lineto
+        closepath fill
+} bind def
+% PS helper: convert (0.2pt) to the token 0.2
+/settexdimen {  /thestring exch def
+        thestring 0 thestring length 2 sub
+        getinterval
+        token
+        pop exch pop } 
+def
+%
+/deftexdimen {
+        settexdimen
+        def     
+} def
+}
+
+
+\PSsetTeXdimen{staffrulethickness}
+\PSsetTeXdimen{staffheight}
+\special{! %
+/draw_decresc
+        {
+                staffrulethickness setlinewidth
+                /cresc_cont exch def
+                /cresc_ht exch def
+                /cresc_wd exch def
+%
+                cresc_wd cresc_cont moveto
+                0 cresc_ht lineto
+                stroke
+                cresc_wd cresc_cont neg moveto
+                0 cresc_ht neg lineto
+                stroke
+        }
+        bind def
+        /draw_cresc
+        {
+                /cresc_cont exch def
+                /cresc_ht exch def
+                /cresc_wd exch def
+%
+                0 cresc_cont moveto
+                cresc_wd cresc_ht lineto
+                stroke
+                0 cresc_cont neg moveto
+                cresc_wd cresc_ht neg lineto
+                stroke
+        }
+        bind def
+ /lily_distance {
+        1 copy mul exch 1 copy mul add sqrt
+ } bind def
+ staffheight 2 div
+ /slurhtlimit exch def
+ /slurratio 0.3333 def
+ %
+ %  (b*ratio)/(1 + b / htlimit)
+ /getslurcontrol 
+ { 
+        slurhtlimit 90 div /slur_alpha exch def
+        slurratio 60 div slur_alpha div  /slur_beta  exch def
+        slur_beta mul 1 atan slur_alpha mul
+ } bind def
+ staffrulethickness 1.5 mul  /slur_thick exch def
+ /draw_slur
+ {
+        staffrulethickness setlinewidth
+        0 0 moveto
+        /slur_dir exch def
+        /slur_dy exch def
+        /slur_dx exch def
+        slur_dy slur_dx lily_distance /slur_b  exch def
+        slur_b getslurcontrol 
+        slur_dir mul /slur_ht exch def
+        slur_b getslurcontrol /slur_indent exch def       
+%
+        slur_dy slur_dx atan rotate
+        slur_indent slur_ht
+        slur_b slur_indent sub slur_ht
+        slur_b 0
+ %      pstack
+        rcurveto        
+ %
+        slur_indent neg slur_ht slur_dir slur_thick mul  sub
+        slur_indent slur_b sub slur_ht slur_dir slur_thick mul  sub
+        slur_b neg  0
+        rcurveto
+ %
+        gsave
+                fill
+        grestore
+        stroke
+ } bind def}}
+
+
+
+
+\def\turnOnExperimentalFeatures{
+% draw a slur in embedded postscript
+\special{ps:
+}}
index 3e2300989e7adbdf8084c2ff7859c24470326a7f..02116e998cb90bc0a0d2772a4abcbe7ec328a334 100644 (file)
@@ -53,7 +53,7 @@
 \newdimen\interlinedist
 \newdimen\stemthickness
 \newcount\n
-\newdimen\balkheight
+\newdimen\staffheight
 \newdimen\notewidth
 \newdimen\noteheight
 \newdimen\staffrulethickness
 % set fonts and primary dimensions
 % ugh
 \def\musixtwentydefs{
-        \balkheight=20pt
+        \staffheight=20pt
         \notewidth=7.15pt
         \noteheight=5pt
-        \musixtwentyfonts
-        \font\textmusic=cmmi12
+        \twentyfonts
         \musixcalc
 }
 
+\def\cmrtwenty{
+        \font\meterfont=cmbx15
+        \font\italicfont=cmti10
+        \font\musicmathfont=cmsy10
+        \font\normaltextfont=cmr10 %\textfont is a primitive
+        \font\smalltextfont=cmr8
+}
+\def\cmrsixteen{
+        \font\smalltextfont=cmr6
+        \font\normaltextfont=cmr8 %\textfont is a primitive
+        \font\meterfont=cmbx12
+        \font\italicfont=cmti8
+        \font\textmusic=cmmi10
+}
 \def\musixsixteendefs{
-        \balkheight=16pt
+        \staffheight=16pt
         \notewidth=5.93pt
         \noteheight=4pt
-        \musixsixteenfonts
-        \font\textmusic=cmmi10
+        \sixteenfonts
         \musixcalc
 }
 
 
 % this has to be synced with the font definition
 \def\musixcalc{
-        \interlinedist=\fontdimen5\musicfnt
         \smallspace=.3\interlinedist
-        \interstaffrule=\balkheight
+        \interstaffrule=\staffheight
         \divide\interstaffrule by 4
 
         %  [D.K.Roush & J.S.Gourlay] say this should be 0.072
 % stacked horizontal lines 
 
 \input dyndefs
+\input fetdefs
 
-\input taupindefs
+%\input taupindefs
 %\input eglerdefs
 
 
 \def\emptybar{}
 
-\def\defaultthinbar{\thinbar{\balkheight}}
-\def\defaultthickbar{\thickbar{\balkheight}}
+\def\defaultthinbar{\thinbar{\staffheight}}
+\def\defaultthickbar{\thickbar{\staffheight}}
 %? what-s wrong with rightalign?
 \def\repeatstopbar{\hss\rightalign{\repeatcolon\hskip2\smallspace\defaultthinbar\hskip\smallspace\defaultthickbar}}
 \def\repeatstartbar{\hbox{\defaultthickbar\kern\smallspace\defaultthinbar\kern2\smallspace\repeatcolon}}
-\def\repeatstopstart{\hbox{\repeatcolon\kern2\smallspace\defaultthinbar\kern\smallspace\defaultthickbar\kern\smallspace\defaultthickbar\kern\smallspace\defaultthinbar\kern2\smallspace\repeatcolon}}
+\def\repeatstopstart{\hbox{\repeatcolon\kern2\smallspace\defaultthickbar\kern\smallspace\defaultthickbar\kern2\smallspace\repeatcolon}}
 
 %compatibility
 \def\repeatbar{\repeatstopbar}
index 582c4dcd90e14844f89e0aa5d4bfd9a38ddc6f5f..a6aa7c70fb0a329e8cda9f52d4b9886814c647aa 100644 (file)
@@ -1,7 +1,5 @@
 \def\musixtwentyfonts{
-        \font\normaltextfont=cmr10 %\textfont is a primitive
-        \font\smalltextfont=cmr8
-        \font\meterfont=cmbx15
+        \font\dynfont=cmbxti10 scaled \magstep2
         \font\slurufont=xslu20
         \font\slurdfont=xsld20
         \font\slurhfont=xslz20
@@ -10,9 +8,6 @@
         \font\hslurhfont=xslhz20
         \font\musicfnt=musix20
         \font\musicdraw=musixsps
-        \font\italicfont=cmti10
-        \font\dynfont=cmbxti10 scaled \magstep2
-        \font\musicmathfont=cmsy10
         \fettwentydefs
 }
 
@@ -20,8 +15,6 @@
 \def\musixsixteenfonts{
         \font\normaltextfont=cmr8 %\textfont is a primitive
         \font\smalltextfont=cmr6
-        \font\meterfont=cmbx12
-        \font\italicfont=cmti8
         \font\slurufont=xslu16
         \font\slurdfont=xsld16
         \font\slurhfont=xslz20 % sigh
 %         \musicfnt\char\count0}}
 
 
-\input fetdefs