- bool continued = broken[Direction (-grow_dir_)];
- Real height = paper_l()->staffheight_f () / 6;
-
- return Molecule (lookup_l ()->hairpin (w_dim, height, grow_dir_ < 0, continued));
-}
-
-Molecule*
-Crescendo::do_brew_molecule_p () const
-{
- Molecule* m_p =0;
- Real absdyn_dim = paper_l ()-> get_realvar (ly_symbol ("crescendo_shorten"));
- Real x_off_dim=0.0;
- if (dyn_b_drul_[LEFT])
- x_off_dim += absdyn_dim;
-
- m_p = new Molecule;
- Molecule s (get_symbol ());
- m_p->add_molecule (s);
- m_p->translate_axis (x_off_dim, X_AXIS);
- return m_p;
+ bool continued = broken[Direction (-gd)];
+ Real height = paper_l()->get_var ("crescendo_height");
+ Real thick = paper_l ()->get_var ("crescendo_thickness");
+
+ const char* hairpin = (gd < 0)? "decrescendo" : "crescendo";
+ Molecule * m
+ = new Molecule;
+ m->dim_.x () = Interval (0, width);
+ m->dim_.y () = Interval (-2*height, 2*height);
+
+ SCM at = gh_list (ly_symbol2scm (hairpin),
+ gh_double2scm (thick),
+ gh_double2scm (width),
+ gh_double2scm (height),
+ gh_double2scm (continued ? height/2 : 0.0),
+ SCM_UNDEFINED);
+
+ m->add_atom (at);
+ m->translate_axis (extra_left, X_AXIS);
+ return m;