]> git.donarmstrong.com Git - lilypond.git/blobdiff - lily/include/collision.hh
release: 1.3.88
[lilypond.git] / lily / include / collision.hh
index 844496a855546467bb8db9f9fbb21a6860da6fd8..650a80f14fbf31ea34175f139e8514ff5f68c0d5 100644 (file)
@@ -1,25 +1,50 @@
 /*
   collision.hh -- declare Collision
 
-  source file of the LilyPond music typesetter
+  source file of the GNU LilyPond music typesetter
 
-  (c) 1997 Han-Wen Nienhuys <hanwen@stack.nl>
+  (c)  1997--2000 Han-Wen Nienhuys <hanwen@cs.uu.nl>
 */
 
 
 #ifndef COLLISION_HH
 #define COLLISION_HH
+
 #include "lily-proto.hh"
-#include "item.hh"
+#include "lily-guile.hh"
+
+
+/**
+  Resolve conflicts between various Note_columns (chords).
+  
+  TODO 
+
+  * multistaff support (see Chlapik: equal noteheads should be on the
+  same hpos.)  
+
+  * Make interface of this, similar to align-interface.
+  
+  Properties:
 
-class Collision : public Item {
-    Array<Note_column*> clash_l_arr_;
-protected:
-    virtual void do_pre_processing();
+  elements -- (see Axis_group_interface)
+
+  merge-differently-dotted -- merge black noteheads with differing dot count.
+
+  horizontal-shift -- integer that identifies ranking of note-column for horizontal shifting.
+  
+  force-hshift -- amount of collision_note_width that overides automatic collision settings.
+  Read and removed from elements.
+
+  note-width -- unit for horizontal translation, measured in staff-space.
+  
+*/
+class Collision                        // interface
+{
 public:
-    NAME_MEMBERS(Collision);
-    void add (Note_column*ncol_l);
-    Collision();
-    
+  static SCM automatic_shift (Score_element*);
+  static SCM forced_shift (Score_element*);
+  static Real force_shift_callback (Score_element *, Axis);
+  static void do_shifts (Score_element*);
+  static void add_column (Score_element*me,Score_element*ncol_l);
 };
 #endif // COLLISION_HH