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.

What I want my set up to look like

Whereas currently I am only able to accomplish the following:

What my set up currently looks like

I have the following lines of code in my vimrc that relate to this (I think):

Plug 'lervag/vimtex'
let g:tex_flavor='latex'
let g:vimtex_view_method='zathura'
let g:vimtex_quickfix_mode=0
set conceallevel=1
let g:tex_conceal='abdmg'
call plug#end()
" Default compiling format
let g:Tex_DefaultTargetFormat='pdf'

" Never Forget, To set the default viewer:: Very Important
let g:Tex_ViewRule_pdf = 'zathura'

function! Synctex()
        " remove 'silent' for debugging
        execute "silent !zathura --synctex-forward " . line('.') . ":" . col('.') . ":" . bufname('%') . " " . g:syncpdf
map <C-enter> :call Synctex()<cr>

Any pointers would be much appreciated.

  • Instead of linking a blog post you should add in your question the result you are expecting, what you actually put in your vimrc and which result it gives. You'll have more chances to get an answer if you don't ask people to read a full blog post to try to understand your need. – statox Feb 23 at 10:52
  • Thanks for that, should've thought about that first. Edited the question to make it clearer what I'm looking for. – ConlangBabble Feb 23 at 13:10
  • Aside from putting the two windows side-by-side, it’s still not clear to me what exactly you want out of vim. Different colors? It doesnt look like Zathura is in the terminal; rather, a tiling window manager is probably involved. As for autocompiling, I cant remember if that’s a feature of vimtex or not but that’s where i would start – D. Ben Knoble Feb 23 at 13:19
  • Ben is right: The original author mention bspwm which is a tilling window manager (which are amazing tools but way out of scope for this website) and according to answers to this question vimtex does autocompile (but I don't know how it works tho) – statox Feb 23 at 13:28
  • I'll try a tiling window manager I wasn't sure what exactly it was because I'd never seen a latex pdf look like that before in the first picture so i just assumed it must have somehow been running inside the terminal (I don't do programming stuff so forgive me). The first photo showing what I want it to look like is taken from Giles Castel's blog about using UltiSnips with Vim for writing latex math quickly. I asked about the autocompile because it looks like it compiles every time there is any change to the document at all. I'll check out the vimtex answer as well. Thanks for the help! – ConlangBabble Feb 23 at 13:47

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.