From: fred Date: Sun, 24 Mar 2002 19:47:12 +0000 (+0000) Subject: lilypond-0.0.73pre X-Git-Tag: release/1.5.59~4505 X-Git-Url: https://git.donarmstrong.com/?a=commitdiff_plain;h=f80e8d60b00596a722732ea8360fab3dfe18f3ff;p=lilypond.git lilypond-0.0.73pre --- diff --git a/input/scsii-menuetto.ly b/input/scsii-menuetto.ly index 8f4b5daa77..9bc9fcf38f 100644 --- a/input/scsii-menuetto.ly +++ b/input/scsii-menuetto.ly @@ -103,9 +103,9 @@ IImenuetto = \melodic{ \score{ \melodic { \IImenuetto } \paper{ - width= 195.0\mm; unitspace= 9.0\mm ;% to get lily to use only three lines geometric= 1.40; + linewidth= 195.0\mm; \output "scsii-menuetto.out"; } \midi{ diff --git a/lily/paper-def.cc b/lily/paper-def.cc index 6a7dd24417..65bf8eac9b 100644 --- a/lily/paper-def.cc +++ b/lily/paper-def.cc @@ -14,7 +14,9 @@ #include "debug.hh" #include "lookup.hh" #include "dimen.hh" - +#include "input-engraver.hh" +#include "engraver-group.hh" +#include "assoc-iter.hh" void Paper_def::set_var(String s, Real r) @@ -48,6 +50,7 @@ Paper_def::duration_to_dist(Moment d) Paper_def::Paper_def() { + igrav_p_ = 0; lookup_p_ = 0; real_vars_p_ = new Assoc; outfile_str_ = "lelie.tex"; @@ -55,18 +58,27 @@ Paper_def::Paper_def() Paper_def::~Paper_def() { + delete igrav_p_; delete real_vars_p_; delete lookup_p_; } Paper_def::Paper_def(Paper_def const&s) { + igrav_p_ = s.igrav_p_ ? new Input_engraver( *s.igrav_p_):0; lookup_p_ = s.lookup_p_? new Lookup(*s.lookup_p_) : 0; lookup_p_->paper_l_ = this; real_vars_p_ = new Assoc (*s.real_vars_p_); outfile_str_ = s.outfile_str_; } +void +Paper_def::set(Input_engraver * igrav_p) +{ + delete igrav_p_; + igrav_p_ = igrav_p; +} + void Paper_def::set(Lookup*l) { @@ -113,12 +125,22 @@ Paper_def::print() const mtor << "Paper {"; mtor << "out: " <print(); + for (Assoc_iter i(*real_vars_p_); i.ok(); i++) { + mtor << i.key() << "= " << i.val() << "\n"; + } mtor << "}\n"; #endif } + Lookup const * Paper_def::lookup_l() { assert( lookup_p_ ); return lookup_p_; } + +Global_translator* +Paper_def::get_global_translator_p() const +{ + return igrav_p_->get_group_engraver_p()->global_l(); +} diff --git a/lily/vertical-align-elem.cc b/lily/vertical-align-elem.cc index 2aecf5d3fc..506bce550c 100644 --- a/lily/vertical-align-elem.cc +++ b/lily/vertical-align-elem.cc @@ -10,7 +10,7 @@ #include "interval.hh" void -Vertical_align_elem::add(Score_elem*el_l) +Vertical_align_element::add(Score_elem*el_l) { assert( ! contains_b(el_l)); elem_l_arr_.push(el_l); @@ -18,7 +18,7 @@ Vertical_align_elem::add(Score_elem*el_l) } void -Vertical_align_elem::do_substitute_dependency(Score_elem*o,Score_elem*n) +Vertical_align_element::do_substitute_dependency(Score_elem*o,Score_elem*n) { int i; while((i = elem_l_arr_.find_i(o))>=0) @@ -28,7 +28,7 @@ Vertical_align_elem::do_substitute_dependency(Score_elem*o,Score_elem*n) elem_l_arr_.del(i); } void -Vertical_align_elem::do_post_processing() +Vertical_align_element::do_post_processing() { Array dims; for (int i=0; i < elem_l_arr_.size(); i++ ) { @@ -47,17 +47,17 @@ Vertical_align_elem::do_post_processing() } bool -Vertical_align_elem::contains_b(Score_elem const *e)const +Vertical_align_element::contains_b(Score_elem const *e)const { return elem_l_arr_.find_l(e); } -Vertical_align_elem::Vertical_align_elem() +Vertical_align_element::Vertical_align_element() { transparent_b_ = true; empty_b_ =true; } -IMPLEMENT_STATIC_NAME(Vertical_align_elem); -IMPLEMENT_IS_TYPE_B1(Vertical_align_elem, Score_elem); +IMPLEMENT_STATIC_NAME(Vertical_align_element); +IMPLEMENT_IS_TYPE_B1(Vertical_align_element, Score_elem); diff --git a/lily/vertical-align-spanner.cc b/lily/vertical-align-spanner.cc new file mode 100644 index 0000000000..461f6bd282 --- /dev/null +++ b/lily/vertical-align-spanner.cc @@ -0,0 +1,12 @@ +/* + vertical-align-spanner.cc -- implement Vertical_align_spanner + + source file of the GNU LilyPond music typesetter + + (c) 1997 Han-Wen Nienhuys +*/ + +#include "vertical-align-spanner.hh" + +IMPLEMENT_STATIC_NAME(Vertical_align_spanner); +IMPLEMENT_IS_TYPE_B2(Vertical_align_spanner, Vertical_align_element, Spanner); diff --git a/tex/lilyponddefs.tex b/tex/lilyponddefs.tex index 299ff2edd8..9607702de1 100644 --- a/tex/lilyponddefs.tex +++ b/tex/lilyponddefs.tex @@ -127,17 +127,18 @@ \def\emptybar{} -\def\thinbar{\vrule height\balkheight width 1.6\staffrulethickness} % TODO parametric. -\def\thickbar{\vrule height\balkheight width 2\smallspace} -\def\maatstreep{\thinbar} - +\def\thinbar#1{\vrule height #1 width 1.6\staffrulethickness} % TODO parametric. +\def\thickbar#1{\vrule height #1 width 2\smallspace} +\def\maatstreep#1{\thinbar{#1}} +\def\defaultthinbar{\thinbar{\balkheight}} +\def\defaultthickbar{\thickbar{\balkheight}} %? what-s wrong with rightalign? -\def\finishbar{\rightalign{\thinbar\kern\smallspace\thickbar}} +\def\finishbar#1{\rightalign{\thinbar{#1}\kern\smallspace\thickbar{#1}}} -\def\repeatstopbar{\hss\rightalign{\repeatcolon\hskip2\smallspace\thinbar\hskip\smallspace\thickbar}} -\def\repeatstartbar{\hbox{\thickbar\kern\smallspace\thinbar\kern2\smallspace\repeatcolon}} -\def\repeatstopstart{\hbox{\repeatcolon\kern2\smallspace\thinbar\kern\smallspace\thickbar\kern\smallspace\thickbar\kern\smallspace\thinbar\kern2\smallspace\repeatcolon}} -\def\doublebar{\hbox{\thinbar\hskip\smallspace\thinbar}} +\def\repeatstopbar{\hss\rightalign{\repeatcolon\hskip2\smallspace\defaultthinbar\hskip\smallspace\defaultthickbar}} +\def\repeatstartbar{\hbox{\defaultthickbar\kern\smallspace\defaultthinbar\kern2\smallspace\repeatcolon}} +\def\repeatstopstart{\hbox{\repeatcolon\kern2\smallspace\defaultthinbar\kern\smallspace\defaultthickbar\kern\smallspace\defaultthickbar\kern\smallspace\defaultthinbar\kern2\smallspace\repeatcolon}} +\def\doublebar#1{\hbox{\thinbar{#1}\hskip\smallspace\thinbar{#1}}} %compatibility \def\repeatbar{\repeatstopbar}