]> git.donarmstrong.com Git - lilypond.git/blob - lily/include/translator-def.hh
* input/test/slur-shape.ly (x): remove file.
[lilypond.git] / lily / include / translator-def.hh
1 /*   
2   translator-def.hh -- declare Translator_def
3   
4   source file of the GNU LilyPond music typesetter
5   
6   (c)  2000--2003 Han-Wen Nienhuys <hanwen@cs.uu.nl>
7   
8  */
9
10 #ifndef TRANSLATOR_DEF_HH
11 #define TRANSLATOR_DEF_HH
12
13 #include "lily-proto.hh"
14 #include "smobs.hh"
15 #include "input.hh"
16
17 /*
18   The definition of a interpretation context as given in the
19   input. The lists are stored in order of definition.
20 */
21 struct Translator_def : public Input
22 {
23 private:
24   /*
25     these lists store the definition, in opposite order of entry
26   */
27   
28   SCM consists_name_list_;
29   SCM end_consists_name_list_;
30   SCM accepts_name_list_;
31   SCM property_ops_;
32
33 public:
34   SCM description_;
35   /*
36     "type" is overloaded.
37    */
38   SCM type_name_;
39   SCM type_aliases_;
40   SCM translator_group_type_;
41
42   SCM modify_definition (SCM, SCM, bool);
43   SCM default_child_context_name ();
44   
45   void set_acceptor (SCM accepts, bool add);
46   void add_element (SCM name);
47   void remove_element (SCM name);
48   void add_last_element (SCM name);
49   void add_property_operation (SCM);
50
51   Link_array<Translator_def> path_to_acceptable_translator (SCM type_string, Music_output_def* odef) const;
52   Translator_group * instantiate (Music_output_def*);
53
54   SCM to_alist () const;
55
56   static SCM make_scm () ;
57
58   SCM clone_scm ()const;
59   void apply_default_property_operations (Translator_group*);
60
61 private:
62   DECLARE_SMOBS (Translator_def,foo);
63   Translator_def ();
64   Translator_def (Translator_def const&);
65
66
67 };
68
69 DECLARE_UNSMOB(Translator_def,translator_def);
70
71
72 #endif /* TRANSLATOR_DEF_HH */
73