2 rhythmic-head.cc -- implement Rhythmic_head
4 source file of the GNU LilyPond music typesetter
6 (c) 1997--2001 Han-Wen Nienhuys <hanwen@cs.uu.nl>
9 #include "rhythmic-head.hh"
13 #include "staff-symbol-referencer.hh"
18 Rhythmic_head::dots_l (Grob*me)
20 SCM s = me->get_grob_property ("dot");
21 return dynamic_cast<Item*> (unsmob_grob (s));
25 Rhythmic_head::balltype_i (Grob*me)
27 SCM s = me->get_grob_property ("duration-log");
28 return gh_number_p (s) ? gh_scm2int (s) <? 2 : 0;
32 Rhythmic_head::stem_l (Grob*me)
34 SCM s = me->get_grob_property ("stem");
35 return dynamic_cast<Item*> (unsmob_grob (s));
39 Rhythmic_head::dot_count (Grob*me)
42 ? gh_scm2int (dots_l (me)->get_grob_property ("dot-count")) : 0;
46 Rhythmic_head::set_dots (Grob*me,Item *dot_l)
48 me->set_grob_property ("dot", dot_l->self_scm ());
53 Rhythmic_head::set_interface (Grob*me)
55 me->set_interface (ly_symbol2scm ("rhythmic-head-interface"));
59 Rhythmic_head::has_interface (Grob*me)
61 return me && me->has_interface (ly_symbol2scm ("rhythmic-head-interface"));