]> git.donarmstrong.com Git - lilypond.git/blobdiff - lily/key-engraver.cc
Release: bump Welcome versions.
[lilypond.git] / lily / key-engraver.cc
index 635f293120c4c3bac29327788536ffb0549f2965..a61d7701d768dbb4c28246ac72743c3d7265303a 100644 (file)
@@ -46,9 +46,9 @@ protected:
   void stop_translation_timestep ();
   void process_music ();
 
-  DECLARE_TRANSLATOR_LISTENER (key_change);
-  DECLARE_ACKNOWLEDGER (clef);
-  DECLARE_ACKNOWLEDGER (bar_line);
+  void listen_key_change (Stream_event *);
+  void acknowledge_clef (Grob_info);
+  void acknowledge_bar_line (Grob_info);
 };
 
 void
@@ -56,7 +56,8 @@ Key_engraver::finalize ()
 {
 }
 
-Key_engraver::Key_engraver ()
+Key_engraver::Key_engraver (Context *c)
+  : Engraver (c)
 {
   key_event_ = 0;
   item_ = 0;
@@ -117,6 +118,7 @@ Key_engraver::create_key (bool is_default)
     {
       SCM visibility = get_property ("explicitKeySignatureVisibility");
       item_->set_property ("break-visibility", visibility);
+      item_->set_property ("non-default", SCM_BOOL_T);
     }
 }
 
@@ -146,7 +148,8 @@ void
 Key_engraver::process_music ()
 {
   if (key_event_
-      || get_property ("lastKeyAlterations") != get_property ("keyAlterations"))
+      || !scm_is_eq (get_property ("lastKeyAlterations"),
+                     get_property ("keyAlterations")))
     create_key (false);
 }