]> git.donarmstrong.com Git - lilypond.git/blobdiff - lily/include/simple-spacer.hh
release: 1.5.29
[lilypond.git] / lily / include / simple-spacer.hh
index 80f7a32904e504633d5e8e80a4b18e742949fc48..1b963650e07184f4abe07a1814800e24d58808b3 100644 (file)
@@ -3,7 +3,7 @@
   
   source file of the GNU LilyPond music typesetter
   
-  (c) 1999 Han-Wen Nienhuys <hanwen@cs.uu.nl>
+  (c) 1999--2002 Han-Wen Nienhuys <hanwen@cs.uu.nl>
   
  */
 
@@ -11,7 +11,7 @@
 #define SIMPLE_SPACER_HH
 
 #include "parray.hh"
-#include "line-spacer.hh"
+#include "lily-proto.hh"
 
 
 struct Spring_description
@@ -24,7 +24,8 @@ struct Spring_description
 
   Real length (Real force) const;
   Spring_description ();
-  Real energy_f (Real) const;
+
+  bool sane_b () const;
 };
 
 /**
@@ -59,17 +60,21 @@ struct Spring_description
 
 
    Perhaps this is not a bad thing, because the 1st looks better anyway.  */
-struct Simple_spacer: public Line_spacer
+struct Simple_spacer
 {
   Array<Spring_description> springs_;
+  Link_array<Grob> spaced_cols_;
+  Link_array<Grob> loose_cols_;
   Real force_f_;
+  Real indent_f_;
+  Real line_len_f_;
+  Real default_space_f_;
+  int active_count_;
 
   Simple_spacer ();
   
-  virtual void solve (Column_x_positions *) const;
-  virtual void lower_bound_solution (Column_x_positions *) const;
-  virtual void add_columns (Link_array<Paper_column>);
-    
+  void solve (Column_x_positions *) const;
+  void add_columns (Link_array<Grob>);
   void my_solve_linelen ();
   void my_solve_natural_len ();
   Real active_springs_stiffness () const;
@@ -79,8 +84,6 @@ struct Simple_spacer: public Line_spacer
   Real active_blocking_force ()const;
   Real configuration_length ()const;
   void set_active_states ();
-  Real energy_f () const;
-
   bool active_b () const;
 };