- * TODO: thickness should be a grob property (unit:
- * stafflinethickness) rather than hardwired to (staff_space / 6).
- */
-
-MAKE_SCHEME_CALLBACK (Breathing_sign,brew_molecule,1);
-SCM
-Breathing_sign::brew_molecule (SCM smob)
-{
- Grob *me = unsmob_grob (smob);
- SCM text = me->get_grob_property ("text");
- if (text == SCM_EOL)
- return divisio_minima (smob);
- SCM properties = Font_interface::font_alist_chain (me);
- Molecule out;
- out = Text_item::text2molecule (me, text, properties);
- SCM space_scm = me->get_grob_property ("word-space");
- if (gh_number_p (space_scm))
- {
- Molecule mol;
- mol.set_empty (false);
- out.add_at_edge (X_AXIS, RIGHT, mol, gh_scm2double (space_scm) *
- Staff_symbol_referencer::staff_space (me), 0);
- }
- return out.smobbed_copy ();
-}
-
-/*
- Simplistic caesura.
- */
-MAKE_SCHEME_CALLBACK (Breathing_sign,railtracks,1);
-SCM
-Breathing_sign::railtracks (SCM smob)
-{
- Grob * me = unsmob_grob (smob);
- Real space = Staff_symbol_referencer::staff_space (me);
- Real th = me->get_paper ()->get_var ("linethickness");
- SCM lt = me->get_grob_property ("thickness");
- if (gh_number_p (lt))
- th *= gh_scm2double (lt);
-
- Offset x1 (0, -space);
- Offset x2 (space / 3, space);
- Molecule l1 (Lookup::line (th, x1, x2));
- Molecule l2 (l1);
- l2.translate_axis (space *0.6 , X_AXIS);
- l1.add_molecule (l2);
- return l1.smobbed_copy();
-}