]> git.donarmstrong.com Git - lilypond.git/commitdiff
lilypond-1.3.94
authorfred <fred>
Tue, 26 Mar 2002 23:26:07 +0000 (23:26 +0000)
committerfred <fred>
Tue, 26 Mar 2002 23:26:07 +0000 (23:26 +0000)
lily/dimension-cache.cc
lily/include/dimension-cache.hh

index 96a51cde5a8ca395b4a4cfeac0dbeab46dad02f9..da14511f52d1f30f694f06f51362d128975595c6 100644 (file)
 Dimension_cache::Dimension_cache (Dimension_cache const &d)
 {
   init();
-  extent_callback_l_ = d.extent_callback_l_;
+  dimension_ = d.dimension_;
+
   offset_ = d.offset_;
-  off_callbacks_ = d.off_callbacks_;
+  offset_callbacks_ = d.offset_callbacks_;
+  offsets_left_ = d.offsets_left_;
   parent_l_ = d.parent_l_;  
 }
 
@@ -29,13 +31,13 @@ Dimension_cache::Dimension_cache ()
 void
 Dimension_cache::init()
 {
-  extent_callback_l_ =0;
-  offset_ =0.0;
+  dimension_ = SCM_EOL;
+
+  offsets_left_ = 0;
+  offset_callbacks_ = SCM_EOL;
   offset_ =0.0;
   
-  dim_.set_empty ();
   parent_l_ =0;
-  valid_b_ = false;
 }
 
 
index ca4fad3c16c370485ce2a3c6b5b51d0e6f819a39..5ae4845fd05daef863900eaeaf2a889a7d4dec1b 100644 (file)
 #include "lily-proto.hh"
 #include "parray.hh"
 #include "dimension-cache-callback.hh"
+#include "lily-guile.hh"
 
 
 /**
-  Adminstration of offset dimension info. 
- */
+  Adminstration of offset dimension info.
+*/
 struct Dimension_cache
 {
-  bool valid_b_;
-  Interval dim_;
+  /*
+    Multi typed:
+
+     - cons: interval
+     - procedure: callback
+     - else: empty
+   */
+  SCM dimension_;
+
   /**
     The offset wrt. to the center of #parent_l_#
    */
 
   Real offset_;
-
-
+  SCM offset_callbacks_;
   
-  Array<Offset_callback> off_callbacks_;
+  char offsets_left_;
 
   /**
      What to call to find extent.  Nil means empty. 
    */
-  Dim_cache_callback extent_callback_l_;
   Score_element * parent_l_;
 
   Dimension_cache(Dimension_cache const&);