]> git.lyx.org Git - features.git/commitdiff
fix for cursor movement from text into mathed.
authorAbdelrazak Younes <younes@lyx.org>
Sat, 22 Dec 2007 09:25:59 +0000 (09:25 +0000)
committerAbdelrazak Younes <younes@lyx.org>
Sat, 22 Dec 2007 09:25:59 +0000 (09:25 +0000)
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@22253 a592a061-630c-0410-9148-cb99ea01b6c8

src/Cursor.cpp

index 416e666047cba1d3e108c0bfded27c0c559aee05..674075a8ec1ff0d0c0271b28e4110db422737ea2 100644 (file)
@@ -419,7 +419,8 @@ void Cursor::getPos(int & x, int & y) const
 
 Row const & Cursor::textRow() const
 {
-       ParagraphMetrics const & pm = bv().parMetrics(text(), pit());
+       CursorSlice const & cs = innerTextSlice();
+       ParagraphMetrics const & pm = bv().parMetrics(cs.text(), cs.pit());
        BOOST_ASSERT(!pm.rows().empty());
        return pm.getRow(pos(), boundary());
 }