mirror of
https://git.lyx.org/repos/lyx.git
synced 2024-12-31 07:45:44 +00:00
Additional cursor position validation required to avoid an assertion in Text::selectWord
This commit is contained in:
parent
04ada8e5fa
commit
7391ca961d
@ -1719,6 +1719,8 @@ void BufferView::dispatch(FuncRequest const & cmd, DispatchResult & dr)
|
|||||||
}
|
}
|
||||||
if (cur.selection())
|
if (cur.selection())
|
||||||
pattern = cur.selectionAsString(false);
|
pattern = cur.selectionAsString(false);
|
||||||
|
else if (!cur.inTexted())
|
||||||
|
break; // not suitable for selectWord at cursor
|
||||||
else {
|
else {
|
||||||
pos_type spos = cur.pos();
|
pos_type spos = cur.pos();
|
||||||
cur.innerText()->selectWord(cur, WHOLE_WORD);
|
cur.innerText()->selectWord(cur, WHOLE_WORD);
|
||||||
|
Loading…
Reference in New Issue
Block a user