lib/softcover/template/latex_styles/softcover.sty in softcover-0.8.9 vs lib/softcover/template/latex_styles/softcover.sty in softcover-0.9.0
- old
+ new
@@ -112,21 +112,17 @@
% Codelistings
\newcounter{codelisting}
\numberwithin{codelisting}{chapter}
\newenvironment{codelisting}{\refstepcounter{codelisting}\begin{framed_shaded}\vspace{-0.5em}}%
{\end{framed_shaded}}
-% Codelisting captions
-\usepackage[hypcap=false]{caption}
-\DeclareCaptionFormat{listing}{\hspace{-0.2em}\colorbox[gray]{.85}{\hspace{0.1em}\parbox{0.997\textwidth}{#1#2#3}}\vspace{-1.3\baselineskip}}
-\captionsetup[listing]{format=listing,labelfont=bf,skip=16pt,font={rm,normalsize}}
-\DeclareCaptionType{listing}
-\newcommand{\codecaption}[1]{\captionof{listing}{#1}}
+% See latex_styles/language_customization.sty for codelisting captions.
% Aside boxes
\usepackage{amsthm}
\theoremstyle{definition}
-\newtheorem{aside}{Box}[chapter]
+\newcommand{\boxlabel}{Box}
+\newtheorem{aside}{\boxlabel}[chapter]
\usepackage{latex_styles/framed}
\definecolor{shadecolor}{gray}{0.97}
\definecolor{boxcolor}{gray}{0.10}
\newenvironment{shaded_aside}[2]{\begin{full_framed_shaded}\begin{aside}\label{#2} \textbf{#1}\end{aside}}{\bigskip\end{full_framed_shaded}}
@@ -141,9 +137,16 @@
\posttitle{%
\par\end{center}
\begin{center}\large#1\end{center}
\vskip0.5em}%
}
+
+% Define some commonly used Unicode characters.
+\usepackage{newunicodechar}
+\newunicodechar{—}{---}
+\newunicodechar{–}{--}
+
+\usepackage{latex_styles/language_customization}
% Add custom commands.
\usepackage{latex_styles/custom}
\usepackage{latex_styles/custom_pdf}