]> git.donarmstrong.com Git - lilypond.git/commitdiff
lilypond-0.1.52
authorfred <fred>
Sun, 24 Mar 2002 20:07:26 +0000 (20:07 +0000)
committerfred <fred>
Sun, 24 Mar 2002 20:07:26 +0000 (20:07 +0000)
12 files changed:
lily/axis-group-element.cc
lily/horizontal-group-elem.cc [new file with mode: 0644]
lily/horizontal-vertical-group-elem.cc [new file with mode: 0644]
lily/include/elem-group.hh
lily/include/horizontal-align-item.hh
lily/include/horizontal-group-elem.hh [new file with mode: 0644]
lily/include/horizontal-group-item.hh
lily/include/horizontal-vertical-group-elem.hh [new file with mode: 0644]
lily/include/horizontal-vertical-group-item.hh
lily/include/vertical-align-elem.hh
lily/include/vertical-group-elem.hh [new file with mode: 0644]
lily/vertical-align-grav.cc

index 8ef35c0beade7a6f7a30917827e143d744ab6d72..b97b94cf61556b8065abba8ed204b78bd6a75b9b 100644 (file)
@@ -57,3 +57,5 @@ Axis_group_element::Axis_group_element()
   transparent_b_ = true;
 }
 
+
+IMPLEMENT_IS_TYPE_B1(Axis_group_element, Score_elem);
diff --git a/lily/horizontal-group-elem.cc b/lily/horizontal-group-elem.cc
new file mode 100644 (file)
index 0000000..85ca745
--- /dev/null
@@ -0,0 +1,34 @@
+
+#include "horizontal-group-elem.hh"
+#include "interval.hh"
+#include "item.hh"
+#include "debug.hh"
+
+
+IMPLEMENT_IS_TYPE_B1(Horizontal_group_element, Axis_group_element);
+
+void
+Horizontal_group_element::remove_all()
+{
+  axis_admin_.remove_all (X_AXIS,X_AXIS);
+}
+
+void
+Horizontal_group_element::add_element (Graphical_element*e)
+{
+  axis_admin_.add_element (e,this, X_AXIS,X_AXIS);
+}
+
+void
+Horizontal_group_element::remove_element (Graphical_element*e)
+{
+  axis_admin_.remove_element (e,X_AXIS,X_AXIS);
+}
+
+
+Interval
+Horizontal_group_element::do_width() const
+{
+  return axis_admin_.extent (X_AXIS);
+}
+
diff --git a/lily/horizontal-vertical-group-elem.cc b/lily/horizontal-vertical-group-elem.cc
new file mode 100644 (file)
index 0000000..6b5ddd7
--- /dev/null
@@ -0,0 +1,26 @@
+
+#include "horizontal-vertical-group-elem.hh"
+#include "interval.hh"
+#include "item.hh"
+#include "debug.hh"
+
+void
+Horizontal_vertical_group_element::remove_all()
+{
+  axis_admin_.remove_all (X_AXIS,Y_AXIS);
+}
+void
+Horizontal_vertical_group_element::add_element (Graphical_element *e)
+{
+  axis_admin_.add_element (e, this, X_AXIS, Y_AXIS);
+}
+
+void
+Horizontal_vertical_group_element::remove_element (Graphical_element*e)
+{
+  axis_admin_.remove_element (e, X_AXIS, Y_AXIS);
+}
+
+
+
+IMPLEMENT_IS_TYPE_B2(Horizontal_vertical_group_element, Horizontal_group_element, Vertical_group_element);
index 82ab4cc787517a1883e8bd518cd0d92aea0e4298..59bb03cdf052c0ad86b357eb622ac569f13d11d5 100644 (file)
 
 
 
-/**
-  Treat a group of elements a unity in horizontal sense .
-  A column is a typical Vertical_group.
- */
-class Horizontal_group_element : public virtual Axis_group_element {
-protected:
-    virtual void remove_all();
-    virtual Interval do_width() const;
-
-public:
-    DECLARE_MY_RUNTIME_TYPEINFO;
-    virtual void add_element (Graphical_element*);
-    virtual void remove_element (Graphical_element*);
-
-};
-/**
-  Like Horizontal_group_element, but in X direction
- */
-class Vertical_group_element : public virtual Axis_group_element {
-protected:
-    virtual Interval do_height() const;
-    virtual void remove_all();
-
-public:
-    virtual void add_element (Graphical_element*);
-    virtual void remove_element (Graphical_element*);
-    DECLARE_MY_RUNTIME_TYPEINFO;
-};
-
-/** A class to treat a group of elements as a single entity. The
-  dimensions are the unions of the dimensions of what it contains.
-  Translation means translating the contents.
-  */
-class Horizontal_vertical_group_element : public Vertical_group_element, 
-                                 public Horizontal_group_element 
-{  
-protected:
-    virtual void remove_all();
-public:
-    virtual void add_element (Graphical_element*);
-    virtual void remove_element (Graphical_element*);
-    
-    DECLARE_MY_RUNTIME_TYPEINFO;    
-};
 
+#error
 #endif // ELEM_GROUP_HH
index f223e07be10d03556be8a80acfcc130c5b61dd2d..7ae19db88ba0a1a4b55810b37e3ea201077d5515 100644 (file)
@@ -9,7 +9,7 @@
 
 #ifndef HORIZONTAL_ALIGN_ITEM_HH
 #define HORIZONTAL_ALIGN_ITEM_HH
