From: fred Date: Thu, 7 Nov 1996 23:19:21 +0000 (+0000) Subject: lilypond-0.0.9 X-Git-Tag: release/1.5.59~6870 X-Git-Url: https://git.donarmstrong.com/?a=commitdiff_plain;h=d05ac30531f882a5ce40a21924eb23b946b2c37a;p=lilypond.git lilypond-0.0.9 --- diff --git a/hdr/rest.hh b/hdr/rest.hh new file mode 100644 index 0000000000..c5d0d7f995 --- /dev/null +++ b/hdr/rest.hh @@ -0,0 +1,33 @@ +/* + rest.hh -- part of LilyPond + + (c) 1996 Han-Wen Nienhuys +*/ + +#ifndef REST_HH +#define REST_HH +#include "item.hh" + +/// ball at the end of the stem +struct Rest : public Item +{ + int dots; + int balltype; + + /****************/ + + void preprocess(); + Rest(int dur,int dots); + void print()const; +private: + void brew_molecole(); +}; +/** + takes care of: + + * help lines + * proper placing of dots + + */ +#endif + diff --git a/hdr/sccol.hh b/hdr/sccol.hh new file mode 100644 index 0000000000..f18b659e7e --- /dev/null +++ b/hdr/sccol.hh @@ -0,0 +1,49 @@ +/* + sccol.hh -- part of LilyPond + + (c) 1996 Han-Wen Nienhuys +*/ + +#ifndef SCCOL_HH +#define SCCOL_HH +#include "pcol.hh" + + +struct Score_column { + + /// indirection to column + PCol * pcol; + /// length of notes/rests in this column + svec durations; + + Real when; + + /// + bool musical; + + /****************/ + + Score_column(Real when); + static int compare(Score_column & c1, Score_column &c2) { + return sgn(c1.when - c2.when); + } + void set_breakable() { + pcol->set_breakable(); + } + bool used(); + void print() const; +}; +/** + + When typesetting hasn't started on PScore yet, the columns which + contain data have a rhythmical position. Score_column is the type + with a rhythmical time attached to it. The calculation of + idealspacing is done with data in these columns. (notably: the + #durations# field) + + */ + +instantiate_compare(Score_column&, Score_column::compare); + +#endif // SCCOL_HH + diff --git a/src/notename.cc b/src/notename.cc new file mode 100644 index 0000000000..8ebc4df244 --- /dev/null +++ b/src/notename.cc @@ -0,0 +1,30 @@ +#include "glob.hh" +#include "string.hh" + + +/// change this along with lex file for other notenames. +const char *notetab[] = +{ +"ceses", "ces", "c", "cis", "cisis", +"deses", "des", "d", "dis", "disis", +"eses", "es", "e", "eis", "eisis", +"feses", "fes", "f", "fis", "fisis", +"geses", "ges", "g", "gis", "gisis", +"ases", "as", "a", "ais", "aisis", +"beses", "bes", "b", "bis", "bisis", +0 +}; + +void +lookup_notename(int &large, int &small, String s) +{ + int i; + for (i =0; notetab[i]; i++) + if (s == notetab[i]) + { + large = i /5; + small = i %5 - 2; + return; + } + assert(false); +}