Skip to main content
Share Your Experience: Take the 2024 Developer Survey

Questions tagged [plugin-vimtex]

Questions about the plugin vim-tex which provides enhanced TeX support for Vim.

Filter by
Sorted by
Tagged with
2 votes
3 answers
71 views

LaTeX with UltiSnips: How to automatically insert backslash in front of every math variable?

I use LaTeX inside Vim with Vim-tex and Ultisnips. The majority of my snippets are those created by Gilles Castel. In one of his snippets, he writes the following: priority 200 context "math()&...
Ian McGettigan's user avatar
2 votes
2 answers
55 views

How can I jump outside the scope of LaTeX delimiters?

I want to define insert mode mappings that will jump outside the scope of any delimiter I'm in (forward/backward). Where "delimiter" is in the broad sense of LaTeX delimiters, so not only {},...
Ur Ya'ar's user avatar
  • 127
2 votes
0 answers
22 views

Apply listchars to concealed text by vimtex

I am writing LaTeX with vimtex conceal feature, and need to distinguish between the regular space U+0020 versus the non breaking space U+00A0. Here is a minimal example to reproduce the issue. \...
flinch9483's user avatar
0 votes
0 answers
62 views

VimTeX: Viewer cannot find Zathura window ID! (Ubuntu 22.04 LTS x11)

The PDF file is not opening with Zathura after the VimTeX compilation. I am using https://github.com/benbrastmckie/.config and the file vimtex.lua in my directory ~/.config/nvim/lua/neotex/plugins ...
raf's user avatar
  • 101
0 votes
1 answer
38 views

VimTex is nonstop compiling if gnuplottex is used

I am using VimTex to write LaTex. I am trying to use gnuplottex in my documents, but get the problem that VimTex won't stop compiling the tex file. I am guessing that some gnuplot related files are ...
dragontec12's user avatar
0 votes
0 answers
74 views

Contextual Snippets not working in inline mathmode of vimwiki

I am trying to use the snippets in math context inside vimwiki filetypes. The math contextual snippets are working fine for ".tex" files, but not for ".wiki" files. However all the ...
vishal rao's user avatar
0 votes
1 answer
305 views

Deoplete + Vimtex with Lazy.nvim. Deoplete is not triggered

I tried to migrate fomr packer.nvim to lazy.nvim and I encounter problem with deoplete. With packer is triggered on every document and .tex files. With Lazy.nvim is not. I appreciate any help! Here is ...
Mafsi's user avatar
  • 225
0 votes
1 answer
110 views

Neovim slow while compiling LaTeX [closed]

When I compile a .tex file using vimtex it takes a hot second to compile. Following this post I obtained the profile.log while compiling latex [given below is just the sorted part] FUNCTIONS SORTED ...
kay's user avatar
  • 61
1 vote
1 answer
71 views

Migrating from Latex-Suite to vimtex

So I've been using latex-suite for a few years, and I realised recently that vimtex has some nice features (especially the text objects). So I'm tempted to use that instead, but it would require me to ...
Ronak M Soni's user avatar
1 vote
1 answer
51 views

VimTeX omnicompletion for bibliography

Problem with builtin omnicompletion for bibliography. It works on main.tex, but not in the chapters. This is the tree structure: ├── chapters │   ├── actors_behaviour.tex │   ├── analysis_acts.tex │   ...
enrico223's user avatar
2 votes
2 answers
714 views

Conceal comments in Vim/Neovim

I am writing a lot of latex and would like to conceal comments. There are often several lines of text that I comment but would like to keep/not delete. Concealing comments explained: A comment is ...
baxbear's user avatar
  • 314
1 vote
1 answer
631 views

Setting custom global variables from command-line with `nvim` command

Occasionally I would like to override my standard nvim configuration, for example, to tell it not to load vimtex's folding configuration for a very large or complicated tex file for which I don't need ...
Alex Roberts's user avatar
-1 votes
1 answer
374 views

vimtex#syntax#in_mathzone with tree-sitter and texlab

Vimtex provides the very useful family of functions vimtex#syntax#in_mathzone(), vimtex#syntax#in_comment() and vimtex#env#is_inside('...'), which come in handy for context sensitive snippets, e.g. ...
Gargantuar's user avatar
1 vote
2 answers
575 views

Vimtex - How to run :VimtexCompile on start using lua

How do I execute :VimtexCompile automatically whenever I open a .tex file? As mentioned in this GitHub thread, this is done in Vimscript via: augroup vimtex_config autocmd User VimtexEventInitPost ...
A is for Ambition's user avatar
1 vote
1 answer
34 views

move (motion or visual selection) to own line and indent

Suppose I have the following text \[ X = (a, b) \] I want to easily convert it to the following, including indentation: \[ X = ( a, b ) \] Suppose my cursor is on a. How can I do ...
japreiss's user avatar
  • 151
0 votes
2 answers
3k views

Configuring VimTeX in NvChad config

I've been trying to configure vim-tex working on the NvChad configs. I got the :VimtexCompile working and giving me output pdf. But the usual <leader>ll is giving me these errors. Also in vim {{ ...
codehumor's user avatar
  • 101
