accept coordinates up to a million...

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@10278 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
André Pönitz 2005-07-17 12:28:02 +00:00
parent a97c06ef62
commit b11f5b1708
2 changed files with 11 additions and 11 deletions

View File

@ -30,12 +30,13 @@ public:
: x_(0), y_(0)
{}
Point(int x, int y) : x_(x), y_(y)
Point(int x, int y)
: x_(x), y_(y)
{
BOOST_ASSERT(x > -3000);
BOOST_ASSERT(x < 4000);
BOOST_ASSERT(y > -3000);
BOOST_ASSERT(y < 4000);
BOOST_ASSERT(x > -1000000);
BOOST_ASSERT(x < 1000000);
BOOST_ASSERT(y > -1000000);
BOOST_ASSERT(y < 1000000);
}
int x_, y_;

View File

@ -37,6 +37,7 @@
#include "mathed/math_data.h"
#include "mathed/math_inset.h"
#include "mathed/math_scriptinset.h"
#include "mathed/math_macrotable.h"
#include "support/limited_stack.h"
@ -915,10 +916,9 @@ bool LCursor::goUpDown(bool up)
MathScriptInset const * p = prevAtom()->asScriptInset();
if (p && p->has(up)) {
--pos();
push(inset());
idx() = up; // the superscript has index 1
push(*const_cast<MathScriptInset*>(p));
idx() = p->idxOfScript(up);
pos() = lastpos();
//lyxerr << "updown: handled by scriptinset to the left" << endl;
return true;
}
}
@ -927,10 +927,9 @@ bool LCursor::goUpDown(bool up)
if (pos() != lastpos()) {
MathScriptInset const * p = nextAtom()->asScriptInset();
if (p && p->has(up)) {
push(inset());
idx() = up;
push(*const_cast<MathScriptInset*>(p));
idx() = p->idxOfScript(up);
pos() = 0;
//lyxerr << "updown: handled by scriptinset to the right" << endl;
return true;
}
}