]> git.donarmstrong.com Git - lilypond.git/blobdiff - lily/include/spacing-spanner.hh
Run `make grand-replace'.
[lilypond.git] / lily / include / spacing-spanner.hh
index f0f81dde7612c38c72117665dd79cede71db83ac..a993aae421eda1f5615dcdd8846936a5c0901eed 100644 (file)
@@ -1,52 +1,45 @@
-/*   
-  spacing-spanner.hh -- declare Spacing_spanner
-  
+/*
+  spacing-spanner.hh -- declare Spacing spanner
+
   source file of the GNU LilyPond music typesetter
-  
-  (c) 1999--2000 Han-Wen Nienhuys <hanwen@cs.uu.nl>
-  
- */
+
+  (c) 2005--2008 Han-Wen Nienhuys <hanwen@xs4all.nl>
+*/
 
 #ifndef SPACING_SPANNER_HH
 #define SPACING_SPANNER_HH
 
-#include "spanner.hh"
-
-/**
-   Read-only properties
-
-   maximum-duration-for-spacing -- rational: space as if a duration of
-     this type is available in this measure.
-
-
-   
-   Read properties from paper-column
+#include "lily-proto.hh"
+#include "rational.hh"
+#include "std-vector.hh"
+#include "grob-interface.hh"
+#include "spring.hh"
 
-   dir-list -- list of stem directions
-
-   shortest-playing-duration -- duration of the shortest playing in that column.
-
-   shortest-starter-duration -- duration of the shortest notes that starts
-     exactly in that column.
-
-   contains-grace -- boolean. Used to widen entries for grace notes.
-
-   extra-space --  pair of distances
-
-   stretch-distance -- pair of distances
- */
 class Spacing_spanner
 {
+private:
+  static void set_distances_for_loose_col (Grob *me, Grob *c, Drul_array<Item *> next_door, Spacing_options const *);
+  static void generate_pair_spacing (Grob *me,
+                                    Paper_column *l, Paper_column *r,
+                                    Paper_column *nextr,
+                                    Spacing_options const *options);
+  static Real default_bar_spacing (Grob *, Grob *, Grob *, Moment);
+  static Rational effective_shortest_duration (Grob *me, vector<Grob*> const &all);
+  static void breakable_column_spacing (Grob *, Item *l, Item *r, Spacing_options const *);
+  static void prune_loose_columns (Grob *, vector<Grob*> *cols, Spacing_options  *);
+  static void set_explicit_neighbor_columns (vector<Grob*> const &cols);
+  static void set_implicit_neighbor_columns (vector<Grob*> const &cols);
+  static void generate_springs (Grob *me, vector<Grob*> const &cols, Spacing_options const *);
+  static void musical_column_spacing (Grob *, Item *, Item *, Spacing_options const *);
+  static bool fills_measure (Grob *, Item *, Item *);
 public:
-  static void set_interface (Score_element*);
-  static void do_measure (Score_element*,Link_array<Score_element>) ;
-
-  DECLARE_SCHEME_CALLBACK(set_springs, (SCM ));
-  static Real stem_dir_correction (Score_element*,Score_element*,Score_element*)  ;
-  static Real default_bar_spacing (Score_element*,Score_element*,Score_element*,Moment)  ;
-  static Real note_spacing (Score_element*,Score_element*,Score_element*,Moment)  ;
-  static Real get_duration_space (Score_element*,Moment dur, Moment shortest) ;
+  static vector<Grob*> get_columns (Grob *me);
+  static Real note_spacing (Grob *, Grob *, Grob *, Spacing_options const *);
+  static Spring standard_breakable_column_spacing (Grob *me, Item *l, Item *r, Spacing_options const *);
+  
+  DECLARE_SCHEME_CALLBACK (set_springs, (SCM));
+  DECLARE_SCHEME_CALLBACK (calc_common_shortest_duration, (SCM));
+  DECLARE_GROB_INTERFACE();
 };
 
 #endif /* SPACING_SPANNER_HH */
-