Template
1
0

Initial Commit

This commit is contained in:
Arindy
2022-05-04 14:27:36 +02:00
commit ac0ad2a895
11 changed files with 285 additions and 0 deletions

4
src/.formats/ebook.tex Normal file
View File

@@ -0,0 +1,4 @@
\documentclass[ebook,oneside]{memoir}
\usepackage[german]{babel}
\input{.formats/structure}
\input{book}

4
src/.formats/oneside.tex Normal file
View File

@@ -0,0 +1,4 @@
\documentclass[oneside]{memoir}
\usepackage[german]{babel}
\input{.formats/structure}
\input{book}

171
src/.formats/structure.tex Normal file
View File

@@ -0,0 +1,171 @@
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% eBook
% Structural Definitions File
% Version 1.0 (29/12/14)
%
% Created by:
% Vel (vel@latextemplates.com)
%
% Modified by:
% Arindy
%
% This file has been downloaded from:
% http://www.LaTeXTemplates.com
%
% License:
% CC BY-NC-SA 3.0 (http://creativecommons.org/licenses/by-nc-sa/3.0/)
%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%----------------------------------------------------------------------------------------
% REQUIRED PACKAGES
%----------------------------------------------------------------------------------------
\usepackage[utf8]{inputenc} % Required for inputting international characters
\usepackage[T1]{fontenc} % Output font encoding for international characters
\usepackage[osf]{libertine} % Use the Libertine font
\usepackage{microtype} % Improves character and word spacing
\usepackage{color}
\usepackage{tikz} % Required for drawing custom shapes
\usepackage{wallpaper} % Required for setting background images (title page)
\usepackage[unicode=true,bookmarks=true,bookmarksnumbered=false,bookmarksopen=false,breaklinks=false,pdfborder={0 0 1},backref=section,colorlinks=false]{hyperref} % PDF meta-information specification
%----------------------------------------------------------------------------------------
% PAPER, MARGIN AND HEADER/FOOTER SIZES
%----------------------------------------------------------------------------------------
\setlrmarginsandblock{50pt}{50pt}{*} % Left/right margins
\setulmarginsandblock{50pt}{50pt}{*} % Top/bottom margins
\setheadfoot{14pt}{12pt} % Header/footer height
%----------------------------------------------------------------------------------------
% HEADER AND FOOTER FORMATS
%----------------------------------------------------------------------------------------
\newcommand{\currentchapter}{}\let\oldchapter\chapter\RenewDocumentCommand{\chapter}{sm}{ \IfBooleanTF{#1}{\oldchapter*{#2}}{\oldchapter{#2} }\renewcommand{\currentchapter}{#2}}
\makepagestyle{mio} % Define a new custom page style
\makeheadrule{mio}{\textwidth}{0.1mm} % Header rule height
\makeevenhead{mio}{\scriptsize{\theauthor\hskip.2cm\textemdash\hskip.2cm\itshape{\thetitle}}}{}{} % Header specification
\makeoddhead{mio}{\hfill\scriptsize{\itshape{\currentchapter}}}{}{} % Header specification
\makeoddfoot{mio}{}{\footnotesize {\thepage}}{} % Footer specification
\makeevenfoot{mio}{}{\footnotesize {\thepage}}{} % Footer specification
\makeoddfoot{plain}{}{\footnotesize {\thepage}}{} % Pages of chapters
\makeevenfoot{plain}{}{\footnotesize {\thepage}}{} % Pages of chapters
\pagestyle{mio} % Set the page style to the custom style defined above
%----------------------------------------------------------------------------------------
% PART FORMAT
%----------------------------------------------------------------------------------------
\renewcommand{\partnamefont}{\centering\sffamily\itshape\Huge} % Part name font specification
\renewcommand{\partnumfont}{\sffamily\Huge} % Part number font specification
\renewcommand{\parttitlefont}{\centering\sffamily\scshape} % Part title font specification
\renewcommand{\beforepartskip}{\null\vskip.618\textheight} % Whitespace above the part heading
%----------------------------------------------------------------------------------------
% CHAPTER FORMAT
%----------------------------------------------------------------------------------------
\makechapterstyle{Tufte}{ % Define a new chapter style
\renewcommand{\chapterheadstart}{\null \vskip3.5\onelineskip} % Whitespace before the chapter starts
\renewcommand{\printchaptername}{\large\itshape\chaptername} % "Chapter" text font specification
\renewcommand{\printchapternum}{\LARGE\thechapter \\} % Chapter number font specification
\renewcommand{\afterchapternum}{} % Space between the chapter number and text
\renewcommand{\printchaptertitle}[1]{ % Chapter title font specification
\raggedright
\itshape\Huge{##1}}
\renewcommand{\afterchaptertitle}{
\vskip3.5\onelineskip
}}
\chapterstyle{Tufte} % Set the chapter style to the custom style defined above
%----------------------------------------------------------------------------------------
% SECTION FORMAT
%----------------------------------------------------------------------------------------
\setsecheadstyle{\sethangfrom{\noindent ##1}\raggedright\sffamily\itshape\Large} % Section title font specification
\setbeforesecskip{-.6\onelineskip} % Whitespace before the section
\setaftersecskip{.3\onelineskip} % Whitespace after the section
%----------------------------------------------------------------------------------------
% SUBSECTION FORMAT
%----------------------------------------------------------------------------------------
\setsubsecheadstyle{\sethangfrom{\noindent ##1}\raggedright\sffamily\large\itshape} % Subsection title font specification
\setbeforesubsecskip{-.5\onelineskip} % Whitespace before the subsection
\setaftersubsecskip{.2\onelineskip} % Whitespace after the subsection
%----------------------------------------------------------------------------------------
% SUBSUBSECTION FORMAT
%----------------------------------------------------------------------------------------
\setsubsubsecheadstyle{\sethangfrom{\noindent ##1}\raggedright\sffamily\itshape} % Subsubsection title font specification
\setbeforesubsubsecskip{-.5\onelineskip} % Whitespace before the subsubsection
\setaftersubsubsecskip{.1\onelineskip} % Whitespace after the subsubsection
%----------------------------------------------------------------------------------------
% CAPTION FORMAT
%----------------------------------------------------------------------------------------
\captiontitlefont{\itshape\footnotesize} % Caption font specification
\captionnamefont{\footnotesize} % "Caption" text font specification
%----------------------------------------------------------------------------------------
% QUOTATION ENVIRONMENT FORMAT
%----------------------------------------------------------------------------------------
\renewenvironment{quotation}
{\par\leftskip=1em\vskip.5\onelineskip\em}
{\par\vskip.5\onelineskip}
%----------------------------------------------------------------------------------------
% QUOTE ENVIRONMENT FORMAT
%----------------------------------------------------------------------------------------
\renewenvironment{quote}
{\list{}{\em\leftmargin=1em}\item[]}{\endlist\relax}
%----------------------------------------------------------------------------------------
% MISCELLANEOUS DOCUMENT SPECIFICATIONS
%----------------------------------------------------------------------------------------
\setlength{\parindent}{1em} % Paragraph indentation
\midsloppy % Fewer overfull lines - used in the memoir class and allows a setting somewhere between \fussy and \sloppy
\checkandfixthelayout % Tell memoir to implement the above
\newcommand{\subtitle}[1]{
\newcommand{\thesubtitle}{#1}
}
\newcommand{\removetitlebox}{
\newcommand{\rtb}{}
}
\newcommand{\coverpage}[2][violet]{
\thispagestyle{empty}
\ifthenelse{\equal{#2}{}}{}{\ThisTileWallPaper{1\paperwidth}{1\paperheight}{#2}}
\ifthenelse{\isundefined{\rtb}}{
\begin{tikzpicture}[remember picture,overlay]
\node [rectangle, rounded corners, fill=white, opacity=0.75, anchor=south west, minimum width=13cm, minimum height=4.2cm] (box) at (-1.5,-6) (box){}; % White rectangle - "minimum width/height" adjust the width and height of the box; "(-0.5,-10)" adjusts the position on the page
\ifthenelse{\isundefined{\thesubtitle}}{}{
\node[anchor=west, #1, xshift=-6.2cm, yshift=-3.9cm, text width=12.9cm, font=\sffamily] at (box.north){
\thesubtitle
};
}
\node[anchor=west, #1, xshift=-6.2cm, yshift=-2.2cm, text width=12.9cm, font=\sffamily\bfseries\scshape\HUGE] at (box.north){\thetitle}; % "Text width" adjusts the wrapping width, "xshift/yshift" adjust the position relative to the white rectangle
\ifthenelse{\isundefined{\theauthor}}{}{
\node[anchor=west, #1, xshift=-6.2cm, yshift=-0.6cm, text width=12.9cm, font=\sffamily\bfseries\large] at (box.north){\theauthor}; % "Text width" adjusts the wrapping width, "xshift/yshift" adjust the position relative to the white rectangle
}
\end{tikzpicture}
}{
\begin{tikzpicture}[remember picture,overlay]
\end{tikzpicture}
}
\newpage % Make sure the following content is on a new page
}

View File

@@ -0,0 +1,4 @@
\documentclass[]{memoir}
\usepackage[german]{babel}
\input{.formats/structure}
\input{book}

17
src/book.tex Executable file
View File

@@ -0,0 +1,17 @@
\usepackage[ left = \glqq{}, right = \grqq{}, leftsub = \glq{}, rightsub = \grq{} ]{dirtytalk}
\author{Arindy}
\title{Template Book}
\subtitle{--- Work in Progress ---}
%\removetitlebox
%-------------------------------------------
\begin{document}
\coverpage[black]{graphics/cover.jpg}
\include{chapters/one}
\end{document}

13
src/chapters/one.tex Normal file
View File

@@ -0,0 +1,13 @@
\chapter{one}\label{ch:one}
Zombie ipsum brains reversus ab cerebellum viral inferno, brein nam rick mend grimes malum cerveau cerebro.
De carne cerebro lumbering animata cervello corpora quaeritis.
Summus thalamus brains sit, morbo basal ganglia vel maleficia?
De braaaiiiins apocalypsi gorger omero prefrontal cortex undead survivor fornix dictum mauris.
Hi brains mindless mortuis limbic cortex soulless creaturas optic nerve, imo evil braaiinns stalking monstra hypothalamus adventus resi hippocampus dentevil vultus brain comedat cerebella pitiutary gland viventium.
Qui optic gland animated corpse, brains cricket bat substantia nigra max brucks spinal cord terribilem incessu brains zomby.
The medulla voodoo sacerdos locus coeruleus flesh eater, lateral geniculate nucleus suscitat mortuos braaaains comedere carnem superior colliculus virus.
Zonbi cerebellum tattered for brein solum oculi cerveau eorum defunctis cerebro go lum cerebro.
Nescio brains an Undead cervello zombies.
Sicut thalamus malus putrid brains voodoo horror.
Nigh basal ganglia tofth eliv ingdead.

BIN
src/graphics/cover.jpg Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 17 KiB

BIN
src/graphics/cover.jpg~ Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 15 KiB