]> git.donarmstrong.com Git - lilypond.git/blob - lily/include/system.hh
skyline vertical spacing.
[lilypond.git] / lily / include / system.hh
1
2 /*
3   line-of-score.hh -- part of GNU LilyPond
4
5   (c) 1996--2006 Han-Wen Nienhuys
6 */
7
8 #ifndef SYSTEM_HH
9 #define SYSTEM_HH
10
11 #include "column-x-positions.hh"
12 #include "spanner.hh"
13 #include "grob-array.hh"
14 #include "skyline.hh"
15
16 /*
17   If you keep following offset reference points, you will always end
18   up at the root object. This root object is called @ref{System}, and it
19   represents a system (i.e. a line of music).
20 */
21 class System : public Spanner
22 {
23   int rank_;
24   Grob_array *all_elements_;
25   Drul_array<Skyline> skylines_;
26   void build_skylines ();
27   void init_elements ();
28   friend class Paper_score;     // ugh.
29   Paper_score *pscore_; // ugh.
30   
31 public:
32   Paper_score *paper_score () const;
33   int get_rank () const;
34   void post_processing ();
35   SCM get_paper_system ();
36   SCM get_paper_systems ();
37
38   System (SCM, Object_key const *);
39   System (System const &, int);
40
41   int element_count () const;
42   int spanner_count () const;
43
44   void break_into_pieces (vector<Column_x_positions> const &);
45   static bool has_interface (Grob *);
46
47   vector<Item*> broken_col_range (Item const *, Item const *) const;
48   vector<Grob*> columns () const;
49
50   void add_column (Paper_column *);
51   void typeset_grob (Grob *);
52   void pre_processing ();
53
54 protected:
55   virtual void derived_mark () const;
56   virtual Grob *clone (int count) const;
57 };
58
59 void set_loose_columns (System *which, Column_x_positions const *posns);
60
61 #endif /* SYSTEM_HH */
62