summary |
shortlog |
log |
commit | commitdiff |
tree
raw |
patch |
inline | side by side (from parent 1:
42d9dbd)
-void MathCursor::getPos(int & x, int & y)
+void MathCursor::getPos(int & x, int & y) const
{
par()->getPos(idx(), pos(), x, y);
}
{
par()->getPos(idx(), pos(), x, y);
}
+int MathCursor::targetX() const
+{
+ if (targetx_ != -1)
+ return targetx_;
+ int x = 0, y = 0;
+ getPos(x, y);
+ return x;
+}
+
+
MathInset * MathCursor::par() const
{
return cursor().par_;
MathInset * MathCursor::par() const
{
return cursor().par_;
/// in pixels from top of screen
void setPos(int x, int y);
/// in pixels from top of screen
/// in pixels from top of screen
void setPos(int x, int y);
/// in pixels from top of screen
- void getPos(int & x, int & y);
+ void getPos(int & x, int & y) const;
+ /// in pixels from left of screen
+ int targetX() const;
/// current inset
MathInset * par() const;
/// return the next enclosing grid inset and the cursor's index in it
/// current inset
MathInset * par() const;
/// return the next enclosing grid inset and the cursor's index in it