-
Notifications
You must be signed in to change notification settings - Fork 395
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
More specific functions for vimtex API #2212
Comments
E.g. something like |
I.e., if you have the following source \begin{x}
cursor here
\end{x} with the cursor where indicated, then |
Wouldn't it be easier to have |
Sorry, I was wrong.
No, not quite - it would have to return the syntax stack. However, we have |
I think a concrete use case would go a long way here...
I'd expect the _inner_most environment to be more useful in most cases? (The outermost environment tends to be So I guess you'd either need two functions ( |
hah, my mistake... in any case, I'll add the functions more or less as described here:
|
I don't see how anybody could complain about that :) |
@lervag thanks a lot for the quick response! Apparently the documentation I read contained only a subset of the commands. |
@lervag An of topic question: Whenever I start the continuous compile mode the preview application on my OS opens and shows the rendered pdf. How can I disable this (that vimtex automatically causes this application to open)/change the application? |
Right? :) I've pushed the first version of this. A "simple" and straightforward implementation, but I believe it should do the trick. Let me know what you think.
Yes, I assume you refer to
First, it is not really VimTeX that does this; it is the standard behaviour of latexmk. But VimTeX does configure latexmk to use the same viewer as specified in VimTeX. And yes, VimTeX does have an option to prevent the automatic viewer. Just add |
@lervag again, thanks a lot for your help (it's very rare that the creator of an extension is so quick in helping its users). |
Glad to help, and thanks for the kind words :) |
The vimtex api is great so far but I would like to have the possibility to find out whether my cursor is currently in a
x
section wherex
is just a placeholder for any possible section, e.g.and I would like to be able to call some API function to tell me whether my cursor currently is in an
x
-block.The text was updated successfully, but these errors were encountered: