Created
March 18, 2015 14:16
-
-
Save ftake/75e4b2931ab88fac2944 to your computer and use it in GitHub Desktop.
my tex preamble
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
% | |
% BEGEIN additional packages and macros | |
% | |
% draft only | |
\pagestyle{plain} | |
% end | |
\newenvironment{syntax}{\setlength{\baselineskip}{12pt} \begin{quote} \flushleft \ttfamily }{\end{quote}} | |
\newcommand{\lb}[0]{\texttt{\symbol{"7B}}}%" | |
\newcommand{\rb}[0]{\texttt{\symbol{"7D}}}%" | |
\newcommand{\hash}[0]{\texttt{\symbol{"23}}} | |
\newcommand{\andand}[0]{\symbol{"26}\symbol{"26}}%" | |
\newcommand{\oror}[0]{$||$}%{\symbol{"7C}\symbol{"7C}} | |
\newcommand{\tab}[0]{\hspace*{2em}} | |
\newcommand{\wb}[1]{\lb#1\rb} | |
\newcommand{\ltgt}[1]{<#1>} | |
\newcommand{\wbracket}[1]{\symbol{"5B}#1\symbol{"5D}} | |
\newcommand{\strlit}[1]{\symbol{"22}#1\symbol{"22}} | |
\newenvironment{myquote}[0]{% | |
\vspace{-3mm}% | |
\begin{list}{}{\setlength{\leftmargin}{2ex}}% | |
\item% | |
}{ | |
\end{list}% | |
\vspace{-3mm} | |
} | |
\newenvironment{displayedprogram}[0]{% | |
\begin{myquote}% | |
\ttfamily% | |
\small% | |
\baselineskip = 2mm% | |
\samepage% | |
}{\end{myquote}} | |
\usepackage{url} | |
\usepackage{graphics} | |
\DeclareUrlCommand\urlemail{\urlstyle{sf}} | |
\usepackage{listings} | |
\renewcommand{\ttdefault}{pcr} | |
\lstset{% | |
language={Java}, | |
basicstyle={\ttfamily\scriptsize}, | |
%commentstyle={\textit}, | |
classoffset=1, | |
keywordstyle={\bfseries},%\textcolor{blue} | |
framesep=5pt, | |
showstringspaces=false, | |
numbers=none, %left, | |
stepnumber=1, | |
numberstyle={\ttfamily\tiny}, | |
%columns=fullflexible, | |
tabsize=2, | |
captionpos=b, | |
morekeywords={}, | |
escapechar={$}, | |
lineskip=-0.3mm, | |
frame=tb, | |
numberbychapter=false, | |
} | |
\renewcommand{\lstlistingname}{List.} | |
\newcommand{\lstsubcaption}[2]{\vspace{-1mm}\hfil\textrm{\textbf{#1}~#2}\hfil} | |
\usepackage{booktabs} | |
\usepackage{amsmath} | |
% | |
% END additional package and macros | |
% |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment