]> git.lyx.org Git - lyx.git/blob - src/mathed/math_fracbase.C
small up/down tweaking
[lyx.git] / src / mathed / math_fracbase.C
1 #ifdef __GNUG__
2 #pragma implementation
3 #endif
4
5 #include "math_fracbase.h"
6
7
8 MathFracbaseInset::MathFracbaseInset()
9         : MathNestInset(2)
10 {}
11
12
13 bool MathFracbaseInset::idxRight(idx_type &, pos_type &) const
14 {
15         return false;
16 }
17
18
19 bool MathFracbaseInset::idxLeft(idx_type &, pos_type &) const
20 {
21         return false;
22 }
23
24
25 bool MathFracbaseInset::idxUpDown(idx_type & idx, pos_type & pos, bool up,
26         int targetx) const
27 {
28         MathInset::idx_type target = !up; // up ? 0 : 1, since upper cell has idx 0
29         if (idx == target)
30                 return false;
31         idx = target;
32         pos = cell(idx).x2pos(targetx);
33         return true;
34 }