0 votes
1 answer
80 views

Change " to `` or '' depending on whether it's typed after a space or non-space

The usecase is LaTeX, which I write using VimTeX. To make double quoted words one would write ``words''. However, I'm much more used, from many other contexts (both prose and code), to type " for ...
Enlico's user avatar
  • 2,214
0 votes
1 answer
112 views

How to toggle vimtex-log?

Here VimTex has a mapping for viewing the log. However, is open in a buffer that cannot be toggled, so I have to type: :bd to return to my text. This is not happening with error buffer where I can use ...
Mafsi's user avatar
  • 225
2 votes
1 answer
166 views

Why is there an ftplugin directory for each plugin?

I am trying to get started with VimTeX. I am reading through a guide (https://www.ejmastnak.com/tutorials/vim-latex/vimtex.html) and using vim-plug to manage plugins. I am very new to Vim generally, ...
monty_m's user avatar
  • 21
1 vote
1 answer
528 views

Vimtex and latexmkrc config. Question about compiling

I didn't understand very well this part, since English is not my native language. LATEXMK *vimtex-compiler-latexmk* As stated, one may customize the `...
Mafsi's user avatar
  • 225
1 vote
1 answer
72 views

Concealing ~ in texvim + conceal

I tried syn match texStatement '\\\[' contained conceal cchar=⟦ syn match texStatement '\\\]' contained conceal cchar=⟧ syn match texStatement '\\~' ...
Yossi Gil's user avatar
  • 755
2 votes
1 answer
222 views

Autocomplete LateX citations in chapters directory

Currently writing my thesis using LateX, I'm trying to obtain autocomplete on my citations when writing the chapters. The directory structure is that each chapter has its own main.tex files (template ...
Jeanot's user avatar
  • 23
1 vote
1 answer
1k views

vimtex: how to switch latex engine dynamically

I now use vimtex to edit my latex source files. Usually, I use the xelatex engine. So I have the following line at the beginning of my .tex file. % !TeX program = xelatex Sometimes I need to switch ...
jiaopjie's user avatar
  • 113
0 votes
1 answer
171 views

vimtex: configure to indent '[ ... ]' and '\[ ... \]' blocks

When setting indentation using vimtex, I meet some problem. I set the option g:vimtex_indent_delims to indent [...] blocks. let g:vimtex_indent_delims = { \ 'open' : ['{','(','['], \ '...
jiaopjie's user avatar
  • 113
1 vote
1 answer
206 views

vimtex: Avoid aligning in align environment in the document

So I'm using vimtex, and it's great, but there is one thing that is so annoying and I cannot believe that people actually use that feature. Namely, say I write something like \begin{align} x &= ...
Jo Mo's user avatar
  • 113
1 vote
1 answer
148 views

vimtex: fully indent a '{ ... }' block

Concerning indent in vimtex, it has some settings controlling indenting of delimiters, the option seems to be g:vimtex_indent_delims. However, I would like to not only indent the text between opening ...
Maximilian Keßler's user avatar
0 votes
1 answer
64 views

Key mapping for converting `((` to `\left( | \right)`

I would like to have something in .vimrc where when I type (( in insert mode, it automatically converts that into \left( | \right) with the cursor position at | in insert mode. Any ideas? I also would ...
Tom's user avatar
  • 379
1 vote
1 answer
123 views

vim command for jumping to <++>

I recently moved from vim-latex-suit to vimtex. In vim-latex-suit, there was this awesome feature that when I press Ctrl-j, it jumps to where <++> is and replace that to the cursor. To clarify, ...
Tom's user avatar
  • 379
0 votes
0 answers
38 views

Cursor get stuck at the statusline bar when saving a .tex file (probably due to vimtex)

To preface this, I'm relatively new to vim, and I'm using Windows Subsytsem for Linux, and the Windows Terminal if this makes any difference. So whenever I'm editing a .tex file and want to save, ...
MoonlessNightss's user avatar
0 votes
0 answers
321 views

Using VimTex "in_mathzone()" in .tid files

I am writing files with the extension ".tid" for a piece of software called TiddlyWiki whose syntax is pretty similar to that of markdown. In these files, I want to be able to write down ...
Isky Mathews's user avatar
1 vote
1 answer
719 views

Wrapping text in environment vimtex

I use vimtex although I am by no means an expert in Vim, so it may be that I'm missing something obvious. Anyway, I am looking for functionality similar to that of 'cse, csc, csd' (which change the ...
Lockjaw's user avatar
  • 145
1 vote
0 answers
121 views

:PlugUpdate is required every time I open vim [closed]

I’m setting up my LaTeX environment for vim, but the snippets (Ultisnips + vim-snippets + Gilles Castel’s tex.snippets with some changes) only work after I run :PlugUpdate (using vim-plug). I have to ...
Sage Stark's user avatar
1 vote
1 answer
271 views

(coc-)vimtex .bib completion strange suggstions

I've noticed that (coc-)vimtex gives suggestions about bib(la)tex keys and allows too searching in the entries of the literature. Now this search works sometimes for me, sometimes not (see the gif). ...
atticus's user avatar
  • 145
1 vote
1 answer
1k views

Vimtex+YouCompleteMe: How to disable autocompletion on plain text?

I have recently setup vimtex and YCM as the associated autocompleter. These work great in their intended scenario, however I believe the autocompleter is giving suggestions when I am typing plain text ...
Zeta-Squared's user avatar
1 vote
1 answer
255 views

Vimtex: `latexmk` compiler gives "no file name specified" error even after a new buffer is written to a file

When I open a new instance of vim without any 'filename' argument and write some LaTeX code, I cannot just compile it to pdf with latexmk, because it needs a file to compile from. However, even after ...
The Footprint's user avatar
0 votes
0 answers
2k views

How to get zathura to appear inside terminal and autocompile

I'm pretty new to vim and linux in general. I've been wanting to use vim for writing my math latex notes in the same fashion as pictured below. Whereas currently I am only able to accomplish the ...
ConlangBabble's user avatar
1 vote
1 answer
1k views

xelatex as default latex engine

I am new to vim and I am currently working with the default configuration of vimtex other than setting my viewer to skim. Here is what \li produces with my current vimtex configuration (used a minimal ...
kan's user avatar
  • 121
1 vote
0 answers
80 views

vimtex-compiler-ss does not open quickfix

Due to my muscle memory(aquired from vim-latex and other code compilation, so <F10> is universal compiler for me), I prefer singleshot calculation. I do have given a shot to \ll and then just ...
BaRud's user avatar
  • 491
3 votes
1 answer
646 views

Contextual Snippets in UltiSnips not working

I have been using vimtex with UltiSnips for a while on Linux platform and it has been working just fine. Recently, I switched to MacBook Air M1 for the same and installed the above mentioned plugins ...
Nitin's user avatar
  • 235
1 vote
1 answer
550 views

Is it possible to setup vim to use vimtex for Rmd files?

I need to write Rmd files, but I can't imagine life without vimtex. Is there a way that I can use vimtex with Rmd files? Ideally, I would also like to keep the syntax highlighting that I have for Rmd ...
evencoil's user avatar
  • 245
1 vote
1 answer
137 views

Latex: smaller Greek letters in math mode

In init.vim, I use vimtex and text-conceal, but it seems Greek letters and math operators look smaller. Here is an example: But when the cursor moves away, the math mode looks like this: . From this, ...
tobinz's user avatar
  • 131
0 votes
1 answer
85 views

Display the same color for all characters in a math section

In a tex file, almost all the characters inside delimiters like $...$ or \[...\] have the same color, but there are some characters, like = (and possibly others) which have a different color. I would ...
The Footprint's user avatar
2 votes
2 answers
1k views

vimtex conceal options and character substitution not working on Windows

I wanted to write and edit a .tex document as fast as possible, so I followed this guide, but I can't get vimtex to work properly. I would like to have Vim hide characters like $,\[ and replace some ...
The Footprint's user avatar
0 votes
0 answers
135 views

Eliminate highlighting of rendered code in vimtex

I am trying out vimtex and I think it is great but I am annoyed because the rendered code looks highlited or selected. I attach a picture that shows what I am talking about. At first I thouhgh it may ...
guestvim's user avatar
1 vote
0 answers
274 views

Vimtex in Spacevim: conceal persists even on cursor line

I am new to (space)vim and I tried to make vimtex work in spacevim. Following the documentation, I added the layer: [[layers]] name = 'lang#latex' in init.toml. Opening a .tex document then the math ...
Patrick.B's user avatar
  • 111
3 votes
1 answer
2k views

Manually disable scripts(/plugins) during a session?

Sorry if this is a noob question(I'm new to configuring vim) but I was wondering if it is possible to disable startup scripts manually during a Vim session. I am aware of the :scriptnames command ...
First User's user avatar
1 vote
1 answer
71 views

Vimtex citation movement bindings

By default <c-x><c-o> opens all citations/references in vimtex, then pressing tab goes over all citations/references backwards. How do I set plugins that make tab go forward? I tried but ...
mahbubweb's user avatar
  • 602
0 votes
1 answer
1k views

How to set a command as a file type specific autocommand

I would like the :Toc command to call :Voom in R markdown files and :VimtexTocOpen in latex files. First try: au BufRead,BufNewFile *.Rmd command! Toc Voom au BufRead,BufNewFile *.tex command! Toc ...
Paul Rougieux's user avatar
1 vote
0 answers
158 views

Conceal with the highlighting of matching begin/end latex environment

I want to use vim conceal feature with the highlighting of matching begin/end latex environment (vimtex plugin). When I use the following code syn match texStatement '\\begin{itemize}' contained ...
sfx's user avatar
  • 33
3 votes
1 answer
133 views

Disabling `kana/vim-textobj-entire` by filetype autocommand

kana/vim-textobj-entire creates text-obejcts ae and ie which stand for the entire buffer. But in lervag/vimtex ae and ie stand for an environment in a .tex file. vimtex's ae and ie mappings are much ...
mahbubweb's user avatar
  • 602