X-Git-Url: https://git.donarmstrong.com/?a=blobdiff_plain;f=lily%2Fscript-engraver.cc;h=f10f29da8a12fd9a8c0ba6ffa96e526dc43f62e3;hb=d959f8d548dc073c162c4599cfef2a596f9b66db;hp=cb3a007d53ed6f3e160e713ce5ec78373a5bbedc;hpb=a1585282d52049561f18de9e3c411f1468bb89aa;p=lilypond.git diff --git a/lily/script-engraver.cc b/lily/script-engraver.cc index cb3a007d53..f10f29da8a 100644 --- a/lily/script-engraver.cc +++ b/lily/script-engraver.cc @@ -1,9 +1,20 @@ /* - script-engraver.cc -- engrave Scripts: Articulations. + This file is part of LilyPond, the GNU music typesetter. - source file of the GNU LilyPond music typesetter + Copyright (C) 1997--2011 Han-Wen Nienhuys - (c) 1997--2006 Han-Wen Nienhuys + LilyPond is free software: you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation, either version 3 of the License, or + (at your option) any later version. + + LilyPond is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with LilyPond. If not, see . */ #include "engraver.hh" @@ -38,14 +49,12 @@ struct Script_tuple class Script_engraver : public Engraver { vector scripts_; - Spanner *slur_; protected: void stop_translation_timestep (); void process_music (); DECLARE_TRANSLATOR_LISTENER (articulation); - DECLARE_ACKNOWLEDGER (slur); DECLARE_ACKNOWLEDGER (rhythmic_head); DECLARE_ACKNOWLEDGER (stem); DECLARE_ACKNOWLEDGER (stem_tremolo); @@ -57,7 +66,6 @@ public: Script_engraver::Script_engraver () { - slur_ = 0; } IMPLEMENT_TRANSLATOR_LISTENER (Script_engraver, articulation); @@ -84,7 +92,7 @@ copy_property (Grob *g, SCM sym, SCM alist) { SCM entry = scm_assoc (sym, alist); if (scm_is_pair (entry)) - g->internal_set_property (sym, scm_cdr (entry)); + g->set_property (sym, scm_cdr (entry)); } } @@ -102,8 +110,8 @@ make_script_from_event (Grob *p, Context *tg, if (art == SCM_BOOL_F) { /* FIXME: */ - warning (_ ("don't know how to interpret articulation: ")); - warning (_ ("scheme encoding: ")); + warning (_ ("do not know how to interpret articulation:")); + warning (_ (" scheme encoding: ")); scm_write (art_type, scm_current_error_port ()); message (""); return; @@ -136,7 +144,7 @@ make_script_from_event (Grob *p, Context *tg, SCM preset = p->get_property_data (sym); if (val == SCM_EOL || scm_call_1 (type, preset) == SCM_BOOL_F) - p->internal_set_property (sym, val); + p->set_property (sym, val); } if (!priority_found) @@ -144,8 +152,6 @@ make_script_from_event (Grob *p, Context *tg, p->set_property ("script-priority", scm_from_int (index)); } - - Side_position_interface::set_axis (p, Y_AXIS); } void @@ -234,27 +240,27 @@ Script_engraver::acknowledge_note_column (Grob_info info) } } -void -Script_engraver::acknowledge_slur (Grob_info info) -{ - slur_ = info.spanner (); -} - void Script_engraver::stop_translation_timestep () { scripts_.clear (); } -ADD_ACKNOWLEDGER (Script_engraver, slur); ADD_ACKNOWLEDGER (Script_engraver, rhythmic_head); ADD_ACKNOWLEDGER (Script_engraver, stem); ADD_ACKNOWLEDGER (Script_engraver, note_column); ADD_ACKNOWLEDGER (Script_engraver, stem_tremolo); ADD_TRANSLATOR (Script_engraver, - /* doc */ "Handles note scripted articulations.", - /* create */ "Script", - /* accept */ "script-event articulation-event", - /* read */ "scriptDefinitions", - /* write */ ""); + /* doc */ + "Handle note scripted articulations.", + + /* create */ + "Script ", + + /* read */ + "scriptDefinitions ", + + /* write */ + "" + );