]> git.lyx.org Git - lyx.git/blobdiff - src/mathed/MathData.cpp
When inserting math inset over selection, place cursor better
[lyx.git] / src / mathed / MathData.cpp
index 87b1820cba7d81b38a5c76b8e39c7e324d73fd69..1c7eaccfa4c73470bd891c2d0a41a1fcf165944f 100644 (file)
@@ -52,6 +52,14 @@ MathData::MathData(Buffer * buf, const_iterator from, const_iterator to)
 {}
 
 
+void MathData::setBuffer(Buffer & b)
+{
+       buffer_ = &b;
+       for (MathAtom & at : *this)
+               at.nucleus()->setBuffer(b);
+}
+
+
 MathAtom & MathData::operator[](pos_type pos)
 {
        LBUFERR(pos < size());