From 90d3ec050c58d6fa91f668dd6ca1ae8f16df20c3 Mon Sep 17 00:00:00 2001 From: Han-Wen Nienhuys Date: Wed, 9 Jul 1997 00:19:26 +0200 Subject: [PATCH] release: 0.0.74pre --- .version | 4 +- ANNOUNCE | 12 +- AUTHORS.text | 12 +- BUGS | 11 + Documentation/AUTHORS.pod | 7 +- Documentation/CodingStyle.pod | 2 +- Documentation/MANIFESTO.pod | 2 +- Documentation/gnu-music.pod | 51 ++++- Documentation/lilyliterature.pod | 242 +++++++++++----------- Documentation/other-packages.pod | 44 ++-- INSTALL.text | 10 +- NEWS | 15 +- TODO | 32 ++- bin/make_website | 3 +- flower/include/iterate.hh | 8 +- init/engraver.ini | 30 +-- init/midi.ini | 5 - init/performer.ini | 26 --- init/symbol.ini | 3 - init/table16.ini | 3 + input/cadenza.ly | 12 +- input/keys.ly | 8 +- input/pedal.ly | 4 +- input/scales.ly | 13 ++ input/scripts.ly | 14 +- lily/.version | 4 +- lily/Stable.make | 6 +- lily/beam.cc | 2 +- lily/crescendo.cc | 38 ++-- lily/engraver-group.cc | 43 ++-- lily/global-gravs.cc | 46 +++- lily/global-performers.cc | 50 ----- lily/identifier.cc | 17 +- lily/include/acceptor.hh | 41 ++++ lily/include/crescendo.hh | 2 + lily/include/engraver-group.hh | 3 +- lily/include/engraver.hh | 4 +- lily/include/global-performers.hh | 33 --- lily/include/global-translator.hh | 2 +- lily/include/identifier.hh | 8 +- lily/include/input-engraver.hh | 46 ---- lily/include/input-performer.hh | 46 ---- lily/include/input-translator.hh | 48 +++++ lily/include/lily-proto.hh | 10 +- lily/include/midi-def.hh | 17 +- lily/include/midi-walker.hh | 31 --- lily/include/music-iterator.hh | 9 +- lily/include/my-lily-parser.hh | 1 - lily/include/note-performer.hh | 24 --- lily/include/p-col.hh | 1 + lily/include/paper-def.hh | 4 +- lily/include/performer-group-performer.hh | 35 ---- lily/include/performer.hh | 29 --- lily/include/rest-column.hh | 2 +- lily/include/score-performer.hh | 25 --- lily/include/score.hh | 2 - lily/include/script.hh | 6 +- lily/include/staff-performer.hh | 22 -- lily/include/staff-side.hh | 14 +- lily/include/staff-sym-grav.hh | 3 +- lily/include/text-item.hh | 6 +- lily/include/todo-performer.hh | 0 lily/include/voice-group-performer.hh | 25 --- lily/input-engraver.cc | 111 ---------- lily/input-performer.cc | 112 ---------- lily/input-translator.cc | 132 ++++++++++++ lily/midi-def.cc | 59 +----- lily/music-iterator.cc | 91 +++++--- lily/my-lily-lexer.cc | 3 +- lily/note-performer.cc | 17 -- lily/note.cc | 2 +- lily/notehead.cc | 4 +- lily/p-col.cc | 10 +- lily/p-score.cc | 9 + lily/paper-def.cc | 17 +- lily/parser.y | 93 ++------- lily/performer-group-performer.cc | 18 -- lily/performer.cc | 48 ----- lily/rest-collision.cc | 26 +-- lily/rest-column.cc | 10 +- lily/score-grav.cc | 2 +- lily/score-performer.cc | 24 --- lily/score.cc | 32 +-- lily/script.cc | 12 +- lily/spanner-elem-group.cc | 3 + lily/spanner.cc | 4 + lily/staff-performer.cc | 25 --- lily/staff-side.cc | 22 +- lily/staff-sym-grav.cc | 5 + lily/staff-sym.cc | 3 + lily/template3.cc | 6 +- lily/template6.cc | 2 - lily/text-item.cc | 15 +- lily/voice-group-performer.cc | 12 -- make/lilypond.lsm | 6 +- make/lilypond.spec | 6 +- make/lilypond.spec.in | 2 +- 97 files changed, 847 insertions(+), 1374 deletions(-) delete mode 100644 init/midi.ini delete mode 100644 init/performer.ini delete mode 100644 lily/global-performers.cc delete mode 100644 lily/include/global-performers.hh delete mode 100644 lily/include/input-engraver.hh delete mode 100644 lily/include/input-performer.hh create mode 100644 lily/include/input-translator.hh delete mode 100644 lily/include/midi-walker.hh delete mode 100644 lily/include/note-performer.hh delete mode 100644 lily/include/performer-group-performer.hh delete mode 100644 lily/include/performer.hh delete mode 100644 lily/include/score-performer.hh delete mode 100644 lily/include/staff-performer.hh create mode 100644 lily/include/todo-performer.hh delete mode 100644 lily/include/voice-group-performer.hh delete mode 100644 lily/input-engraver.cc delete mode 100644 lily/input-performer.cc create mode 100644 lily/input-translator.cc delete mode 100644 lily/note-performer.cc delete mode 100644 lily/performer-group-performer.cc delete mode 100644 lily/performer.cc delete mode 100644 lily/score-performer.cc delete mode 100644 lily/staff-performer.cc delete mode 100644 lily/voice-group-performer.cc diff --git a/.version b/.version index e60f251d79..62907006a8 100644 --- a/.version +++ b/.version @@ -1,7 +1,7 @@ TOPLEVEL_MAJOR_VERSION = 0 TOPLEVEL_MINOR_VERSION = 0 -TOPLEVEL_PATCH_LEVEL = 73 +TOPLEVEL_PATCH_LEVEL = 74 # use to send patches, always empty for released version: # include separator: ".postfix", "-pl" makes rpm barf -TOPLEVEL_MY_PATCH_LEVEL = pre.jcn1 +TOPLEVEL_MY_PATCH_LEVEL = pre diff --git a/ANNOUNCE b/ANNOUNCE index 96ae973635..987b26c7cb 100644 --- a/ANNOUNCE +++ b/ANNOUNCE @@ -29,11 +29,10 @@ Wendy (hanwen@stack.nl) Those deserving special mention (in no particular order): Esther, Marijke, Heike, Inge, Judith, Hannah, Auke, Ilse, Evelyn, -Maartje, Suzanne, Ilse (gee, again?), my friends in the -Eindhovens Jongeren Ensemble and last (but certainly not least) +Maartje, Suzanne, Ilse (gee, again?) and last (but certainly not least) Janneke! - HW + 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, @@ -42,6 +41,11 @@ Eva, Roos, Judith, 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 too. + + --- * --- [ And now the serious part ] @@ -120,7 +124,7 @@ general n-plet (triplet, quadruplets, etc.), lyrics, transposition dynamics (both absolute and hairpin style) clef changes, meter changes, cadenza-mode, key changes, repeat bars -[Kudos to the FSF, all linux hackers, and --of course-- especially +[Kudos to the FSF, all Linux hackers, and --of course-- especially GrandMaster Linus T, for The Kernel and The Announce :-] Han-Wen Nienhuys diff --git a/AUTHORS.text b/AUTHORS.text index c1d175bcef..59947c7976 100644 --- a/AUTHORS.text +++ b/AUTHORS.text @@ -12,16 +12,19 @@ DDDDEEEESSSSCCCCRRRRIIIIPPPPTTTTIIIIOOOONNNN wrote. AAAAUUUUTTTTHHHHOOOORRRRSSSS - +o Han-Wen Nienhuys + +o Han-Wen Nienhuys , + http://www.stack.nl/~hanwen Main author, all files files except mentioned below - +o Jan Nieuwenhuizen + +o Jan Nieuwenhuizen , + http://www.digicash.com/~jan lily/midi-*, mi2mu/*, parts flower/string*.cc, make/*.make, */Makefile parts of Documentation/mudela.pod, lib/*source-file*, lib/duration.cc, lib/source, flower/*{list,cursor}*, + lily/rest-collision*, conflily, cygnus w32 stuff and corresponding header files. @@ -58,9 +61,6 @@ CCCCOOOONNNNTTTTRRRRIIIIBBBBUUUUTTTTOOOORRRRSS - - - -30/Jun/97 LilyPond 0.0.73 1 +7/Jul/97 LilyPond 0.0.74 1 diff --git a/BUGS b/BUGS index e69de29bb2..ab3880a17e 100644 --- a/BUGS +++ b/BUGS @@ -0,0 +1,11 @@ +This file documents bugs which were "re-introduced" in various pl's + +pl69 + * slurs.ly + +pl68: + * opening rests wohltemperirt + + * lyrics broken, + + * midi broken diff --git a/Documentation/AUTHORS.pod b/Documentation/AUTHORS.pod index dc2f0b2431..d79edec206 100644 --- a/Documentation/AUTHORS.pod +++ b/Documentation/AUTHORS.pod @@ -12,17 +12,18 @@ This file lists authors of GNU LilyPond, and what they wrote. =item * -Han-Wen Nienhuys +Han-Wen Nienhuys , http://www.stack.nl/~hanwen Main author, all files files except mentioned below =item * -Jan Nieuwenhuizen +Jan Nieuwenhuizen , http://www.digicash.com/~jan lily/midi-*, mi2mu/*, parts flower/string*.cc, make/*.make, */Makefile parts of Documentation/mudela.pod, lib/*source-file*, lib/duration.cc, -lib/source, flower/*{list,cursor}*, +lib/source, flower/*{list,cursor}*, lily/rest-collision*, conflily, +cygnus w32 stuff and corresponding header files. diff --git a/Documentation/CodingStyle.pod b/Documentation/CodingStyle.pod index 334cbbde63..e4693e3641 100644 --- a/Documentation/CodingStyle.pod +++ b/Documentation/CodingStyle.pod @@ -429,6 +429,6 @@ The following generic identifications are used: down == -1 Intervals are pictured lying on a horizontal numberline (Interval[-1] -is the minimum) +is the minimum). The 2D plane has +x on the right, +y pointing up. diff --git a/Documentation/MANIFESTO.pod b/Documentation/MANIFESTO.pod index e15a09d517..4eab08fbd8 100644 --- a/Documentation/MANIFESTO.pod +++ b/Documentation/MANIFESTO.pod @@ -49,7 +49,7 @@ Further considerations while doing the programming 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 very convenient for producing output. +TeX is convenient for producing output. =item * diff --git a/Documentation/gnu-music.pod b/Documentation/gnu-music.pod index 977933a1a6..98b8b3600d 100644 --- a/Documentation/gnu-music.pod +++ b/Documentation/gnu-music.pod @@ -8,23 +8,50 @@ Random ranting about the GNU Music project =head1 GOAL -Provide the users with free software for: +Provide musicians with free software for - - composing - - setting - - playing - - sequencing - - interchanging music +=over 4 + +=item - + +composing + +=item - + +engraving + +=item - + +playing + +=item - + +sequencing + +=item - + +interchanging music + +=back and possibly for - - arranging - - performing +=over 4 + +=item - + +arranging + +=item - + +performing + +=back Music publishers make lots of money out of selling sheet music which is in the public domain (the composers died a long time ago). It is usually prohibited to xerox the sheet music. Publishers have two -arguments for not allowing this: high prices are there to guarantee +arguments to justify this policy: the high prices are there to guarantee diversity (keeping lots of stock is expensive), and to encourage new work being composed. @@ -37,6 +64,9 @@ The public deserves to get public domain music for free (zero cents). The public deserves free tools for composing and printing. +In general, the same arguments as for software hold for music. See +Stallmans articles on free software. + =head1 REQUIREMENTS @@ -149,7 +179,8 @@ system and the typesetting engine. =item * -Libraries for reading, writing various audio/music/notation formats. +Libraries for reading and writing various audio/music/notation +formats. =back diff --git a/Documentation/lilyliterature.pod b/Documentation/lilyliterature.pod index 5200873a16..8ab344a029 100644 --- a/Documentation/lilyliterature.pod +++ b/Documentation/lilyliterature.pod @@ -1,238 +1,240 @@ -=head1 NAME +=head1 NAME Lily Literature -- reading on music engraving/typesetting/etc. =head1 DESCRIPTION A list of resources on music printing/writing and engraving. Please -note that don't have access to most material. +note that don't have access to most material. -[What I do know, I've commented inside brackets. They are just -my personal comments, not to be taken too seriously] +[What I do know, I've commented inside brackets. They are just my +personal comments, not to be taken too seriously] -=head2 Music engraving +=head2 Music engraving: references -Wanske, Helene. ``Musiknotation --- Von der Syntax des Notenstichs -zum EDV-gesteuerten Notensatz'', Schott-Verlag, Mainz 1988. ISBN -3-7957-2886-x. +Helene Wanske. ``Musiknotation --- Von der Syntax des Notenstichs zum +EDV-gesteuerten Notensatz'', Schott-Verlag, Mainz 1988.ISBN 3-7957-2886-x. [I. A very thorough overview of engraving practices of various craftsmen. It includes detailed specs of characters, dimensions etc. II. a thorough overview of a (by now antiquated) automated system called Ikarus; EDV Means e(lektronischen) D(aten)v(erarbeitung), -electronic data processing] +electronic data processing HWN] Maxwell Weaner and Walter Boelke, Standard Music Notation Practice, revised edition by Arnold Broido and Daniel Dorff. Music Publisher's Association of the United States Inc., 1993. -Ross, Ted. ``Teach yourself the art of music engraving and -processing'' (3rd edition). Hansen House, Miami Beach, FL. - - Hansen House - 1820 West Ave. - Miami, FL 33139 - (305) 532-5461 +Ted Ross. ``Teach yourself the art of music engraving and processing'' +(3rd edition). Hansen House, Miami Beach, FLorida. [This is about I i.e. professional music typesetting, and includes some good spacing tables MB] -Read, Gardner. ``Modern Rhythmic Notation.'' Indiana University Press, 1978. +Gardner Read. ``Modern Rhythmic Notation.'' Indiana University Press, +1978. -Read, Gardner. ``Music Notation'' (2nd edition). Taplinger Publishing, +Gardner Read. ``Music Notation'' (2nd edition). Taplinger Publishing, New York. -[This is as close to the ``standard'' reference work for music notation issues -as one is likely to get. MB] +[This is as close to the ``standard'' reference work for music +notation issues as one is likely to get. MB] + +MPA. Standard music notation specifications for computer programming. +December 1996 -=head2 Related papers +[Pamphlet explaining some fine points in music font design HWN] +=head2 Notation with computers -Byrd, Donald. ``Music Notation by Computer''. Diss. Indiana Univ., -1985. +Donald Byrd. ``Music Notation by Computer''. Dissertation Indiana +University, 1985. -Byrd, Donaldn. ``A System for Music Printing by Computer.'' -Computers and the Humanities, 8 (1974), 161-72. +Donald Byrd. ``A System for Music Printing by Computer.'' Computers +and the Humanities, 8 (1974), 161-72. -Smith, Leland. ``Editing and Printing Music by Computer.'' Journal -of Music Theory, 17 (1973), 292-309. +Leland Smith. ``Editing and Printing Music by Computer.'' Journal of +Music Theory, 17 (1973), 292-309. [If I remember correctly, this was concerned more with an input language than with the typography. SP.] -Gomberg, David A. ``A Computer-Oriented System for Music Printing.'' Diss. -Washington Univ. 1975. +David A Gomberg. ``A Computer-Oriented System for Music Printing.'' +Dissertation Washington University. 1975. -Hewlett, Walter B. and Eleanor Selfridge-Field. Directory of Computer -Assisted Research in Musicology. Menlo Park, CA: Center for Computer -Assisted Research in the Humanities. +Walter B Hewlett. and Eleanor Selfridge-Field. ``Directory of Computer +Assisted Research in Musicology''. Menlo Park, CA: Center for Computer +Assisted Research in the Humanities. [Annual editions since 1985, many containing surveys of music typesetting technology. SP] +Wael A. Hegazy and John S. Gourlay. ``Optimal line breaking in music''. In +Document Manipulation and Typography, J.C. van Vliet (ed) 1988. -W.A. Hegazy and J. S. Gourlay. Optimal line breaking in music. In -``Document Manipulation and Typography'', J.C. van Vliet (ed) 1988. - -[This generalizes TeX's breaking algorithm to music] +[This generalizes TeX's breaking algorithm to music HWN] -David A. Gomberg; A Computer-oriented System for Music Printing. +David A. Gomberg; ``A Computer-oriented System for Music Printing.'' Computers and the Humanities, Vol.11, pp 63-80. -J. Gourlay, ``Spacing a Line of Music,'' Technical Report +John S. Gourlay. ``Spacing a Line of Music,'' Technical Report OSU-CISRC-10/87-TR35, Department of Computer and Information Science, The Ohio State University, 1987. -J. Gourlay, A. Parrish, D. Roush, F. Sola, Y. Tien, ``Computer -Formatting of Music,'' Technical Report OSU-CISRC-2/87-TR3, -Department of Computer and Information Science, The Ohio State -University, 1987. +John S. Gourlay, A. Parrish, D. Roush, F. Sola, Y. Tien. ``Computer +Formatting of Music,'' Technical Report OSU-CISRC-2/87-TR3, Department +of Computer and Information Science, The Ohio State University, 1987. -W. Hegazy, ``On the Implementation of the MusiCopy Language +Wael A. Hegazy. ``On the Implementation of the MusiCopy Language Processor,'' Technical Report OSU-CISRC-10/87-TR34, Department of Computer and Information Science, The Ohio State University, 1987. -A. Parrish and J. Gourlay, ``Computer Formatting of Musical -Simultaneities,'' Technical Report OSU-CISRC-10/87-TR28, Department -of Computer and Information Science, The Ohio State University, 1987. +A. Parrish and John S. Gourlay. ``Computer Formatting of Musical +Simultaneities,'' Technical Report OSU-CISRC-10/87-TR28, Department of +Computer and Information Science, The Ohio State University, 1987. -D. Roush, ``Music Formatting Guidelines,'' Technical Report +D. Roush. ``Music Formatting Guidelines,'' Technical Report OSU-CISRC-3/88-TR10, Department of Computer and Information Science, The Ohio State University, 1988. -F. Sola, ``Computer Design of Musical Slurs, Ties and Phrase -Marks,'' Technical Report OSU-CISRC-10/87-TR32, Department of -Computer and Information Science, The Ohio State University, 1987. +F. Sola. ``Computer Design of Musical Slurs, Ties and Phrase Marks,'' +Technical Report OSU-CISRC-10/87-TR32, Department of Computer and +Information Science, The Ohio State University, 1987. -F. Sola and D. Roush, ``Design of Musical Beams,'' Technical -Report OSU-CISRC-10/87-TR30, Department of Computer and Information -Science, The Ohio State University, 1987. +F. Sola and D. Roush. ``Design of Musical Beams,'' Technical Report +OSU-CISRC-10/87-TR30, Department of Computer and Information Science, +The Ohio State University, 1987. -J. S. Gourlay. A language for music printing. In ``Communications of -the ACM''. Vol. 29(5), 388--401, 1986. +John. S. Gourlay. ``A language for music printing'', Communications +of the ACM, Vol. 29(5), 388--401, 1986. [This paper describes a vapourware music setting system and an input -language to go with it. ] +language to go with it. HWN] -D. Blostein and L. Haken, The Lime Music Editor: A Diagram Editor -Involving Complex Translations, Software Practice and Experience, -Vol. 24, No. 3, March 1994, pp. 289-306. +Dorothea Blostein and Lippold Haken, ``The Lime Music Editor: A Diagram +Editor Involving Complex Translations'', Software Practice and +Experience, Vol. 24, No. 3, March 1994, pp. 289-306. [A description of various conversions, decisions and issues relating -to this interactive editor] +to this interactive editor HWN] -L. Haken and D. Blostein, The Tilia Music Representation: +Lippold Haken and Dorothea Blostein, ``The Tilia Music Representation: Extensibility, Abstraction, and Notation Contexts for the Lime Music -Editor, Computer Music Journal, Vol. 17, No. 3, 1993, pp. 43-58 +Editor'', Computer Music Journal, Vol. 17, No. 3, 1993, pp. 43-58 [A description of Lime internals (which resemble older (before -0.0.68pre) LilyPond data structures somewhat)] +0.0.68pre) LilyPond data structures somewhat) HWN] -L. Haken and D. Blostein, A New Algorithm for Horizontal Spacing of -Printed Music, International Computer Music Conference, Banff, -Sept. 1995, pp. 118-119. +Lippold Haken and Dorothea Blostein, ``A New Algorithm for Horizontal +Spacing of Printed Music'', International Computer Music Conference, +Banff, Sept. 1995, pp. 118-119. [This describes an algorithm which uses springs between adjacent -columns. This algorithm is a "subclass" of the LilyPond algorithm.] +columns. This algorithm is a "subclass" of the LilyPond algorithm. HWN] -D. Blostein and L. Haken, Justification of Printed Music, -Communications of the ACM, VolJ34, No. 3, March 1991, pp. 88-99. +Dorothea Blostein and Lippold Haken, ``Justification of Printed Music'', +Communications of the ACM, VolJ34, No. 3, March 1991, pp. 88-99. [This paper provides a shallow overview of the algorithm used in LIME -for spacing individual lines.] +for spacing individual lines. HWN] -Gary M. Rader, ``Creating Printed Music Automatically''. Computer Vol +Gary M. Rader. ``Creating Printed Music Automatically''. Computer Vol 29(6), June 1996, pp 61--69. [Describes a system called MusicEase, and explains that it uses "constraints" (which go unexplained) to automatically position various -elements.] +elements. HWN] Stephen Dowland Page. ``Computer Tools for Music Information -Retrieval''. Dissertation Univ of Oxford, 1988. +Retrieval''. Dissertation University of Oxford, 1988. [Don't ask Stephen for a copy. Write to the Bodleian Library, Oxford, -or to the British Library, instead.] +or to the British Library, instead. SP] + +Ren\'e Roelofs. ``Een Geautomatiseerd Systeem voor het Afdrukken van +Muziek'' afstudeerscriptie Bestuurlijke informatica, no 45327, Erasmus +universiteit Rotterdam, 1991. (``An automated system for printing +music'' Master's Thesis Managerial Computer Science.) + +[This thesis describes a simplistic (monophonic) typesetting system, +and focuses on the breaking algorithm, which is taken from Hegazy & +Gourlay HWN] + +Miguel Filgueiras and Jos\'e Paulo Leal. ``Representation and +manipulation of music documents in SceX''. Electronic Publishing, +vol. 6 (4), 507--518, 1993. + +Eric Foxley, Music --- A language for typesetting music scores. +Software --- Practice and Experience, Vol. 17(8), 485--502, 1987. + +[A paper on a TROFF preprocessor to typeset music. The output shown is +not very sophisticated, and contains some typographical atrocities HWN] + +Miguel Filgueiras, ``Implementing a Symbolic Music Processing +System''. LIACC, Universidade do Porto, 1996; submitted. -=head2 Further reading +Miguel Filgueiras, ``Some Music Typesetting Algorithms''. LIACC, +Universidade do Porto, forthcoming. -Chlapik, Herbert. ``Die Praxis des Notengraphikers''. Doblinger, 1987. +=head2 Engraving: further reading + +Herbert Chlapik. ``Die Praxis des Notengraphikers''. Doblinger, 1987. ISBN 3-9000 035-96-2. [An clearly written book for the casually interested reader. It shows -some of the conventions and difficulties in printing music] +some of the conventions and difficulties in printing music HWN] The University of Colorado Music Engraving page. http://obenamots.cc.colorado.edu/Musicpress/engraving.html -More on GNU Music: http://dept-info.labri.u-bordeaux.fr/~strandh/Gsharp - -Tablature: http://wabakimi.carleton.ca/~phacket2/guitar/tabfaq.html - -Donato, Anthony. Preparing Music Manuscript. Englewood Cliffs: +Anthony Donato. Preparing Music Manuscript. Englewood Cliffs: Prentice-Hall, 1963. Donemus. ``Uitgeven van muziek''. Donemus Amsterdam, 1900 -Heussenstamm, George. The Norton Manual of Music Notation. New York: +George Heussenstamm. The Norton Manual of Music Notation. New York: Norton, 1987. -Karkoshka, Erdhard. Notation in New Music. Trans. Ruth Koenig. New York: -Praeger Publishers, 1972. Out of print. - -Roelofs, Ren\'e. ``Een Geautomatiseerd Systeem voor het Afdrukken van -Muziek'' afstudeerscriptie Bestuurlijke informatica, no 45327, Erasmus -universiteit Rotterdam, 1991. (``An automated system for printing -music'' Master's Thesis Managerial Computer Science.) - -[This thesis describes a simplistic (monophonic) typesetting system, -and focuses on the breaking algorithm, which is taken from Hegazy & Gourlay] +Erdhard Karkoshka. ``Notation in New Music. Trans. Ruth +Koenig''. Praeger Publishers, New York, 1972. Out of print. C. Roemer, The Art of Music Copying. Roerick music co., Sherman Oaks (CA), 1973. -Rosecrans, Glen. Music Notation Primer. New York: Passantino, 1979. +Glen Rosecrans. Music Notation Primer. New York: Passantino, 1979. -Stone, Kurt. Music Notation in the Twentieth Century. New York: Norton, 1980. +Kurt Stone. Music Notation in the Twentieth Century. New York: Norton, +1980. -=head2 other stuff +=head2 other stuff -Peter S. Langston, Unix music tools at Bellcore. -Software --- Practice and Experience, Vol. 20(S1), S1/47--S1/61, 1990. -[This paper deals with some command-line tools for music editing and -playback. It doesn't mention notation issues, but does come with the -grand idea (not) of using music to monitor complex systems. Imagine your -nuclear plant supervisor to use AC/DC for checking the reactor] +More on GNU Music: +http://dept-info.labri.u-bordeaux.fr/~strandh/Gsharp -Cindy Grande, NIFF6a Notation Interchange File Format. -Grande Software Inc., 1995. ftp://blackbox.cartah.washington.edu/pub/ - -[Specs for NIFF, a comprehensive but binary (yuk) format for notation] +Tablature: http://wabakimi.carleton.ca/~phacket2/guitar/tabfaq.html -Miguel Filgueiras and Jos\'e Paulo Leal. Representation and -manipulation of music documents in SceX. Electronic Publishing, -vol. 6 (4), 507--518, 1993. -Eric Foxley, Music --- A language for typesetting music scores. -Software --- Practice and Experience, Vol. 17(8), 485--502, 1987. +Peter S. Langston, ``Unix music tools at Bellcore''. Software --- +Practice and Experience, Vol. 20(S1), S1/47--S1/61, 1990. -[A paper on a TROFF preprocessor to typeset music. The output shown is -not very sophisticated, and contains some typographical atrocities] +[This paper deals with some command-line tools for music editing and +playback. It doesn't mention notation issues, but does come with the +grand idea (not) of using music to monitor complex systems. Imagine +your nuclear plant supervisor to use AC/DC for checking the reactor HWN] -Alexander Brinkman, PASCAL Programming for Music Research. -The University of Chicago Press, 1990. +Cindy Grande, NIFF6a Notation Interchange File Format. Grande +Software Inc., 1995. ftp://blackbox.cartah.washington.edu/pub/ -Miguel Filgueiras, Implementing a Symbolic Music Processing -System. LIACC, Universidade do Porto, 1996; submitted. +[Specs for NIFF, a comprehensive but binary (yuk) format for notation HWN] -Miguel Filgueiras, Some Music Typesetting Algorithms. LIACC, -Universidade do Porto, forthcoming. +Alexander Brinkman, ``PASCAL Programming for Music Research''. The +University of Chicago Press, 1990. =head1 AUTHORS -Refs contributed by Han-Wen Nienhuys, Miguel Filgueiras, Mark +References contributed by Han-Wen Nienhuys, Miguel Filgueiras, Mark Basinski, Dorothea Blostein, Stephen Page, Jan Nieuwenhuizen. This should really be redone in BibTeX diff --git a/Documentation/other-packages.pod b/Documentation/other-packages.pod index 0e1f58d35a..bfd965afb0 100644 --- a/Documentation/other-packages.pod +++ b/Documentation/other-packages.pod @@ -31,19 +31,13 @@ A amateurish notation program for TclTk and X. A preprocessor to MusixTeX by Jan Nieuwenhuizen and Han-Wen Nienhuys. It is outdated by its successor, LilyPond. -=item Music, http://www.cs.nott.ac.uk/Departement/Staff/ef/printing.html +=item LilyPond, http://www.stack.nl/~hanwen/lilypond/index.html -A TROFF preprocessor by Eric Foxley +Added for completeness. You are currently reading her documentation. -MusE +=item Music, http://www.cs.nott.ac.uk/Department/Staff/ef/printing.html -A-R Music Engraving, by A-R Editions, Inc. Professional engraving on -Sun boxen. - -=item Mup, http://www.arkkra.com/ - -A program which creates PS from a script input. Although it comes with -C source code, it is Shareware. +A TROFF preprocessor by Eric Foxley =item PMX, http://www.gmd.de/Misc/Music/ @@ -53,12 +47,12 @@ A Preprocessor for MusiXTeX by Don Simons MusixTeX is a macro package for TeX to typeset polyphonic or instrumental music by Daniel Taupin, Ross Mitchell and Andreas -Egler. It includes a font set with lots symbols +Egler. It includes a full-featured set of fonts. =item ABC2MTeX, http://www.gmd.de/Misc/Music/ -A preprocessor to MusixTeX by Chris Walshaw for way of transcribing folk -and traditional music. +A preprocessor to MusixTeX by Chris Walshaw for transcribing folk and +traditional music. =item SceX http://www.ncc.up.pt/~mig/SceX.html @@ -79,6 +73,15 @@ A NeXT package by William F. Clocksin. Requires Adobe fonts. =head2 Proprietary +=item Scribe, http:// + +A formatter for medieval scores. + +=item Mup, http://www.arkkra.com/ + +A program which creates PS from a script input. Although it comes with +C source code, it is Shareware. + =item MusicEase, http://mesa.colorado.edu/~grader/musicez.html Described in Computer vol 29(6). Shareware @@ -87,23 +90,26 @@ Described in Computer vol 29(6). Shareware =item Sibelius, http://www.acorn.co.uk/developers/sibelius -Finale +=item Finale -Score +=item Score -Personal Composer +=item Personal Composer +=item MusE +A-R Music Engraving, by A-R Editions, Inc. Professional engraving on +Sun boxen. =item Mozart, http://www.mozart.co.uk/ A shareware windows package -Capella +=item Capella -Encore +=item Encore -Musicator +=item Musicator =head2 Unknown diff --git a/INSTALL.text b/INSTALL.text index c27731e276..1a6758d625 100644 --- a/INSTALL.text +++ b/INSTALL.text @@ -61,7 +61,7 @@ CCCCOOOONNNNFFFFIIIIGGGGUUUURRRRIIIINNNNGGGG a -7/Jul/97 LilyPond 0.0.73 1 +7/Jul/97 LilyPond 0.0.74 1 @@ -127,7 +127,7 @@ INSTALL(1) LilyPond documentation INSTALL(1) -7/Jul/97 LilyPond 0.0.73 2 +7/Jul/97 LilyPond 0.0.74 2 @@ -193,7 +193,7 @@ RRRRUUUUNNNNNNNNIIIINNNNGGGG -7/Jul/97 LilyPond 0.0.73 3 +7/Jul/97 LilyPond 0.0.74 3 @@ -259,7 +259,7 @@ RRRREEEEDDDDHHHHAAAATTTT LLLLIIIINNNNUUUUXXXX -7/Jul/97 LilyPond 0.0.73 4 +7/Jul/97 LilyPond 0.0.74 4 @@ -325,6 +325,6 @@ AAAAUUUUTTTTHHHHOOOORRRRSSSS -7/Jul/97 LilyPond 0.0.73 5 +7/Jul/97 LilyPond 0.0.74 5 diff --git a/NEWS b/NEWS index c1c73b8ec8..8024812612 100644 --- a/NEWS +++ b/NEWS @@ -1,9 +1,12 @@ -pl 72pre.jcn1 - - - naming fixes; some iter*() explicitations - - removed acceptor.hh - - second draft of midi (audio/...) based on engraver hierarchy - +pl 74pre + - Input_engraver -> Input_translator + - bf: span start/stop is now a "used" col. + - Rest_column/Rest_collisions bugfixes + - bf: crescendi. + - Spanner do_print() + +****** +july 7 pl 73pre - some refs doco. - move Input_engraver into Paper_def diff --git a/TODO b/TODO index b322e39d18..790be44516 100644 --- a/TODO +++ b/TODO @@ -6,6 +6,13 @@ done, or is an idea that I want to think about Most of the items are marked in the code as well, with full explanation. grep for TODO and ugh/ugr + * Redo MIDI output to use Translators + - remember more horizontal info than melodics: + - tempo change + - repeat + - slurs + - dynamics etc. + * pushgroup/popgroup * strict separation between visual and auditive processing. @@ -21,8 +28,6 @@ grep for TODO and ugh/ugr * implement better breaking algorithm * update 20 pt table - - * use Hungarian throughout code * decent TeX page layout @@ -32,6 +37,12 @@ grep for TODO and ugh/ugr PROJECTS + * grace notes + - adapt for multiple font sizes. + - make separate class for Grace_*_engravers + (which is at Voice_gravs level) + - move stem, beam, slur into baseclass to adapt for (fixed size) grace notes. + * accidentals per Voice_group * Convert all ref/bib stuff into BibTeX. @@ -77,21 +88,13 @@ PROJECTS - separate visual from rhythmic info even more - beams over bars - * Redo MIDI output to use Translators - - remember more horizontal info than melodics: - - tempo change - - repeat - - slurs - - dynamics etc. - * Redo font support - - use GSharp fonts? - rename mf fonts to avoid conflicts with musixtex - - check (c) issues - use own fonts/update musixtex fonts/find older (c)-less fonts - hack up mf sources for decent spacing info (and then read AFM/TFM directly, for text too) + - use MF to generate rules. * lines: - Ledger lines, should be separate item: Ledger_lines, Ledger_lines @@ -122,8 +125,6 @@ tekst staat erg ver van notenbalken af BUGS - * spurious Weird stem size warnings - * fix mysterious Flex malloc bug * should adjust stemlength for flag number. @@ -138,11 +139,6 @@ SEVERELY LACKING: * SPEED! - * grace notes - - -FURTHER FOR ORCHESTRAL SCORE: - * multibar rests * barnumbers, markers diff --git a/bin/make_website b/bin/make_website index 096d700280..4fec78309e 100755 --- a/bin/make_website +++ b/bin/make_website @@ -71,7 +71,8 @@ sub my_system local $base="lilypond/"; -local @examples=("multi", "wohltemperirt" ,"standchen", "toccata-fuga-E", "scsii-menuetto", "collisions"); +local @examples=("multi", "wohltemperirt" ,"standchen", "toccata-fuga-E", + "scsii-menuetto", "collisions", "cadenza", "scales"); # rhythm, scales, diff --git a/flower/include/iterate.hh b/flower/include/iterate.hh index 74e6ff202c..9aee1ec550 100644 --- a/flower/include/iterate.hh +++ b/flower/include/iterate.hh @@ -10,13 +10,7 @@ #ifndef ITERATE_HH #define ITERATE_HH -/* - ugh. - jcn: kjoet. - if we wouldn't have had this, things might have been - just a little bit easier to read, imho. - (it does save quite some disk space, though) - */ + #define iterator(set) typeof((set).top()) #define iterator_bot(set) typeof((set).bottom()) diff --git a/init/engraver.ini b/init/engraver.ini index d0a6f457bc..fac0e15c06 100644 --- a/init/engraver.ini +++ b/init/engraver.ini @@ -2,19 +2,21 @@ % setup for Request->Element conversion. Guru-only % -\requestengraver { - "Score_engraver" +\requesttranslator { + Engraver Score_engraver \alias "Score"; + \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 "Span_bar_engraver"; - \contains\requestengraver { - "Staff_engravers" + \contains\requesttranslator { + Engraver "Staff_engravers" \alias "Staff"; \consists "Bar_engraver"; \consists "Clef_engraver"; @@ -24,16 +26,16 @@ \consists "Staff_sym_engraver"; \consists "Collision_engraver"; \consists "Rest_collision_engraver"; - \contains \requestengraver { - "Voice_group_engravers" + \contains \requesttranslator { + Engraver "Voice_group_engravers" \alias "Voice_group"; \consists "Dynamic_engraver"; \consists "Stem_beam_engraver"; \consists "Script_engraver"; \consists "Note_column_engraver"; \consists "Slur_engraver"; - \contains \requestengraver { - "Engraver_group_engraver" + \contains \requesttranslator { + Engraver "Engraver_group_engraver" \alias "Voice"; \consists "Note_head_engraver" ; \consists "Tie_engraver"; @@ -41,14 +43,14 @@ } } - \contains\requestengraver { - "Staff_engravers" + \contains\requesttranslator { + Engraver "Staff_engravers" \alias "Lyric"; - \contains\requestengraver{ - "Voice_group_engravers" + \contains\requesttranslator{ + Engraver "Voice_group_engravers" \alias "Voice_group"; - \contains\requestengraver{ - "Engraver_group_engraver" + \contains\requesttranslator{ + Engraver "Engraver_group_engraver" \consists "Lyric_engraver"; \consists "Swallow_engraver"; } diff --git a/init/midi.ini b/init/midi.ini deleted file mode 100644 index 29f4c2d9da..0000000000 --- a/init/midi.ini +++ /dev/null @@ -1,5 +0,0 @@ - -default_midi = \midi { - \tempo 4:60; - \include "performer.ini" -} diff --git a/init/performer.ini b/init/performer.ini deleted file mode 100644 index 7dffbbf48c..0000000000 --- a/init/performer.ini +++ /dev/null @@ -1,26 +0,0 @@ -% -% setup for Request->Element conversion. Guru-only -% - -\requestperformer { - "Score_performer" - \alias "Score"; - \consists "Clef_performer"; - \consists "Key_performer"; - \consists "Meter_performer"; - \consists "Tempo_performer"; - - \contains\requestperformer { - "Staff_performers" - \alias "Midi"; - \contains\requestperformer{ - "Voice_group_performers" - \alias "Voice_group"; - \contains\requestperformer{ - "Performer_group_performer" - \consists "Lyric_performer"; - \consists "Note_performer"; - } - } - } -} diff --git a/init/symbol.ini b/init/symbol.ini index 77f7fdd5f6..2c26af1cc5 100644 --- a/init/symbol.ini +++ b/init/symbol.ini @@ -5,9 +5,6 @@ \include "script.ini" \include "paper16.ini" -% ugh -\include "midi.ini" - left = -1 right = 1 up = 1 diff --git a/init/table16.ini b/init/table16.ini index 6d202aa420..d09a275b72 100644 --- a/init/table16.ini +++ b/init/table16.ini @@ -111,6 +111,9 @@ table_sixteen= "1" "\wholerest" 0.0\pt 6.0\pt 0.0\pt 2.0\pt "2" "\halfrest" 0.0\pt 6.0\pt -2.0\pt 0.0\pt "2o" "\outsidehalfrest" 0.0\pt 6.0\pt -2.0\pt 0.0\pt + "4o" "\quartrest" -5.0\pt 2.0\pt -5.0\pt 5.0\pt + "8o" "\eighthrest" 0.0\pt 5.0\pt 0.0\pt 8.0\pt + "16o" "\sixteenthrest" 0.0\pt 6.0\pt 0.0\pt 12.0\pt "4" "\quartrest" -5.0\pt 2.0\pt -5.0\pt 5.0\pt "8" "\eighthrest" 0.0\pt 5.0\pt 0.0\pt 8.0\pt "16" "\sixteenthrest" 0.0\pt 6.0\pt 0.0\pt 12.0\pt diff --git a/input/cadenza.ly b/input/cadenza.ly index 90f7c45c8f..eda6e6bfd7 100644 --- a/input/cadenza.ly +++ b/input/cadenza.ly @@ -17,27 +17,27 @@ cad = \melodic { \cadenza 1; \grouping 1*4;\duration 8;\octave c'; - \clef \violin ; + \clef "violin"; c'4.\mf g8 [e'^"accel" ~ d' c' b] [b~ c'] g-\fermata - \bar \empty; + \bar "empty"; c [c_"rubato" e g c'] \octave c''; e4. e [g ~ f_"rit" e d] \duration 16; dis4~ e4 - \bar \empty ; + \bar "" ; r8 [c d] [e f g gis] \duration 4; a-> 'f~ 'e g f-> 'd~ 'cis e \duration 8; d4^\fermata - \bar \empty ; + \bar "" ; r8 'a ['b cis] \duration 16; [d cis d e] @@ -45,10 +45,10 @@ cad = \melodic { 'b4 \octave c'; [2/3 d'8 c'8 a8]1/1 g2 - \bar \empty ; + \bar "" ; [g c e g] [c' e g c']\octave c''; [e 'g c e] g4^\fermata %~ % BUG! - \bar \empty ; + \bar "" ; [g8.(_"a tempo" e g8. )e] a4. g8 [f8 e8 d8 c8] 'g2 d2^"tr" diff --git a/input/keys.ly b/input/keys.ly index 076ea00fe7..4a30ea61f9 100644 --- a/input/keys.ly +++ b/input/keys.ly @@ -10,7 +10,7 @@ Tested Features: local key, key, forced accidentals EndMudelaHeader %} -\version "0.0.58"; +\version "0.0.61"; blah = \melodic{ @@ -31,8 +31,6 @@ blah = \melodic{ } \score{ - \staff { - melodicregs - blah - } + \blah + } diff --git a/input/pedal.ly b/input/pedal.ly index caa9905430..f9a5b9eaf9 100644 --- a/input/pedal.ly +++ b/input/pedal.ly @@ -24,10 +24,9 @@ % \lbheel \lbheel \lfheel \lftoe % \rbheel \rbtoe \rfheel \rftoe -\version "0.0.58"; +\version "0.0.61"; \score{ - \staff{ melodicregs \melodic { \meter 4/4; \key fis cis; @@ -44,7 +43,6 @@ [d-\lfheel e-\rbtoe fis-\ltoe e-\rbtoe] [d-\lfheel e-\rbtoe fis-\lheel e] [d e fis e] [d e fis e] | d4 r4 r4 [b-\rtoe a-\ltoe b-\rtoe fis-\ltoe] | - } } \paper{} } diff --git a/input/scales.ly b/input/scales.ly index c1f32c13bc..c594d77876 100644 --- a/input/scales.ly +++ b/input/scales.ly @@ -1,3 +1,16 @@ +%{MudelaHeader + + filename: scales.ly + title: + description: + composers: + entered-by: HWN + copyright: public domain + + Tested Features: scripts, beams, transposition, +EndMudelaHeader +%} + % % scales with accents. % diff --git a/input/scripts.ly b/input/scripts.ly index 42b1fa1731..3882327d27 100644 --- a/input/scripts.ly +++ b/input/scripts.ly @@ -10,12 +10,10 @@ Tested Features: scripts, text. EndMudelaHeader %} -\version "0.0.58"; +\version "0.0.61"; -blah = \staff{ melodicregs - - \melodic { +blah = \melodic { \octave c'; 'c ->-.-\fermata-"text" c ->-.-\fermata-"text" @@ -65,11 +63,9 @@ blah = \staff{ melodicregs [c-\lheel \< d-\lheel e-\lheel \! f-\lheel] [d'-\lheel \> e'-\lheel f'-\lheel \! g'-\lheel] } -} + \score{ - blah - \paper{ - \symboltables {table_sixteen} - } + \blah + } diff --git a/lily/.version b/lily/.version index 5e83560950..e6694dfa00 100644 --- a/lily/.version +++ b/lily/.version @@ -1,7 +1,7 @@ MAJOR_VERSION = 0 MINOR_VERSION = 0 -PATCH_LEVEL = 73 +PATCH_LEVEL = 74 # use to send patches, always empty for released version: # include separator: ".postfix", "-pl" makes rpm barf -MY_PATCH_LEVEL = pre.jcn1 +MY_PATCH_LEVEL = pre diff --git a/lily/Stable.make b/lily/Stable.make index 71e49f46c8..fb03ccca1d 100644 --- a/lily/Stable.make +++ b/lily/Stable.make @@ -3,8 +3,8 @@ # a bit of a hack to keep exec size under control. stablecc=atom.cc command-request.cc musical-request.cc bar.cc boxes.cc \ keyword.cc leastsquares.cc \ - lookup.cc molecule.cc meter.cc\ - paper-def.cc parser.cc lexer.cc qlp.cc qlpsolve.cc\ + lookup.cc meter.cc\ + parser.cc lexer.cc qlp.cc qlpsolve.cc\ template1.cc template2.cc template3.cc template4.cc\ template5.cc template6.cc version.cc tex-stream.cc tex.cc\ - identifier.cc note.cc voice-gravs.cc\ + identifier.cc note.cc diff --git a/lily/beam.cc b/lily/beam.cc index d4f741d788..872cfae025 100644 --- a/lily/beam.cc +++ b/lily/beam.cc @@ -378,7 +378,7 @@ Beam::do_print()const { #ifndef NPRINT mtor << "slope " <lookup_l()->hairpin( lookup_wid, grow_dir_i_ < 0) ); + return Symbol( paper()->lookup_l()->hairpin( w_dim, grow_dir_i_ < 0) ); +} + +Molecule* +Crescendo::brew_molecule_p() const +{ + Molecule* m_p =0; + Real x_off_dim=0.0; + if ( left_dyn_b_) + x_off_dim += absdyn_dim; + + m_p = new Molecule; + Symbol s(get_symbol()); m_p->add(Atom(s)); - int pos = get_position_i(s.dim.y); - m_p->translate(Offset(x_off_dim + 0.05 * w_dim, - pos * paper()->internote_f())); + m_p->translate(Offset(x_off_dim, pos_i_ * paper()->internote_f())); return m_p; } diff --git a/lily/engraver-group.cc b/lily/engraver-group.cc index 1fd484572b..f876bf2605 100644 --- a/lily/engraver-group.cc +++ b/lily/engraver-group.cc @@ -13,7 +13,8 @@ #include "debug.hh" #include "p-score.hh" #include "score-elem.hh" -#include "input-engraver.hh" +#include "input-translator.hh" +Engraver* get_engraver_p(String); Engraver_group_engraver::~Engraver_group_engraver() { @@ -41,14 +42,13 @@ Engraver_group_engraver::removable_b()const Engraver_group_engraver::Engraver_group_engraver() { - igrav_l_ =0; + itrans_l_ =0; } void Engraver_group_engraver::set_feature(Feature d) { - PCursor i(grav_list_.top()); - // why the while construct? + iter_top(grav_list_, i); while (i.ok()) { // this construction to ensure clean deletion Engraver *grav_l = i++; @@ -59,8 +59,9 @@ Engraver_group_engraver::set_feature(Feature d) void Engraver_group_engraver::sync_features() { - PCursor i(grav_list_.top()); + iter_top(grav_list_, i); while (i.ok()) { + Engraver *grav_l = i++; grav_l->sync_features(); } @@ -69,8 +70,9 @@ Engraver_group_engraver::sync_features() void Engraver_group_engraver::do_pre_move_processing() { - PCursor i(grav_list_.top()); + iter_top(grav_list_, i); while (i.ok()) { + Engraver *grav_l = i++; grav_l->pre_move_processing(); } @@ -79,8 +81,9 @@ Engraver_group_engraver::do_pre_move_processing() void Engraver_group_engraver::do_process_requests() { - PCursor i(grav_list_.top()); + iter_top(grav_list_, i); while (i.ok()) { + Engraver *grav_l = i++; grav_l->process_requests(); } @@ -90,7 +93,7 @@ Engraver_group_engraver::do_process_requests() void Engraver_group_engraver::do_post_move_processing() { - PCursor i(grav_list_.top()); + iter_top(grav_list_, i); while (i.ok()) { // this construction to ensure clean deletion Engraver *grav_l = i++; @@ -106,8 +109,8 @@ Engraver_group_engraver::contains_b(Engraver* grav_l)const if (parent_b) return true; - for (PCursor i(grav_list_.top()); i.ok(); i++) - if (i->contains_b(grav_l)) + for (iter_top(grav_list_, j); j.ok(); j++) + if (j->contains_b(grav_l)) return true; return false; } @@ -150,7 +153,7 @@ Engraver_group_engraver::remove_engraver_p(Engraver*grav_l) { group_l_arr_.substitute((Engraver_group_engraver*)grav_l,0); nongroup_l_arr_.substitute(grav_l,0); - PCursor grav_cur( grav_list_.find(grav_l) ); + iterator(grav_list_) grav_cur= grav_list_.find(grav_l); return grav_cur.remove_p(); } @@ -174,7 +177,7 @@ Engraver_group_engraver::do_print()const { #ifndef NPRINT mtor << "ID: " << id_str_ << "\n"; - for (PCursor i(grav_list_.top()); i.ok(); i++) + for (iter_top(grav_list_, i); i.ok(); i++) i->print(); #endif } @@ -197,17 +200,17 @@ Translator* Engraver_group_engraver::find_get_translator_l(String n,String id) { Translator * ret=0; - Input_engraver * igrav_l= igrav_l_-> recursive_find ( n ); - if (igrav_l ) { + Input_translator * itrans_l= itrans_l_-> recursive_find ( n ); + if (itrans_l ) { ret = find_engraver_l(n,id); if (!ret) { Engraver_group_engraver * group = - igrav_l-> get_group_engraver_p(); + itrans_l-> get_group_engraver_p(); add(group); ret = group; - if (group->igrav_l_->is_name_b( n ) ) + if (group->itrans_l_->is_name_b( n ) ) ret ->id_str_ = id; else return ret->find_get_translator_l(n,id); @@ -270,7 +273,7 @@ Engraver_group_engraver::do_announces() void Engraver_group_engraver::do_removal_processing() { - for (PCursor i(grav_list_.top()); i.ok(); i++) + for (iter( grav_list_.top(), i); i.ok(); i++) i->do_removal_processing(); } @@ -292,8 +295,8 @@ Engraver_group_engraver::get_default_interpreter() if ( is_bottom_engraver_b() ) return daddy_grav_l_->get_default_interpreter(); - Engraver_group_engraver *grav_p= igrav_l_-> - get_default_igrav_l()->get_group_engraver_p(); + Engraver_group_engraver *grav_p= itrans_l_-> + get_default_itrans_l()->get_group_engraver_p(); add(grav_p ); if (grav_p->is_bottom_engraver_b()) return grav_p; @@ -304,5 +307,5 @@ Engraver_group_engraver::get_default_interpreter() bool Engraver_group_engraver::is_bottom_engraver_b()const { - return !igrav_l_->get_default_igrav_l(); + return !itrans_l_->get_default_itrans_l(); } diff --git a/lily/global-gravs.cc b/lily/global-gravs.cc index 1805012269..6ffbc175ad 100644 --- a/lily/global-gravs.cc +++ b/lily/global-gravs.cc @@ -1,5 +1,5 @@ /* - global-gravs.cc -- implement + global-gravs.cc -- implement Engraver,Performer ctors source file of the GNU LilyPond music typesetter @@ -8,7 +8,7 @@ #include "proto.hh" #include "plist.hh" -#include "input-engraver.hh" +#include "input-translator.hh" #include "debug.hh" #include "engraver.hh" @@ -28,7 +28,7 @@ struct Engraver_table_entry { static Array *grav_table=0; void -add_Engraver(String s, Grav_ctor f) +add_engraver(String s, Grav_ctor f) { if (!grav_table) grav_table = new Array; @@ -47,3 +47,43 @@ get_engraver_p(String s) error("Unknown engraver `" + s +"\'"); return 0; } + +#if 0 + +struct Performer_table_entry +{ + String name_str_; + Perf_ctor ctor_l_; + Performer_table_entry(String s, Perf_ctor f) { + name_str_ =s; + ctor_l_ = f; + } + Performer_table_entry() + { + ctor_l_ =0; + } +} + +static Array *perf_table=0; + +void +add_performer(String s, Perf_ctor f) +{ + if (!perf_table) + perf_table = new Array; + + perf_table->push(Performer_table_entry(s, f)); +} + + +Performer* +get_performer_p(String s) +{ + for (int i=0; i < perf_table->size(); i++) { + if ((*perf_table)[i].name_str_ == s) + return (*(*perf_table)[i].ctor_l_)(); + } + error("Unknown performer `" + s +"\'"); + return 0; +} +#endif diff --git a/lily/global-performers.cc b/lily/global-performers.cc deleted file mode 100644 index 43c4ec33b5..0000000000 --- a/lily/global-performers.cc +++ /dev/null @@ -1,50 +0,0 @@ -/* - global-performers.cc -- implement - - source file of the GNU LilyPond music typesetter - - (c) 1997 Han-Wen Nienhuys - Jan Nieuwenhuizen -*/ - -#include "proto.hh" -#include "plist.hh" -#include "input-performer.hh" -#include "debug.hh" -#include "performer.hh" - -struct Performer_table_entry { - String name_str_; - Perf_ctor ctor_l_; - Performer_table_entry(String s, Perf_ctor f) { - name_str_ =s; - ctor_l_ = f; - } - Performer_table_entry() - { - ctor_l_ =0; - } -}; - -static Array *perf_table=0; - -void -add_Performer(String s, Perf_ctor f) -{ - if (!perf_table) - perf_table = new Array; - - perf_table->push(Performer_table_entry(s, f)); -} - - -Performer* -get_performer_p(String s) -{ - for (int i=0; i < perf_table->size(); i++) { - if ((*perf_table)[i].name_str_ == s) - return (*(*perf_table)[i].ctor_l_)(); - } - error("Unknown performer `" + s +"\'"); - return 0; -} diff --git a/lily/identifier.cc b/lily/identifier.cc index 0a2c813f2f..40c7e543e8 100644 --- a/lily/identifier.cc +++ b/lily/identifier.cc @@ -7,18 +7,17 @@ */ #include -#include "midi-def.hh" #include "paper-def.hh" #include "score.hh" #include "identifier.hh" #include "my-lily-lexer.hh" #include "debug.hh" + #include "symtable.hh" #include "lookup.hh" #include "script-def.hh" #include "request.hh" -#include "input-engraver.hh" -#include "input-performer.hh" +#include "input-translator.hh" IMPLEMENT_STATIC_NAME(Identifier); IMPLEMENT_IS_TYPE_B(Identifier); @@ -67,9 +66,7 @@ DEFAULT_PRINT(Symtables_id, Symtables, symtables); DEFAULT_PRINT(Music_id,Music , music); DEFAULT_PRINT(Request_id, Request, request); DEFAULT_PRINT(Score_id, Score, score); -DEFAULT_PRINT(Input_gravs_id, Input_engraver, igravs); -DEFAULT_PRINT(Input_perfs_id, Input_performer, iperfs); -DEFAULT_PRINT(Midi_def_id,Midi_def, mididef); +DEFAULT_PRINT(Input_trans_id, Input_translator, itrans); DEFAULT_PRINT(Paper_def_id,Paper_def, paperdef); void @@ -122,9 +119,7 @@ implement_id_class(Symtables_id, Symtables, symtables); implement_id_class(Music_id, Music, music); implement_id_class(Score_id, Score, score); implement_id_class(Request_id, Request, request); -implement_id_class(Input_gravs_id, Input_engraver, igravs); -implement_id_class(Input_perfs_id, Input_performer, iperfs); -implement_id_class(Midi_def_id, Midi_def, mididef); +implement_id_class(Input_trans_id, Input_translator, itrans); implement_id_class(Paper_def_id, Paper_def, paperdef); Identifier::Identifier(Identifier const&) @@ -140,7 +135,5 @@ default_accessor(Symtables_id, Symtables, symtables); virtual_accessor(Music_id, Music, music); default_accessor(Score_id, Score, score); virtual_accessor(Request_id, Request, request); -default_accessor(Input_gravs_id, Input_engraver, igravs); -default_accessor(Input_perfs_id, Input_performer, iperfs); -default_accessor(Midi_def_id, Midi_def, mididef); +default_accessor(Input_trans_id, Input_translator, itrans); default_accessor(Paper_def_id, Paper_def, paperdef); diff --git a/lily/include/acceptor.hh b/lily/include/acceptor.hh index e69de29bb2..872f374aee 100644 --- a/lily/include/acceptor.hh +++ b/lily/include/acceptor.hh @@ -0,0 +1,41 @@ +/* + acceptor.hh -- declare Translator + + source file of the GNU LilyPond music typesetter + + (c) 1997 Han-Wen Nienhuys +*/ + + +#ifndef ACCEPTOR_HH +#define ACCEPTOR_HH +#error + +#include "string.hh" +#include "lily-proto.hh" +#include "interpreter.hh" +#include "virtual-methods.hh" + +class Translator { +public: + String id_str_; + + int iterator_count_; + + virtual Interpreter * interpreter_l() { return 0; } + + /// Score_engraver = 0, Staff_engravers = 1, etc) + virtual int depth_i()const=0; + virtual Translator *find_get_translator_l(String name, String id)=0; + virtual Translator *ancestor_l(int l=1)=0; + virtual ~Translator(){} + NAME_MEMBERS(); + Translator(); + virtual Translator *get_default_interpreter()=0; +}; + +class Interpreter : public virtual Translator { +public: + virtual bool interpret_request_b(Request*) { return false;} +}; +#endif // ACCEPTOR_HH diff --git a/lily/include/crescendo.hh b/lily/include/crescendo.hh index 998c1669ee..0ebf499cdf 100644 --- a/lily/include/crescendo.hh +++ b/lily/include/crescendo.hh @@ -28,9 +28,11 @@ public: protected: SCORE_ELEM_CLONE(Crescendo); virtual Molecule*brew_molecule_p()const; + virtual Interval symbol_height()const; NAME_MEMBERS(); private: + Symbol get_symbol()const; }; diff --git a/lily/include/engraver-group.hh b/lily/include/engraver-group.hh index bf3c761a2a..8710ff53ad 100644 --- a/lily/include/engraver-group.hh +++ b/lily/include/engraver-group.hh @@ -10,7 +10,6 @@ #ifndef ENGRAVERGROUP_HH #define ENGRAVERGROUP_HH -#include "lily-proto.hh" #include "parray.hh" #include "plist.hh" #include "score-elem-info.hh" @@ -36,7 +35,7 @@ protected: virtual bool removable_b()const; public: - Input_engraver * igrav_l_; + Input_translator * itrans_l_; void check_removal(); Engraver_group_engraver(); ~Engraver_group_engraver(); diff --git a/lily/include/engraver.hh b/lily/include/engraver.hh index 9752fd75fc..5047877145 100644 --- a/lily/include/engraver.hh +++ b/lily/include/engraver.hh @@ -147,13 +147,13 @@ struct c ## init { \ return new c; \ } \ c ## init () { \ - add_Engraver(c::static_name(), globalctor); \ + add_engraver(c::static_name(), globalctor); \ \ } \ } _ ## c ## init; typedef Engraver*(*Grav_ctor)(void); -void add_Engraver(String s, Grav_ctor f); +void add_engraver(String s, Grav_ctor f); #endif // ENGRAVER_HH diff --git a/lily/include/global-performers.hh b/lily/include/global-performers.hh deleted file mode 100644 index b3e65743d9..0000000000 --- a/lily/include/global-performers.hh +++ /dev/null @@ -1,33 +0,0 @@ - -/* - global-performers.hh -- declare global performer stuff - - source file of the GNU LilyPond music typesetter - - (c) 1996, 1997 Han-Wen Nienhuys - Jan Nieuwenhuizen -*/ - -#ifndef GLOBAL_PERFORMER_HH -#define GLOBAL_PERFORMER_HH - -/** - A macro to automate administration of performers - */ -#define ADD_THIS_PERFORMER( c ) \ -struct c ## init { \ - static Performer* globalctor () \ - { \ - return new c;\ - } \ - c ## init () \ - { \ - add_Performer( c::static_name(), globalctor ); \ - } \ -} _ ## c ## init; - -// typedef Performer*(*Perf_ctor)(void); c++ ? -typedef Performer*(*Perf_ctor)(); -void add_Performer(String s, Perf_ctor f); - -#endif // GLOBAL_PERFORMER_HH diff --git a/lily/include/global-translator.hh b/lily/include/global-translator.hh index 8344d3d898..877020b10d 100644 --- a/lily/include/global-translator.hh +++ b/lily/include/global-translator.hh @@ -36,4 +36,4 @@ protected: -#endif // GLOBAL_TRANSLATOR_HH +#endif // Global_translator_HH diff --git a/lily/include/identifier.hh b/lily/include/identifier.hh index 1c0aa86207..5a0d8d5395 100644 --- a/lily/include/identifier.hh +++ b/lily/include/identifier.hh @@ -31,11 +31,9 @@ struct Identifier : public Input { NAME_MEMBERS(); void error(String); IDACCESSOR(Music, music) - IDACCESSOR(Input_engraver, igravs) - IDACCESSOR(Input_performer, iperfs) + IDACCESSOR(Input_translator, itrans) IDACCESSOR(General_script_def, script) IDACCESSOR(Symtables, symtables) - IDACCESSOR(Midi_def, mididef) IDACCESSOR(Paper_def, paperdef) IDACCESSOR(Lookup,lookup) IDACCESSOR(Real,real) @@ -68,8 +66,6 @@ declare_id_class(Music_id, Music, music); declare_id_class(Int_id, int, intid); declare_id_class(Score_id, Score, score); declare_id_class(Request_id, Request, request); -declare_id_class(Input_gravs_id, Input_engraver, igravs); -declare_id_class(Input_perfs_id, Input_performer, iperfs); -declare_id_class(Midi_def_id,Midi_def, mididef); +declare_id_class(Input_trans_id, Input_translator, itrans); declare_id_class(Paper_def_id,Paper_def, paperdef); #endif // IDENTIFIER_ diff --git a/lily/include/input-engraver.hh b/lily/include/input-engraver.hh deleted file mode 100644 index b9514a69cd..0000000000 --- a/lily/include/input-engraver.hh +++ /dev/null @@ -1,46 +0,0 @@ -/* - input-engraver.hh -- declare Input_engraver - - source file of the GNU LilyPond music typesetter - - (c) 1997 Han-Wen Nienhuys -*/ - - -#ifndef INPUT_ENGRAVER_HH -#define INPUT_ENGRAVER_HH - -#include "plist.hh" -#include "string.hh" -#include "lily-proto.hh" -#include "input.hh" -#include "string.hh" -#include "varray.hh" - -struct Input_engraver_list : public Pointer_list -{ - Input_engraver_list(Input_engraver_list const &); - Input_engraver_list(){} -}; - -struct Input_engraver : Input { - Input_engraver_list contains_igrav_p_list_; - Array consists_str_arr_; - Array alias_str_arr_; - String type_str_; - - void add(Input_engraver *); - bool is_name_b(String); - bool accept_req_b(); - bool accepts_b(String); - void print() const; - Engraver_group_engraver * get_group_engraver_p(); - Input_engraver * get_default_igrav_l(); - Input_engraver * recursive_find(String nm); - Input_engraver * find_igrav_l(String nm); -}; - - -Engraver*get_engraver_p(String s); - -#endif // INPUT_ENGRAVER_HH diff --git a/lily/include/input-performer.hh b/lily/include/input-performer.hh deleted file mode 100644 index b86514811c..0000000000 --- a/lily/include/input-performer.hh +++ /dev/null @@ -1,46 +0,0 @@ -/* - input-performer.hh -- declare Input_performer - - source file of the GNU LilyPond music typesetter - - (c) 1997 Han-Wen Nienhuys - Jan Nieuwenhuizen -*/ - -#ifndef INPUT_PERFORMER_HH -#define INPUT_PERFORMER_HH - -#include "plist.hh" -#include "string.hh" -#include "lily-proto.hh" -#include "input.hh" -#include "string.hh" -#include "varray.hh" - -struct Input_performer_list : public Pointer_list -{ - Input_performer_list(Input_performer_list const &); - Input_performer_list(){} -}; - -struct Input_performer : Input { - Input_performer_list contains_iperf_p_list_; - Array consists_str_arr_; - Array alias_str_arr_; - String type_str_; - - void add(Input_performer *); - bool is_name_b(String); - bool accept_req_b(); - bool accepts_b(String); - void print() const; - Performer_group_performer * get_group_performer_p(); - Input_performer * get_default_iperf_l(); - Input_performer * recursive_find(String nm); - Input_performer * find_iperf_l(String nm); -}; - - -Performer*get_performer_p(String s); - -#endif // INPUT_PERFORMER_HH diff --git a/lily/include/input-translator.hh b/lily/include/input-translator.hh new file mode 100644 index 0000000000..fa4790cbe8 --- /dev/null +++ b/lily/include/input-translator.hh @@ -0,0 +1,48 @@ +/* + input-translator.hh -- declare Input_translator + + source file of the GNU LilyPond music typesetter + + (c) 1997 Han-Wen Nienhuys +*/ + + +#ifndef INPUT_TRANSLATOR_HH +#define INPUT_TRANSLATOR_HH + +#include "plist.hh" +#include "string.hh" +#include "lily-proto.hh" +#include "input.hh" +#include "string.hh" +#include "varray.hh" + +struct Input_translator_list : public Pointer_list +{ + Input_translator_list(Input_translator_list const &); + Input_translator_list(){} +}; + +struct Input_translator : Input { + Input_translator_list contains_itrans_p_list_; + Array consists_str_arr_; + Array alias_str_arr_; + String base_str_; + String type_str_; + String default_id_str_; + + void add(Input_translator *); + bool is_name_b(String); + bool accept_req_b(); + bool accepts_b(String); + void print() const; + Engraver_group_engraver * get_group_engraver_p(); + // Performer_group_performer * get_group_performer_p(); + Input_translator * get_default_itrans_l(); + Input_translator * recursive_find(String nm); + Input_translator * find_itrans_l(String nm); +}; +Engraver* get_engraver_p(String); +Performer* get_performer_p(String); + +#endif // Input_translator_HH diff --git a/lily/include/lily-proto.hh b/lily/include/lily-proto.hh index 5aa2fb9998..0dbc8f0863 100644 --- a/lily/include/lily-proto.hh +++ b/lily/include/lily-proto.hh @@ -31,7 +31,6 @@ struct Chord; struct Clef_change_req; struct Clef_item; struct Clef_engraver; -struct Clef_performer; struct Col_hpositions; struct Chord; struct Colinfo; @@ -62,15 +61,13 @@ struct Idealspacing; struct Identifier; struct Interpreter; struct Input_file; -struct Input_engraver; -struct Input_performer; +struct Input_translator; struct Input_score; struct Item; struct Key; struct Key_change_req; struct Key_item; struct Key_engraver; -struct Key_performer; struct Keyword; struct Keyword_table; struct Lily_stream; @@ -88,7 +85,6 @@ struct Melodic_req; struct Meter; struct Meter_change_req; struct Meter_engraver; -struct Meter_performer; struct Midi_def; struct Midi_duration; struct Midi_header; @@ -109,13 +105,13 @@ struct Music_list; struct My_lily_parser; struct Note_column; struct Note_column_engraver; -struct Note_performer; struct Note_req; struct Note_head; struct Note_head_engraver; struct Notename_table; struct Offset; struct Output; +struct Performer; struct PCol; struct PScore; struct Paper_def; @@ -125,8 +121,6 @@ struct Pulk_voice; struct Pulk_voices; struct Rational; struct Engraver_group_engraver; -struct Performer; -struct Performer_group_performer; struct Request; struct Request_column; struct Engraver; diff --git a/lily/include/midi-def.hh b/lily/include/midi-def.hh index 788cf1dc4f..9673783d25 100644 --- a/lily/include/midi-def.hh +++ b/lily/include/midi-def.hh @@ -7,8 +7,8 @@ */ -#ifndef MIDI_DEF_HH -#define MIDI_DEF_HH +#ifndef MIDIDEF_HH +#define MIDIDEF_HH #include "lily-proto.hh" #include "real.hh" #include "string.hh" @@ -25,25 +25,18 @@ struct Midi_def { /// output file name String outfile_str_; - Assoc *real_vars_p_; - Input_performer* iperf_p_; - /// duration of whole note Real whole_seconds_f_; Midi_def(); - Midi_def( Midi_def const& midi_c_r ); + Midi_def(Midi_def const& midi_c_r); ~Midi_def(); Real duration_to_seconds_f(Moment); - Global_translator* get_global_translator_p() const; - Real get_var( String s ) const; int get_tempo_i( Moment moment ); - void print() const; - void set( Input_performer* iperf_p ); - void set_var( String s, Real r ); void set_tempo( Moment moment, int count_per_minute_i ); + void print() const; }; -#endif // MIDI_DEF_HH +#endif // MIDIDEF_HH // diff --git a/lily/include/midi-walker.hh b/lily/include/midi-walker.hh deleted file mode 100644 index 5bdea63b14..0000000000 --- a/lily/include/midi-walker.hh +++ /dev/null @@ -1,31 +0,0 @@ -/* - midi-walker.hh -- declare Midi_walker - - (c) 1996,97 Han-Wen Nienhuys, Jan Nieuwenhuizen - */ - -#ifndef MIDIWALKER_HH -#define MIDIWALKER_HH - - -#include "lily-proto.hh" - -#if 0 - -/* - sketch. . . - - It would be totally cool to share code with the Engraver hierarchy, - but this is very tough i think. - - */ - -class Voice_performer_group_performer : public Performer_group_performer { - -}; - -#endif - -#endif // MIDIWALKER_HH - - diff --git a/lily/include/music-iterator.hh b/lily/include/music-iterator.hh index 661d380d6c..25f3c7fbc3 100644 --- a/lily/include/music-iterator.hh +++ b/lily/include/music-iterator.hh @@ -12,6 +12,7 @@ #include "lily-proto.hh" #include "plist.hh" +#include "varray.hh" #include "moment.hh" class Music_iterator { @@ -22,11 +23,17 @@ protected: public: Music_iterator *daddy_iter_l_; NAME_MEMBERS(); - Translator *report_to_l_; + Arrayreport_to_l_arr_; + + Translator *report_to_l()const; static Music_iterator* static_get_iterator_p(Music*,Translator*); Music_iterator* get_iterator_p(Music*)const; void set_translator(Translator*); + void push_translator(Translator*); + void pop_translator(); + + Music_iterator(); virtual void process_and_next(Moment until); diff --git a/lily/include/my-lily-parser.hh b/lily/include/my-lily-parser.hh index 6c96382498..5ecfd7d62c 100644 --- a/lily/include/my-lily-parser.hh +++ b/lily/include/my-lily-parser.hh @@ -55,7 +55,6 @@ public: Input pop_spot(); Paper_def*default_paper(); - Midi_def*default_midi(); void do_yyparse(); void parser_error(String); void clear_notenames(); diff --git a/lily/include/note-performer.hh b/lily/include/note-performer.hh deleted file mode 100644 index c4a25de1ef..0000000000 --- a/lily/include/note-performer.hh +++ /dev/null @@ -1,24 +0,0 @@ -/* - note-performer.hh -- declare Note_performer - - (c) 1996, 1997 Han-Wen Nienhuys - Jan Nieuwenhuizen - */ - -#ifndef NOTE_PERFORMER_HH -#define NOTE_PERFORMER_HH - -#include "performer.hh" - -class Note_performer : public Performer { - Melodic_req* current_l_; - Moment off_mom_; - Moment on_mom_; - -public: - virtual void process_request() { - if ( when() == off_mom_ ) - play_event( Note_event( current_l_->pitch() ) ); -}; - -#endif // NOTE_PERFORMER_HH diff --git a/lily/include/p-col.hh b/lily/include/p-col.hh index 593420cea0..87f1584164 100644 --- a/lily/include/p-col.hh +++ b/lily/include/p-col.hh @@ -47,6 +47,7 @@ public: Real hpos; // should use ptr? bool error_mark_b_; + bool used_b_ ; // manual override.. PScore * pscore_l_; diff --git a/lily/include/paper-def.hh b/lily/include/paper-def.hh index d93246dfaf..d172c0bc38 100644 --- a/lily/include/paper-def.hh +++ b/lily/include/paper-def.hh @@ -37,7 +37,7 @@ class Paper_def { Lookup *lookup_p_; Assoc *real_vars_p_; - Input_engraver * igrav_p_; + Input_translator * itrans_p_; public: String outfile_str_; @@ -48,7 +48,7 @@ public: void reinit(); Paper_def(); void set(Lookup*); - void set (Input_engraver * ); + void set (Input_translator * ); Global_translator * get_global_translator_p()const; ~Paper_def(); Paper_def(Paper_def const&); diff --git a/lily/include/performer-group-performer.hh b/lily/include/performer-group-performer.hh deleted file mode 100644 index eeff9f63ac..0000000000 --- a/lily/include/performer-group-performer.hh +++ /dev/null @@ -1,35 +0,0 @@ -/* - performer-group-performer.hh -- declare Performer_group_performer - - (c) 1996, 1997 Han-Wen Nienhuys - Jan Nieuwenhuizen - */ - -#ifndef PERFORMER_GROUP_PERFORMER_HH -#define PERFORMER_GROUP_PERFORMER_HH - -#include "lily-proto.hh" -#include "parray.hh" -#include "plist.hh" -#include "performer.hh" -#include "translator.hh" - -/** - Group a number of performers. Usually delegates everything to its contents. -*/ - -class Performer_group_performer : public Performer, public virtual Translator { - Pointer_list perf_p_list_; - - Link_array group_l_arr_; - Link_array nongroup_l_arr_; - -public: - Input_performer* iperf_l_; - - virtual bool try_request( Request* req_l ); - virtual void add( Performer* perf_p ); -}; - -#endif // PERFORMER_GROUP_PERFORMER_HH - diff --git a/lily/include/performer.hh b/lily/include/performer.hh deleted file mode 100644 index 4fb1a298cc..0000000000 --- a/lily/include/performer.hh +++ /dev/null @@ -1,29 +0,0 @@ -/* - performer.hh -- declare Performer - - (c) 1996, 1997 Han-Wen Nienhuys - Jan Nieuwenhuizen - */ - -#ifndef PERFORMER_HH -#define PERFORMER_HH - -#include "lily-proto.hh" - -class Performer { - Performer_group_performer* daddy_perf_l_; - -public: - NAME_MEMBERS(); - Performer(); - virtual ~Performer(); - - void print() const; - - virtual void play_event( Midi_item i ); - virtual bool try_request( Request* req_l ); -}; - -#include "global-performers.hh" - -#endif // PERFORMER_HH diff --git a/lily/include/rest-column.hh b/lily/include/rest-column.hh index 8c9e4b80f5..05327cbc6c 100644 --- a/lily/include/rest-column.hh +++ b/lily/include/rest-column.hh @@ -24,8 +24,8 @@ public: void add(Note_head *); void add(Stem *); NAME_MEMBERS(); - void translate_y(Real dy); Rest_column(); + void translate_heads(int dy); protected: virtual void do_print() const; virtual void do_substitute_dependency(Score_elem*, Score_elem*); diff --git a/lily/include/score-performer.hh b/lily/include/score-performer.hh deleted file mode 100644 index 6c5eb6e350..0000000000 --- a/lily/include/score-performer.hh +++ /dev/null @@ -1,25 +0,0 @@ -/* - score-performer.hh -- declare Score_performer - - (c) 1996, 1997 Han-Wen Nienhuys - Jan Nieuwenhuizen - */ - -#ifndef SCORE_PERFORMER_HH -#define SCORE_PERFORMER_HH - -#include "performer-group-performer.hh" -#include "global-translator.hh" - -class Score_performer: - public Performer_group_performer, public Global_translator -{ - Midi_file* file_p_; - Moment prev_mom_; - -public: - virtual void play_event( Midi_item i ); - virtual void prepare( Moment mom ); -}; - -#endif // SCORE_PERFORMER_HH diff --git a/lily/include/score.hh b/lily/include/score.hh index 15486e2aaa..b11118f17f 100644 --- a/lily/include/score.hh +++ b/lily/include/score.hh @@ -62,9 +62,7 @@ public: private: void run_translator(Global_translator*); - void midi_output(); void paper_output(); - /// do midi stuff void midi(); diff --git a/lily/include/script.hh b/lily/include/script.hh index f6d41a2c2f..ef7dae9f32 100644 --- a/lily/include/script.hh +++ b/lily/include/script.hh @@ -15,8 +15,6 @@ */ class Script : public Item, public Staff_side { - int pos_i_; - Stem *stem_l_; /* *************** */ @@ -24,14 +22,12 @@ protected: Molecule *brew_molecule_p()const; virtual void do_substitute_dependency(Score_elem*,Score_elem*); virtual void do_print() const; - virtual void do_post_processing(); + virtual Interval symbol_height()const; virtual void do_pre_processing(); virtual Interval do_width() const; private: void set_default_dir(); - void set_default_index(); - Symbol symbol()const; public: General_script_def *specs_l_; diff --git a/lily/include/staff-performer.hh b/lily/include/staff-performer.hh deleted file mode 100644 index 685aa8297d..0000000000 --- a/lily/include/staff-performer.hh +++ /dev/null @@ -1,22 +0,0 @@ -/* - staff-performer.hh -- declare Staff_performer - - (c) 1996, 1997 Han-Wen Nienhuys - Jan Nieuwenhuizen - */ - -#ifndef STAFF_PERFORMER_HH -#define STAFF_PERFORMER_HH - -#include "performer-group-performer.hh" - -class Staff_performer : public Performer_group_performer -{ - int midi_track_i_; - -public: - String instrument_str() - virtual void play_event( Midi_item i ); -}; - -#endif // STAFF_PERFORMER_HH diff --git a/lily/include/staff-side.hh b/lily/include/staff-side.hh index 1d4245abbb..d62da65dad 100644 --- a/lily/include/staff-side.hh +++ b/lily/include/staff-side.hh @@ -11,13 +11,18 @@ #define STAFF_SIDE_HH #include "score-elem.hh" +#include "interval.hh" -/// A symbol which sits along the staff +/** A symbol which sits along a staff + + Should override translate_y() ? + */ class Staff_side : virtual Score_elem { Link_array support_l_arr_; int staff_size_i_; Interval support_height()const; Staff_symbol* staff_sym_l_; + int get_position_i()const; void read_staff_sym(); public: @@ -26,10 +31,13 @@ public: Vertical dir of symbol relative to staff. -1 = below staff? */ int dir_i_; + Interval sym_int_; /// follow the support inside the staff? bool inside_staff_b_; + int pos_i_; + void set_staffsym(Staff_symbol * ); Staff_side(); @@ -37,8 +45,8 @@ public: NAME_MEMBERS(); protected: + virtual Interval symbol_height() const; virtual void do_substitute_dependency(Score_elem *, Score_elem*); - int get_position_i()const; - int get_position_i(Interval)const; + virtual void do_post_processing(); }; #endif // STAFF_SIDE_HH diff --git a/lily/include/staff-sym-grav.hh b/lily/include/staff-sym-grav.hh index 3e0043ed31..b606abf014 100644 --- a/lily/include/staff-sym-grav.hh +++ b/lily/include/staff-sym-grav.hh @@ -1,5 +1,5 @@ /* - staff-sym-grav.hh -- declare + staff-sym-grav.hh -- declare Staff_sym_engraver source file of the GNU LilyPond music typesetter @@ -21,6 +21,7 @@ public: Staff_sym_engraver(); NAME_MEMBERS(); protected: + virtual ~Staff_sym_engraver(); virtual void do_process_requests(); virtual void fill_staff_info(Staff_info&); virtual void do_removal_processing(); diff --git a/lily/include/text-item.hh b/lily/include/text-item.hh index 16bffcd0d8..d4cbcff364 100644 --- a/lily/include/text-item.hh +++ b/lily/include/text-item.hh @@ -19,8 +19,6 @@ class Text_item : public Item ,public Staff_side{ public: - int pos_i_; - /// do I have width? bool fat_b_; @@ -33,9 +31,9 @@ public: protected: General_script_def * tdef_p_; - virtual void set_default_index(); + virtual Interval symbol_height()const; + virtual Molecule* brew_molecule_p() const; - virtual void do_post_processing(); virtual void do_pre_processing(); }; diff --git a/lily/include/todo-performer.hh b/lily/include/todo-performer.hh new file mode 100644 index 0000000000..e69de29bb2 diff --git a/lily/include/voice-group-performer.hh b/lily/include/voice-group-performer.hh deleted file mode 100644 index 93f8ed0495..0000000000 --- a/lily/include/voice-group-performer.hh +++ /dev/null @@ -1,25 +0,0 @@ -/* - voice-group-performer.hh -- declare Voice_group_performer - - (c) 1996, 1997 Han-Wen Nienhuys - Jan Nieuwenhuizen - */ - -#ifndef VOICE_GROUP_PERFORMER_HH -#define VOICE_GROUP_PERFORMER_HH - -#include "performer-group-performer.hh" - -class Voice_performer_group_performer : public Performer_group_performer { - -}; - -#if 0 -class Voice_performer : - public Performer_group_performer, public Interpreter -{ - -}; -#endif - -#endif // VOICE_GROUP_PERFORMER_HH diff --git a/lily/input-engraver.cc b/lily/input-engraver.cc deleted file mode 100644 index 706634b52b..0000000000 --- a/lily/input-engraver.cc +++ /dev/null @@ -1,111 +0,0 @@ -/* - input-engraver.cc -- implement Input_engraver - - source file of the GNU LilyPond music typesetter - - (c) 1997 Han-Wen Nienhuys -*/ - -#include "debug.hh" -#include "engraver.hh" -#include "input-engraver.hh" -#include "parray.hh" -#include "input-engraver.hh" -#include "engraver-group.hh" - -bool -Input_engraver::is_name_b(String n) -{ - for (int i=0; i < alias_str_arr_.size(); i++) - if (alias_str_arr_[i] == n) - return true; - return false; -} - -void -Input_engraver::print() const -{ -#ifndef NPRINT - mtor << "type " << type_str_; - mtor << "Consists of "; - for (int i=0; i< consists_str_arr_.size(); i++) - mtor << consists_str_arr_[i] << ','; - mtor << "contains " ; - for (PCursor i(contains_igrav_p_list_.top()); i.ok(); i++) - i->print(); -#endif -} - - - -Input_engraver * -Input_engraver::recursive_find(String nm) -{ - if ( is_name_b( nm) ) - return this; - - Input_engraver * r =0; - PCursor i(contains_igrav_p_list_.top()); - for (; !r &&i.ok(); i++) { - if (i->recursive_find(nm)) - r = i.ptr(); - } - - return r; -} - -Input_engraver * -Input_engraver::find_igrav_l(String nm) -{ - for (PCursor i(contains_igrav_p_list_.top()); i.ok(); i++) - if (i->is_name_b( nm)) - return i; - - return 0; -} - - -Engraver_group_engraver * -Input_engraver::get_group_engraver_p() -{ - Engraver_group_engraver * grav_p = (Engraver_group_engraver*) - get_engraver_p(type_str_); - - for (int i=0; i < consists_str_arr_.size(); i++) { - grav_p->add( get_engraver_p( consists_str_arr_[i]) ); - } - grav_p -> igrav_l_ = this; - return grav_p; -} - - -bool -Input_engraver::accept_req_b() -{ - return ! contains_igrav_p_list_.size(); -} - -void -Input_engraver::add(Input_engraver *ip) -{ - contains_igrav_p_list_.bottom().add(ip); -} - -Input_engraver* -Input_engraver::get_default_igrav_l() -{ - if ( contains_igrav_p_list_.size() ) - return contains_igrav_p_list_.top(); - else - return 0; -} - - -Input_engraver_list::Input_engraver_list(Input_engraver_list const &s) -{ - for (PCursor pc(s); pc.ok(); pc++) { - Input_engraver *q = pc; - Input_engraver *p=new Input_engraver(*q) ; - bottom().add(p); - } -} diff --git a/lily/input-performer.cc b/lily/input-performer.cc deleted file mode 100644 index 6d2ead1450..0000000000 --- a/lily/input-performer.cc +++ /dev/null @@ -1,112 +0,0 @@ -/* - input-performer.cc -- implement Input_performer - - source file of the GNU LilyPond music typesetter - - (c) 1997 Han-Wen Nienhuys - Jan Nieuwenhuizen -*/ - -#include "debug.hh" -#include "performer.hh" -#include "input-performer.hh" -#include "parray.hh" -#include "input-performer.hh" -#include "performer-group-performer.hh" - -bool -Input_performer::is_name_b(String n) -{ - for (int i=0; i < alias_str_arr_.size(); i++) - if (alias_str_arr_[i] == n) - return true; - return false; -} - -void -Input_performer::print() const -{ -#ifndef NPRINT - mtor << "type " << type_str_; - mtor << "Consists of "; - for (int i=0; i< consists_str_arr_.size(); i++) - mtor << consists_str_arr_[i] << ','; - mtor << "contains " ; - for (PCursor i(contains_iperf_p_list_.top()); i.ok(); i++) - i->print(); -#endif -} - - - -Input_performer * -Input_performer::recursive_find(String nm) -{ - if ( is_name_b( nm) ) - return this; - - Input_performer * r =0; - PCursor i(contains_iperf_p_list_.top()); - for (; !r &&i.ok(); i++) { - if (i->recursive_find(nm)) - r = i.ptr(); - } - - return r; -} - -Input_performer * -Input_performer::find_iperf_l(String nm) -{ - for (PCursor i(contains_iperf_p_list_.top()); i.ok(); i++) - if (i->is_name_b( nm)) - return i; - - return 0; -} - - -Performer_group_performer * -Input_performer::get_group_performer_p() -{ - Performer_group_performer * perf_p = (Performer_group_performer*) - get_performer_p(type_str_); - - for (int i=0; i < consists_str_arr_.size(); i++) { - perf_p->add( get_performer_p( consists_str_arr_[i]) ); - } - perf_p -> iperf_l_ = this; - return perf_p; -} - - -bool -Input_performer::accept_req_b() -{ - return ! contains_iperf_p_list_.size(); -} - -void -Input_performer::add(Input_performer *ip) -{ - contains_iperf_p_list_.bottom().add(ip); -} - -Input_performer* -Input_performer::get_default_iperf_l() -{ - if ( contains_iperf_p_list_.size() ) - return contains_iperf_p_list_.top(); - else - return 0; -} - - -Input_performer_list::Input_performer_list(Input_performer_list const &s) -{ - for (PCursor pc(s); pc.ok(); pc++) { - Input_performer *q = pc; - Input_performer *p=new Input_performer(*q) ; - bottom().add(p); - } -} diff --git a/lily/input-translator.cc b/lily/input-translator.cc new file mode 100644 index 0000000000..a90325bd5e --- /dev/null +++ b/lily/input-translator.cc @@ -0,0 +1,132 @@ +/* + input-translator.cc -- implement Input_translator + + source file of the GNU LilyPond music typesetter + + (c) 1997 Han-Wen Nienhuys +*/ + +//#include "translator-admin.hh" +#include "debug.hh" +#include "engraver.hh" +#include "input-translator.hh" +#include "parray.hh" +#include "input-translator.hh" +#include "engraver-group.hh" + +bool +Input_translator::is_name_b(String n) +{ + for (int i=0; i < alias_str_arr_.size(); i++) + if (alias_str_arr_[i] == n) + return true; + return false; +} + +void +Input_translator::print() const +{ +#ifndef NPRINT + mtor << base_str_ <<" " << type_str_<<" {\n"; + mtor << "Consists of "; + for (int i=0; i< consists_str_arr_.size(); i++) + mtor << consists_str_arr_[i] << ','; + if (contains_itrans_p_list_.size()) + mtor << "\nContains " ; + for (iter(contains_itrans_p_list_.top(), i); i.ok(); i++) + i->print(); + mtor << "}\n"; +#endif +} + + + +Input_translator * +Input_translator::recursive_find(String nm) +{ + if ( is_name_b( nm) ) + return this; + + Input_translator * r =0; + iter(contains_itrans_p_list_.top(), i); + for (; !r &&i.ok(); i++) { + if (i->recursive_find(nm)) + r = i.ptr(); + } + + return r; +} + +Input_translator * +Input_translator::find_itrans_l(String nm) +{ + for (iter(contains_itrans_p_list_.top(), i); i.ok(); i++) + if (i->is_name_b( nm)) + return i; + + return 0; +} + + +Engraver_group_engraver * +Input_translator::get_group_engraver_p() +{ + assert (base_str_ == "Engraver"); + Engraver_group_engraver * grav_p = (Engraver_group_engraver*) + get_engraver_p(type_str_); + + for (int i=0; i < consists_str_arr_.size(); i++) { + grav_p->add( get_engraver_p( consists_str_arr_[i]) ); + } + grav_p->itrans_l_ = this; + grav_p->id_str_ = default_id_str_; + return grav_p; +} + +#if 0 +Performer_group_performer* +Input_translator::get_group_performer_p() +{ + assert (base_str_ == "Performer"); + Performer_group_performer * grav_p = (Performer_group_performer*) + get_performer_p(type_str_); + + for (int i=0; i < consists_str_arr_.size(); i++) { + grav_p->add( get_performer_p( consists_str_arr_[i]) ); + } + grav_p->itrans_l_ = this; + grav_p->id_str_ = default_id_str_; + return grav_p; +} +#endif + +bool +Input_translator::accept_req_b() +{ + return ! contains_itrans_p_list_.size(); +} + +void +Input_translator::add(Input_translator *ip) +{ + contains_itrans_p_list_.bottom().add(ip); +} + +Input_translator* +Input_translator::get_default_itrans_l() +{ + if ( contains_itrans_p_list_.size() ) + return contains_itrans_p_list_.top(); + else + return 0; +} + + +Input_translator_list::Input_translator_list(Input_translator_list const &s) +{ + for (PCursor pc(s); pc.ok(); pc++) { + Input_translator *q = pc; + Input_translator *p=new Input_translator(*q) ; + bottom().add(p); + } +} diff --git a/lily/midi-def.cc b/lily/midi-def.cc index 481515a836..2f703f01f8 100644 --- a/lily/midi-def.cc +++ b/lily/midi-def.cc @@ -8,10 +8,6 @@ #include #include "misc.hh" #include "midi-def.hh" -#include "input-performer.hh" -#include "performer-group-performer.hh" -#include "assoc-iter.hh" - #include "debug.hh" // classes, alphasorted @@ -27,48 +23,27 @@ int Midi_def::num_i_s = 4; Midi_def::Midi_def() { - outfile_str_ = "lelie.midi"; - iperf_p_ = 0; - real_vars_p_ = new Assoc; - // ugh set_tempo( Moment( 1, 4 ), 60 ); + outfile_str_ = "lelie.midi"; } -Midi_def::Midi_def( Midi_def const& s ) +Midi_def::Midi_def( Midi_def const& midi_c_r ) { - whole_seconds_f_ = s.whole_seconds_f_; - iperf_p_ = s.iperf_p_ ? new Input_performer( *s.iperf_p_ ) : 0; - real_vars_p_ = new Assoc ( *s.real_vars_p_ ); - outfile_str_ = s.outfile_str_; + whole_seconds_f_ = midi_c_r.whole_seconds_f_; + outfile_str_ = midi_c_r.outfile_str_; } Midi_def::~Midi_def() { - delete iperf_p_; - delete real_vars_p_; } Real -Midi_def::duration_to_seconds_f( Moment mom ) +Midi_def::duration_to_seconds_f( Moment moment ) { - if ( !mom ) + if (!moment) return 0; - return Moment( whole_seconds_f_ ) * mom; -} - -Global_translator* -Midi_def::get_global_translator_p() const -{ - return iperf_p_->get_group_performer_p()->global_l(); -} - -Real -Midi_def::get_var( String s ) const -{ - if ( !real_vars_p_->elt_b( s ) ) - error ( "unknown midi variable `" + s + "'" ); - return real_vars_p_->elem( s ); + return Moment( whole_seconds_f_ ) * moment; } int @@ -81,32 +56,14 @@ void Midi_def::print() const { #ifndef NPRINT - mtor << "Midi {"; - mtor << "4/min: " << Real( 60 ) / ( whole_seconds_f_ * 4 ); + mtor << "Midi {4/min: " << Real( 60 ) / ( whole_seconds_f_ * 4 ); mtor << "out: " << outfile_str_; - for (Assoc_iter i( *real_vars_p_ ); i.ok(); i++) { - mtor << i.key() << "= " << i.val() << "\n"; - } mtor << "}\n"; #endif } -void -Midi_def::set( Input_performer* iperf_p ) -{ - delete iperf_p_; - iperf_p_ = iperf_p; -} - void Midi_def::set_tempo( Moment moment, int count_per_minute_i ) { whole_seconds_f_ = Moment( count_per_minute_i ) / Moment( 60 ) / moment; } - -void -Midi_def::set_var( String s, Real r ) -{ - real_vars_p_->elem( s ) = r; -} - diff --git a/lily/music-iterator.cc b/lily/music-iterator.cc index 9cbc9d7747..38cfd02349 100644 --- a/lily/music-iterator.cc +++ b/lily/music-iterator.cc @@ -26,7 +26,7 @@ Music_iterator::print() const { #ifndef NPRINT mtor << name() << "{"; - mtor << "report to " << report_to_l_ << " (" << report_to_l_->name() << ")\n"; + mtor << "report to " << report_to_l() << " (" << report_to_l()->name() << ")\n"; mtor << "next at " << next_moment() << " "; do_print(); mtor << "}\n"; @@ -36,27 +36,48 @@ Music_iterator::print() const Translator* Music_iterator::get_req_translator_l() { - assert(report_to_l_); - if (report_to_l_->is_bottom_engraver_b() ) - return report_to_l_; + assert(report_to_l()); + if (report_to_l()->is_bottom_engraver_b() ) + return report_to_l(); - set_translator( report_to_l_->get_default_interpreter() ); - return report_to_l_; + set_translator( report_to_l()->get_default_interpreter() ); + return report_to_l(); } void -Music_iterator::set_translator(Translator*trans) -{ - if (report_to_l_==trans) - return; +Music_iterator::push_translator(Translator*t) +{ + if (t) { + report_to_l_arr_.push(t); + t->iterator_count_ ++; + } +} + +void +Music_iterator::pop_translator() +{ + if (report_to_l()) { + report_to_l()->iterator_count_ --; + report_to_l_arr_.pop(); + } +} + +Translator* +Music_iterator::report_to_l()const +{ + if (! report_to_l_arr_.size() ) + return 0; + return report_to_l_arr_.top(); +} - if (report_to_l_) - report_to_l_->iterator_count_ --; - report_to_l_ = trans; - - if (report_to_l_) - report_to_l_->iterator_count_ ++; +void +Music_iterator::set_translator(Translator*reg) +{ + if (report_to_l()==reg) + return; + pop_translator(); + push_translator(reg); } void @@ -115,7 +136,7 @@ Music_iterator::static_get_iterator_p(Music *m, } } - if (! p->report_to_l_ ) + if (! p->report_to_l() ) p ->set_translator(report_l); return p; @@ -124,7 +145,7 @@ Music_iterator::static_get_iterator_p(Music *m, Music_iterator* Music_iterator::get_iterator_p(Music*m)const { - Music_iterator*p = static_get_iterator_p(m,report_to_l_); + Music_iterator*p = static_get_iterator_p(m,report_to_l()); p->daddy_iter_l_ = (Music_iterator*)this; p->construct_children(); return p; @@ -133,7 +154,6 @@ Music_iterator::get_iterator_p(Music*m)const Music_iterator::Music_iterator() { daddy_iter_l_ =0; - report_to_l_ = 0; first_b_ = true; } @@ -147,11 +167,11 @@ Chord_iterator::Chord_iterator(Chord const *chord_C) void Chord_iterator::construct_children() { - int j = 0; - for(PCursor i(chord_C_->music_p_list_.top()); //, int j = 0; - i.ok(); j++, i++) { + int j =0; + for(iter(chord_C_->music_p_list_.top(), i); i.ok(); j++, i++) { + Music_iterator * mi = get_iterator_p( i.ptr()); - set_translator(mi->report_to_l_->ancestor_l( chord_C_->multi_level_i_ )); + set_translator(mi->report_to_l()->ancestor_l( chord_C_->multi_level_i_ )); if ( mi->ok() ) children_p_list_.bottom().add( mi ); else @@ -162,16 +182,16 @@ void Chord_iterator::do_print() const { #ifndef NPRINT - for (PCursor i(children_p_list_.top()); i.ok(); i++) { + for (iter(children_p_list_.top(), i); i.ok(); i++ ) { i->print(); - } + } #endif } void Chord_iterator::process_and_next(Moment until) { - for (PCursor i(children_p_list_.top()); i.ok(); ) { + for (iter(children_p_list_.top(), i); i.ok(); ) { if (i->next_moment() == until) { i->process_and_next(until); } @@ -192,7 +212,7 @@ Moment Chord_iterator::next_moment()const { Moment next_ = INFTY; - for (PCursor i(children_p_list_.top()); i.ok(); i++) + for (iter(children_p_list_.top(), i); i.ok(); i++) next_ = next_ next_moment() ; return next_; } @@ -227,8 +247,8 @@ Voice_iterator::construct_children() { if (ok()) { iter_p_ = Music_iterator::get_iterator_p( ptr() ); - if (iter_p_->report_to_l_->depth_i() > report_to_l_->depth_i()) - set_translator(iter_p_->report_to_l_); + if (iter_p_->report_to_l()->depth_i() > report_to_l()->depth_i()) + set_translator(iter_p_->report_to_l()); } } @@ -300,7 +320,7 @@ void Request_iterator::process_and_next(Moment m) { if ( first_b_ ) { - bool gotcha = daddy_iter_l_->report_to_l_->try_request(req_l_); + bool gotcha = daddy_iter_l_->report_to_l()->try_request(req_l_); if (!gotcha) req_l_->warning("Junking request: " + String(req_l_->name())); first_b_ = false; @@ -346,12 +366,15 @@ void Change_iterator::process_and_next(Moment mom) { #if 0 + if ( id[0] == '-') { + + Engraver_group_engraver *group_l = - report_to_l_->find_get_grav_l(change_l_->type_str_, - change_l_->id_str_); + report_to_l()->find_get_translator_l(change_l_->type_str_, + change_l_->id_str_); - report_to_l_->daddy_grav_l_->remove_engraver_p(report_to_l_); - group_l->add(report_to_l_); + report_to_l()->daddy_grav_l_->remove_engraver_p(report_to_l()); + group_l->add(report_to_l()); #endif Music_iterator::process_and_next(mom); } diff --git a/lily/my-lily-lexer.cc b/lily/my-lily-lexer.cc index c3fa8a3d8f..9792102b5a 100644 --- a/lily/my-lily-lexer.cc +++ b/lily/my-lily-lexer.cc @@ -38,8 +38,7 @@ static Keyword_ent the_key_tab[]={ {"id", ID}, {"in", IN_T}, {"init_end", INIT_END}, - {"requestengraver", REQUESTENGRAVER}, - {"requestperformer", REQUESTPERFORMER}, + {"requesttranslator", REQUESTENGRAVER}, {"lyric", LYRIC}, {"key", KEY}, {"melodic" , MELODIC}, diff --git a/lily/note-performer.cc b/lily/note-performer.cc deleted file mode 100644 index 95adb43ae6..0000000000 --- a/lily/note-performer.cc +++ /dev/null @@ -1,17 +0,0 @@ -/* - note-performer.cc -- implement Note_performer - - (c) 1996, 1997 Han-Wen Nienhuys - Jan Nieuwenhuizen - */ - -#if 0 -#include "note-performer.hh" - -void -process_request() -{ - if ( when() == off_mom_ ) - play_event( Note_event( current_l_->pitch() ) ); -} -#endif diff --git a/lily/note.cc b/lily/note.cc index 2db3dd6bef..a783ca7a09 100644 --- a/lily/note.cc +++ b/lily/note.cc @@ -2,6 +2,7 @@ could use cleanup */ #include + #include "my-lily-lexer.hh" #include "string.hh" #include "real.hh" @@ -9,7 +10,6 @@ #include "musical-request.hh" #include "command-request.hh" #include "music-list.hh" -#include "script.hh" #include "identifier.hh" #include "varray.hh" #include "text-def.hh" diff --git a/lily/notehead.cc b/lily/notehead.cc index acf7bb59d1..bd7fa443ed 100644 --- a/lily/notehead.cc +++ b/lily/notehead.cc @@ -50,9 +50,9 @@ Note_head::do_pre_processing() if (rest_b_) { if (balltype_i_ == 1) - position_i_ = 6; + position_i_ += 6; else if (balltype_i_ == 2) - position_i_ = 4; + position_i_ += 4; } } diff --git a/lily/p-col.cc b/lily/p-col.cc index eb7a78ef10..7036bebee3 100644 --- a/lily/p-col.cc +++ b/lily/p-col.cc @@ -29,14 +29,15 @@ PCol::clean_breakable_items() if (!line_l_) { its.junk_links(); } - if (prebreak_p_) prebreak_p_->clean_breakable_items(); - if (postbreak_p_) postbreak_p_->clean_breakable_items(); + if (prebreak_p_) + prebreak_p_->clean_breakable_items(); + if (postbreak_p_) + postbreak_p_->clean_breakable_items(); } int PCol::rank_i() const { - assert(rank_i_ != -1); return rank_i_; } @@ -117,6 +118,7 @@ PCol::breakable_b() const PCol::PCol(PCol *parent) { + used_b_ = false; error_mark_b_ = false; daddy_l_ = parent; prebreak_p_=0; @@ -143,5 +145,5 @@ PCol::add( Item *i) bool PCol::used_b()const { - return breakable_b() || its.size(); + return breakable_b() || its.size()|| used_b_; } diff --git a/lily/p-score.cc b/lily/p-score.cc index de266d1b20..92e8d4e871 100644 --- a/lily/p-score.cc +++ b/lily/p-score.cc @@ -62,6 +62,12 @@ PScore::typeset_unbroken_spanner(Spanner*span_p) { spanners.bottom().add(span_p); span_p->pscore_l_=this; + + if ( span_p->left_col_l_) + span_p->left_col_l_->used_b_ = true; + if ( span_p->right_col_l_) + span_p->right_col_l_->used_b_ = true; + // do not init start/stop fields. These are for broken spans only. span_p->add_processing(); } @@ -164,6 +170,9 @@ PScore::print() const mtor << "\n elements: "; for (iter_top(elem_p_list_,cc); cc.ok(); cc++) cc->print(); + mtor << "\n unbroken spanners: "; + for (iter(spanners.top(), i); i.ok(); i++) + i->print(); mtor << "\ncolumns: "; for (iter_top(cols,cc); cc.ok(); cc++) cc->print(); diff --git a/lily/paper-def.cc b/lily/paper-def.cc index 65bf8eac9b..9d784050cb 100644 --- a/lily/paper-def.cc +++ b/lily/paper-def.cc @@ -14,7 +14,7 @@ #include "debug.hh" #include "lookup.hh" #include "dimen.hh" -#include "input-engraver.hh" +#include "input-translator.hh" #include "engraver-group.hh" #include "assoc-iter.hh" @@ -50,7 +50,7 @@ Paper_def::duration_to_dist(Moment d) Paper_def::Paper_def() { - igrav_p_ = 0; + itrans_p_ = 0; lookup_p_ = 0; real_vars_p_ = new Assoc; outfile_str_ = "lelie.tex"; @@ -58,14 +58,14 @@ Paper_def::Paper_def() Paper_def::~Paper_def() { - delete igrav_p_; + delete itrans_p_; delete real_vars_p_; delete lookup_p_; } Paper_def::Paper_def(Paper_def const&s) { - igrav_p_ = s.igrav_p_ ? new Input_engraver( *s.igrav_p_):0; + itrans_p_ = s.itrans_p_ ? new Input_translator( *s.itrans_p_):0; lookup_p_ = s.lookup_p_? new Lookup(*s.lookup_p_) : 0; lookup_p_->paper_l_ = this; real_vars_p_ = new Assoc (*s.real_vars_p_); @@ -73,10 +73,10 @@ Paper_def::Paper_def(Paper_def const&s) } void -Paper_def::set(Input_engraver * igrav_p) +Paper_def::set(Input_translator * itrans_p) { - delete igrav_p_; - igrav_p_ = igrav_p; + delete itrans_p_; + itrans_p_ = itrans_p; } void @@ -125,6 +125,7 @@ Paper_def::print() const mtor << "Paper {"; mtor << "out: " <print(); + itrans_p_->print(); for (Assoc_iter i(*real_vars_p_); i.ok(); i++) { mtor << i.key() << "= " << i.val() << "\n"; } @@ -142,5 +143,5 @@ Paper_def::lookup_l() Global_translator* Paper_def::get_global_translator_p() const { - return igrav_p_->get_group_engraver_p()->global_l(); + return itrans_p_->get_group_engraver_p()->global_l(); } diff --git a/lily/parser.y b/lily/parser.y index 61e87b0cd9..27472489af 100644 --- a/lily/parser.y +++ b/lily/parser.y @@ -1,17 +1,6 @@ %{ // -*-Fundamental-*- - -/* - parser.y -- lily parser - - source file of the GNU LilyPond music typesetter - - (c) 1997 Han-Wen Nienhuys - Jan Nieuwenhuizen -*/ - #include -// mmm #define MUDELA_VERSION "0.0.61" #include "script-def.hh" @@ -31,8 +20,7 @@ #include "musical-request.hh" #include "my-lily-parser.hh" #include "text-def.hh" -#include "input-engraver.hh" -#include "input-performer.hh" +#include "input-translator.hh" #include "score.hh" #include "music-list.hh" @@ -59,8 +47,7 @@ Chord * chord; Duration *duration; Identifier *id; - Input_engraver * igravs; - Input_performer * iperfs; + Input_translator * iregs; Music *music; Music_list *musiclist; Score *score; @@ -120,7 +107,6 @@ yylex(YYSTYPE *s, void * v_l) %token GROUPING %token GROUP %token REQUESTENGRAVER -%token REQUESTPERFORMER %token HSHIFT %token IN_T %token ID @@ -175,7 +161,6 @@ yylex(YYSTYPE *s, void * v_l) %token REAL_IDENTIFIER %token INT_IDENTIFIER %token SCORE_IDENTIFIER -%token MIDI_IDENTIFIER %token PAPER_IDENTIFIER %token REQUEST_IDENTIFIER %token REAL @@ -218,8 +203,7 @@ yylex(YYSTYPE *s, void * v_l) %type old_identifier %type symboldef %type symtable symtable_body -%type input_engraver_spec input_engraver_spec_body -%type input_performer_spec input_performer_spec_body +%type input_translator_spec input_translator_spec_body %left PRIORITY @@ -304,10 +288,6 @@ declaration: $$ = new Paper_def_id(*$1, $3, PAPER_IDENTIFIER); delete $1; } - | declarable_identifier '=' midi_block { - $$ = new Midi_def_id(*$1, $3, MIDI_IDENTIFIER); - delete $1; - } | declarable_identifier '=' script_definition { $$ = new Script_id(*$1, $3, SCRIPT_IDENTIFIER); delete $1; @@ -340,56 +320,36 @@ declaration: -input_engraver_spec: - REQUESTENGRAVER '{' input_engraver_spec_body '}' +input_translator_spec: + REQUESTENGRAVER '{' input_translator_spec_body '}' { $$ = $3; } ; -input_engraver_spec_body: - STRING { - $$ = new Input_engraver; - $$->type_str_ =*$1; +input_translator_spec_body: + STRING STRING { + $$ = new Input_translator; + $$->base_str_ = *$1; + $$->type_str_ =*$2; $$->set_spot ( THIS->here_input() ); delete $1; + delete $2; } - | input_engraver_spec_body ALIAS STRING ';' { - $$-> alias_str_arr_.push(*$3); - delete $3; - } - | input_engraver_spec_body CONSISTS STRING ';' { - $$-> consists_str_arr_.push(*$3); + | input_translator_spec_body ID STRING ';' { + $$-> default_id_str_ = *$3; delete $3; } - | input_engraver_spec_body CONTAINS input_engraver_spec { - $$->add($3); - } - ; - -input_performer_spec: - REQUESTPERFORMER '{' input_performer_spec_body '}' - { $$ = $3; } - ; - -input_performer_spec_body: - STRING { - $$ = new Input_performer; - $$->type_str_ =*$1; - $$->set_spot ( THIS->here_input() ); - delete $1; - } - | input_performer_spec_body ALIAS STRING ';' { + | input_translator_spec_body ALIAS STRING ';' { $$-> alias_str_arr_.push(*$3); delete $3; } - | input_performer_spec_body CONSISTS STRING ';' { + | input_translator_spec_body CONSISTS STRING ';' { $$-> consists_str_arr_.push(*$3); delete $3; } - | input_performer_spec_body CONTAINS input_performer_spec { + | input_translator_spec_body CONTAINS input_translator_spec { $$->add($3); } ; - /* SCORE */ @@ -445,7 +405,7 @@ paper_block: paper_body: /* empty */ { - $$ = THIS->default_paper(); // paper / video / engrave + $$ = THIS->default_paper(); } | paper_body OUTPUT STRING ';' { $$->outfile_str_ = *$3; delete $3; @@ -457,7 +417,7 @@ paper_body: | paper_body STRING '=' REAL ';' { $$->set_var(*$2, $4); } - | paper_body input_engraver_spec { + | paper_body input_translator_spec { $$->set( $2 ); } | paper_body error { @@ -474,8 +434,8 @@ midi_block: '{' midi_body '}' { $$ = $3; } ; -midi_body: /* empty */ { - $$ = THIS->default_midi(); // midi / audio / perform +midi_body: { + $$ = new Midi_def; } | midi_body OUTPUT STRING ';' { $$->outfile_str_ = *$3; @@ -484,14 +444,14 @@ midi_body: /* empty */ { | midi_body TEMPO notemode_duration ':' int ';' { $$->set_tempo( $3->length(), $5 ); } - | midi_body input_performer_spec { - $$->set( $2 ); - } | midi_body error { } ; + + + /* MUSIC */ @@ -1108,10 +1068,3 @@ My_lily_parser::default_paper() return id ? id->paperdef(true) : new Paper_def ; } -Midi_def* -My_lily_parser::default_midi() -{ - Identifier *id = lexer_p_->lookup_identifier( "default_midi" ); - return id ? id->mididef(true) : new Midi_def ; -} - diff --git a/lily/performer-group-performer.cc b/lily/performer-group-performer.cc deleted file mode 100644 index e8d1045e65..0000000000 --- a/lily/performer-group-performer.cc +++ /dev/null @@ -1,18 +0,0 @@ -/* - performer-group-performer.cc -- implement Performer_group_performer - - (c) 1996, 1997 Han-Wen Nienhuys - Jan Nieuwenhuizen - */ - -#if 0 - bool try_request( Request* req_l ) - { - bool hebbes_b =false; - for (int i =0; !hebbes_b && i < nongroup_l_arr_.size() ; i++) - hebbes_b =nongroup_l_arr_[i]->try_request(req_l); - if (!hebbes_b) - hebbes_b = daddy_grav_l_->try_request(req_l); - return hebbes_b ; - } -#endif diff --git a/lily/performer.cc b/lily/performer.cc deleted file mode 100644 index 1ff6b024bc..0000000000 --- a/lily/performer.cc +++ /dev/null @@ -1,48 +0,0 @@ -/* - performer.cc -- declare Performer - - (c) 1996, 1997 Han-Wen Nienhuys - Jan Nieuwenhuizen - */ - -#if 0 - -#include "lily-proto.hh" -#include "performer.hh" -#include "performer-group-performer.hh" - -IMPLEMENT_STATIC_NAME(Performer); -IMPLEMENT_IS_TYPE_B(Performer); - -Performer::Performer() -{ -} - -Performer::~Performer() -{ -} - -bool -Performer::try_request( Request* req_l ); -{ - return daddy_perf_l_->try_request( req_l ); -} - -void -Performer::play_event( Midi_item i ) -{ - daddy_perf_l_->play_event( i ); -} - -void -Performer::print() const -{ -#ifndef NPRINT - mtor << "\n" << name() << " {"; - do_print(); - mtor << "}"; -#endif -} - - -#endif diff --git a/lily/rest-collision.cc b/lily/rest-collision.cc index e3b7807f6d..6408a96450 100644 --- a/lily/rest-collision.cc +++ b/lily/rest-collision.cc @@ -64,7 +64,6 @@ Rest_collision::do_post_processing() if (!(stem_l->beams_left_i_ || stem_l->beams_right_i_)) return; - Real inter_f = paper()->internote_f(); int dir_i = rest_l_arr_[0]->dir_i_; int midpos = 4; #if 1 @@ -75,8 +74,7 @@ Rest_collision::do_post_processing() #else // nogo: stem_start not set for rests? int pos = (stem_l->stem_start_f() - midpos) + dir_i * 2; #endif - Real dy = pos * inter_f; - rest_l_arr_[0]->translate_y(dy); + rest_l_arr_[0]->translate_heads(pos); } void @@ -97,39 +95,41 @@ Rest_collision::do_pre_processing() if (rest_l_arr_.size() + ncol_l_arr_.size() < 2 ) return; - Real inter_f = paper()->internote_f(); - // meisjes met meisjes if (!ncol_l_arr_.size()) { - Real dy = rest_l_arr_.size() > 2 ? 6 * inter_f : 4 * inter_f; - rest_l_arr_[0]->translate_y(dy); + int dy = rest_l_arr_.size() > 2 ? 6 : 4; + rest_l_arr_[0]->translate_heads(dy); // top is last element... - rest_l_arr_.top()->translate_y(-dy); + rest_l_arr_.top()->translate_heads(-dy); } // meisjes met jongetjes else { #if 0 // breendet: rests go always under // geen gemug, trug op je rug int dir_i = -1; - rest_l_arr_[0]->translate_y(dir_i * 3 * inter_f); + rest_l_arr_[0]->translate_heads(dir_i * 3 ); #else // int dir_i = - ncol_l_arr_[0]->dir_i_; int dir_i = rest_l_arr_[0]->dir_i_; // hope it's 4: if it works->doco int midpos = 4; - // minimum move + + // minimum move int minpos = 4; + // quart rest height + // UGH Should get dims from table! int size_i = 6; + int sep_i = 3 + size_i / 2; for (int i = 0; i < ncol_l_arr_.size(); i++) { // how to know whether to sort? ncol_l_arr_[i]->sort(); for ( int j = 0; j < ncol_l_arr_[i]->head_l_arr_.size(); j++ ) - minpos = minpos >? dir_i * ( ncol_l_arr_[i]->head_l_arr_[j]->position_i_ - midpos ) + sep_i; + minpos = minpos >? dir_i * + (ncol_l_arr_[i]->head_l_arr_[j]->position_i_ -midpos ) + sep_i; } - Real dy = dir_i * minpos * inter_f; - rest_l_arr_[0]->translate_y(dy); + rest_l_arr_[0]->translate_heads(dir_i * minpos ); #endif } } diff --git a/lily/rest-column.cc b/lily/rest-column.cc index 219b83307b..a58e73846f 100644 --- a/lily/rest-column.cc +++ b/lily/rest-column.cc @@ -56,12 +56,14 @@ Rest_column::do_substitute_dependency(Score_elem*o,Score_elem*n) (n)? (Note_head*)n->item() : 0); } -/* - Are you sure. Horizontal_vertical_group_item::translate_y could handle this + +/** + translate the rest symbols */ void -Rest_column::translate_y(Real dy_f) +Rest_column::translate_heads(int dy_i) { for (int i=0; i < head_l_arr_.size(); i++) - head_l_arr_[i]->translate_y(dy_f); + head_l_arr_[i]->position_i_ += dy_i; } + diff --git a/lily/score-grav.cc b/lily/score-grav.cc index f837dba557..ee3b325a00 100644 --- a/lily/score-grav.cc +++ b/lily/score-grav.cc @@ -1,5 +1,5 @@ /* - score-grav.cc -- implement Score_engraver + score-reg.cc -- implement Score_engraver source file of the GNU LilyPond music typesetter diff --git a/lily/score-performer.cc b/lily/score-performer.cc deleted file mode 100644 index ed96521437..0000000000 --- a/lily/score-performer.cc +++ /dev/null @@ -1,24 +0,0 @@ -/* - score-performer.cc -- implement Score_performer - - (c) 1996, 1997 Han-Wen Nienhuys - Jan Nieuwenhuizen - */ - -#if 0 - -#include "score-performer.hh" - -void -Score_performer::play_event( Midi_item i ) -{ - file_p_->output( i ); -} - -void -Score_performer::prepare(Moment m) -{ - file_p_->move( mom.prev_ ); -} - -#endif diff --git a/lily/score.cc b/lily/score.cc index 38b30b5043..fd23b08522 100644 --- a/lily/score.cc +++ b/lily/score.cc @@ -60,37 +60,8 @@ void Score::process() { paper(); - midi(); } -void -Score::midi() -{ -#if 0 - if (!midi_p_) - return; - - *mlog << "\nCreating elements ..." << flush; -// pscore_p_ = new PScore(paper_p_); - - Global_translator * score_trans= paper_p_->get_global_translator_p(); - run_translator( score_trans ); - delete score_trans; - - if( errorlevel_i_){ - // should we? hampers debugging. - warning("Errors found, /*not processing score*/"); -// return; - } - print(); - *mlog << endl; -// pscore_p_->process(); - - // output - midi_output(); -#endif -} - void Score::paper() { @@ -122,6 +93,7 @@ Score::paper() // output paper_output(); + } /** @@ -247,7 +219,7 @@ Score::paper_output() } void -Score::midi_output() +Score::midi() { #if 0 if (!midi_p_) diff --git a/lily/script.cc b/lily/script.cc index bf01359399..c74afdb1fb 100644 --- a/lily/script.cc +++ b/lily/script.cc @@ -43,7 +43,6 @@ Script::Script() specs_l_ = 0; inside_staff_b_ = false; stem_l_ = 0; - pos_i_ = 0; dir_i_ = 0; } @@ -64,11 +63,6 @@ Script::set_default_dir() assert(dir_i_); } -void -Script::set_default_index() -{ - pos_i_ = get_position_i(specs_l_->get_atom(paper(), dir_i_).extent().y); -} Interval Script::do_width() const @@ -84,10 +78,10 @@ Script::do_pre_processing() inside_staff_b_ = specs_l_->inside_b(); } -void -Script::do_post_processing() +Interval +Script::symbol_height()const { - set_default_index(); + return specs_l_->get_atom(paper(), dir_i_).extent().y; } Molecule* diff --git a/lily/spanner-elem-group.cc b/lily/spanner-elem-group.cc index 9ec544e52d..f0b76a277c 100644 --- a/lily/spanner-elem-group.cc +++ b/lily/spanner-elem-group.cc @@ -22,6 +22,9 @@ Spanner_elem_group::do_width() const void Spanner_elem_group::do_print() const { +#ifndef NPRINT + Spanner::do_print(); Horizontal_vertical_group::do_print(); +#endif } diff --git a/lily/spanner.cc b/lily/spanner.cc index 2d071cb8ad..f66aa49497 100644 --- a/lily/spanner.cc +++ b/lily/spanner.cc @@ -17,8 +17,12 @@ IMPLEMENT_IS_TYPE_B1(Spanner,Score_elem); void Spanner::do_print()const { +#ifndef NPRINT + mtor << "Between col " << + left_col_l_->rank_i() << ", " << right_col_l_->rank_i() ; if (broken_into_l_arr_.size()) mtor << "with broken pieces\n"; +#endif } void diff --git a/lily/staff-performer.cc b/lily/staff-performer.cc deleted file mode 100644 index 856551f90a..0000000000 --- a/lily/staff-performer.cc +++ /dev/null @@ -1,25 +0,0 @@ -/* - staff-performer.cc -- implement Staff_performer - - (c) 1996, 1997 Han-Wen Nienhuys - Jan Nieuwenhuizen - */ - -#if 0 - -#include "staff-performer.hh" - -String -Staff_performer::instrument_str() -{ - return Translator::id_str_; -} - -void -Staff_performer::play_event( Midi_item i ) -{ - i.track_i_ = midi_track_i_; - Performer::play_event( i ); -} - -#endif diff --git a/lily/staff-side.cc b/lily/staff-side.cc index e7d8ccebf6..9cb61495f9 100644 --- a/lily/staff-side.cc +++ b/lily/staff-side.cc @@ -22,6 +22,8 @@ Staff_side::set_staffsym(Staff_symbol* s_l) Staff_side::Staff_side() { + pos_i_ =0; + sym_int_ = Interval(0,0); staff_size_i_ = 0; staff_sym_l_=0; dir_i_ =0; @@ -86,16 +88,20 @@ Staff_side::get_position_i()const return int(rint(Real(y)/inter_f)); // should ret a float? } -int -Staff_side::get_position_i(Interval sym_dim) const -{ - int i= get_position_i(); - if (dir_i_) - return i+ int(rint(- sym_dim[-dir_i_] / paper()->internote_f())); - else - return i; +Interval +Staff_side::symbol_height() const +{ + return Interval(0,0); } +void +Staff_side::do_post_processing() +{ + sym_int_ = symbol_height(); + pos_i_ = get_position_i( ); + if (dir_i_) + pos_i_ += int(rint(- sym_int_[-dir_i_] / paper()->internote_f())); +} void Staff_side::do_substitute_dependency(Score_elem*o, Score_elem*n) diff --git a/lily/staff-sym-grav.cc b/lily/staff-sym-grav.cc index 2e093b0c71..2894a34120 100644 --- a/lily/staff-sym-grav.cc +++ b/lily/staff-sym-grav.cc @@ -18,6 +18,11 @@ Staff_sym_engraver::fill_staff_info(Staff_info&i) i.staff_sym_l_ = span_p_; } +Staff_sym_engraver::~Staff_sym_engraver() +{ + assert( !span_p_); +} + Staff_sym_engraver::Staff_sym_engraver() { span_p_ = 0; diff --git a/lily/staff-sym.cc b/lily/staff-sym.cc index b83406c3a9..718bddbc58 100644 --- a/lily/staff-sym.cc +++ b/lily/staff-sym.cc @@ -24,7 +24,10 @@ IMPLEMENT_IS_TYPE_B1(Staff_symbol,Spanner); void Staff_symbol::do_print()const { +#ifndef NPRINT + Spanner::do_print(); mtor << "lines: " << no_lines_i_; +#endif } Molecule* diff --git a/lily/template3.cc b/lily/template3.cc index d100cbce98..82d84d1965 100644 --- a/lily/template3.cc +++ b/lily/template3.cc @@ -8,12 +8,10 @@ #include "symbol.hh" #include "request.hh" -#include "input-engraver.hh" -#include "input-performer.hh" +#include "input-translator.hh" #include "molecule.hh" #include "plist.tcc" #include "pcursor.tcc" IPL_instantiate(Atom); -IPL_instantiate(Input_engraver); -IPL_instantiate(Input_performer); +IPL_instantiate(Input_translator); diff --git a/lily/template6.cc b/lily/template6.cc index 38344df600..2fbc121679 100644 --- a/lily/template6.cc +++ b/lily/template6.cc @@ -1,7 +1,5 @@ #include "proto.hh" #include "plist.tcc" #include "engraver.hh" -#include "performer.hh" IPL_instantiate(Engraver); -IPL_instantiate(Performer); diff --git a/lily/text-item.cc b/lily/text-item.cc index 42ae3994c4..a8cddcfade 100644 --- a/lily/text-item.cc +++ b/lily/text-item.cc @@ -19,7 +19,6 @@ Text_item::Text_item(General_script_def*tdef_l, int d) dir_i_ = d; fat_b_ = false; tdef_p_ = tdef_l->clone(); - pos_i_ =0; } Text_item::~Text_item() @@ -27,13 +26,6 @@ Text_item::~Text_item() delete tdef_p_; } -void -Text_item::set_default_index() -{ - pos_i_ = get_position_i( - tdef_p_->get_atom(paper(), dir_i_).extent().y ); -} - void Text_item::do_pre_processing() { @@ -41,12 +33,11 @@ Text_item::do_pre_processing() dir_i_ = -1; } -void -Text_item::do_post_processing() +Interval +Text_item::symbol_height()const { - set_default_index(); + return tdef_p_->get_atom(paper(), dir_i_).sym_.dim.y; } - Molecule* Text_item::brew_molecule_p() const diff --git a/lily/voice-group-performer.cc b/lily/voice-group-performer.cc deleted file mode 100644 index 74df78ef5a..0000000000 --- a/lily/voice-group-performer.cc +++ /dev/null @@ -1,12 +0,0 @@ -/* - voice-group-performer.cc -- implement Voice_group_performer - - (c) 1996, 1997 Han-Wen Nienhuys - Jan Nieuwenhuizen - */ - -#if 0 - -#include "voice-group-performer.hh" - -#endif diff --git a/make/lilypond.lsm b/make/lilypond.lsm index 5f3c765ef1..991a9f5987 100644 --- a/make/lilypond.lsm +++ b/make/lilypond.lsm @@ -2,8 +2,8 @@ Begin3 Title: LilyPond -Version: 0.0.73pre -Entered-date: 07/03/97 +Version: 0.0.74pre +Entered-date: 07/08/97 Description: LilyPond is a program which converts a music-script (mudela) into TeX output, or MIDI to produce multi-staff scores. Features include multiple meters, clefs, keys, lyrics, versatile input-language, cadenzas @@ -13,7 +13,7 @@ Author: hanwen@stack.nl (Han-Wen Nienhuys) jan@digicash.com (Jan Nieuwenhuizen) Maintained-by: hanwen@stack.nl (Han-Wen Nienhuys) Primary-site: pcnov095.win.tue.nl /pub/lilypond/ - 300k lilypond-0.0.73pre.tar.gz + 300k lilypond-0.0.74pre.tar.gz Alternate-site: Original-site: Platform: unix/win32, GNU C++ diff --git a/make/lilypond.spec b/make/lilypond.spec index 4939bf97e4..9d83eea9c2 100644 --- a/make/lilypond.spec +++ b/make/lilypond.spec @@ -1,9 +1,9 @@ Name: lilypond -Version: 0.0.73pre +Version: 0.0.74pre Release: 1 Copyright: GPL Group: Applications/Publishing -Source0: pcnov095.win.tue.nl:/pub/lilypond/lilypond-0.0.73pre.tar.gz +Source0: pcnov095.win.tue.nl:/pub/lilypond/lilypond-0.0.74pre.tar.gz Summary: A preprocessor to make TeX typeset music. URL: http://www.stack.nl/~hanwen/lilypond Packager: Han-Wen Nienhuys @@ -20,7 +20,7 @@ voices. %prep %setup %build -configure --enable-checking --disable-debugging --enable-printing --prefix=/usr --enable-optimise --enable-shared +./configure --enable-checking --disable-debugging --enable-printing --prefix=/usr --enable-optimise --enable-shared make all %install rm -rf $RPM_BUILD_ROOT diff --git a/make/lilypond.spec.in b/make/lilypond.spec.in index 9eb34ddb3c..76b484ae60 100644 --- a/make/lilypond.spec.in +++ b/make/lilypond.spec.in @@ -20,7 +20,7 @@ voices. %prep %setup %build -configure --enable-checking --disable-debugging --enable-printing --prefix=/usr --enable-optimise --enable-shared +./configure --enable-checking --disable-debugging --enable-printing --prefix=/usr --enable-optimise --enable-shared make all %install rm -rf $RPM_BUILD_ROOT -- 2.39.2