]> git.lyx.org Git - features.git/commitdiff
* LyXText::getPitNearY(): Make it const.
authorAbdelrazak Younes <younes@lyx.org>
Wed, 28 Mar 2007 09:20:38 +0000 (09:20 +0000)
committerAbdelrazak Younes <younes@lyx.org>
Wed, 28 Mar 2007 09:20:38 +0000 (09:20 +0000)
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@17607 a592a061-630c-0410-9148-cb99ea01b6c8

src/lyxtext.h
src/text2.C

index 897808cca860789ac90c57995140309b4efb7b67..e1c4dc378b20708439e0c999f6d8d20fbd7a1dcf 100644 (file)
@@ -139,10 +139,9 @@ public:
        /// This method uses the BufferView CoordCache to locate the
        /// paragraph. The y-coodinate is allowed to be off-screen and
        /// the CoordCache will be automatically updated if needed. This is
-       /// the reason why we need a non const BufferView and why this
-       /// method is non-const.
+       /// the reason why we need a non const BufferView.
        /// FIXME: move to TextMetrics.
-       pit_type getPitNearY(BufferView & bv, int y);
+       pit_type getPitNearY(BufferView & bv, int y) const;
 
        /** Find the word under \c from in the relative location
         *  defined by \c word_location.
index d27f5e1dbdb4fcdfe5b8580174c4e20014816fdd..f4d8a4df17ade22a2ff72efac852c908a9cf3d14 100644 (file)
@@ -751,7 +751,7 @@ void LyXText::setCurrentFont(LCursor & cur)
 }
 
 // y is screen coordinate
-pit_type LyXText::getPitNearY(BufferView & bv, int y)
+pit_type LyXText::getPitNearY(BufferView & bv, int y) const
 {
        BOOST_ASSERT(!paragraphs().empty());
        BOOST_ASSERT(bv.coordCache().getParPos().find(this) != bv.coordCache().getParPos().end());