]> git.lyx.org Git - lyx.git/blobdiff - src/dimension.C
* GuiView.C (updateTab): do not update early if current tab has
[lyx.git] / src / dimension.C
index f7fdd750899f90af92f586d3bbe3ee7d1ed6e98e..c9a51d37e4f3944ecc52e7a08720382d0fc09454 100644 (file)
@@ -5,29 +5,23 @@
  *
  *  \author André Pönitz
  *
- * Full author contact details are available in file CREDITS
+ * Full author contact details are available in file CREDITS.
  */
 
-
 #include <config.h>
 
 #include "dimension.h"
-#include "frontends/font_metrics.h"
+
+namespace lyx {
 
 
 void Dimension::operator+=(Dimension const & dim)
 {
-       if (a < dim.a)
-               a = dim.a;
-       if (d < dim.d)
-               d = dim.d;
-       w += dim.w;
+       if (asc < dim.asc)
+               asc = dim.asc;
+       if (des < dim.des)
+               des = dim.des;
+       wid += dim.wid;
 }
 
-
-void Dimension::clear(LyXFont const & font)
-{
-       a = font_metrics::maxAscent(font);
-       d = font_metrics::maxDescent(font);
-       w = 0;
-}
+} // namespace lyx