source file of the GNU LilyPond music typesetter
- (c) 1997--2002 Han-Wen Nienhuys <hanwen@cs.uu.nl>
+ (c) 1997--2004 Han-Wen Nienhuys <hanwen@cs.uu.nl>
*/
void init ();
public:
Music_output_def * output_def_;
- String type_string_;
- bool is_alias_b (String) const;
-
-
+ bool is_alias (SCM) const;
Translator (Translator const &);
virtual Moment now_mom () const;
/*
- ugh: bubbled up from Translator_group.
+ ugh: bubbled up.
*/
- SCM simple_trans_list_;
- SCM trans_group_list_;
SCM definition_;
-
SCM properties_scm_;
- DECLARE_SMOBS (Translator, dummy);
-
+ SCM trans_group_list_;
+ SCM accepts_list_;
+ virtual SCM get_simple_trans_list ();
public:
- TRANSLATOR_DECLARATIONS(Translator);
- /**
- try to fit the request in this engraver
+ DECLARE_SMOBS (Translator, dummy);
+private:
+ /*
+ ugh: bubbled up from Translator_group.
+ */
- @return
- false: not noted, not taken.
+protected: // should be private.
+ SCM simple_trans_list_;
+ friend class Context_def;
+ // ugir.
+ // friend SCM Translator_group::get_simple_trans_list ();
- true: request swallowed. Don't try to put the request elsewhere.
- */
+public:
+ Global_translator * top_translator () const;
+ TRANSLATOR_DECLARATIONS(Translator);
virtual bool try_music (Music *req);
virtual void stop_translation_timestep ();
virtual void start_translation_timestep ();
T *t = new T;\
T::static_description_ = t->static_translator_description ();\
scm_permanent_object (T::static_description_);\
- t->type_string_ = classname (t);\
add_translator (t);\
}\
SCM T::translator_description() const\
-#define ENTER_DESCRIPTION(classname,desc,grobs,acked,read,write) \
+#define ENTER_DESCRIPTION(classname,desc,grobs,accepted,acked,read,write) \
ADD_THIS_TRANSLATOR (classname);\
SCM \
classname::static_translator_description () const \
parse_symbol_list (grobs), static_properties); \
\
static_properties= scm_acons (ly_symbol2scm ("description"), \
- ly_str02scm (desc), static_properties); \
+ scm_makfrom0str (desc), static_properties); \
\
static_properties= scm_acons (ly_symbol2scm ("interfaces-acked"), \
parse_symbol_list (acked), static_properties); \
+ static_properties= scm_acons (ly_symbol2scm ("events-accepted"), \
+ parse_symbol_list (accepted), static_properties); \
\
static_properties= scm_acons (ly_symbol2scm ("properties-read"), \
parse_symbol_list (read), static_properties); \
-extern Dictionary<Translator*> *global_translator_dict;
void add_translator (Translator*trans);
-Translator*get_translator (String s);
+Translator*get_translator (SCM s);
DECLARE_UNSMOB(Translator,translator);
#endif // TRANSLATOR_HH