We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent b9f1fca commit 2263349Copy full SHA for 2263349
plugins_/command_completions/__init__.py
@@ -31,9 +31,13 @@ def _escape_in_snippet(v):
31
32
33
def is_plugin(view):
34
- """Use some heuristics to determine whether a Python view shows a plugin."""
+ """Use some heuristics to determine whether a Python view shows a plugin.
35
+
36
+ Or the console input widget, should it be using the Python syntax.
37
+ """
38
return (view.find("import sublime", 0, sublime.LITERAL) is not None
- or sublime.packages_path() in (view.file_name() or ""))
39
+ or sublime.packages_path() in (view.file_name() or "")
40
+ or view.settings().get('is_widget'))
41
42
43
def create_args_snippet_from_command_args(command_args, quote_char='"', for_json=True):
0 commit comments