![]() The canonical option on macOS is Skim, which you can download as a macOS dmg file from its homepage or from SourceForge. Note, however, that many more Linux-compatible PDF readers exist-see the VimTeX plugin’s documentation at :help g:vimtex_view_method if curious. The VimTeX plugin also makes configuration between Zathura and Vim very easy. I recommend and will cover Zathura, under the assumption that anyone reading a multi-article Vim series will appreciate Zathura’s Vim-like key bindings and text-based configurability. The PDF reader integrates with a program called SyncTeX, which makes it easy for Vim and the PDF reader to communicate with each other-SyncTeX makes forward and inverse search possible. Or I guess you could hack together a shell script to do this for you, but why bother?) (The alternative: manually switch applications to the PDF reader, refresh the document, and switch back to Vim after every single compilation. In the background, the PDF reader constantly listens for changes to the PDF document and automatically updates its display when the document’s contents change after compilation. A Vim Configuration Primer for Filetype-Specific Workflows, which explains everything you need to know about Vim key mappings to understand this series (the same concepts apply if you use Neovim and Lua).Ī PDF reader used in a LaTeX workflow should meet two important requirements: We will also define some Vim key mappings in this article-if Vim keywords like :map,, , and are unfamiliar to you, consider taking a detour and reading through the final article in this series, 7. ![]() In case you are just dropping in now and Vim’s ftplugin system sounds unfamiliar, consider first reading through an earlier article in this series, which covers what you need to know about ftplugin. This article will make regular references to the file ftplugin/tex.vim, which we will use to implement LaTeX-specific Vim configuration through Vim’s filetype plugin system. Returning focus to MacVim after inverse search on macOS.Returning focus to Neovim after inverse search on macOS.Building Zathura and dependencies on macOS.Optional tip: Return focus to gVim after forward and inverse search.Optional tip: Return focus to Vim/Neovim after forward search.Ensure Vim starts a server (for terminal Vim on Linux).Ensure you have a clientserver-enabled Vim.Inter-process communication requires a server.Zathura on macOS (Intel-based MacBook Pro 11,5 macOS 12.1 Zathura 0.4.9 built from homebrew-zathura).Skim on macOS (tested on macOS 12.1 using Skim 1.6.9).Zathura on Linux (tested with i3 on Arch using Zathura 0.4.8).This article explains, for both Linux and macOS, how to set up a PDF reader for displaying the PDF file associated with the LaTeX source file being edited in Vim. This is part six in a seven part series explaining how to use the Vim or Neovim text editors to efficiently write LaTeX documents. Setting Up a PDF Reader for Writing LaTeX with Vim
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |