]> git.lyx.org Git - lyx.git/blobdiff - src/mathed/InsetMathGrid.C
make it compile again (hopefully)
[lyx.git] / src / mathed / InsetMathGrid.C
index 4336e0657278ab41eb31cbe0ac6bac65c2d36836..8c160fc63961ba36078bd0485311020cd285990b 100644 (file)
@@ -44,7 +44,6 @@ using std::string;
 using std::auto_ptr;
 using std::istream;
 using std::istringstream;
-using std::ostringstream;
 using std::vector;
 
 
@@ -60,12 +59,12 @@ public:
        ///
        virtual string const inset2string(Buffer const &) const
        {
-               ostringstream data;
+               lyx::odocstringstream data;
                //data << name() << " active_cell " << inset.getActCell() << '\n';
-               data << name() << " active_cell " << 0 << '\n';
+               data << lyx::from_utf8(name()) << " active_cell " << 0 << '\n';
                WriteStream ws(data);
                inset_.write(ws);
-               return data.str();
+               return lyx::to_utf8(data.str());
        }
 
 protected:
@@ -784,7 +783,7 @@ bool InsetMathGrid::idxUpDown(LCursor & cur, bool up) const
                        return false;
                cur.idx() += ncols();
        }
-       cur.pos() = cur.cell().x2pos(cur.x_target() - cur.cell().xo());
+       cur.pos() = cur.cell().x2pos(cur.x_target() - cur.cell().xo(cur.bv()));
        return true;
 }