From: Peter Kümmel Date: Wed, 13 Apr 2011 18:54:58 +0000 (+0000) Subject: #7452, no spellcheck menu needed when no text is below cursor X-Git-Tag: 2.0.0~139 X-Git-Url: https://git.lyx.org/gitweb/?a=commitdiff_plain;h=697ffd35d8672d9e36c32e1fff07ddf3974e4379;p=features.git #7452, no spellcheck menu needed when no text is below cursor git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@38369 a592a061-630c-0410-9148-cb99ea01b6c8 --- diff --git a/src/frontends/qt4/Menus.cpp b/src/frontends/qt4/Menus.cpp index 26f90b1078..e150b08758 100644 --- a/src/frontends/qt4/Menus.cpp +++ b/src/frontends/qt4/Menus.cpp @@ -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;