dotfiles/dot_config/nvim/langprefs/tex.vim

19 lines
832 B
VimL

vnoremap <C-l>tt <esc>`>a}<esc>`<i\texttt{<esc>
vnoremap <C-l>bf <esc>`>a}<esc>`<i\textbf{<esc>
vnoremap <C-l>sl <esc>`>a}<esc>`<i\textsl{<esc>
vnoremap <C-l>sc <esc>`>a}<esc>`<i\textsc{<esc>
inoremap <C-l>#<space> \section{}<Left>
inoremap <C-l>##<space> \subsection{}<Left>
inoremap <C-l>###<space> \subsubsection{}<Left>
inoremap <C-l>ol<space> \begin{enumerate}<CR>\end{enumerate}<esc>O
inoremap <C-l>ul<space> \begin{itemize}<CR>\end{itemize}<esc>O
inoremap <C-l>li<space> \item<space>{}<esc>i
inoremap <C-l>code<space> \begin{minted}{}<CR>\end{minted}<esc>O
inoremap <C-l>pre<space> \texttt{}<Left>
inoremap <C-l>b<space> \textbf{}<Left>
inoremap <C-l>\<space> \textbackslash
inoremap <C-l>i<space> \emph{}<Left>
inoremap <C-l>s<space> \cancel{}<Left>
inoremap <C-l>br<space> \newline<CR>
inoremap <C-l>pt<space> \newpage<CR>