-#include "elem-group.hh"
+
 #include "item.hh"
 
 /**
diff --git a/lily/include/horizontal-group-elem.hh b/lily/include/horizontal-group-elem.hh
new file mode 100644 (file)
index 0000000..8d3adfb
--- /dev/null
@@ -0,0 +1,33 @@
+/*   
+  horizontal-group-elem.hh -- declare 
+  
+  source file of the GNU LilyPond music typesetter
+  
+  (c) 1997 Han-Wen Nienhuys <hanwen@cs.ruu.nl>
+  
+ */
+
+#ifndef HORIZONTAL_GROUP_ELEM_HH
+#define HORIZONTAL_GROUP_ELEM_HH
+
+#include "axis-group-element.hh"
+
+/**
+  Treat a group of elements a unity in horizontal sense .
+  A column is a typical Vertical_group.
+ */
+class Horizontal_group_element : public virtual Axis_group_element {
+protected:
+    virtual void remove_all();
+    virtual Interval do_width() const;
+
+public:
+    DECLARE_MY_RUNTIME_TYPEINFO;
+    virtual void add_element (Graphical_element*);
+    virtual void remove_element (Graphical_element*);
+
+};
+
+
+#endif /* HORIZONTAL_GROUP_ELEM_HH */
+
index 10d8106b1d5eb790fe6ede1ef08d765e9b22e30e..568c257c64bfc0d890d02310f92950207f8b2f4b 100644 (file)
@@ -10,7 +10,7 @@
 #ifndef HORIZONTAL_GROUP_ITEM_HH
 #define HORIZONTAL_GROUP_ITEM_HH
 
-#include "elem-group.hh"
+#include "horizontal-group-elem.hh"
 #include "axis-group-item.hh"
 
 /**
diff --git a/lily/include/horizontal-vertical-group-elem.hh b/lily/include/horizontal-vertical-group-elem.hh
new file mode 100644 (file)
index 0000000..9080872
--- /dev/null
@@ -0,0 +1,35 @@
+/*   
+  horizontal-vertical-group-elem.hh -- declare 
+  
+  source file of the GNU LilyPond music typesetter
+  
+  (c) 1997 Han-Wen Nienhuys <hanwen@cs.ruu.nl>
+  
+ */
+
+#ifndef HORIZONTAL_VERTICAL_GROUP_ELEM_HH
+#define HORIZONTAL_VERTICAL_GROUP_ELEM_HH
+
+#include "vertical-group-elem.hh"
+#include "horizontal-group-elem.hh"
+
+/** A class to treat a group of elements as a single entity. The
+  dimensions are the unions of the dimensions of what it contains.
+  Translation means translating the contents.
+  */
+class Horizontal_vertical_group_element : public Vertical_group_element, 
+                                 public Horizontal_group_element 
+{  
+protected:
+    virtual void remove_all();
+public:
+    virtual void add_element (Graphical_element*);
+    virtual void remove_element (Graphical_element*);
+    
+    DECLARE_MY_RUNTIME_TYPEINFO;    
+};
+
+
+#endif /* HORIZONTAL_VERTICAL_GROUP_ELEM_HH */
+
+
index 733ff639bda653b427a01c914c3dee44373354d8..1aa8c8b82ca5254d09d91afd42f7845800ef29e2 100644 (file)
@@ -11,7 +11,7 @@
 #define HORIZONTAL_VERTICAL_GROUP_ITEM_HH
 
 #include "axis-group-item.hh"
-#include "elem-group.hh"
+#include "horizontal-vertical-group-elem.hh"
 
 
 /**
index bb6b7ed48f937217b1eefa836eb5537b9895d6af..a01e2c5164c045e212a16e5f75957f02ad351e80 100644 (file)
@@ -10,7 +10,7 @@
 #ifndef VERTICAL_ALIGN_ITEM_HH
 #define VERTICAL_ALIGN_ITEM_HH
 
-#include "elem-group.hh"
+#include "score-elem.hh"
 
 /**
   Order elements top to bottom.
diff --git a/lily/include/vertical-group-elem.hh b/lily/include/vertical-group-elem.hh
new file mode 100644 (file)
index 0000000..5e46c66
--- /dev/null
@@ -0,0 +1,29 @@
+/*   
+  vertical-group-elem.hh -- declare 
+  
+  source file of the GNU LilyPond music typesetter
+  
+  (c) 1997 Han-Wen Nienhuys <hanwen@cs.ruu.nl>
+  
+ */
+
+#ifndef VERTICAL_GROUP_ELEM_HH
+#define VERTICAL_GROUP_ELEM_HH
+
+#include "axis-group-element.hh"
+/**
+  Like Horizontal_group_element, but in X direction
+ */
+class Vertical_group_element : public virtual Axis_group_element {
+protected:
+    virtual Interval do_height() const;
+    virtual void remove_all();
+
+public:
+    virtual void add_element (Graphical_element*);
+    virtual void remove_element (Graphical_element*);
+    DECLARE_MY_RUNTIME_TYPEINFO;
+};
+
+#endif /* VERTICAL_GROUP_ELEM_HH */
+
index 94f5d0520437e3da70de61835c5c920c39731380..fe773a9375ac5a2dea9da15c57c91555b112143e 100644 (file)
@@ -9,6 +9,7 @@
 #include "p-col.hh"
 #include "vertical-align-grav.hh"
 #include "vertical-align-spanner.hh"
+#include "vertical-group-elem.hh"
 
 Vertical_align_engraver::Vertical_align_engraver()
 {