ctrl+space closes completion panel if only one item is displayed
Description of the bug
Title and the following should make it clear.
Steps to reproduce
-
open ST in safe mode
-
create a new view and paste
<table> <thead> <?php bcompiler_write_header ?> </thead> </table> -
set caret behind
bcompiler_write_headerand hitctrl+space-> completions popup opens -
hit
ctrl+spaceagain
Expected behavior
In this particular situation, nothing should happen as there is only one completion available.
ST should however query new completions and update completions if more ore found.
Actual behavior
If multiple completions are displayed, ctrl+space works as expected, doing nothing if last of multiple items is selected.
If however a single completion (bcompiler_write_header) is displayed, completion popup is closed by hitting ctrl+space and caret moves to next line.
Sublime Text build number
4175
Operating system & version
Windows 11
(Linux) Desktop environment and/or window manager
No response
Additional information
It seems to be related with a change made by ST 4145. Can't find a changelog entry or related bug entry though, which gives reasons for this change in behavior. Maybe moving to next line is intentional for some reason, but it feels odd in the particular situation, described.
diff --git a/Default (Windows).sublime-keymap b/Default (Windows).sublime-keymap
--- a/Default (Windows).sublime-keymap
+++ b/Default (Windows).sublime-keymap
@@ -360,6 +361,5 @@
- { "keys": ["ctrl+space"], "command": "move", "args": { "by": "lines", "forward": true }, "context":
+ { "keys": ["ctrl+space"], "command": "move", "args": {"by": "lines", "forward": true}, "context":
[
- { "key": "auto_complete_visible", "operator": "equal", "operand": true }
+ { "key": "auto_complete_primed", "operator": "equal", "operand": true },
]
},
OpenGL context information
No response