]> git.lyx.org Git - lyx.git/blobdiff - src/mathed/math_fracbase.C
use stream-like syntax for LaTeX output
[lyx.git] / src / mathed / math_fracbase.C
index e52a841fccd689220d2953e3db542bc9bc1eeb7f..0cb0086bb2fb93e0403091b9df4853d6a0062a7b 100644 (file)
@@ -10,31 +10,37 @@ MathFracbaseInset::MathFracbaseInset()
 {}
 
 
-bool MathFracbaseInset::idxRight(int &, int &) const
+bool MathFracbaseInset::idxRight(MathInset::idx_type &,
+                                MathInset::pos_type &) const
 {
        return false;
 }
 
 
-bool MathFracbaseInset::idxLeft(int &, int &) const
+bool MathFracbaseInset::idxLeft(MathInset::idx_type &,
+                               MathInset::pos_type &) const
 {
        return false;
 }
 
 
-bool MathFracbaseInset::idxUp(int & idx, int &) const
+bool MathFracbaseInset::idxUp(MathInset::idx_type & idx,
+                             MathInset::pos_type & pos) const
 {
        if (idx == 0)
                return false;
        idx = 0;
+       pos = std::min(pos, cell(idx).size());
        return true;
 }
 
 
-bool MathFracbaseInset::idxDown(int & idx, int &) const
+bool MathFracbaseInset::idxDown(MathInset::idx_type & idx,
+                               MathInset::pos_type & pos) const
 {
        if (idx == 1)
                return false;
        idx = 1;
+       pos = std::min(pos, cell(idx).size());
        return true;
 }