]> git.donarmstrong.com Git - lilypond.git/blob - lily/dimension-cache.cc
*** empty log message ***
[lilypond.git] / lily / dimension-cache.cc
1 /*
2   dimension-cache.cc -- implement Dimension_cache
3
4   source file of the GNU LilyPond music typesetter
5
6   (c) 1998--2005 Han-Wen Nienhuys <hanwen@cs.uu.nl>
7 */
8
9
10 #include "dimension-cache.hh"
11 #include "warn.hh"
12 #include "grob.hh"
13
14 Dimension_cache::Dimension_cache (Dimension_cache const &d)
15 {
16   init ();
17   dimension_ = d.dimension_;
18   dimension_callback_ = d.dimension_callback_;
19   offset_ = d.offset_;
20   offset_callbacks_ = d.offset_callbacks_;
21   offsets_left_ = d.offsets_left_;
22   parent_ = d.parent_;
23 }
24
25 Dimension_cache::Dimension_cache ()
26 {
27   init ();
28 }
29
30 void
31 Dimension_cache::init ()
32 {
33   dimension_ = SCM_EOL;
34   dimension_callback_ = SCM_EOL;
35
36   offsets_left_ = 0;
37   offset_callbacks_ = SCM_EOL;
38   offset_ = 0.0;
39
40   parent_ = 0;
41 }
42