]> git.donarmstrong.com Git - lilypond.git/blobdiff - lily/paper-score.cc
Update using bison-CVS.
[lilypond.git] / lily / paper-score.cc
index 430cd52c57fefa94bbd873fbe1688bf6493f5ddd..800aa132ed77023f08d0388d5e9c4c7933de4124 100644 (file)
@@ -3,32 +3,27 @@
 
   source file of the GNU LilyPond music typesetter
 
-  (c) 1996--2004 Han-Wen Nienhuys <hanwen@cs.uu.nl>
+  (c) 1996--2005 Han-Wen Nienhuys <hanwen@cs.uu.nl>
 */
 
-#include "score.hh"
-#include "main.hh"
-#include "warn.hh"
-#include "font-metric.hh"
-#include "spanner.hh"
-#include "paper-def.hh"
-#include "system.hh"
-#include "paper-column.hh"
 #include "paper-score.hh"
-#include "paper-column.hh"
-#include "scm-hash.hh"
+
+#include "all-font-metrics.hh"
 #include "gourlay-breaking.hh"
-//#include "paper-outputter.hh"
+#include "main.hh"
 #include "misc.hh"
-#include "all-font-metrics.hh"
-
-#include "stencil.hh"
+#include "output-def.hh"
 #include "paper-book.hh"
-#include "ly-module.hh"
+#include "paper-column.hh"
+#include "scm-hash.hh"
+#include "score.hh"
+#include "stencil.hh"
+#include "system.hh"
+#include "warn.hh"
 
 Paper_score::Paper_score ()
 {
-  paper_ = 0;
+  layout_ = 0;
   system_ = 0;
 }
 
@@ -53,10 +48,10 @@ Paper_score::typeset_line (System *system)
 Array<Column_x_positions>
 Paper_score::calc_breaking ()
 {
-  Break_algorithm *algorithm=0;
+  Break_algorithm *algorithm = 0;
   Array<Column_x_positions> sol;
 
-  algorithm = new Gourlay_breaking ;
+  algorithm = new Gourlay_breaking;
   algorithm->set_pscore (this);
   sol = algorithm->solve ();
   delete algorithm;
@@ -67,30 +62,31 @@ Paper_score::calc_breaking ()
 SCM
 Paper_score::process (String)
 {
-  if (verbose_global_b)
-    progress_indication (_f ("Element count %d (spanners %d) ",
+  if (be_verbose_global)
+    message (_f ("Element count %d (spanners %d) ",
                             system_->element_count (),
                             system_->spanner_count ()));
 
-  progress_indication (_ ("Preprocessing graphical objects...") + " ");
+  message (_ ("Preprocessing graphical objects...") + " ");
 
   /* FIXME: Check out why we need this - removing gives assertion failures
      down the road.
-     
+
      doubly, also done in Score_engraver */
   Link_array<Grob> pc (system_->columns ());
   pc[0]->set_property ("breakable", SCM_BOOL_T);
   pc.top ()->set_property ("breakable", SCM_BOOL_T);
-    
+
   system_->pre_processing ();
+
   Array<Column_x_positions> breaking = calc_breaking ();
   system_->break_into_pieces (breaking);
   SCM lines = system_->get_lines ();
-  progress_indication ("\n");
 
-  /* Only keep result stencils in lines_, *title_; delete all grobs.  */
-  systems_ = SCM_EOL;
-  
+  /*
+    retain Grobs, since they are pointed to by the point & click data
+    structures, and are not marked fully, because child -> parent
+    links aren't marked.
+   */
   return lines;
 }