def on_query_completions(self, view, prefix, locations):
sometuple = ("MyCompletion\thelper text","MyCompletion")
Are you referring to triggering the auto_completion within a textCommand?
Do you mean how you can have helper in grey on the popup?
TypeError: No registered converter was able to produce a C++ rvalue of type class std::basic_string<wchar_t,struct std::char_traits<wchar_t>,class std::allocator<wchar_t> > from this Python object of type tuple
C0D312 wrote:Unless I'm missing something, you can't add autocompletions via a textCommand. You need to add them with on_query_completions. You can send completions from a textCommand to on_query_completions though.
C0D312 wrote:That triggers the autocompletion popup to appear. It's doing the same job as control+space. However, it doesn't add anything to the completions. In that plugin, I have a global variable "completions." The textCommand adds completions to the variable. Then, because it's global, the method on_query_completions has access to it. On_query_completions then returns a list of tuples for the autocompletion.
Users browsing this forum: Exabot [Bot], mattst, Yahoo [Bot] and 5 guests