aboutsummaryrefslogtreecommitdiff
path: root/modules
diff options
context:
space:
mode:
authormitchell <70453897+667e-11@users.noreply.github.com>2011-10-26 23:06:14 -0400
committermitchell <70453897+667e-11@users.noreply.github.com>2011-10-26 23:06:14 -0400
commit1e33a4f3673ede2cfc0bea244f02fe2267905a65 (patch)
treeef78e08e8a6fbd0c3a3177ad15be1cb09ae6c206 /modules
parent69c46537c92d39fce84ff5a85e4e0e3995770389 (diff)
downloadtextadept-1e33a4f3673ede2cfc0bea244f02fe2267905a65.tar.gz
textadept-1e33a4f3673ede2cfc0bea244f02fe2267905a65.zip
Fixed Adeptsense autocomplete for single item; modules/textadept/adeptsense.lua
Diffstat (limited to 'modules')
-rw-r--r--modules/textadept/adeptsense.lua4
1 files changed, 2 insertions, 2 deletions
diff --git a/modules/textadept/adeptsense.lua b/modules/textadept/adeptsense.lua
index ee6fa1e9..5be70959 100644
--- a/modules/textadept/adeptsense.lua
+++ b/modules/textadept/adeptsense.lua
@@ -515,8 +515,8 @@ function complete(sense, only_fields, only_functions)
else
-- Scintilla does not emit `AUTO_C_SELECTION` in this case. This is
-- necessary for autocompletion with multiple selections.
- events.emit(events.AUTO_C_SELECTION, completions[1]:sub(#part + 1),
- buffer.current_pos)
+ local text = completions[1]:sub(#part + 1):match('^(.+)%?%d+$')
+ events.emit(events.AUTO_C_SELECTION, text, buffer.current_pos)
end
return true
end