]> git.lyx.org Git - features.git/commitdiff
#7452, no spellcheck menu needed when no text is below cursor
authorPeter Kümmel <syntheticpp@gmx.net>
Wed, 13 Apr 2011 18:54:58 +0000 (18:54 +0000)
committerPeter Kümmel <syntheticpp@gmx.net>
Wed, 13 Apr 2011 18:54:58 +0000 (18:54 +0000)
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@38369 a592a061-630c-0410-9148-cb99ea01b6c8

src/frontends/qt4/Menus.cpp

index 26f90b1078e4cb5c7ac4f2b9e3ed746fe25e2bb2..e150b08758af7676f79bc8a864511cffabbd5a4f 100644 (file)
@@ -764,9 +764,11 @@ void MenuDefinition::expandSpellingSuggestions(BufferView const * bv)
 {
        if (!bv)
                return;
+       Cursor const & cur = bv->cursor();
+       if (!cur.inTexted())
+               return;
        WordLangTuple wl;
        docstring_list suggestions;
-       Cursor const & cur = bv->cursor();
        Paragraph const & par = cur.paragraph();
        pos_type from = cur.pos();
        pos_type to = from;