]> git.lyx.org Git - lyx.git/blobdiff - src/VSpace.cpp
continue spellchecking after "replace all"
[lyx.git] / src / VSpace.cpp
index 0cbf1bbb0b15357b5af80daacbeb1792a6f044cd..19f6af41a1f638d282263e6f6be1ef01ccdf19a3 100644 (file)
@@ -23,7 +23,7 @@
 #include "support/convert.h"
 #include "support/lstrings.h"
 
-#include "support/assert.h"
+#include "support/lassert.h"
 
 #include <cstring>
 
@@ -493,6 +493,24 @@ docstring const VSpace::asGUIName() const
 }
 
 
+string VSpace::asHTMLLength() const 
+{
+       string result;
+       switch (kind_) {
+               case DEFSKIP:   result = "2ex"; break;
+               case SMALLSKIP: result = "1ex"; break;
+               case MEDSKIP:   result = "3ex"; break;
+               case BIGSKIP:   result = "5ex"; break;
+               case LENGTH: {
+                       Length tmp = len_.len();
+                       if (tmp.value() > 0)
+                               result = tmp.asHTMLString();
+               }
+               case VFILL:     break;
+       }
+       return result;
+}
+
 int VSpace::inPixels(BufferView const & bv) const
 {
        // Height of a normal line in pixels (zoom factor considered)