]> git.donarmstrong.com Git - lilypond.git/blob - lily/dots.cc
release: 0.1.13
[lilypond.git] / lily / dots.cc
1 /*
2   dots.cc -- implement Dots
3
4   source file of the GNU LilyPond music typesetter
5
6   (c) 1997 Han-Wen Nienhuys <hanwen@stack.nl>
7 */
8
9 #include "dots.hh"
10 #include "molecule.hh"
11 #include "paper-def.hh"
12 #include "lookup.hh"
13
14 Dots::Dots ()
15 {
16   no_dots_i_ =0;
17   position_i_ =0;
18 }
19
20 void
21 Dots::do_post_processing ()
22 {
23   if (!(position_i_ % 2))
24     position_i_ ++;
25 }
26
27 Molecule* 
28 Dots::brew_molecule_p () const
29 {
30   Symbol d = paper ()->lookup_l ()->dots (no_dots_i_);
31   Molecule *out = new Molecule (Atom (d));
32   Real inter_f = paper ()->internote_f ();
33   out->translate (inter_f * position_i_, Y_AXIS);
34   return out;
35 }
36
37 IMPLEMENT_IS_TYPE_B1(Dots, Item);