]> git.donarmstrong.com Git - lilypond.git/blobdiff - lily/box.cc
* mf/feta-schrift.mf ("Trill (`tr')"): Fix typo.
[lilypond.git] / lily / box.cc
index efed2217b57af21b1d870e0e11a95d90d44a17b8..5463abef8633e85cbc5e5c6c0f35f80bbf3a42ba 100644 (file)
@@ -3,23 +3,24 @@
 
   source file of the GNU LilyPond music typesetter
 
-  (c) 1996--2002 Han-Wen Nienhuys <hanwen@cs.uu.nl>
+  (c) 1996--2004 Han-Wen Nienhuys <hanwen@cs.uu.nl>
 */
 
 #include "box.hh"
+
 #include "array.hh"
 
 void
 Box::translate (Offset o)
 {
-  for (Axis i=X_AXIS; i < NO_AXES; incr (i))
+  for (Axis i = X_AXIS; i < NO_AXES; incr (i))
     interval_a_[i] += o[i];
 }
 
 void
 Box::unite (Box b)
 {
-  for (Axis i=X_AXIS; i < NO_AXES; incr (i))
+  for (Axis i = X_AXIS; i < NO_AXES; incr (i))
     interval_a_[i].unite (b[i]);
 }
 
@@ -72,6 +73,12 @@ Box::add_point (Offset o)
 Offset
 Box::center () const
 {
-  return Offset (interval_a_[X_AXIS].center(),
-                interval_a_[Y_AXIS].center()); 
+  return Offset (interval_a_[X_AXIS].center (),
+                interval_a_[Y_AXIS].center ()); 
+}
+void
+Box::widen (Real x, Real y)
+{
+  interval_a_[X_AXIS].widen (x);
+  interval_a_[Y_AXIS].widen (y);
 }