Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- \ProvidesClass{studentlitteratur}[2014/10/05 v1.6]
- \NeedsTeXFormat{LaTeX2e}[2001/01/01]
- %
- \newif\if@stdl@colorcmyk \@stdl@colorcmykfalse
- \newif\if@stdl@hasparts \@stdl@haspartstrue
- \newif\if@stdl@english \@stdl@englishfalse
- \newif\if@stdl@fleqn \@stdl@fleqntrue
- \newif\if@stdl@normalis \@stdl@normalistrue
- %
- % Options
- %
- \DeclareOption{cmyk}{\@stdl@colorcmyktrue}
- \DeclareOption{gray}{\@stdl@colorcmykfalse}
- \DeclareOption{grey}{\@stdl@colorcmykfalse}
- \DeclareOption{draft}{\PassOptionsToClass{draft}{memoir}}
- \DeclareOption{noparts}{\@stdl@haspartsfalse}
- \DeclareOption{english}{\@stdl@englishtrue}
- \DeclareOption{centerequations}{\@stdl@fleqnfalse}
- \DeclareOption{170x245}{\@stdl@normalisfalse}
- \DeclareOption{155x223}{\@stdl@normalistrue}
- \DeclareOption*{\PackageWarning{studentlitteratur}{Unknown
- `\CurrentOption'}}
- \ProcessOptions\relax
- %
- %
- \if@stdl@fleqn
- \LoadClass[a4paper,11pt,twoside,fleqn,showtrims]{memoir}
- \else
- \LoadClass[a4paper,11pt,twoside,showtrims]{memoir}
- \fi
- \RequirePackage{url}
- \urlstyle{same}
- \RequirePackage{textcomp}
- % Load babel with swedish or english as the default language
- \if@stdl@english
- %\RequirePackage[swedish,english]{babel}
- \else
- \RequirePackage[english,latin,swedish]{babel}
- \fi
- %
- % Load xcolor with the appropriate color model (cmyk/gray)
- % Define a (dummy) spotcolor for twotone printing
- \if@stdl@colorcmyk
- \RequirePackage[cmyk]{xcolor}
- \definecolor{spotcolor}{cmyk}{1,0,0,0}
- \else
- \RequirePackage[gray]{xcolor}
- \definecolor{spotcolor}{gray}{0}
- \fi
- % Load the rest of the required packages
- \RequirePackage{graphicx}
- \if@stdl@fleqn
- \RequirePackage[fleqn]{amsmath}
- \else
- \RequirePackage{amsmath}
- \fi
- \RequirePackage{amssymb}
- \RequirePackage[babel]{microtype}
- \RequirePackage[medfamily,textosf,mathlf,mnsy,amsbb,mixedgreek,minionint,openg,footnotefigures]{MinionPro}
- \RequirePackage{MnSymbol,pifont}
- \RequirePackage[onlytext,medfamily,osf]{MyriadPro}
- \RequirePackage{tikz}
- \RequirePackage[overload]{textcase}
- \RequirePackage{fix-cm}
- \RequirePackage{t1enc}
- \RequirePackage{pdftexcmds}
- \RequirePackage{xstring}
- \RequirePackage{wrapfig}
- %\RequirePackage[thmmarks,amsmath]{ntheorem}
- \RequirePackage[framemethod=TikZ]{mdframed}
- \RequirePackage{icomma}
- \RequirePackage{varwidth}
- \RequirePackage{etoolbox}
- \RequirePackage{tabu}
- \RequirePackage{colortbl}
- \RequirePackage{ragged2e}
- %
- % Setup siunitx
- %
- \RequirePackage{siunitx}
- \if@stdl@english
- \sisetup{%
- detect-family = true,
- detect-inline-family = text,
- detect-display-math = true,
- output-decimal-marker = {.},
- group-digits = integer,
- group-separator = {\;},
- group-four-digits = false,
- range-phrase = --,
- list-separator = {; },
- list-final-separator = { and },
- separate-uncertainty
- }
- \else
- \sisetup{%
- detect-family = true,
- detect-inline-family = text,
- detect-display-math = true,
- output-decimal-marker = {,},
- group-digits = integer,
- group-separator = {\;},
- group-four-digits = true,
- range-phrase = --,
- list-separator = {; },
- list-final-separator = { och },
- separate-uncertainty
- }
- \fi
- %
- % Setup the fixed width font
- %
- \renewcommand{\ttdefault}{pcr}
- %
- % Define colors for background and headers
- %
- \newcommand{\colpartbg}{spotcolor!10} % Also used in TOC
- \newcommand{\colchapbg}{spotcolor!10}
- \newcommand{\colfancyhead}{spotcolor!25}
- \newcommand{\colfancybox}{spotcolor!5}
- \newcommand{\colplainbox}{spotcolor!10}
- \newcommand{\colsideline}{black!50}
- \newcommand{\colpart}{black}
- \newcommand{\colchapter}{black}
- \newcommand{\colsection}{black}
- \newcommand{\colsubsection}{spotcolor}
- \newcommand{\colsubsubsection}{black}
- \newcommand{\colsubsubsubsection}{black}
- \newcommand{\colparagraph}{black}
- \newcommand{\coltablehead}{spotcolor!10}
- % Courier is not available in light, substitute
- % medium weight silently
- %
- \DeclareFontFamily{T1}{pcr}{\hyphenchar \font\m@ne}
- \DeclareFontShape{T1}{pcr}{m}{n}{<-> pcrr8t}{}
- \DeclareFontShape{T1}{pcr}{m}{sc}{<-> pcrrc8t}{}
- \DeclareFontShape{T1}{pcr}{m}{sl}{<-> pcrro8t}{}
- \DeclareFontShape{T1}{pcr}{b}{n}{<-> pcrb8t}{}
- \DeclareFontShape{T1}{pcr}{b}{sc}{<-> pcrbc8t}{}
- \DeclareFontShape{T1}{pcr}{b}{sl}{<-> pcrbo8t}{}
- \DeclareFontShape{T1}{pcr}{m}{it}{<->ssub * pcr/m/sl}{}
- \DeclareFontShape{T1}{pcr}{bx}{n}{<->ssub * pcr/b/n}{}
- \DeclareFontShape{T1}{pcr}{bx}{sc}{<->ssub * pcr/b/sc}{}
- \DeclareFontShape{T1}{pcr}{bx}{sl}{<->ssub * pcr/b/sl}{}
- \DeclareFontShape{T1}{pcr}{b}{it}{<->ssub * pcr/b/sl}{}
- \DeclareFontShape{T1}{pcr}{bx}{it}{<->ssub * pcr/b/it}{}
- \DeclareFontShape{T1}{pcr}{l}{n}{ <->ssub * pcr/m/n}{}
- \DeclareFontShape{T1}{pcr}{l}{it}{ <->ssub * pcr/m/sl}{}
- \DeclareFontShape{T1}{pcr}{l}{sl}{ <->ssub * pcr/m/sl}{}
- \DeclareFontShape{T1}{pcr}{l}{sc}{ <->ssub * pcr/m/sc}{}
- %
- % Add extra spacing before :;!?
- % (as recommended by Hellmark, typografisk handbok)
- %
- \DeclareMicrotypeSet{standard}{%
- encoding = {OT1,T1,LY1},
- family = {rm*, sf*}
- }
- \if@stdl@english
- \else
- \SetExtraKerning
- [ name = swedish-default,
- context = swedish,
- unit = space ]
- { encoding = {T1,LY1} }
- {
- : = {200, },
- ; = {200, },
- ! = {200, },
- ? = {200, }
- }
- \DeclareMicrotypeBabelHook{swedish}{kerning=swedish, spacing=}
- \fi
- \UseMicrotypeSet[protrusion,kerning,expansion]{standard}
- %
- % Font sizes et al
- %
- \def\@listI{\leftmargin\leftmargini
- \topsep \topsepi
- \parsep \parsepi
- \itemsep \itemsepi
- \itemindent \z@
- \setlength{\parfillskip}{0pt plus 1fill}
- }%
- \if@stdl@fleqn
- \setlength{\mathindent}{28pt}
- \renewcommand{\normalsize}{%
- \@setfontsize\normalsize{10.4}{14}%
- \abovedisplayskip 14\p@ \@plus2\p@ \@minus6\p@%
- \belowdisplayskip \abovedisplayskip%
- \abovedisplayshortskip \abovedisplayskip%
- \belowdisplayshortskip \abovedisplayskip%
- \let\@listi\@listI}
- \normalsize
- \renewcommand{\small}{%
- \@setfontsize\small{9.5}{13}%
- \abovedisplayskip 13\p@ \@plus2\p@ \@minus5\p@%
- \belowdisplayskip \abovedisplayskip%
- \abovedisplayshortskip \abovedisplayskip%
- \belowdisplayshortskip \abovedisplayskip%
- \def\@listi{\leftmargin\leftmargini%
- \topsep 13pt%
- \parsep \z@%
- \itemsep \parsep%
- \itemindent \z@%
- \setlength{\parfillskip}{0pt plus 1fill}%
- }%
- }
- \renewcommand{\footnotesize}{%
- \@setfontsize\footnotesize{8.5}{12}%
- \abovedisplayskip 6\p@ \@plus2\p@ \@minus2\p@%
- \abovedisplayshortskip \z@ \@plus\p@%
- \belowdisplayshortskip 4\p@ \@plus2\p@ \@minus2\p@%
- \def\@listi{\leftmargin\leftmargini%
- \topsep 12pt%
- \parsep \z@%
- \itemsep \parsep%
- \itemindent \z@%
- \setlength{\parfillskip}{0pt plus 1fill}%
- }%
- \belowdisplayskip \abovedisplayskip%
- }
- \else
- \renewcommand{\normalsize}{%
- \@setfontsize\normalsize{10.4}{14}%
- \abovedisplayskip 7\p@ \@plus2\p@ \@minus2\p@%
- \belowdisplayskip \abovedisplayskip%
- \abovedisplayshortskip \z@ \@plus2\p@%
- \belowdisplayshortskip 6\p@ \@plus2\p@ \@minus2\p@%
- \let\@listi\@listI}
- \normalsize
- \renewcommand{\small}{%
- \@setfontsize\small{9.5}{13}%
- \abovedisplayskip 6.5\p@ \@plus2\p@ \@minus2\p@%
- \belowdisplayskip \abovedisplayskip%
- \abovedisplayshortskip \z@ \@plus2\p@%
- \belowdisplayshortskip 5\p@ \@plus2\p@ \@minus2\p@%
- \def\@listi{\leftmargin\leftmargini%
- \topsep 13pt%
- \parsep \z@%
- \itemsep \parsep%
- \itemindent \z@%
- \setlength{\parfillskip}{0pt plus 1fill}%
- }%
- }
- \renewcommand{\footnotesize}{%
- \@setfontsize\footnotesize{8.5}{12}%
- \abovedisplayskip 6\p@ \@plus2\p@ \@minus2\p@%
- \abovedisplayshortskip \z@ \@plus\p@%
- \belowdisplayshortskip 4\p@ \@plus2\p@ \@minus2\p@%
- \def\@listi{\leftmargin\leftmargini%
- \topsep 12pt%
- \parsep \z@%
- \itemsep \parsep%
- \itemindent \z@%
- \setlength{\parfillskip}{0pt plus 1fill}%
- }%
- \belowdisplayskip \abovedisplayskip%
- }
- \fi
- \renewcommand{\miniscule}{\@setfontsize\miniscule{7.5}{9}}
- \renewcommand{\tiny}{\@setfontsize\tiny{6.9}{8}}
- \renewcommand{\scriptsize}{\@setfontsize\scriptsize{7.5}{9}}
- \renewcommand{\large}{\@setfontsize\large{12}{16}}
- \renewcommand{\Large}{\@setfontsize\Large{14}{20}}
- \renewcommand{\LARGE}{\@setfontsize\LARGE{17}{23}}
- \renewcommand{\huge}{\@setfontsize\huge{20}{24}}
- \renewcommand{\Huge}{\@setfontsize\Huge{24}{30}}
- \renewcommand{\HUGE}{\@setfontsize\Huge{28}{33}}
- \setlength{\onelineskip}{14pt}
- \setlength{\parindent}{14pt}
- \setlength{\parskip}{0pt}
- \setlength{\leftmargini}{14pt}
- \setlength{\leftmarginii}{14pt}
- \setlength{\leftmarginiii}{14pt}
- \setlength{\leftmarginiv}{14pt}
- \setlength{\leftmarginv}{14pt}
- \setlength{\leftmarginvi}{14pt}
- \newlength{\enummargini}
- \newlength{\enummarginii}
- \newlength{\enummarginiii}
- \newlength{\enummarginiv}
- \setlength{\enummargini}{0pt}
- \setlength{\enummarginii}{3pt}
- \setlength{\enummarginiii}{6pt}
- \setlength{\enummarginiv}{6pt}
- \setlength{\topsepi}{\onelineskip}
- \setlength{\topsepii}{0pt}
- \setlength{\topsepiii}{0pt}
- \setlength{\parsepi}{0pt}
- \setlength{\parsepii}{0pt}
- \setlength{\itemsepi}{0pt}
- \setlength{\labelwidth}{\leftmargini}
- \addtolength{\labelwidth}{-\labelsep}
- %
- % Set paper size and type area
- %
- \if@stdl@normalis
- \settrimmedsize{223mm}{155mm}{*}
- \setlength{\trimtop}{\stockheight}
- \addtolength{\trimtop}{-\paperheight}
- \setlength{\trimedge}{\stockwidth}
- \addtolength{\trimedge}{-\paperwidth}
- \settrims{0.5\trimtop}{0.5\trimedge}
- \setbinding{0mm}
- \setulmarginsandblock{20.5mm}{26.9mm}{*}
- \setlrmarginsandblock{26mm}{19mm}{*}
- \setheadfoot{5mm}{10.9mm}
- \setheaderspaces{*}{5.8mm}{*}
- \checkandfixthelayout
- \else
- \settrimmedsize{245mm}{170mm}{*}
- \setlength{\trimtop}{\stockheight}
- \addtolength{\trimtop}{-\paperheight}
- \setlength{\trimedge}{\stockwidth}
- \addtolength{\trimedge}{-\paperwidth}
- \settrims{0.5\trimtop}{0.5\trimedge}
- \setbinding{0mm}
- \setulmarginsandblock{20mm}{31mm}{*}
- \setlrmarginsandblock{19mm}{48mm}{*}
- \setheadfoot{13mm}{13mm}
- \setheaderspaces{*}{7mm}{*}
- \setmarginnotes{5mm}{31mm}{28pt}
- \renewcommand{\sideparfont}{\sffamily\fontseries{l}\fontsize{8.5}{11.5}\selectfont}
- \renewcommand{\sideparform}{\RaggedRight}
- \renewcommand{\sidebarfont}{\sffamily\fontseries{l}\fontsize{8.5}{11.5}\selectfont}
- \sideparmargin{outer}
- \sidebarmargin{outer}
- \setsidecaps{5mm}{31mm}
- \sidecapmargin{outer}
- \strictpagecheck
- \setsidecappos{t}
- \renewcommand{\sidecapstyle}{\RaggedRight}
- \checkandfixthelayout
- \marginparmargin{outer}
- \let\@stdl@marginpar\marginpar
- \renewcommand\marginpar[1]{\@stdl@marginpar{\sideparfont\sideparform#1}}
- \fi
- %
- % Define trim marks
- %
- \renewcommand*{\tmarktm}{%
- \color{black}
- \begin{picture}(0,0)
- \unitlength 1mm
- \thinlines
- \put(0,10){\makebox[0pt]{\normalfont\small
- \today{} -- sida~\thepage{} -- \#~\thesheetsequence}}
- \end{picture}}
- \renewcommand*{\Ltrimpictl}{%
- \begin{picture}(0,0)
- \unitlength 1mm
- \thinlines
- \put(-2,0){\line(-1,0){9}}
- \put(0,2){\line(0,1){9}}
- \end{picture}}
- \renewcommand*{\Ltrimpictr}{%
- \begin{picture}(0,0)
- \unitlength 1mm
- \thinlines
- \put(2,0){\line(1,0){9}}
- \put(0,2){\line(0,1){9}}
- \end{picture}}
- \renewcommand*{\Ltrimpicbl}{%
- \begin{picture}(0,0)
- \unitlength 1mm
- \thinlines
- \put(-2,0){\line(-1,0){9}}
- \put(0,-2){\line(0,-1){9}}
- \end{picture}}
- \renewcommand*{\Ltrimpicbr}{%
- \begin{picture}(0,0)
- \unitlength 1mm
- \thinlines
- \put(2,0){\line(1,0){9}}
- \put(0,-2){\line(0,-1){9}}
- \end{picture}}
- \trimLmarks
- %
- % Headers and footers
- %
- \if@stdl@hasparts
- \makepsmarks{headings}{%
- \def\chaptermark##1{%
- \markright{%
- \ifnum \c@secnumdepth >\m@ne
- \if@mainmatter
- \thechapter\space
- \fi
- \fi
- ##1}}%
- \def\partmark##1{\markboth{%
- \partname~\thepart\hspace{0.5em} ##1}{}}%
- \createplainmark{toc}{both}{\contentsname}
- \createplainmark{lof}{both}{\listfigurename}
- \createplainmark{lot}{both}{\listtablename}
- \createplainmark{bib}{both}{\bibname}
- \createplainmark{index}{both}{\indexname}
- \createplainmark{glossary}{both}{\glossaryname}}
- \else
- \makepsmarks{headings}{%
- \let\@mkboth\markboth
- \def\chaptermark##1{%
- \markboth{%
- \ifnum \c@secnumdepth >\m@ne
- \if@mainmatter
- \thechapter\space
- \fi
- \fi
- ##1}{%
- \ifnum \c@secnumdepth >\m@ne
- \if@mainmatter
- \thechapter\space
- \fi
- \fi
- ##1}}%
- \def\tocmark{\markboth{\contentsname}{\contentsname}}%
- \def\lofmark{\markboth{\listfigurename}{\listfigurename}}%
- \def\lotmark{\markboth{\listtablename}{\listtablename}}%
- \def\bibmark{\markboth{\bibname}{\bibname}}%
- \def\indexmark{\markboth{\indexname}{\indexname}}%
- }
- \fi
- \newlength{\@stdl@headrulelength}
- \if@stdl@normalis
- \setlength{\@stdl@headrulelength}{\textwidth}
- \else
- \setlength{\@stdl@headrulelength}{139mm}
- \fi
- \makeheadposition{headings}{flushright}{flushleft}{flushright}{flushleft}
- %\makeheadfootstrut{headings}{}
- \makerunningwidth{headings}{\@stdl@headrulelength}
- \makeevenhead{headings}{\normalfont\fontsize{8.5}{11}\selectfont
- \scshape\textls*[70]{\MakeLowercase{\leftmark}}}{}{}
- \makeoddhead{headings}{}{}{\normalfont\fontsize{8.5}{11}\selectfont
- \scshape\textls*[70]{\MakeLowercase{\rightmark}}}
- \makeheadrule{headings}{\@stdl@headrulelength}{0.3pt}
- \makeoddfoot{headings}{\normalfont\fontsize{5.5}{6.5}\selectfont
- \textls*[120]{\stdl@copyrightmsg}}{}{\normalsize\textls*[-18]{\thepage}}
- \makeevenfoot{headings}{\normalsize\textls*[-18]{\thepage}}{}{\normalfont\fontsize{5.5}{6.5}\selectfont\textls*[120]{\stdl@copyrightmsg}}
- \pagestyle{headings}
- \copypagestyle{frontheadings}{headings}
- \makepsmarks{frontheadings}{%
- \let\@mkboth\markboth
- \def\chaptermark##1{%
- \markboth{##1}{##1}}%
- \def\sectionmark##1{}%
- \def\tocmark{\markboth{\contentsname}{\contentsname}}%
- \def\lofmark{\markboth{\listfigurename}{\listfigurename}}%
- \def\lotmark{\markboth{\listtablename}{\listtablename}}%
- \def\bibmark{\markboth{\bibname}{\bibname}}%
- \def\indexmark{\markboth{\indexname}{\indexname}}%
- }
- %
- % Updated header in appendices, 2013/11/20
- %
- \copypagestyle{appendixheadings}{headings}
- \makeevenhead{appendixheadings}{\normalfont\fontsize{8.5}{11}\selectfont
- \scshape\textls*[70]{\MakeLowercase{\stdl@appendixname~\leftmark}}}{}{}
- \makeoddhead{appendixheadings}{}{}{\normalfont\fontsize{8.5}{11}\selectfont
- \scshape\textls*[70]{\MakeLowercase{\stdl@appendixname~\rightmark}}}
- \makepsmarks{appendixheadings}{%
- \let\@mkboth\markboth
- \def\chaptermark##1{%
- \markboth{%
- \ifnum \c@secnumdepth >\m@ne
- \if@mainmatter
- \thechapter\space
- \fi
- \fi
- ##1}{%
- \ifnum \c@secnumdepth >\m@ne
- \if@mainmatter
- \thechapter\space
- \fi
- \fi
- ##1}}%
- \def\tocmark{\markboth{\contentsname}{\contentsname}}%
- \def\lofmark{\markboth{\listfigurename}{\listfigurename}}%
- \def\lotmark{\markboth{\listtablename}{\listtablename}}%
- \def\bibmark{\markboth{\bibname}{\bibname}}%
- \def\indexmark{\markboth{\indexname}{\indexname}}%
- }
- % Bug fix 2013/02/25. Headers in frontmatter and endmatter
- % were justified to the wrong side of the page
- \makeevenhead{frontheadings}{\normalfont\fontsize{8.5}{11}\selectfont
- \scshape\textls*[70]{\MakeLowercase{\leftmark}}}{}{}
- \makeoddhead{frontheadings}{}{}{\normalfont\fontsize{8.5}{11}\selectfont
- \scshape\textls*[70]{\MakeLowercase{\rightmark}}}
- %
- \copypagestyle{frontchapter}{frontheadings}
- \makeoddhead{frontchapter}{}{}{}
- \makeevenhead{frontchapter}{}{}{}
- \aliaspagestyle{part}{empty}
- \copypagestyle{chapter}{headings}
- \makeevenhead{chapter}{}{}{}
- \makeoddhead{chapter}{}{}{}
- \makeheadrule{chapter}{0pt}{0pt}
- \maxsecnumdepth{subsubsection}
- \setsecnumdepth{section}
- \settocdepth{subsection}
- %
- % List markers
- %
- \renewcommand{\theenumi}{\@Alph\c@enumi}
- \renewcommand{\theenumii}{\@arabic\c@enumii}
- \renewcommand{\theenumiii}{\@alph\c@enumiii}
- \renewcommand{\theenumiv}{\@roman\c@enumiv}
- \renewcommand{\labelenumi}{\theenumi}
- \renewcommand{\labelenumii}{\theenumii}
- \renewcommand{\labelenumiii}{\theenumiii)}
- \renewcommand{\labelenumiv}{\theenumiv}
- %
- \renewcommand{\labelitemi}{\textbullet}
- \renewcommand{\labelitemii}{\normalfont\bfseries \textendash}
- \renewcommand{\labelitemiii}{\textperiodcentered}
- \renewcommand{\labelitemiv}{\textasteriskcentered}
- %
- \newcommand{\ornament}[1]{\Pisymbol{MinionPro-Extra}{#1}}
- \newcommand{\fancypar}{\par\nopagebreak\vspace{6pt plus 1pt minus 1pt}{\centering\ornament{121}\par}\vspace{8pt plus 1pt minus 1pt}\@doendeq}
- %
- % Bibliography
- %
- \renewcommand{\prebibhook}{\pagestyle{frontheadings}\thispagestyle{frontchapter}}
- \renewcommand{\biblistextra}{\itemsep=\bibitemsep\raggedright}
- %
- % Fix the current page node, taking stock size into account
- %
- \usetikzlibrary{decorations.pathmorphing, calc}
- \newcommand\setpagenode{
- % The original current page node code can be found in the file
- % generic/pgf/modules/pgfmoduleshapes.code.tex
- \expandafter\def\csname pgf@sh@ns@current page\endcsname{rectangle}
- % Use a few low level Memoir macros to check if we are on an even or odd page.
- \strictpagecheck
- \checkoddpage
- \ifoddpage%
- \expandafter\def\csname pgf@sh@np@current page\endcsname{%
- % Set the current page.south west coordinate
- \def\southwest{\pgfpoint{\stockwidth-\paperwidth-\trimedge}%
- {\stockheight-\trimtop-\paperheight}}%
- % Set the current page.north east coordinate
- \def\northeast{\pgfpoint{\stockwidth-\trimedge}{\stockheight-\trimtop}}%
- }
- \else
- \expandafter\def\csname pgf@sh@np@current page\endcsname{%
- \def\southwest{\pgfpoint{\trimedge}{\stockheight-\trimtop-\paperheight}}%
- \def\northeast{\pgfpoint{\trimedge+\paperwidth}{\stockheight-\trimtop}}%
- }
- \fi
- \expandafter\def\csname pgf@sh@nt@current page\endcsname{{1}{0}{0}{1}{0pt}{0pt}}
- \expandafter\def\csname pgf@sh@pi@current page\endcsname{pgfpageorigin}
- }
- \AtBeginDocument{\pgfkeys{/tikz/overlay/.add code={}{\setpagenode}}}
- %
- % Title page
- %
- \if@stdl@english
- \newcommand{\stdl@ordinal}[1]{%
- \ifnum\pdf@strcmp{#1}{1}=0 first%
- \else\ifnum\pdf@strcmp{#1}{2}=0 second%
- \else\ifnum\pdf@strcmp{#1}{3}=0 third%
- \else\ifnum\pdf@strcmp{#1}{4}=0 fourth%
- \else\ifnum\pdf@strcmp{#1}{5}=0 fifth%
- \else\ifnum\pdf@strcmp{#1}{6}=0 sixth%
- \else\ifnum\pdf@strcmp{#1}{7}=0 seventh%
- \else\ifnum\pdf@strcmp{#1}{8}=0 eighth%
- \else\ifnum\pdf@strcmp{#1}{9}=0 ninth%
- \else #1%
- \fi\fi\fi\fi\fi\fi\fi\fi\fi
- }
- \newcommand{\stdl@Ordinal}[1]{%
- \ifnum\pdf@strcmp{#1}{1}=0 First%
- \else\ifnum\pdf@strcmp{#1}{2}=0 Second%
- \else\ifnum\pdf@strcmp{#1}{3}=0 Thrird%
- \else\ifnum\pdf@strcmp{#1}{4}=0 Fourth%
- \else\ifnum\pdf@strcmp{#1}{5}=0 Fifth%
- \else\ifnum\pdf@strcmp{#1}{6}=0 Sixth%
- \else\ifnum\pdf@strcmp{#1}{7}=0 Seventh%
- \else\ifnum\pdf@strcmp{#1}{8}=0 Eighth%
- \else\ifnum\pdf@strcmp{#1}{9}=0 Ninth%
- \else #1%
- \fi\fi\fi\fi\fi\fi\fi\fi\fi
- }
- \else
- \newcommand{\stdl@ordinal}[1]{%
- \ifnum\pdf@strcmp{#1}{1}=0 f\"orsta%
- \else\ifnum\pdf@strcmp{#1}{2}=0 andra%
- \else\ifnum\pdf@strcmp{#1}{3}=0 tredje%
- \else\ifnum\pdf@strcmp{#1}{4}=0 fj\"rde%
- \else\ifnum\pdf@strcmp{#1}{5}=0 femte%
- \else\ifnum\pdf@strcmp{#1}{6}=0 sj\"tte%
- \else\ifnum\pdf@strcmp{#1}{7}=0 sjunde%
- \else\ifnum\pdf@strcmp{#1}{8}=0 \aa{}ttonde%
- \else\ifnum\pdf@strcmp{#1}{9}=0 nionde%
- \else #1%
- \fi\fi\fi\fi\fi\fi\fi\fi\fi
- }
- \newcommand{\stdl@Ordinal}[1]{%
- \ifnum\pdf@strcmp{#1}{1}=0 F\"orsta%
- \else\ifnum\pdf@strcmp{#1}{2}=0 Andra%
- \else\ifnum\pdf@strcmp{#1}{3}=0 Tredje%
- \else\ifnum\pdf@strcmp{#1}{4}=0 Fj\"rde%
- \else\ifnum\pdf@strcmp{#1}{5}=0 Femte%
- \else\ifnum\pdf@strcmp{#1}{6}=0 Sj\"tte%
- \else\ifnum\pdf@strcmp{#1}{7}=0 Sjunde%
- \else\ifnum\pdf@strcmp{#1}{8}=0 \AA{}ttonde%
- \else\ifnum\pdf@strcmp{#1}{9}=0 Nionde%
- \else #1%
- \fi\fi\fi\fi\fi\fi\fi\fi\fi
- }
- \fi
- \newcommand*{\stdl@formatfirst}[1]{\MakeUppercase{#1}}
- \newcommand*{\stdl@capitalize}[1]{%
- \expandafter\stdl@formatfirst\expandafter{\@car #1\@empty\@nil}%
- \@cdr #1\@empty\@nil}
- \newcommand{\thesubtitle}{\relax}
- \newcommand{\subtitle}[1]{\renewcommand{\thesubtitle}{\vspace*{6mm}#1}}
- \newcommand{\thetranslator}{\relax}
- \if@stdl@english
- \newcommand{\stdl@translatorname}{Translator}
- \newcommand{\stdl@translationname}{Translation}
- \newcommand{\stdl@theartno}{Art.~No}
- \newcommand{\stdl@techreview}{Technical review}
- \newcommand{\stdl@coverdesign}{Cover design by}
- \newcommand{\stdl@coverimage}{Cover image by}
- \newcommand{\stdl@editionname}{Edition}
- \newcommand{\stdl@editionnamex}{edition}
- \newcommand{\stdl@and}{and}
- \else
- \newcommand{\stdl@translatorname}{\"Overs\"attare}
- \newcommand{\stdl@translationname}{\"Overs\"attning}
- \newcommand{\stdl@theartno}{Art.nr}
- \newcommand{\stdl@techreview}{Fackgranskning}
- \newcommand{\stdl@coverdesign}{Omslagslayout:}
- \newcommand{\stdl@coverimage}{Omslagsbild:}
- \newcommand{\stdl@editionname}{Upplaga}
- \newcommand{\stdl@editionnamex}{upplagan}
- \newcommand{\stdl@and}{och}
- \fi
- \newcommand{\stdl@thetranslator}{\relax}
- \newcommand{\translator}[1]{\renewcommand{\thetranslator}{\stdl@translatorname: #1\par}\renewcommand{\stdl@thetranslator}{\stdl@translationname:~#1\\}}
- \newcommand{\theedition}{\ClassError{studentlitteratur}{Command \protect\edition\space must be defined before \protect\maketitle}{Command \protect\edition\space must be defined before \protect\maketitle}}
- \newcommand{\edition}[1]{\renewcommand{\theedition}{#1}}
- %\newcommand{\theartnr}{\ClassError{studentlitteratur}{Command
- %\protect\artnr\space must be defined before
- %\protect\maketitle}{Command \protect\artnr\space must be defined
- %before \protect\maketitle}}
- \newcommand{\theartnr}{\relax}
- \newcommand{\artnr}[1]{\renewcommand{\theartnr}{\stdl@theartno~#1\\}}
- \newcommand{\theisbn}{\ClassError{studentlitteratur}{Command \protect\isbn\space must be defined before \protect\maketitle}{Command \protect\space must be defined before \protect\maketitle}}
- \newcommand{\isbn}[1]{\renewcommand{\theisbn}{\textls[60]{\textsc{isbn}}~#1\\}}
- \newcommand{\thetechnicalreview}{\relax}
- \newcommand{\technicalreview}[1]{\renewcommand{\thetechnicalreview}{\stdl@techreview:~#1\\}}
- \newcommand{\thecoverlayout}{\relax}
- \newcommand{\coverlayout}[1]{\renewcommand{\thecoverlayout}{\stdl@coverdesign~#1\\}}
- \newcommand{\thecoverimage}{\relax}
- \newcommand{\coverimage}[1]{\renewcommand{\thecoverimage}{\stdl@coverimage~#1\\}}
- \newcommand{\theprinter}{\ClassError{studentlitteratur}{Command \protect\printer\space must be defined before \protect\maketitle}{Command \protect\printer\space must be defined before \protect\maketitle}}
- %\newcommand{\coverlayout}[1]{\renewcommand{\theprinter}{Printed by~#1}}
- \newcommand{\printer}[1]{\renewcommand{\theprinter}{Printed by~#1}}
- \newcommand{\thecovertext}{\relax}
- \newcommand{\covertext}[1]{\renewcommand{\thecovertext}{#1}}
- \newcommand{\thecopyrightyear}{\the\year}
- \newcommand{\copyrightyear}[1]{\renewcommand{\thecopyrightyear}{#1}}
- \newcommand{\theprintyear}{\the\year}
- \newcommand{\printyear}[1]{\renewcommand{\theprintyear}{#1}}
- \newcommand{\signature}[2]{\par\vspace{\baselineskip}%
- \noindent\begin{minipage}{0.9\textwidth}%
- \noindent#1\\[\baselineskip]\textit{#2}
- \end{minipage}}
- %
- \protected@xdef\stdl@authorlist{\relax}
- \if@stdl@english
- \newcommand*{\stdl@authors}[1]{\IfSubStr{#1}{ xxx }{The Authors}{The Author}}%
- \newcommand{\stdl@copyrightmsg}{\textcopyright~%
- \IfSubStr{\stdl@authorlist}{ xxx }{THE AUTHORS}{THE AUTHOR} AND STUDENTLITTERATUR}
- \newcommand{\overrideauthors}[1]{%
- \renewcommand*{\stdl@authors}[1]{#1}
- \renewcommand*{\stdl@copyrightmsg}{\textcopyright~%
- \MakeUppercase{#1} AND STUDENTLITTERATUR}}
- \else
- \newcommand*{\stdl@authors}[1]{\IfSubStr{#1}{ xxx }{F\"orfattarna}{Montathar Faraon}}%
- \newcommand{\stdl@copyrightmsg}{\textcopyright~%
- \IfSubStr{\stdl@authorlist}{ xxx }{F\"ORFATTARNA}{F\"ORFATTAREN} OCH STUDENTLITTERATUR}
- \newcommand{\overrideauthors}[1]{%
- \renewcommand*{\stdl@authors}[1]{#1}
- \renewcommand*{\stdl@copyrightmsg}{\textcopyright~%
- \MakeUppercase{#1} OCH STUDENTLITTERATUR}}
- \fi
- \renewcommand{\author}[1]{
- \begingroup%
- \renewcommand{\and}{ xxx }%
- \protected@xdef\stdl@authorlist{#1}%
- \endgroup%
- \begingroup%
- \renewcommand{\and}{\unskip\\}%
- \protected@xdef\theauthor{#1}%
- \endgroup%
- }
- %
- \usetikzlibrary{fit,positioning}
- \newsavebox{\@stdl@chapbox}
- \newlength{\@stdl@rulew}
- \if@stdl@normalis
- \renewcommand{\maketitle}{%
- \thispagestyle{empty}
- \noindent\hspace*{34.5mm}\begin{minipage}[t]{70mm}%
- \vspace*{36pt}%
- \begin{tikzpicture}[node distance=0mm,
- tbox/.style={inner sep=0pt,align=left}]
- \node[tbox,anchor=south west] (title) at (0,0) {%
- \begin{varwidth}{70mm}
- \raggedright\normalfont\fontsize{20}{24}\selectfont\thetitle
- \end{varwidth}
- };
- \node[tbox,below=of title.south west,anchor=north west,minimum height=14pt] (subtitle) {%
- \begin{varwidth}{70mm}
- \raggedright\normalsize\itshape\thesubtitle
- \end{varwidth}
- };
- \node[tbox, below=of subtitle.south west,anchor=north west, minimum height=4mm] (spacing) {};
- \node[tbox,fit={(title) (subtitle) (spacing)}] (A) {};
- \draw[line width=0.3pt,below=2mm] (A.south west) -- (A.south east);
- \end{tikzpicture}
- \par\vspace*{2mm}
- \normalfont\fontsize{11}{15}\scshape\textls[100]{\MakeLowercase\theauthor}\par
- \vspace*{7.5mm}
- \normalfont\fontsize{10}{15}\thetranslator
- \if\theedition1\relax\else
- \vspace{7.5mm}
- \stdl@Ordinal{\theedition}~\stdl@editionnamex\par\fi
- \end{minipage}
- \vfill
- \noindent\hspace*{34.5mm}\begin{minipage}[t]{70mm}
- \includegraphics{Studlit_inlaga_svart_08}
- \end{minipage}
- \newpage
- \thispagestyle{empty}
- \enlargethispage{10mm}
- \noindent\begin{minipage}[t]{79.2mm}
- \normalfont\fontsize{8.5}{13}\selectfont\RaggedRight%
- \thecovertext
- \end{minipage}
- \vfill
- \noindent\begin{minipage}[t]{79.2mm}
- \setlength{\parindent}{0pt}\setlength{\parskip}{2.5mm}
- \raggedright
- \if@stdl@english
- \tikz[baseline] {%
- \draw[thick,rounded corners=2pt] (0,0) -- (3ex,0) -- (60:3ex) -- cycle;
- \draw[very thick,line cap=round] (1.5ex, 0.55ex) -- (1.5ex, 1.45ex);
- }
- \sffamily\fontsize{8.5}{13}\selectfont\textbf{Copying prohibited}\par
- \normalfont\fontsize{8.5}{13}\selectfont
- All rights reserved. No part of this publication may be\\
- reproduced or transmitted in any form or by any means,\\
- electronic or mechanical, including photocopying, recording,\\
- or any information storage and retrieval system, without\\
- permission in writing from the publisher.
- The papers and inks used in this product are eco-friendly.
- \else
- \begin{minipage}[c]{10mm}
- \includegraphics[width=8mm]{KopieringsK}
- \end{minipage}
- \sffamily\fontsize{8.5}{13}\selectfont\textbf{Kopieringsf\"orbud}\par
- \normalfont\fontsize{8.5}{13}\selectfont
- Detta verk \"ar skyddat av upphovsr\"attslagen. Kopiering,\\
- ut\"over l\"arares begr\"ansade r\"att att kopiera f\"or undervisningsbruk\\
- enligt Bonus Presskopias skolkopieringsavtal, \"ar f\"orbjuden. F\"or\\
- information om avtalet h\"anvisas till utbildningsanordnarens\\
- huvudman eller Bonus Presskopia. Testar
- Den som bryter mot lagen om upphovsr\"att kan \aa{}talas av\\
- allm\"an \aa{}klagare och d\"omas till b\"oter eller f\"angelse i upp\\
- till tv\aa{}\ \aa{}r samt bli skyldig att erl\"agga ers\"attning till\\
- upphovsman eller r\"attsinnehavare.
- Denna trycksak \"ar milj\"oanpassad, b\aa{}de n\"ar det g\"aller\\
- papper och tryckprocess. Testar.
- \fi
- \par
- \vspace*{2.5mm}
- \theartnr
- \theisbn
- \stdl@editionname~\theedition:1
- \textcopyright~\stdl@authors{\stdl@authorlist} \stdl@and~%
- Studentlitteratur~\thecopyrightyear \\
- www.studentlitteratur.se\\
- Studentlitteratur AB, Lund
- \stdl@thetranslator
- \thetechnicalreview
- \thecoverlayout
- \thecoverimage
- \vspace{2.5mm}\theprinter~\theprintyear
- \end{minipage}
- \newpage
- }
- \else
- \renewcommand{\maketitle}{%
- \thispagestyle{empty}
- \begin{adjustwidth}{42mm}{-58mm}%
- \noindent\hspace*{14pt}%
- \begin{minipage}[t]{92mm}%
- \vspace*{46pt}%
- \begin{tikzpicture}[node distance=0mm,
- tbox/.style={inner sep=0pt,align=left}]
- \node[tbox,anchor=south west] (title) at (0,0) {%
- \begin{varwidth}{86mm}
- \raggedright\normalfont\fontsize{20}{24}\selectfont\thetitle
- \end{varwidth}
- };
- \node[tbox,below=of title.south west,anchor=north west,minimum height=14pt] (subtitle) {%
- \begin{varwidth}{86mm}
- \raggedright\normalsize\itshape\thesubtitle
- \end{varwidth}
- };
- \node[tbox, below=of subtitle.south west,anchor=north west, minimum height=4mm] (spacing) {};
- \node[tbox,fit={(title) (subtitle) (spacing)}] (A) {};
- \draw[line width=0.3pt,below=2mm] (A.south west) -- (A.south east);
- \end{tikzpicture}
- \par\vspace*{2mm}
- \normalfont\fontsize{11}{15}\scshape\textls[100]{\MakeLowercase\theauthor}\par
- \vspace*{7.5mm}
- \normalfont\fontsize{10}{15}\thetranslator
- \if\theedition1\relax\else
- \vspace{7.5mm}
- \stdl@Ordinal{\theedition}~\stdl@editionnamex\par\fi
- \end{minipage}
- \end{adjustwidth}
- \enlargethispage{2mm}
- \vfill
- \noindent\hspace*{47mm}\begin{minipage}[t]{50mm}%
- \includegraphics{Studlit_inlaga_svart_08}
- \end{minipage}
- \newpage
- \thispagestyle{empty}
- \enlargethispage{2mm}
- \noindent\hspace*{-36mm}\begin{minipage}[t]{86mm}
- \normalfont\fontsize{8.5}{13}\selectfont\RaggedRight%
- \noindent\thecovertext
- \end{minipage}
- \vfill
- \noindent\hspace*{-29mm}\begin{minipage}[t]{86mm}
- \setlength{\parindent}{0pt}\setlength{\parskip}{2.5mm}
- \raggedright
- \if@stdl@english
- \tikz[baseline] {%
- \draw[thick,rounded corners=2pt] (0,0) -- (3ex,0) -- (60:3ex) -- cycle;
- \draw[very thick,line cap=round] (1.5ex, 0.55ex) -- (1.5ex, 1.45ex);
- }
- \sffamily\fontsize{8.5}{13}\selectfont\textbf{Copying prohibited}\par
- \normalfont\fontsize{8.5}{13}\selectfont
- All rights reserved. No part of this publication may be\\
- reproduced or transmitted in any form or by any means,\\
- electronic or mechanical, including photocopying, recording,\\
- or any information storage and retrieval system, without\\
- permission in writing from the publisher.
- The papers and inks used in this product are eco-friendly.
- \else
- \begin{minipage}[c]{10mm}
- \includegraphics[width=8mm]{KopieringsK}
- \end{minipage}
- \sffamily\fontsize{8.5}{13}\selectfont\textbf{Kopieringsf\"orbud}\par
- \normalfont\fontsize{8.5}{13}\selectfont
- Detta verk \"ar skyddat av upphovsr\"attslagen. Kopiering,\\
- ut\"over l\"arares r\"att att kopiera f\"or undervisningsbruk enligt\\
- BONUS-Presskopias avtal, \"ar f\"orbjuden. S\aa{}dant avtal tecknas\\
- mellan upphovsr\"attsorganisationer och huvudman f\"or\\
- utbildningssamordnare t.ex. kommuner/universitet. F\"or\\
- information om avtalet h\"anvisas till utbildningsanordnarens\\
- huvudman eller BONUS-Presskopia.
- Den som bryter mot lagen om upphovsr\"att kan \aa{}talas av\\
- allm\"an \aa{}klagare och d\"omas till b\"oter eller f\"angelse i upp\\
- till tv\aa{}\ \aa{}r samt bli skyldig att erl\"agga ers\"attning till\\
- upphovsman eller r\"attsinnehavare.
- Denna trycksak \"ar milj\"oanpassad, b\aa{}de n\"ar det g\"aller\\
- papper och tryckprocess.
- \fi
- \par
- \vspace*{2.5mm}
- \theartnr
- \theisbn
- \stdl@editionname~\theedition:1
- \textcopyright~\stdl@authors{\stdl@authorlist} \stdl@and~%
- Studentlitteratur~\thecopyrightyear \\
- www.studentlitteratur.se\\
- Studentlitteratur AB, Lund
- \stdl@thetranslator
- \thetechnicalreview
- \thecoverlayout
- \thecoverimage
- \vspace{2.5mm}\theprinter~\theprintyear
- \end{minipage}
- \newpage
- }
- \fi
- %
- % Chapter headings
- %
- \newlength{\@stdl@rulelength}
- \if@stdl@normalis
- \renewcommand{\beforepartskip}{%
- \begin{tikzpicture}[remember picture, overlay]
- \node at (current page.north west) {
- \begin{tikzpicture}[remember picture, overlay]
- \fill[\colpartbg] (-4mm,4mm) rectangle (159mm,-227mm);
- \end{tikzpicture}
- };
- \end{tikzpicture}%
- }
- \renewcommand{\afterpartskip}{\vfill\newpage
- \begin{tikzpicture}[remember picture, overlay]
- \node at (current page.north west) {
- \begin{tikzpicture}[remember picture, overlay]
- \fill[\colpartbg] (-4mm,4mm) rectangle (159mm,-227mm);
- \end{tikzpicture}
- };
- \end{tikzpicture}
- }
- \else
- \renewcommand{\beforepartskip}{%
- \begin{tikzpicture}[remember picture, overlay]
- \node at (current page.north west) {
- \begin{tikzpicture}[remember picture, overlay]
- \fill[\colpartbg] (-4mm,4mm) rectangle (174mm,-249mm);
- \end{tikzpicture}
- };
- \end{tikzpicture}%
- }
- \renewcommand{\afterpartskip}{\vfill\newpage
- \begin{tikzpicture}[remember picture, overlay]
- \node at (current page.north west) {
- \begin{tikzpicture}[remember picture, overlay]
- \fill[\colpartbg] (-4mm,4mm) rectangle (174mm,-249mm);
- \end{tikzpicture}
- };
- \end{tikzpicture}
- }
- \fi
- \renewcommand{\midpartskip}{\vspace*{2mm}}
- \renewcommand*{\partnamefont}{\sffamily\fontseries{l}\fontsize{9}{14}\selectfont\color{\colpart}}
- \renewcommand*{\partnumfont}{\sffamily\fontseries{l}\fontsize{9}{14}\selectfont}
- \renewcommand*{\printpartname}{\noindent\ignorespaces\hspace*{32.2mm}\partnamefont\textls*[100]{\MakeUppercase\partname}}
- \renewcommand*{\printpartnum}{\partnumfont\textls*[100]{\thepart}\hfill}
- \renewcommand*{\printpartname}{\relax}
- \renewcommand*{\printpartnum}{\relax}
- \renewcommand*{\partnamenum}{\hspace*{4pt}}
- \renewcommand*{\parttitlefont}{\normalfont\fontsize{20}{24}\selectfont}
- \if@stdl@english
- \newcommand{\stdl@partname}{PART}
- \else
- \newcommand{\stdl@partname}{DEL}
- \fi
- \renewcommand*{\printparttitle}[1]{
- \vspace*{10mm}\begin{adjustwidth}{42mm}{-58mm}%
- \noindent\hspace*{14pt}\raggedright
- \parttitlefont
- \begin{tikzpicture}
- [node distance=2.5mm,tbox/.style={inner sep=0pt,align=left}]
- \node[tbox,anchor=north west] (header) { \partnumfont\textls*[100]{\stdl@partname}\hspace*{4pt}\textls*[100]{\thepart} };
- \node[tbox,below=of header.south west,anchor=north west,inner ysep=2.5mm] (title) { #1 };
- \draw (title.north west) -- (title.north east);
- \node[tbox,fit={(header) (title)}] (A) {};
- \end{tikzpicture}
- \end{adjustwidth}
- }
- % Chapter style for frontmatter
- \makechapterstyle{frontmatterstyle}{%
- \chapterstyle{default}
- \renewcommand{\chapterheadstart}{\pagestyle{frontheadings}\thispagestyle{frontchapter}}
- \renewcommand{\chaptitlefont}{\sffamily\fontsize{11}{14}\selectfont}
- \renewcommand{\printchaptertitle}[1]{\chaptitlefont\MakeUppercase{\textls[60]{##1}}}
- \setlength{\beforechapskip}{-14pt}
- \setlength{\afterchapskip}{98pt}
- \renewcommand*{\afterchaptertitle}{%
- \par\nobreak \vskip\afterchapskip\noindent\par}
- }
- % Chapter style for mainmatter
- \if@stdl@normalis
- \makechapterstyle{studentlitteratur}{%
- \chapterstyle{default}
- \renewcommand*{\chapnumfont}{\sffamily\small}
- \renewcommand*{\chapnamefont}{\sffamily\small}
- \renewcommand*{\chaptitlefont}{\normalfont\Huge}
- \setlength{\afterchapskip}{65pt}
- \setlength{\beforechapskip}{0pt}
- \setlength{\midchapskip}{0pt}
- \renewcommand*{\printchapternum}{}
- \renewcommand*{\printchaptername}{%
- \begin{tikzpicture}[remember picture,overlay]
- \node[shift={(-19mm,-36mm)}] at (current page.north east)
- {%
- \begin{tikzpicture}[remember picture,overlay]
- \fill[\colchapbg] (0,0) rectangle (23mm,40mm);
- \node[rotate=90,anchor=north west,inner sep=0mm] at (3mm,1.3mm)
- {
- \chapnamefont\figureversion{lining}
- \MakeUppercase{\textls*[90]{\@chapapp}\hspace{0.5em}\thechapter}
- };
- \end{tikzpicture}
- };
- \end{tikzpicture}
- }
- \renewcommand*{\printchaptertitle}[1]{%
- \savebox{\@stdl@chapbox}{%
- \begin{minipage}[b]{0.90\textwidth}
- \leavevmode\chaptitlefont\color{\colchapter} ##1
- \end{minipage}
- }
- \vbox to 0pt{\vss\usebox{\@stdl@chapbox}}%
- }
- \renewcommand*{\chapterheadstart}{\vspace*{5pt}\par\noindent}
- \renewcommand*{\afterchaptertitle}{%
- \par\nobreak\vskip\afterchapskip\noindent\par}
- }
- \newcommand{\chaptersubtitle}[1]{%
- \begin{tikzpicture}[remember picture, overlay]
- \node[anchor=north west,inner sep=0pt] at ($(current page.north west)+(26mm,-42mm)$) {%
- \normalsize\itshape\color{\colchapter} #1
- };
- \end{tikzpicture}
- \addcontentsline{toc}{subh}{#1}
- }
- \newcommand{\chapterauthor}[1]{%
- \begin{tikzpicture}[remember picture, overlay]
- \node[anchor=north west,inner sep=0pt] at ($(current page.north west)+(26mm,-48mm)$) {
- \begin{tikzpicture}[remember picture, overlay]
- \node[anchor=north west]{
- \noindent%
- \begin{minipage}[b]{80mm}
- \leavevmode\fontsize{11}{15}\selectfont
- \color{\colchapter}
- \scshape\textls*[100]{\MakeLowercase{#1}}
- \end{minipage}};
- \end{tikzpicture}
- };
- \end{tikzpicture}
- \addcontentsline{toc}{chapauth}{\textls[100]{\MakeLowercase{#1}}}}
- \newcommand{\chapterquote}[2]{%
- \noindent\begin{minipage}[b]{80mm}
- \itshape #1\\[1.5mm]
- \normalfont\fontsize{8.7}{10}\selectfont\scshape\textls[60]{#2}
- \end{minipage}\vspace*{2\baselineskip}\par\ignorespaces\@doendeq}
- \else
- \makechapterstyle{studentlitteratur}{%
- \chapterstyle{default}
- \renewcommand*{\chapnumfont}{\sffamily\small}
- \renewcommand*{\chapnamefont}{\sffamily\small}
- \renewcommand*{\chaptitlefont}{\normalfont\Huge}
- \setlength{\afterchapskip}{84pt}
- \setlength{\beforechapskip}{0pt}
- \setlength{\midchapskip}{0pt}
- \renewcommand*{\printchapternum}{}
- \renewcommand*{\printchaptername}{%
- \begin{tikzpicture}[remember picture,overlay]
- \node[shift={(-12mm,-36mm)}] at (current page.north east)
- {%
- \begin{tikzpicture}[remember picture,overlay]
- \fill[\colchapbg] (0,0) rectangle (16mm,40mm);
- \node[rotate=90,anchor=north west,inner sep=0mm] at (3mm,1.3mm)
- {
- \chapnamefont\figureversion{lining}
- \MakeUppercase{\textls*[90]{\@chapapp}\hspace{0.5em}\thechapter}
- };
- \end{tikzpicture}
- };
- \end{tikzpicture}
- }
- \renewcommand*{\printchaptertitle}[1]{%
- \savebox{\@stdl@chapbox}{%
- \begin{minipage}[b]{0.90\textwidth}
- \leavevmode\chaptitlefont\color{\colchapter} ##1
- \end{minipage}
- }
- \vbox to 0pt{\vss\usebox{\@stdl@chapbox}}%
- }
- \renewcommand*{\chapterheadstart}{\vspace*{5pt}\par\noindent}
- \renewcommand*{\afterchaptertitle}{%
- \par\nobreak\vskip\afterchapskip\noindent\par}
- }
- \newcommand{\chaptersubtitle}[1]{%
- \begin{tikzpicture}[remember picture, overlay]
- \node[anchor=north west,inner sep=0pt] at ($(current page.north west)+(19mm,-42mm)$) {%
- \normalsize\itshape\color{\colchapter} #1
- };
- \end{tikzpicture}
- \addcontentsline{toc}{subh}{#1}
- }
- \newcommand{\chapterauthor}[1]{%
- \begin{tikzpicture}[remember picture, overlay]
- \node[anchor=north west,inner sep=0pt] at ($(current page.north west)+(19mm,-48mm)$) {
- \begin{tikzpicture}[remember picture, overlay]
- \node[anchor=north west]{
- \noindent%
- \begin{minipage}[b]{92mm}
- \leavevmode\fontsize{11}{15}\selectfont
- \color{\colchapter}
- \scshape\textls*[100]{\MakeLowercase{#1}}
- \end{minipage}};
- \end{tikzpicture}
- };
- \end{tikzpicture}
- \addcontentsline{toc}{chapauth}{\textls[100]{\MakeLowercase{#1}}}}
- \newcommand{\chapterquote}[2]{%
- \noindent\begin{minipage}[b]{80mm}
- \itshape #1\\[1.5mm]
- \normalfont\fontsize{8.7}{10}\selectfont\scshape\textls[60]{#2}
- \end{minipage}\vspace*{2\baselineskip}\par\ignorespaces\@doendeq}
- \fi
- \chapterstyle{studentlitteratur}
- %
- % Section headings
- %
- \raggedbottomsection
- %
- \setsecindent{0pt}
- \setbeforesecskip{-8mm plus -1mm minus -1mm}
- \setaftersecskip{1.411mm plus 0.2mm minus 0.2mm}
- \setsecnumformat{\csname the#1\endcsname\hspace*{0.5em}}
- \setsecheadstyle{\rmfamily\mdseries\fontsize{14}{14}\selectfont\raggedright\color{\colsection}}
- %
- \setsubsecindent{0pt}
- \setbeforesubsecskip{-24pt plus -3pt minus -2pt}
- \setaftersubsecskip{4pt plus 0pt}
- %\setsubsecnumformat{\csname the#1\endcsname\hspace*{0.5em}}
- \setsubsecheadstyle{\sffamily\bfseries\boldmath\fontsize{9.5}{14}\selectfont\raggedright\color{\colsubsection}\MakeUppercase}
- %
- \setsubsubsecindent{0pt}
- \setbeforesubsubsecskip{-24pt plus -3pt minus -2pt}
- \setaftersubsubsecskip{4pt}
- \setsubsubsecheadstyle{\sffamily\bfseries\boldmath\fontsize{9.5}{14}\selectfont\raggedright\color{\colsubsubsection}}
- %
- \setparaindent{0pt}
- \setbeforeparaskip{-24pt plus -2pt minus -1pt}
- \setafterparaskip{4pt}
- \setparaheadstyle{\sffamily\fontsize{9.5}{14}\selectfont\raggedright\color{\colparagraph}}
- %
- \setsubparaindent{0pt}
- \setbeforesubparaskip{-24pt plus -2pt minus -1pt}
- \setaftersubparaskip{4pt}
- \setsubparaheadstyle{\normalfont\normalsize\itshape\raggedright\color{\colparagraph}}
- \raggedbottomsectionfalse
- %
- % Table of contents
- %
- \DeclareRobustCommand{\LaTeX}{%
- {%
- L%
- \setbox\z@\hbox{\check@mathfonts
- \fontsize\sf@size\z@
- \math@fontsfalse\selectfont
- A}%
- \kern-.57\wd\z@
- \sbox\tw@ T%
- \vbox to\ht\tw@{\copy\z@ \vss}%
- \kern-.2\wd\z@}%
- {%
- \ifdim\fontdimen1\font=\z@
- \else
- \count\z@=\fontdimen5\font
- \multiply\count\z@ by 64\relax
- \divide\count\z@ by\p@
- \count\tw@=\fontdimen1\font
- \multiply\count\tw@ by\count\z@
- \divide\count\tw@ by 64\relax
- \divide\count\tw@ by\tw@
- \kern-\the\count\tw@ sp\relax
- \fi}%
- \TeX}
- \renewcommand{\tocheadstart}{\vspace*{-10pt}}
- \renewcommand{\printtoctitle}[1]{\sffamily\fontsize{11}{14}\selectfont\textls*[80]{\MakeUppercase #1}}
- \renewcommand{\aftertoctitle}{\pagestyle{frontheadings}\thispagestyle{frontchapter}\par\nobreak\vspace*{86pt}}
- %
- \if@stdl@english
- \newcommand{\stdl@chaptername}{CHAPTER}
- \newcommand{\stdl@appendixname}{APPENDIX}
- \else
- \newcommand{\stdl@chaptername}{KAPITEL}
- \newcommand{\stdl@appendixname}{BILAGA}
- \fi
- % Part entries
- \setlength{\cftbeforepartskip}{2.5mm plus 2pt minus 2pt}
- \renewcommand{\cftpartname}{\mdseries\textls[50]{\stdl@partname}~}
- \renewcommand{\cftpartformatpnum}[1]{\strut}
- \renewcommand{\cftpartaftersnumb}{}
- \renewcommand{\cftpartafterpnum}{\cftparfillskip}
- \newcommand*{\hnode}[1]{%
- \tikz[remember picture] \node[minimum size=0pt,inner sep=0pt,outer sep=3pt] (#1) {};}
- \renewcommand{\cftpartfont}{\hnode{P1}\sffamily\fontsize{8.5}{11}\bfseries\selectfont
- \tikz[remember picture,overlay] \draw (P1.north west) [line width={14pt}, \colpartbg] -- ++($(\textwidth,0) + (1ex,0)$);%----- 0 --
- }
- % Chapter entries
- \setlength{\cftbeforechapterskip}{5.644mm plus 3pt minus 6pt}
- \renewcommand{\cftchapterfont}{\sffamily\fontsize{10.4}{16}\bfseries\selectfont}
- \renewcommand{\cftchaptername}{\fontsize{8.5}{16}\mdseries\selectfont\textls[50]{\stdl@chaptername}~\figureversion{lining}}
- \renewcommand{\cftchapterpagefont}{\cftchapterfont}
- \renewcommand{\cftchapterformatpnum}[1]{\cftchapterfont\hspace{0.5em}#1}
- \renewcommand{\cftchapterleader}{}
- \renewcommand{\cftchapterafterpnum}{\cftparfillskip\par\vspace{2mm}}
- \renewcommand{\cftappendixname}{\fontsize{8.5}{16}\mdseries\selectfont\textls[50]{\stdl@appendixname}~\figureversion{lining}}
- \newlistentry{subh}{toc}{0}
- \renewcommand{\cftsubhleader}{}
- \renewcommand{\cftsubhafterpnum}{\cftparfillskip}
- \renewcommand{\cftsubhformatpnum}[1]{}
- \renewcommand{\cftsubhfont}{\normalfont\itshape}
- \setlength{\cftbeforesubhskip}{0.6mm}
- \newlistentry{chapauth}{toc}{0}
- \renewcommand{\cftchapauthleader}{}
- \renewcommand{\cftchapauthafterpnum}{\cftparfillskip\par\vspace{2mm}}
- \renewcommand{\cftchapauthformatpnum}[1]{}
- \renewcommand{\cftchapauthfont}{\normalfont\fontsize{9.5}{10}\scshape}
- \setlength{\cftbeforechapauthskip}{0.8mm}
- \setlength{\cftchapauthindent}{0mm}
- \setlength{\cftchapauthnumwidth}{0mm}
- % Section entries
- \setlength{\cftsectionindent}{0mm}
- \setlength{\cftsectionnumwidth}{12mm}
- \setlength{\cftbeforesectionskip}{0mm}
- \renewcommand{\cftsectionpagefont}{\cftsectionfont}
- \renewcommand{\cftsectionformatpnum}[1]{\cftsectionfont\hspace{0.5em}#1}
- \renewcommand{\cftsectionleader}{}
- \renewcommand{\cftsectionafterpnum}{\cftparfillskip\nobreak}
- % Subsection entries
- \setlength{\cftsubsectionnumwidth}{12mm}
- \setlength{\cftsubsectionindent}{6mm}
- \renewcommand{\cftsubsectionpagefont}{\cftsubsectionfont}
- \renewcommand{\cftsubsectionleader}{}
- \renewcommand{\cftsubsectionafterpnum}{\cftparfillskip}
- \renewcommand{\cftsubsectionformatpnum}[1]{\cftsubsectionfont\hspace{0.5em}#1}
- \renewcommand{\cftsubsectionpresnum}{\hspace*{-6mm}}
- \renewcommand{\cftsubsectionaftersnumb}{\hspace*{-6mm}}
- % Subsubsection entries
- \setlength{\cftsubsubsectionnumwidth}{12mm}
- \setlength{\cftsubsubsectionindent}{12mm}
- \renewcommand{\cftsubsubsectionpagefont}{\cftsubsectionfont}
- \renewcommand{\cftsubsubsectionleader}{}
- \renewcommand{\cftsubsubsectionafterpnum}{\cftparfillskip}
- \renewcommand{\cftsubsubsectionformatpnum}[1]{\cftsubsectionfont\hspace{0.5em}#1}
- \renewcommand{\cftsubsubsectionpresnum}{\hspace*{-12mm}}
- \renewcommand{\cftsubsubsectionaftersnumb}{\hspace*{-12mm}}
- %
- % Custom frontmatter
- %
- \renewcommand{\frontmatter}{%
- \@mainmatterfalse
- \setcounter{secnumdepth}{-10}
- \@memfront@floats
- \chapterstyle{frontmatterstyle}
- \pagestyle{frontheadings}
- }
- \renewcommand{\mainmatter}{%
- \cleardoublepage
- \@mainmattertrue
- \chapterstyle{studentlitteratur}
- \pagestyle{headings}
- \setcounter{secnumdepth}{\value{maxsecnumdepth}}
- \@memmain@floats}
- \renewcommand{\backmatter}{%
- \cleardoublepage
- \chapterstyle{frontmatterstyle}
- \pagestyle{frontheadings}
- \@mainmatterfalse
- \setcounter{secnumdepth}{-10}
- \@memback@floats}
- \renewcommand{\appendix}{%
- \cleardoublepage%
- \pagestyle{appendixheadings}%
- \setcounter{chapter}{0}%
- \setcounter{section}{0}%
- \gdef\@chapapp{\appendixname}%
- \gdef\thechapter{\@Alph\c@chapter}%
- \anappendixtrue}
- %
- % Lists and such
- %
- \newcommand*{\@doendeq}{\everypar{{\setbox\z@\lastbox}\everypar{}}}
- \renewenvironment{quotation}%
- {\list{}{%
- \setlength{\leftmargin}{20pt}
- \setlength{\rightmargin}{14pt}
- \setlength{\itemindent}{14pt}
- \setlength{\listparindent}{14pt}
- \setlength{\parsep}{7pt}}
- \fontsize{9.5}{13}\selectfont\item[]\noindent\ignorespaces%
- }%
- {\endlist}
- \AfterEndEnvironment{quotation}{\par\ignorespaces\@doendeq}
- \renewenvironment{quote}%
- {\list{}{\rightmargin\leftmargin}%
- \item[]\noindent}%
- {\endlist}
- \AfterEndEnvironment{quote}{\par\ignorespaces\@doendeq}
- % Note: These _should_ be lower case (transformed to small caps when used)
- \if@stdl@english
- \newcommand{\stdl@sourcename}{source}
- \else
- \newcommand{\stdl@sourcename}{k\"alla}
- \fi
- \newcommand{\source}[1]{\par\nobreak\fontsize{8}{10}\selectfont\noindent\scshape\textls[60]{\stdl@sourcename: \MakeLowercase{#1}}\vspace*{1mm}}
- \newcommand{\wrapquote}[2][5]{%
- \begin{wrapfigure}[#1]{r}{50mm}
- \fontsize{13}{17}\selectfont\vspace*{-10pt}
- \hspace*{4pt}\begin{tikzpicture}
- \node[anchor=north east,inner xsep=1pt] at (0,12pt) {\fontsize{32}{32}\selectfont''};
- \node[anchor=north west,text width=40mm, align=left, inner sep=0pt] at (0,4pt) { #2 };
- \end{tikzpicture}
- \end{wrapfigure}}
- \newenvironment{ingress}{\sffamily\fontsize{9}{14}\fontseries{sb}\selectfont}{\vspace{\baselineskip}\normalfont}
- \AfterEndEnvironment{ingress}{\par\ignorespaces\@doendeq}
- %
- % Captions and floats
- %
- \AtBeginDocument{%
- \if@stdl@english
- \renewcommand{\figurename}{FIGURE}
- \renewcommand{\tablename}{TABLE}
- \else
- \renewcommand{\figurename}{FIGUR}
- \renewcommand{\tablename}{TABELL}
- \fi
- }
- \newsubfloat{figure}
- \newsubfloat{table}
- \captionnamefont{\sffamily\figureversion{lining}\fontsize{6.5}{11}\fontseries{sb}\selectfont}
- \captiondelim{\hspace{0.5em}}
- \captiontitlefont{\sffamily\fontsize{8}{11}\fontseries{l}\selectfont}
- \captionstyle{\RaggedRight}
- %\precaption{\MakeUppercase}
- \subcaptionsize{\fontsize{6.5}{11}\selectfont}
- \subcaptionlabelfont{\sffamily\bfseries}
- \subcaptionfont{\sffamily\fontseries{l}\fontsize{8}{11}\selectfont}
- \subcaptionstyle{\RaggedRight}
- \hangsubcaption
- \let\@stdl@caption=\caption
- \newfixedcaption[\@stdl@caption]{\figcaption}{figure}
- \newfixedcaption[\@stdl@caption]{\tabcaption}{table}
- \newcommand{\wrapfig}[4][50mm]{%
- \begin{wrapfigure}[#3]{#2}[10mm]{#1}
- \vspace*{-10pt}
- \centering
- \let\caption=\figcaption
- \noindent\ignorespaces #4
- \end{wrapfigure}}
- \newcommand{\wraptab}[4][50mm]{%
- \begin{wrapfigure}[#3]{#2}[10mm]{#1}
- \vspace*{-10pt}
- \centering
- \let\caption=\tabcaption
- \noindent\ignorespaces #4
- \end{wrapfigure}}
- \newcommand{\wrapfigr}[2][5]{\wrapfig[50mm]{r}{#1}{#2}}
- \newcommand{\wrapfigR}[2][5]{\wrapfig[50mm]{R}{#1}{#2}}
- \newcommand{\wrapfigl}[2][5]{\wrapfig[50mm]{l}{#1}{#2}}
- \newcommand{\wrapfigL}[2][5]{\wrapfig[50mm]{L}{#1}{#2}}
- \newcommand{\wrapfigi}[2][5]{\wrapfig[50mm]{i}{#1}{#2}}
- \newcommand{\wrapfigI}[2][5]{\wrapfig[50mm]{I}{#1}{#2}}
- \newcommand{\wrapfigo}[2][5]{\wrapfig[50mm]{o}{#1}{#2}}
- \newcommand{\wrapfigO}[2][5]{\wrapfig[50mm]{O}{#1}{#2}}
- %
- \newcommand{\wraptabr}[2][5]{\wraptab[50mm]{r}{#1}{#2}}
- \newcommand{\wraptabR}[2][5]{\wraptab[50mm]{R}{#1}{#2}}
- \newcommand{\wraptabl}[2][5]{\wraptab[50mm]{l}{#1}{#2}}
- \newcommand{\wraptabL}[2][5]{\wraptab[50mm]{L}{#1}{#2}}
- \newcommand{\wraptabi}[2][5]{\wraptab[50mm]{i}{#1}{#2}}
- \newcommand{\wraptabI}[2][5]{\wraptab[50mm]{I}{#1}{#2}}
- \newcommand{\wraptabo}[2][5]{\wraptab[50mm]{o}{#1}{#2}}
- \newcommand{\wraptabO}[2][5]{\wraptab[50mm]{O}{#1}{#2}}
- %
- % Tables
- %
- \newcommand{\pretable}{%
- \sffamily\fontsize{8}{10.5}\fontseries{l}\selectfont
- \tabulinesep=1.5mm
- }
- \newcommand{\tablehead}{%
- \rowfont{\sffamily\mdseries\fontsize{8}{14}\selectfont}
- \rowcolor{\coltablehead}
- %\vphantom{\rule{4pt}{6pt}} %% FW:2013/02/03
- }
- \newcommand{\tablemain}{%
- \tabucline[0.3pt]{-}
- \everyrow{\tabucline[0.3pt on 0.3pt off 1pt]{-}}
- }
- \newcommand{\tablebottom}{%
- \everyrow{}
- \\ \tabucline[0.3pt]{-}
- }
- %
- % Footnotes
- %
- \renewcommand{\footnoterule}{\noindent\rule{25mm}{0.4pt}\vspace*{0.5mm}}
- \setlength{\footmarkwidth}{0pt}
- \setlength{\footmarksep}{0pt}
- \setlength{\footparindent}{0.5em}
- \footmarkstyle{\normalfont #1\hspace*{0.5em}}
- %
- % Set up the theorem environments
- %
- \DeclareRobustCommand{\sbem}{%
- \@nomath\em \if b\expandafter\@car\f@series\@nil
- \normalfont \else \bfseries \fi}
- %
- %\newcommand{\thmqed}{}
- % \declaretheoremstyle[
- % spaceabove=14pt plus 2pt minus 6pt,
- % spacebelow=14pt plus 2pt minus 6pt,
- % headpunct={},
- % postheadspace=0.5em,
- % headfont=\bfseries,
- % bodyfont=\itshape\let\em\sbem,
- % qed=\diamond
- % ]{stdtheorem}
- % \declaretheoremstyle[
- % spaceabove=14pt plus 2pt minus 6pt,
- % spacebelow=14pt plus 2pt minus 6pt,
- % headpunct={},
- % postheadspace=0.5em,
- % headfont=\bfseries,
- % bodyfont=\normalfont
- % ]{stddefinition}
- % \declaretheoremstyle[
- % spaceabove=14pt plus 2pt minus 6pt,
- % spacebelow=14pt plus 2pt minus 6pt,
- % headpunct={},
- % postheadspace=0.5em,
- % headfont=\itshape,
- % bodyfont=\normalfont
- % ]{stdremark}
- % \declaretheoremstyle[
- % spaceabove=14pt plus 2pt minus 6pt,
- % spacebelow=14pt plus 2pt minus 6pt,
- % headpunct={},
- % postheadspace=0.5em,
- % headfont=\itshape,
- % bodyfont=\normalfont,
- % headformat={\NAME\ \NOTE}
- % ]{stdproof}
- %
- % Boxed theorems
- %
- %
- \newcommand{\mdneedspace}{5\baselineskip}
- \mdfdefinestyle{mdtheoremstyle}{%
- linewidth=1pt,%
- roundcorner=4pt,%
- frametitlerule=false,%
- apptotikzsetting={%
- \tikzset{mdfframetitlebackground/.append style={fill=\colfancyhead}}%
- \tikzset{mdfbackground/.append style={fill=\colfancybox}}%
- },
- frametitlefont={\sffamily\bfseries\small},%
- theoremtitlefont={\sffamily\small},%
- font=\itshape\let\em\sbem,%
- frametitleaboveskip=3pt plus 1pt,%
- frametitlebelowskip=2pt plus 1pt,%
- innertopmargin=7pt plus 1pt minus 1pt,%
- innerbottommargin=8pt plus 1pt minus 1pt,%
- usetwoside=false,%
- leftmargin=0pt,%
- rightmargin=0pt,%
- splitbottomskip=10pt,%
- splittopskip=14pt,%
- needspace=\mdneedspace,%
- skipabove=14pt plus 2pt minus 6pt,%
- skipbelow=14pt plus 2pt minus 6pt%
- }
- \mdfdefinestyle{mddefinitionstyle}{%
- linewidth=1pt,%
- roundcorner=4pt,%
- frametitlerule=false,%
- apptotikzsetting={%
- \tikzset{mdfframetitlebackground/.append style={fill=\colfancyhead}}%
- \tikzset{mdfbackground/.append style={fill=\colfancybox}}%
- },%
- frametitlefont={\sffamily\bfseries\small\strut},%
- theoremtitlefont={\sffamily\small},%
- frametitleaboveskip=3pt plus 1pt,%
- frametitlebelowskip=2pt plus 1pt,%
- innertopmargin=7pt plus 1pt minus 1pt,%
- innerbottommargin=8pt plus 1pt minus 1pt,%
- outermargin = 0pt,%
- innermargin = 0pt,%
- splitbottomskip=10pt,%
- splittopskip=14pt,%
- needspace=\mdneedspace,%
- skipabove=14pt plus 2pt minus 6pt,%
- skipbelow=14pt plus 2pt minus 6pt%
- }
- \mdfdefinestyle{mdremarkstyle}{%
- linewidth=1pt,%
- roundcorner=4pt,%
- frametitlerule=false,%
- apptotikzsetting={%
- \tikzset{mdfframetitlebackground/.append style={fill=\colfancyhead}}%
- \tikzset{mdfbackground/.append style={fill=\colfancybox}}%
- },%
- frametitlefont={\sffamily\small\bfseries\strut},% FW:2013/02/03
- theoremtitlefont={\sffamily\small},%
- frametitleaboveskip=3pt plus 1pt,%
- frametitlebelowskip=2pt plus 1pt,%
- innertopmargin=7pt plus 1pt minus 1pt,%
- innerbottommargin=8pt plus 1pt minus 1pt,%
- outermargin = 0pt,%
- innermargin = 0pt,%
- splitbottomskip=10pt,%
- splittopskip=14pt,%
- needspace=\mdneedspace,%
- skipabove=14pt plus 2pt minus 6pt,%
- skipbelow=14pt plut 2pt minus 6pt%
- }
- \mdfdefinestyle{mdplainboxstyle}{%
- linewidth=1pt,%
- outermargin = 0pt,%
- innertopmargin = 7pt plus 3pt minus 1pt,%
- innerbottommargin = 7pt plus 4pt minus 2pt,%
- splittopskip = 14pt,%
- splitbottomskip = 10pt,%
- skipabove = 14pt plus 2pt minus 6pt,%
- skipbelow = 14pt plus 2pt minus 6pt%
- }
- \mdfdefinestyle{mdsidebarstyle}{%
- middlelinewidth = 2pt,%
- topline = false, rightline = false, bottomline = false,%
- linecolor=\colsideline,%
- usetwoside = false,%
- rightmargin = -0.1pt,%
- leftmargin = 0pt,%
- innertopmargin = 0pt,%
- innerbottommargin = 0pt,%
- innerleftmargin = 4mm,%
- innerrightmargin = 1pt,%
- splittopskip = 14pt,%
- splitbottomskip = 10pt,%
- skipabove = 14pt plus 2pt minus 6pt,%
- skipbelow = 14pt plus 2pt minus 6pt%
- }
- \mdfdefinestyle{mdthinsidebarstyle}{%
- middlelinewidth = 0.5pt,%
- topline = false, rightline = false, bottomline = false,%
- linecolor=black,%
- usetwoside = false,%
- rightmargin = -0.1pt,%
- leftmargin = 0pt,%
- innertopmargin = 0pt,%
- innerbottommargin = 0pt,%
- innerleftmargin = 4mm,%
- innerrightmargin = 1pt,%
- splittopskip = 14pt,%
- splitbottomskip = 10pt,%
- skipabove = 14pt plus 2pt minus 6pt,%
- skipbelow = 14pt plus 2pt minus 6pt%
- }
- \newmdenv[style=mddefinitionstyle]{fancybox}
- \newmdenv[style=mdplainboxstyle,backgroundcolor=\colplainbox]{plainbox}
- \newmdenv[style=mdplainboxstyle]{whitebox}
- \surroundwithmdframed[style=mdplainboxstyle]{raggedbox}
- \newmdenv[style=mdsidebarstyle]{sideline}
- \newmdenv[style=mdthinsidebarstyle]{thinsideline}
- \AfterEndEnvironment{fancybox}{\par\ignorespaces\@doendeq}
- \AfterEndEnvironment{plainbox}{\par\ignorespaces\@doendeq}
- \AfterEndEnvironment{whitebox}{\par\ignorespaces\@doendeq}
- \AfterEndEnvironment{raggedbox}{\par\ignorespaces\@doendeq}
- \AfterEndEnvironment{sideline}{\par\ignorespaces\@doendeq}
- \AfterEndEnvironment{thinsideline}{\par\ignorespaces\@doendeq}
- %
- % Index
- %
- \renewcommand{\preindexhook}{\fontsize{9.5}{13}\selectfont}
- \renewcommand{\l@index}{\@dottedtocline{1}{0em}{0pt}}
- \renewcommand{\@idxitem} {\par\hangindent 40\p@}
- \renewcommand{\subitem} {\par\hangindent 5mm \hspace*{3mm}--\ }
- \renewcommand{\subsubitem}{\par\hangindent 8mm \hspace*{6mm}--\ }
- \renewcommand{\indexspace}{\par\vskip 13\p@ \@plus2\p@
- \@minus2\p@\relax}
- \aliaspagestyle{indextitlepagestyle}{frontchapter}
- \xindyindex
- \newcommand{\lettergroup}[1]{\relax}
- %
- % Smart comma, orphans and widows
- %
- \clubpenalty=150
- \widowpenalty=10000
- \tolerance=1414
- \hbadness=1414
- \relpenalty=300
- % Make last line of each paragraph at least (approximately) 12 characters
- \setlength{\parfillskip}{0pt plus\dimexpr\textwidth-3\parindent}
- \emergencystretch.3\textwidth
- %
- \tightlists
- %
- % Prevent hyphenation of words beginning with an upper case letter.
- % This makes sure that proper names are never hyphenated, but
- % might cause slightly worse linebreaks, since it also prevents the
- % first word of each sentence to be hyphenated.
- %
- \uchyph=0
- %
- % Forbid hyphenations with two-letter parts
- %
- \AtBeginDocument{\righthyphenmin=3\lefthyphenmin=3}
- %
- % Code for testing
- %
- \newcommand{\testlayout}{
- \begin{tikzpicture}[remember picture,overlay]
- \node[anchor=north west,inner sep=0pt] at (current page.north west) {
- \begin{tikzpicture}[overlay]
- \draw[help lines,step=4mm] (0,-223mm) grid (155mm, 0);
- \foreach \y in {0,2,4,6,8,10,12,14,16,18,20,22} {
- \node[anchor=east] at (-3mm,-\y) { $\y$ };
- }
- \draw[red,very thin] (26mm,0) -- (26mm,-223mm);
- \draw[red,very thin] (19mm,0) -- (19mm,-223mm);
- \draw[red,very thin] (136mm,0) -- (136mm,-223mm);
- \draw[red,very thin] (129mm,0) -- (129mm,-223mm);
- \draw[red,very thin] (0,-14.5mm) -- (155mm,-14.5mm);
- \draw[red,very thin] (0,-69.5mm) -- (155mm,-69.5mm);
- \draw[red,very thin] (0,-207mm) -- (155mm,-207mm);
- \end{tikzpicture}
- };
- \end{tikzpicture}
- }
- \if@stdl@normalis
- \newcommand{\testgrid}{
- \begin{tikzpicture}[overlay,remember picture]
- \node[anchor=north west,inner sep=0pt] at (current page.north west) {
- \begin{tikzpicture}[overlay]
- \foreach \y in {-30,...,9} {
- \draw[blue, very thin] (0,-69.5mm+14pt*\y) -- (155mm,-69.5mm+14pt*\y);
- }
- \draw[red,very thin] (0,-69.5mm) -- (155mm,-69.5mm);
- \draw[red,very thin] (0,-36mm) -- (155mm,-36mm);
- \draw[red,very thin] (66mm,0) -- (66mm,-223mm);
- \draw[red,very thin] (0, -197mm) -- (155mm, -197mm);
- %\draw[red,very thin] (0, -31mm) -- (155mm, -31mm);
- \end{tikzpicture}
- };
- \end{tikzpicture}
- }
- \else
- \newcommand{\testgrid}{
- \begin{tikzpicture}[overlay,remember picture]
- \node[anchor=north west,inner sep=0pt] at (current page.north west) {
- \begin{tikzpicture}[overlay]
- \foreach \y in {-30,...,9} {
- \draw[blue, very thin] (0,-69.5mm+14pt*\y) -- (170mm,-69.5mm+14pt*\y);
- }
- \draw[red,thick] (0,-36mm) -- (170mm,-36mm);
- \draw[red,thick] (0,-70mm) -- (170mm,-70mm);
- \draw[blue,thick] (0,-245mm) -- (170mm,-245mm);
- \draw[blue,thick] (0,-229mm) -- (170mm,-229mm);
- \draw[blue,thick] (0,-217mm) -- (170mm,-217mm);
- %\draw[blue,thick] (0,-13mm) -- (170mm,-13mm);
- \draw[blue,thick] (0,-24mm) -- (170mm,-24mm);
- \draw[blue,thick] (19mm,0) -- (19mm,-245mm);
- \draw[blue,thick] (122mm,0) -- (122mm,-245mm);
- \draw[green,thick] (12mm,0) -- (12mm,-245mm);
- \draw[green,thick] (48mm,0) -- (48mm,-245mm);
- \draw[green,thick] (151mm,0) -- (151mm,-245mm);
- \end{tikzpicture}
- };
- \end{tikzpicture}
- }
- \newcommand{\testtitlegrid}{
- \begin{tikzpicture}[overlay,remember picture]
- \node[anchor=north west,inner sep=0pt] at (current page.north west) {
- \begin{tikzpicture}[overlay]
- \draw[green,thick] (66mm,0) -- (66mm,-245mm);
- \draw[green,thick] (19mm,0) -- (19mm,-245mm);
- \draw[red,thick] (0,-60mm) -- (170mm,-60mm);
- \draw[red,thick] (0,-217mm) -- (170mm,-217mm);
- \end{tikzpicture}
- };
- \end{tikzpicture}
- }\fi
- \newcommand{\includegraphicscolormodel}[2][]{%
- \if@stdl@colorcmyk
- \includegraphics[#1]{#2-cmyk}
- \else
- \includegraphics[#1]{#2-grey}
- \fi
- }
- \newcommand{\tikzmark}[1]{\tikz[overlay,remember picture,baseline] \node [anchor=base] (#1) {};}%
- %
- % Fix bug in colortbl/amsmath hdotsfor not filling columns
- %
- \def\hdots@for#1#2{\multicolumn{#2}c%
- {\m@th\dotsspace@1.5mu\mkern-#1\dotsspace@
- \xleaders\hbox{$\m@th\mkern#1\dotsspace@.\mkern#1\dotsspace@$}%
- \hskip\z@\@plus 1filll
- \mkern-#1\dotsspace@}%
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement