]> git.donarmstrong.com Git - lilypond.git/blobdiff - lily/include/grob.hh
release: 1.5.19
[lilypond.git] / lily / include / grob.hh
index dc95ba514311b805fad570ffea75c3bf1ead75b7..e9665ea31b6057f4b75d96cdc740ca0f290f4998 100644 (file)
@@ -28,6 +28,10 @@ enum Grob_status {
 
 typedef void (Grob::*Grob_method_pointer) (void);
 
+
+#define get_grob_property(x) internal_get_grob_property(ly_symbol2scm(x))
+#define set_grob_property(x,y) internal_set_grob_property(ly_symbol2scm(x),y)
+
 /*
    Basic output object.
 */
@@ -46,7 +50,7 @@ public:
 
     0 means ORPHAN,
    */
-  char status_i_;
+  char status_c_;
   String name () const;
 
   /*
@@ -62,12 +66,14 @@ public:
   /*
     properties
    */
-  SCM get_grob_property (const char*) const;
-  SCM get_grob_property (SCM) const;
-  void set_grob_property (const char * , SCM val);
+  SCM internal_get_grob_property (SCM) const;
+  void internal_set_grob_property (SCM, SCM val);
+  
+#if 0
   void set_immutable_grob_property (const char * , SCM val);
-  void set_immutable_grob_property (SCM key, SCM val);  
-  void set_grob_property (SCM , SCM val);  
+  void set_immutable_grob_property (SCM key, SCM val);
+#endif
+  
   void set_elt_pointer (const char*, SCM val);
   friend class Property_engraver; //  UGHUGHUGH.
   SCM remove_grob_property (const char* nm);
@@ -89,14 +95,14 @@ public:
  
   /**
      Recursively track all dependencies of this Grob.  The
-     status_i_ field is used as a mark-field.  It is marked with
+     status_c_ field is used as a mark-field.  It is marked with
      #busy# during execution of this function, and marked with #final#
      when finished.
 
      #funcptr# is the function to call to update this element.
    */
   void calculate_dependencies (int final, int busy, SCM funcname);
-  static SCM handle_broken_smobs (SCM, SCM criterion);
+  static SCM handle_broken_grobs(SCM, SCM criterion);
 
   virtual void do_break_processing ();
   virtual Grob *find_broken_piece (Line_of_score*) const;
@@ -170,11 +176,11 @@ public:
    */
   void set_parent (Grob* e, Axis);
   
-  Grob *parent_l (Axis a) const;
+  Grob *parent_l (Axis a) const {   return  dim_cache_[a].parent_l_; }
   DECLARE_SCHEME_CALLBACK (fixup_refpoint, (SCM));
 };
 
-Grob * unsmob_grob (SCM);
+DECLARE_UNSMOB(Grob,grob);
 
 #endif // STAFFELEM_HH