X-Git-Url: https://git.donarmstrong.com/?a=blobdiff_plain;f=lily%2Finclude%2Fengraver-group.hh;h=367b6a8f4cd244772c691d4d6e9dc762356a2474;hb=84a3f805e16aeec81ea36e33fa7e7e069ecec9f9;hp=1ca9787d239e164e0f962d04a2fe9ac06718a7ef;hpb=75eebcb49e52d296b1da3e1074e0825d2c780db4;p=lilypond.git diff --git a/lily/include/engraver-group.hh b/lily/include/engraver-group.hh index 1ca9787d23..367b6a8f4c 100644 --- a/lily/include/engraver-group.hh +++ b/lily/include/engraver-group.hh @@ -1,9 +1,20 @@ /* - engraver-group.hh -- declare Engraver_group + This file is part of LilyPond, the GNU music typesetter. - source file of the GNU LilyPond music typesetter + Copyright (C) 1997--2015 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 . */ #ifndef ENGRAVER_GROUP_HH @@ -12,18 +23,34 @@ #include "engraver.hh" #include "translator-group.hh" -class Engraver_group : public virtual Translator_group +class Announce_grob_info : public Grob_info +{ + Direction start_end_; +public: + Announce_grob_info (Grob_info gi, Direction start_end) + : Grob_info (gi), start_end_ (start_end) + { } + Direction start_end () const { return start_end_; } +}; + +class Engraver_group : public Preinit, public Translator_group { protected: - Array announce_infos_; - SCM acknowledge_hash_table_; + vector announce_infos_; + Drul_array acknowledge_hash_table_drul_; + void override (SCM); + void revert (SCM); public: - VIRTUAL_COPY_CONSTRUCTOR (Translator_group, Engraver_group); + DECLARE_CLASSNAME (Engraver_group); + void pre_init (); Engraver_group (); virtual void derived_mark () const; void do_announces (); - virtual void announce_grob (Grob_info); - int pending_grob_count () const; + virtual void connect_to_context (Context *c); + virtual void disconnect_from_context (); + virtual void announce_grob (Grob_info, Direction start_end, + Context *reroute_context = 0); + bool pending_grobs () const; private: virtual void acknowledge_grobs (); }; @@ -34,4 +61,3 @@ void engraver_each (SCM list, Engraver_method method); #endif /* ENGRAVERGROUP_HH */ -