commit 5d3a0d2e33d523bc766c99a7cb9684c2a4adebca
parent 717901f7b46501d96130e6a71b465e32f656a999
Author: Anders Damsgaard <anders@adamsgaard.dk>
Date: Wed, 17 Apr 2019 09:47:05 +0200
Add article snippet for tex, update x colors
Diffstat:
2 files changed, 96 insertions(+), 2 deletions(-)
diff --git a/.Xresources b/.Xresources
@@ -5,8 +5,8 @@ Xcursor.size: 16
! terminal colors ------------------------------------------------------------
! see https://ciembor.github.io/4bit
-*.foreground: #c5c8c6
-*.background: #1d1f21
+*.foreground: #4d4d4c
+*.background: #ffffff
/* black */
*color0: #434944
diff --git a/.vim/UltiSnips/tex.snippets b/.vim/UltiSnips/tex.snippets
@@ -75,3 +75,97 @@ endsnippet
snippet $vec_ "Insert boldsymbol vector"
$\boldsymbol{$1}_\text{$2}^{$3}$
endsnippet
+
+snippet article "Blank article template"
+\documentclass[a4paper,twoside,onecolumn,10pt]{article}
+% substitute draft for final
+\usepackage[utf8]{inputenc}
+
+%% Language
+\usepackage[english]{babel} % break words
+
+%\captionnamefont{\bfseries\footnotesize}
+%\captiontitlefont{\footnotesize}
+\captionnamefont{\bfseries}
+\captiontitlefont{}
+%\captionstyle{}
+\captiondelim{. }
+\changecaptionwidth
+\captionwidth{0.8\linewidth}
+
+%\usepackage[rightcaption]{sidecap}
+
+%% Font settings (recommended in Butterick's practical typography)
+% http://practicaltypography.com/
+\usepackage[T1]{fontenc} % Font encoding
+\usepackage{charter} % Serif body font
+\usepackage[charter]{mathdesign} % Math font
+\usepackage[scale=0.9]{sourcecodepro} % Monospaced fontenc
+\usepackage[lf]{FiraSans} % Sans-serif font
+
+%% Graphics
+\usepackage{graphicx}
+\usepackage{tikz} % Drawing library
+
+%% Mathematics, scientific and chemical notation
+\usepackage{amsmath}
+%\usepackage{mathtools}
+\usepackage{booktabs} % \toprule, \midrule and \bottomrule in tabular
+\usepackage[detect-all]{siunitx}
+\DeclareSIUnit\year{a}
+%\usepackage[version=3]{mhchem}
+
+%% Code typesetting
+% http://en.wikibooks.org/wiki/LaTeX/Source_Code_Listings
+\usepackage{listings}
+% \begin{lstlisting}[float,label=lst:test,caption=A source code test,basicstyle=\ttfamily,language=Python]
+\usepackage{color}
+\definecolor{mygreen}{rgb}{0,0.6,0}
+\definecolor{mygray}{rgb}{0.5,0.5,0.5}
+\definecolor{mymauve}{rgb}{0.58,0,0.82}
+\lstset{%
+ numbers=left,
+ numberstyle=\tiny,
+ language=Python,
+ basicstyle=\ttfamily\footnotesize,
+ captionpos=b,
+ frame=single,
+ keepspaces=true,
+ keywordstyle=\color{blue},
+ showstringspaces=false,
+ stepnumber=1,
+ tabsize=4,
+ title=\lstname,
+ commentstyle=\color{mygreen},
+ stringstyle=\color{myauve}
+}
+
+%% Links, colors, citations
+\usepackage{color}
+%\definecolor{AUblue}{rgb}{0.0, 0.3, 0.5}
+%\usepackage[colorlinks=true,linkcolor=red,citecolor=AUblue]{hyperref}
+\usepackage{hyperref}
+%\usepackage{chapterbib} % multiple bibliographies in a document
+%\usepackage[round]{natbib}
+%\bibliographystyle{abbrvnat}
+\usepackage[natbib=true, style=authoryear, bibstyle=authoryear-comp, maxbibnames=10,
+maxcitenames=2, backend=bibtex8]{biblatex}
+%\bibliography{/Users/ad/articles/own/BIBnew.bib}
+
+%%% TITLE
+\title{${1:Title}}
+\author{${2:Anders Damsgaard}}
+\date{${3:\today}}
+
+\begin{document}
+
+$0
+
+%% Bibliography
+%\newpage
+%\addcontentsline{toc}{part}{Bibliography}
+%\bibliography{/Users/ad/articles/own/BIBnew.bib}
+\printbibliography
+
+\end{document}
+endsnippet