2 crescendo.cc -- implement Crescendo
4 source file of the GNU LilyPond music typesetter
6 (c) 1997 Han-Wen Nienhuys <hanwen@stack.nl>
11 #include "crescendo.hh"
13 #include "paper-def.hh"
16 Crescendo::Crescendo()
20 left_dyn_b_ = right_dyn_b_ =false;
26 Crescendo::brew_molecule_p() const
30 Real absdyn_dim = 10 PT; // ugh
33 Real w_dim = width().length();
36 x_off_dim += absdyn_dim;
43 warning("Crescendo too small");
46 Real lookup_wid = w_dim * 0.9; // make it slightly smaller.
48 Symbol s( paper()->lookup_l()->hairpin( lookup_wid, grow_dir_i_ < 0) );
50 int pos = get_position_i(s.dim.y);
51 m_p->translate(Offset(x_off_dim + 0.05 * w_dim,
52 pos * paper()->internote_f()));
56 IMPLEMENT_STATIC_NAME(Crescendo);