]> git.lyx.org Git - lyx.git/blobdiff - src/Dimension.h
Account for old versions of Pygments
[lyx.git] / src / Dimension.h
index 8b7744b2742fa20fd411e96ae0f2cf44cb09c5b5..0607be6eba20e222f1eda6a18d43f4b34d5a13dc 100644 (file)
@@ -4,7 +4,7 @@
  * This file is part of LyX, the document processor.
  * Licence details can be found in the file COPYING.
  *
- * \author André Pönitz
+ * \author André Pönitz
  *
  * Full author contact details are available in file CREDITS.
  */
@@ -32,6 +32,8 @@ public:
        void operator+=(Dimension const & dim);
        /// set to empty box
        void clear() { wid = asc = des = 0; }
+       /// check if box is empty
+       bool empty() const { return wid == 0 && asc == 0 && wid == 0; }
        /// get height
        int height() const { return asc + des; }
        /// get ascent