]> git.lyx.org Git - features.git/commitdiff
Use normal cursor shape in ERT insets.
authorDekel Tsur <dekelts@tau.ac.il>
Mon, 13 Aug 2001 17:57:14 +0000 (17:57 +0000)
committerDekel Tsur <dekelts@tau.ac.il>
Mon, 13 Aug 2001 17:57:14 +0000 (17:57 +0000)
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@2506 a592a061-630c-0410-9148-cb99ea01b6c8

src/BufferView2.C
src/ChangeLog

index faf26c0d291b9533f0a5e41ab9193b657352ffd7..3aac225fed9347551cb1e7eb8c430e3798658db7 100644 (file)
@@ -411,16 +411,19 @@ void BufferView::showLockedInsetCursor(int x, int y, int asc, int desc)
 {
        if (available() && theLockingInset()) {
                LyXCursor cursor = text->cursor;
+               Inset * locking_inset = theLockingInset()->getLockingInset();
+
                if ((cursor.pos() - 1 >= 0) &&
                    (cursor.par()->getChar(cursor.pos() - 1) ==
                     Paragraph::META_INSET) &&
                    (cursor.par()->getInset(cursor.pos() - 1) ==
-                    theLockingInset()->getLockingInset()))
+                    locking_inset))
                        text->setCursor(this, cursor,
                                        cursor.par(), cursor.pos() - 1);
                LyXScreen::Cursor_Shape shape = LyXScreen::BAR_SHAPE;
                LyXText * txt = getLyXText();
-               if (theLockingInset()->getLockingInset()->isTextInset() &&
+               if (locking_inset->isTextInset() &&
+                   locking_inset->lyxCode() != Inset::ERT_CODE &&
                    (txt->real_current_font.language() !=
                     buffer()->params.language
                     || txt->real_current_font.isVisibleRightToLeft()
index d8d1cd744eb17cd8de14ef2fb363ea1d1ac7973d..391c1024123980640618accf2a446e6dad682c02 100644 (file)
@@ -1,3 +1,8 @@
+2001-08-13  Dekel Tsur  <dekelts@tau.ac.il>
+
+       * BufferView2.C (showLockedInsetCursor): Use normal cursor shape in
+       ERT insets.
+
 2001-08-13  Juergen Vigna  <jug@sad.it>
 
        * text.C (fill): return 0 instead of 20 as this seems to be the more