On 2021-06-22, David Fishburn <
dfishb...@gmail.com> wrote:
> Life,
>
> I am not sure I quite understand your use case for the plugin.
Thanks for the feedback. My goal is to have some sort of
context-sensitive completion. My use case is ConTeXt, which can include
MetaPost blocks:
\starttext
TeX code here: filetype is `context`
\startMPcode
% Nested filetype here is `mp`.
% MetaPost code here.
% Only `mpSomething` syntax groups should be used for
% completion.
\stopMPcode
TeX code again: filetype is again `context`.
Only `contextSomething` syntax groups should be used.
\stoptext
Within the ...MPcode block, where a nested filetype is active, I'd like
completion only for that filetype. AFAICT, I can add MetaPost syntax
groups using omni_syntax_group_include_context, but they will be active
throughout the buffer.
The snippet I have posted allows me to do that sort of context-sensitive
completion, but maybe there is a better/more efficient way.
Thanks,
Life.