]> git.donarmstrong.com Git - lilypond.git/blobdiff - hdr/stem.hh
partial: 0.0.38.jcn
[lilypond.git] / hdr / stem.hh
index 372011d1b1171d2ee4096da6b4fe510f55af8c93..2aafd66074c0ba1db2f5de7faa5eccd3b81d4c0f 100644 (file)
@@ -1,18 +1,28 @@
 /*
-  stem.hh -- 
+  stem.hh -- declare Stem
 
-  (c) 1996 Han-Wen Nienhuys
+  (c) 1996,97 Han-Wen Nienhuys
 */
 
 #ifndef STEM_HH
 #define STEM_HH
 #include "item.hh"
+#include "varray.hh"
+#include "moment.hh"
 
-/// the rule attached to the ball
-struct Stem : public Item {
-    Real note_length;
-    
-    // heads the stem encompasses (positions)
+
+/**the rule attached to the ball.
+  takes care of:
+
+  \begin{itemize}
+  \item the rule
+  \item the flag
+  \item up/down position.
+  \end{itemize}
+  */
+
+struct Stem : Item {
+    /// heads that the stem encompasses (positions)
     int minnote, maxnote;
 
     /// false if in beam
@@ -24,51 +34,47 @@ struct Stem : public Item {
     /// needed for determining direction/length
     int staff_center;
 
-    // extent of the stem (positions)
-    Real bot, top;
-    /**
+
+    /**extent of the stem (positions).
       fractional, since Beam has to adapt them.
       */
 
+    Real bot, top;
     Real stemlen;
     
     /// flagtype? 4 none, 8 8th flag, 0 = beam.
     int flag;
 
-    ///geen gedonder, jij gaat onder
-    int dir;
+
     /**
+      geen gedonder, jij gaat onder.
        -1 stem points down, +1: stem points up
        */
 
+    int dir;
     Real stem_xoffset;
-    /****************/
+    
+    Array<Notehead*> heads;
 
+    /* *************** */
+    Stem(int center); //, Moment duration);
+    
     /// ensure that this Stem also encompasses the Notehead #n#
     void add(Notehead*n);
-    Real hpos()const;
-    void print() const;
+    const char * name() const;
+
+    Real hindex()const;
+    void do_print() const;
     void set_stemend(Real);
+    int get_default_dir();
     void set_default_dir();
     void set_default_stemlen();
     void set_default_extents();
-    void postprocess();
-    void preprocess();
-    Stem(int center, Real duration);
+    void set_noteheads();
+    void do_pre_processing();
 
     Interval width() const;
-private:
 
-    void brew_molecole();
+    Molecule* brew_molecule_p() const;
 };
-/**
-  takes care of:
-
-  \begin{itemize}
-  \item the rule
-  \item the flag
-  \item up/down position.
-  \end{itemize}
-  */
-
 #endif