]> git.donarmstrong.com Git - lilypond.git/blob - lily/include/staff-symbol-referencer.hh
1b4c096b8ee4b38fa0351a360191342f4f2e649b
[lilypond.git] / lily / include / staff-symbol-referencer.hh
1 /*
2   staff-sym-referencer.hh -- declare staff_symbol_referencer
3
4   source file of the GNU LilyPond music typesetter
5
6   (c) 1999--2006 Han-Wen Nienhuys <hanwen@xs4all.nl>
7 */
8
9 #ifndef STAFF_SYMBOL_REFERENCER_HH
10 #define STAFF_SYMBOL_REFERENCER_HH
11
12 #include "grob.hh"
13
14 /**
15    A notation object that needs access to variables of the staff (no
16    lines, leading).
17 */
18 class Staff_symbol_referencer
19 {
20 public:
21   static bool has_interface (Grob *);
22   static bool ugly_hack (Grob *);
23   static void set_position (Grob *, Real);
24   DECLARE_SCHEME_CALLBACK (callback, (SCM element));
25
26   /**
27      Leading are the lead strips between the sticks (lines) of
28      typeface. ie. leading is vertical space.
29   */
30   static Real line_thickness (Grob *);
31   static Real staff_space (Grob *);
32   static Grob *get_staff_symbol (Grob *);
33   static bool on_line (Grob *);
34   static bool on_line (Grob *, int);
35   static bool on_staff_line (Grob *, int);
36   static bool on_staff_line (Grob *);
37   static int line_count (Grob *);
38   static Real get_position (Grob *);
39   static Real staff_radius (Grob *);
40   static int get_rounded_position (Grob *);
41 };
42
43 int compare_position (Grob *const &, Grob *const &);\
44 bool position_less (Grob *const &, Grob *const &);
45 #endif /* STAFF_SYMBOL_REFERENCER_HH */
46