]> git.donarmstrong.com Git - lilypond.git/commitdiff
lilypond-1.1.13
authorfred <fred>
Tue, 26 Mar 2002 21:44:57 +0000 (21:44 +0000)
committerfred <fred>
Tue, 26 Mar 2002 21:44:57 +0000 (21:44 +0000)
init/engraver.ly
lily/include/chord-name-engraver.hh [new file with mode: 0644]
lily/include/lily-proto.hh
lily/include/lyric-engraver.hh
lily/lyric-engraver.cc
lily/paper-def.cc

index a2c9db5990218e42a3f290174420dd401f83e93f..a7c13b6bbc23b12d0e81b50099d0725d1f8a38e5 100644 (file)
@@ -68,6 +68,7 @@ StaffContext=\translator {
        \accepts "RhythmicStaff";
        \accepts "GrandStaff";
        \accepts "Lyrics";
+       \accepts "ChordNames";
 }
 
 
@@ -102,7 +103,7 @@ VoiceContext = \translator {
        \consists "Font_size_engraver";
        \consists "Slur_engraver";
        \consists "Ties_engraver";
-%      \consists "Tuplet_engraver";    
+       \consists "Tuplet_engraver";    
        \consists "Note_heads_engraver" ;       
        \consists "Skip_req_swallow_translator";
 };
@@ -132,6 +133,7 @@ GrandStaffContext=\translator{
        \accepts "RhythmicStaff";
        \accepts "GrandStaff";
        \accepts "Lyrics";
+       \accepts "ChordNames";
 }
 
 \translator{
@@ -152,6 +154,21 @@ GrandStaffContext=\translator{
        \accepts "LyricVoice";
 }
 
+\translator{
+       \type "Line_group_engraver_group";
+
+       \name ChordNameVoice ;
+       \consists "Separating_line_group_engraver";
+       \consists "Chord_name_engraver";
+}
+
+\translator {
+       \type "Line_group_engraver_group";
+       \name ChordNames;
+       \consists "Vertical_align_engraver";
+       \accepts "ChordNameVoice";
+}
+
 ScoreContext = \translator {
        \type Score_engraver;
        \name Score;
@@ -169,6 +186,7 @@ ScoreContext = \translator {
        \accepts "Staff";
        \accepts "RhythmicStaff";       
        \accepts "Lyrics";
+       \accepts "ChordNames";
        \accepts "GrandStaff";
        \accepts "ChoirStaff";
 };
@@ -259,5 +277,6 @@ OrchestralScoreContext= \translator {
        \accepts "Staff";
        \accepts "RhythmicStaff";       
        \accepts "Lyrics";
+       \accepts "ChordNames";
        \accepts "GrandStaff";
 };
diff --git a/lily/include/chord-name-engraver.hh b/lily/include/chord-name-engraver.hh
new file mode 100644 (file)
index 0000000..f7b44b5
--- /dev/null
@@ -0,0 +1,35 @@
+/*
+  chord-name-engraver.hh -- declare Chord_name_engraver
+
+  source file of the GNU LilyPond music typesetter
+
+  (c) 1998 Jan Nieuwenhuizen <janneke@gnu.org>
+*/
+
+#ifndef CHORD_NAME_ENGRAVER_HH
+#define CHORD_NAME_ENGRAVER_HH
+
+#include "engraver.hh"
+#include "array.hh"
+#include "musical-pitch.hh"
+
+#include "lily-proto.hh"
+
+class Chord_name_engraver : public Engraver 
+{
+protected:
+  virtual void do_pre_move_processing ();
+  virtual void acknowledge_element (Score_element_info i);
+  virtual void do_process_requests ();
+  virtual bool do_try_music (Music* m);
+
+public:
+  Chord_name_engraver ();
+  VIRTUAL_COPY_CONS (Translator);
+
+private:
+  Array<Musical_pitch> pitch_arr_;
+  Link_array<Text_item> text_p_arr_;
+};
+
+#endif // CHORD_NAME_ENGRAVER_HH
index 20a49da261ce2ca8fa1c3915439a49e4cb4edf02..3bd510b23118e3580a581604dee98a8c47c82d7a 100644 (file)
@@ -46,7 +46,7 @@ struct Break_req;
 struct Cadenza_req;
 struct Change_iterator;
 struct Change_translator;
-struct Simultaneous_music;
+struct Chord_name_engraver;
 struct Clef_change_req;
 struct Clef_item;
 struct Clef_engraver;
@@ -186,7 +186,6 @@ struct Rhythmic_grouping;
 struct Rhythmic_head;
 struct Rhythmic_grouping_req;
 struct Rhythmic_req;
-struct Single_malt_grouping_item;
 struct Scope;
 struct Separating_group_spanner;
 struct Score;
@@ -200,6 +199,8 @@ struct Script_def;
 struct Script_engraver;
 struct Script_req;
 struct Simple_music;
+struct Simultaneous_music;
+struct Single_malt_grouping_item;
 struct Skip_req;
 struct Slur;
 struct Slur_engraver;
index 15b5f510e04b345e904921edd027366371a51dcf..0087e21e5e7e20de9fe5f76370d27107bdf2046f 100644 (file)
@@ -20,7 +20,6 @@ protected:
   virtual void do_pre_move_processing();
   virtual bool do_try_music (Music*);
   virtual void do_process_requests();
-  virtual void do_post_move_processing();
 
 public:
   Lyric_engraver();
index bac629b38578ea4fb4b76bb4551a6aacc30aa9f1..9fb403f2da0d2c264553e05c6f687017515f0bf5 100644 (file)
@@ -65,11 +65,6 @@ Lyric_engraver::do_process_requests()
     }
 }
 
-void
-Lyric_engraver::do_post_move_processing()
-{
-}
-
 void
 Lyric_engraver::do_pre_move_processing()
 {
index a98af9d3896d1fcacd3a69fc4618db32b528ece9..93193f1508211b615d28eed5fdb12e7b1c1e592e 100644 (file)
@@ -102,7 +102,7 @@ Paper_def::duration_to_dist (Moment d,Real k) const
 
 
 /**
-  Get the measure wide constant for arithmetic.
+  Get the measure wide constant for arithmetic spacing.
 
   @see
   John S. Gourlay. ``Spacing a Line of Music,'' Technical Report
@@ -122,13 +122,6 @@ Paper_def::arithmetic_spacing (Moment d ,Real k) const
   return (log_2 (d) + k)* get_var ("arithmetic_multiplier");
 }
 
-Real
-Paper_def::geometric_spacing (Moment d) const
-{
-  Real dur_f = (d) ?pow (get_var ("geometric"), log_2 (d)) : 0;
-  return get_var ("basicspace") + get_var ("unitspace")  * dur_f;
-}
-
 void
 Paper_def::set_lookup (int i, Lookup*l)
 {