dotfiles

My personal shell configs and stuff
git clone git://git.alex.balgavy.eu/dotfiles.git
Log | Files | Refs | Submodules | README | LICENSE

commit a14635e5c8a1ee31a85f9b9b52c4e712706dd425
parent a6664d28596682d30cb3c622907398668d5e30d9
Author: Alex Balgavy <a.balgavy@gmail.com>
Date:   Tue, 23 Apr 2019 15:23:10 +0200

Latex snippets


Former-commit-id: 6c35d59f69bfc182a10925453b709d4410f8f121
Diffstat:
Mvim/ultisnips/tex.snippets | 36+++++++++++++++++++++++++++++++++++-
1 file changed, 35 insertions(+), 1 deletion(-)

diff --git a/vim/ultisnips/tex.snippets b/vim/ultisnips/tex.snippets @@ -62,9 +62,16 @@ snippet ul "unordered list" b \end{itemize} endsnippet +snippet ol "ordered list" b +\begin{enumerate} + \item $1 + $2 +\end{enumerate} +endsnippet + snippet - "item in list" b \item $1 - $2 +$2 endsnippet snippet beg "begin{} / end{}" bA @@ -102,6 +109,19 @@ snippet dm "Displayed math" wA $1 \] $0 endsnippet + +snippet table "Table" w +\vspace{1em} +\renewcommand{\arraystretch}{1.5} +\begin{tabular}{| l | c | r |} + \hline + \textbf{${1:heading}} & \textbf{${2:heading}} & \textbf{${3:heading}} \\\\ \hline + ${4:cell} & ${5:cell} & ${6:cell} \\\\ \hline + $0 \\\\ \hline +\end{tabular} +\renewcommand{\arraystretch}{1} +\vspace{1em} +endsnippet # }}} # Word processing {{{ @@ -116,6 +136,10 @@ endsnippet snippet " "quote" w \`\`$1''$0 endsnippet + +snippet ' "single quote" w +\`$1'$0 +endsnippet # }}} # Math {{{ @@ -193,6 +217,11 @@ context "math()" snippet * "×" wA \times$0 endsnippet + +context "math()" +snippet \given "P(A | B)" wA +\given{$1}{$2}$0 +endsnippet # }}} # Custom commands {{{ @@ -205,4 +234,9 @@ snippet cmd "\given{A}{B} - (A|B)" b \makeatother %%%%%%%%%%%%%%%%%%%%%%%%%%%%% endsnippet +snippet cmd "subsection a), b), c)" b +% lettered subsections % +\renewcommand\thesubsection{\thesection.\alph{subsection}} +%%%%%%%%%%%%%%%%%%%%%%%%%%%%% +endsnippet # }}}