word completion ignore the word on which the cursor is present
This commit is contained in:
parent
2b997719c3
commit
1d7a481e81
|
@ -771,11 +771,17 @@ public:
|
|||
|
||||
String prefix{begin, end};
|
||||
|
||||
while (end != buffer.end() and is_word(*end))
|
||||
++end;
|
||||
|
||||
String current_word{begin, end};
|
||||
|
||||
std::unordered_set<String> matches;
|
||||
auto bufmatches = get_word_db(buffer).find_prefix(prefix);
|
||||
matches.insert(bufmatches.begin(), bufmatches.end());
|
||||
|
||||
matches.erase(current_word);
|
||||
|
||||
if (other_buffers)
|
||||
{
|
||||
for (const auto& buf : BufferManager::instance())
|
||||
|
|
Loading…
Reference in New Issue
Block a user