]> git.donarmstrong.com Git - lilypond.git/blob - lily/paper-line.cc
* lily/global-context.cc (run_iterator_on_me): fix grace note
[lilypond.git] / lily / paper-line.cc
1 /*
2   paper-line.cc -- implement Paper_line
3
4   source file of the GNU LilyPond music typesetter
5
6   (c) 2004 Jan Nieuwenhuizen <janneke@gnu.org>
7 */
8
9 #include "paper-line.hh"
10 #include "ly-smobs.icc"
11
12 Paper_line::Paper_line (Offset o, SCM stencils, bool is_title)
13 {
14   dim_ = o;
15   stencils_ = stencils;
16   is_title_ = is_title;
17   smobify_self ();
18 }
19
20 Offset
21 Paper_line::dim () const
22 {
23   return dim_;
24 }
25
26 bool
27 Paper_line::is_title () const
28 {
29   return is_title_;
30 }
31
32 SCM
33 Paper_line::stencils () const
34 {
35   return stencils_;
36 }
37
38 SCM
39 Paper_line::mark_smob (SCM s)
40 {
41   Paper_line *line = (Paper_line*) ly_cdr (s);
42   return line->stencils_;
43 }
44
45 int
46 Paper_line::print_smob (SCM, SCM port, scm_print_state*)
47 {
48   scm_puts ("#<Paper_line ", port);
49   scm_puts (" >", port);
50   return 1;
51 }
52
53 Paper_line::~Paper_line ()
54 {
55 }
56
57 IMPLEMENT_SMOBS (Paper_line);
58 IMPLEMENT_TYPE_P (Paper_line, "ly:paper-line?");
59 IMPLEMENT_DEFAULT_EQUAL_P (Paper_line);