From 9c1b2d3de876b8a823b92b8bac4ce3f2acc2fa67 Mon Sep 17 00:00:00 2001 From: Han-Wen Nienhuys Date: Mon, 18 Apr 2005 12:53:17 +0000 Subject: [PATCH] * lily/score.cc (default_rendering): use Music_output too. * lily/text-spanner.cc: add bound-padding. * lily/line-interface.cc (make_arrow): new function. Patch by Jonatan Liljedahl (arrows): idem. * lily/line-spanner.cc (line_stencil): add arrows. --- ChangeLog | 2 ++ lily/score.cc | 32 +++++++++++++++----------------- 2 files changed, 17 insertions(+), 17 deletions(-) diff --git a/ChangeLog b/ChangeLog index faecbcf94b..43bd3a5a3c 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,7 @@ 2005-04-18 Han-Wen Nienhuys + * lily/score.cc (default_rendering): use Music_output too. + * input/test/chord-names-languages.ly (Module): rename file. * lily/text-spanner.cc: add bound-padding. diff --git a/lily/score.cc b/lily/score.cc index 68146c1676..ee628b9b25 100644 --- a/lily/score.cc +++ b/lily/score.cc @@ -116,27 +116,25 @@ default_rendering (SCM music, SCM outdef, } SCM context = ly_run_translator (music, scaled_def, key); - if (Global_context *g = dynamic_cast - (unsmob_context (context))) + Music_output *output = unsmob_music_output (ly_format_output (context)); + + if (Paper_score *pscore = dynamic_cast (output)) { - SCM systems = ly_format_output (context); - Music_output *output = g->get_output (); - if (systems != SCM_UNDEFINED) - { - /* ugh, this is strange, Paper_book without a Book object. */ - Paper_book *paper_book = new Paper_book (); - paper_book->header_ = header; - paper_book->paper_ = unsmob_output_def (scaled_bookdef); + /* ugh, this is strange, Paper_book without a Book object. */ + Paper_book *paper_book = new Paper_book (); + paper_book->header_ = header; + paper_book->paper_ = unsmob_output_def (scaled_bookdef); - if (ly_c_module_p (header)) - paper_book->add_score (header); - paper_book->add_score (systems); + if (ly_c_module_p (header)) + paper_book->add_score (header); - paper_book->classic_output (ly_scm2string (outname)); - scm_gc_unprotect_object (paper_book->self_scm ()); - } - scm_gc_unprotect_object (output->self_scm ()); + SCM systems = pscore->get_paper_systems (); + paper_book->add_score (systems); + + paper_book->classic_output (ly_scm2string (outname)); + scm_gc_unprotect_object (paper_book->self_scm ()); } + scm_gc_unprotect_object (output->self_scm ()); scm_remember_upto_here_1 (scaled_def); scm_remember_upto_here_1 (scaled_bookdef); -- 2.39.2