]> git.lyx.org Git - lyx.git/blobdiff - src/support/lyxmanip.h
the freespacing patch from Kayvan, draw the math empty delim with onoffdash, asure...
[lyx.git] / src / support / lyxmanip.h
index 9b1bdcd3373d5cb7be5ee13f2ed2d5a4b3df4d49..75e6c4e04d008f46cfbb3c7f0450f461b0c24337 100644 (file)
@@ -2,19 +2,27 @@
 #ifndef LYX_MANIP_H
 #define LYX_MANIP_H
 
-#include <iomanip>
+#include <iostream>
+
+///
+struct NewLineAndDepth_ {
+       int depth_;
+};
 
 ///
 inline
-ostream & newlineAndDepth_helper(ostream & s, int n)
+NewLineAndDepth_ newlineAndDepth(int n)
 {
-       return s << '\n' << string(n, ' ');
+       NewLineAndDepth_ nlad_;
+       nlad_.depth_ = n;
+       return nlad_;
 }
 ///
 inline
-omanip<int> newlineAndDepth(int n)
+ostream & operator<<(ostream & os, NewLineAndDepth_ const & nlad_)
 {
-       return omanip<int>(newlineAndDepth_helper, n);
+       os << string(nlad_.depth_, ' ');
+       return os;
 }
 
 #endif