2 breathing_sign.cc -- implement Breathing_sign
4 Copyright (C) 1999 Michael Krause
6 written for the GNU LilyPond music typesetter
8 TODO: --> see breathing-sign-engraver.cc
12 #include "staff-symbol-referencer.hh"
13 #include "directional-element-interface.hh"
14 #include "breathing-sign.hh"
16 #include "molecule.hh"
17 #include "paper-def.hh"
20 #include "dimensions.hh"
21 #include "direction.hh"
24 Breathing_sign::Breathing_sign (SCM s)
31 MAKE_SCHEME_SCORE_ELEMENT_CALLBACK(Breathing_sign,brew_molecule);
34 Breathing_sign::brew_molecule (SCM smob)
36 Score_element * sc = unsmob_element (smob);
37 Staff_symbol_referencer_interface si (sc);
39 Real space = si.staff_space();
42 Interval i1(0, space / 6), i2(-space / 2, space / 2);
45 return sc->lookup_l()->filledbox(b).create_scheme ();
48 GLUE_SCORE_ELEMENT(Breathing_sign,after_line_breaking);
50 Breathing_sign::member_after_line_breaking ()
52 Real space = Staff_symbol_referencer_interface (this).staff_space();
53 Direction d = Directional_element_interface (this). get ();
57 Directional_element_interface (this).set (d);
60 translate_axis(2.0 * space * d, Y_AXIS);