]> git.donarmstrong.com Git - lilypond.git/blobdiff - lily/rest-column.cc
release: 0.1.8
[lilypond.git] / lily / rest-column.cc
index 8d0963482abc49ab7be4d6ccdddd5a5801111a96..3b17ca9ac7cd8dc8e04576b0d74699245cc82703 100644 (file)
@@ -6,38 +6,23 @@
   (c) 1997 Han-Wen Nienhuys <hanwen@stack.nl>
 */
 
+#include "debug.hh"
 #include "rest-column.hh"
 #include "note-head.hh"
 #include "rest-column.hh"
+#include "stem.hh"
 
-void
-Rest_column::add(Note_head *n_l)
-{
-    add_support(n_l);
-    head_l_arr_.push(n_l);
-}
-
-void
-Rest_column::translate_y(Real dy_f)
-{
-    for (int i=0; i < head_l_arr_.size(); i++)
-       head_l_arr_[i]->translate(Offset(0,dy_f));
-}
 
-IMPLEMENT_STATIC_NAME(Rest_column);
+IMPLEMENT_IS_TYPE_B1(Rest_column,Head_column);
 
-Rest_column::Rest_column()
-{
-    dir_i_ = 0;
-}
-    
 
+/**
+  translate the rest symbols
+ */
 void
-Rest_column::do_substitute_dependency(Score_elem*o,Score_elem*n)
+Rest_column::translate_heads (int dy_i)
 {
-    Script_column::do_substitute_dependency(o,n);
-    if (o->name() == Note_head::static_name()) {
-       head_l_arr_.substitute( (Note_head*)o->item(), 
-                               (n)? (Note_head*)n->item() : 0);
-    }
+    for (int i=0; i < head_l_arr_.size(); i++)
+       head_l_arr_[i]->position_i_ += dy_i;
 }
+