diff options
Diffstat (limited to 'tex/src/preamble-project.tex')
-rw-r--r-- | tex/src/preamble-project.tex | 37 |
1 files changed, 32 insertions, 5 deletions
diff --git a/tex/src/preamble-project.tex b/tex/src/preamble-project.tex index c4d7feb..9b956cf 100644 --- a/tex/src/preamble-project.tex +++ b/tex/src/preamble-project.tex @@ -8,11 +8,9 @@ %% For the `\url' command. \usepackage{url} -% correct bad hyphenation here -\hyphenation{op-tical net-works semi-conduc-tor} - -%% To use colors. -\usepackage{xcolor} +%% No need to load xcolor, its included by others below (it conflicts with +%% the listings package. +%\usepackage{xcolor} %% To have links. \usepackage[ @@ -25,3 +23,32 @@ %% To have typewriter font \usepackage{courier} + +%% To have bold monospace +%\usepackage[scaled=0.85]{beramono} +\usepackage{inconsolata} + +%% To display codes. +\usepackage{listings} +\usepackage{etoolbox} +\input{listings-bash.prf} +\lstset{ + frame=lines, + numbers=none, + language=bash, + commentstyle=\color{gray}, + abovecaptionskip=0mm, + belowcaptionskip=0mm, + keywordstyle=\mdseries, + basicstyle=\small\ttfamily\color{blue!35!black}, +} +\makeatletter +\preto\lstlisting{\def\@captype{table}} +\pretocmd\lst@makecaption{\noindent{\rule{\linewidth}{1pt}}}{}{} +\makeatother + + + + +%% Custom macros +\newcommand{\inlinecode}[1]{\textcolor{blue!35!black}{\texttt{#1}}} |