From 760f3a0451021c9eb19f1eb36ec978ea9bb1e87d Mon Sep 17 00:00:00 2001 From: Kenneth Odle Date: Mon, 6 Jul 2026 14:43:38 -0400 Subject: [PATCH] Added memoir class template --- chapters/1-titlepage.tex | 32 +++++++++++++++++ chapters/2-impressum.tex | 46 ++++++++++++++++++++++++ memoir-class-template.tex | 49 ++++++++++++++++++++++++++ parts/1-packages.tex | 13 +++++++ parts/2-class.tex | 74 +++++++++++++++++++++++++++++++++++++++ parts/3-variables.tex | 7 ++++ parts/4-commands.tex | 50 ++++++++++++++++++++++++++ 7 files changed, 271 insertions(+) create mode 100644 chapters/1-titlepage.tex create mode 100644 chapters/2-impressum.tex create mode 100644 memoir-class-template.tex create mode 100644 parts/1-packages.tex create mode 100644 parts/2-class.tex create mode 100644 parts/3-variables.tex create mode 100644 parts/4-commands.tex diff --git a/chapters/1-titlepage.tex b/chapters/1-titlepage.tex new file mode 100644 index 0000000..2ccea26 --- /dev/null +++ b/chapters/1-titlepage.tex @@ -0,0 +1,32 @@ +%% Title Page +\pagestyle{empty} +\vspace*{25mm} +%\fontsize{28}{42}\selectfont +{\centering +{\Huge \textsc{TITLE}} +\noindent{}{\color{green5}\rule{\textwidth}{1.5pt}} +\noindent{}{\color{green5}\rule[2mm]{\textwidth}{0.5pt}} + +\vspace{2mm} +{\large SUBTITLE} + +\vspace{5mm} +Issue \#\kissue{} + +\vspace{5mm} +Written and Edited by\\K.J. Odle + +\vspace{5mm} +\kpubdate{} + +\vspace{2mm} +First Printing + +\vspace{20mm} +Typeset in \LaTeX{} + + +} % end centering environment + +\newpage + diff --git a/chapters/2-impressum.tex b/chapters/2-impressum.tex new file mode 100644 index 0000000..f4137f8 --- /dev/null +++ b/chapters/2-impressum.tex @@ -0,0 +1,46 @@ +\chapterstyle{kfront} + +%% Impressum +%\setcounter{page}{1} +\chapter*{Impressum} +\addcontentsline{toc}{chapter}{Impressum} + +All contents \copyright\kpubyear{} Kenneth John Odle + +\vspace{50mm} + +\noindent{}More information about this zine (as well as information about my other zines) can be found here: + +\kref{https://just13.click/just13}{just13.click/just13} + +\noindent{}This is typeset in \LaTeX \,using the memoir document class. It then gets exported to a letterhalf (5.5 in x 8.5 in) pdf, which then gets made into a booklet using PDF Booklet, which you can find at + +\kref{https://pdfbooklet.sourceforge.io/wordpress/}{https://pdfbooklet.sourceforge.io/wordpress/} + +\medskip + +\noindent{}I'm pushing this to my own git server as I write this. You can find it at: + + \kref{https://git.kjodle.net/kjodle/REPONAME}{https://git.kjodle.net/kjodle/REPONAME} + +\medskip + +\noindent{}If you want to donate financial support for the creation of this zine (and all the hours of research that go into it), you can do so at + +\kref{https://paypal.me/kjodle}{https://paypal.me/kjodle} (Thanks!) + +\medskip + +\noindent{}\textbf{Errata:} To err is human, to document those errors is divine. A list of errata can be found at: + +\kref{https://git.kjodle.net/kjodle/REPONAME/wiki/Errata}{https://git.kjodle.net/kjodle/REPONAME/wiki/Errata} + +\medskip + +\noindent{}I am on social media at: + +\noindent{}\kref{https://bsky.app/profile/iswpw.bsky.social}{https://bsky.app/profile/iswpw.bsky.social}\\ +\kref{https://mastodon.social/@kjodle}{https://mastodon.social/@kjodle} + +\newpage + diff --git a/memoir-class-template.tex b/memoir-class-template.tex new file mode 100644 index 0000000..f87ad9e --- /dev/null +++ b/memoir-class-template.tex @@ -0,0 +1,49 @@ +\documentclass[9pt,openany]{memoir} + +%%% Input parts +% \input{parts/1-packages} +% \input{parts/2-memoir} +% \input{parts/3-variables} +% \input{parts/4-commands} + +%%% Get it started +\checkandfixthelayout % Required if you have altered settings for the memoir class +\begin{document} + +\pagenumbering{roman} + +%%% Input titlepage and impressum here +% \input{chapters/1-titlepage} +% \input{chapters/2-impressum} + +%%% TOC +\pagestyle{empty} +\tableofcontents +\clearpage % Delete if TOC runs to 2n pages + +\pagestyle{empty} +\listoffigures +\clearpage + + +%%% Begin Contents +\setcounter{page}{1} +\pagenumbering{arabic} +\pagestyle{kpage} +\chapterstyle{kchap} + +%%% Input chapters here +% \input{chapters/ch01} +% \input{chapters/ch02} +% \input{chapters/ch03} + +\end{document} + +%%% Chapter template +\chapter{} + +\begin{multicols*}{2} + +\lettrine[lraise=0.0, nindent=-0pt]{}{} + +\end{multicols*} \ No newline at end of file diff --git a/parts/1-packages.tex b/parts/1-packages.tex new file mode 100644 index 0000000..d6f631a --- /dev/null +++ b/parts/1-packages.tex @@ -0,0 +1,13 @@ +%% Generic packages +\usepackage[utf8]{inputenc} +\usepackage{ninecolors} +\usepackage{lettrine} % Drop caps +\usepackage[object=vectorian]{pgfornament} +\usepackage[english]{babel} % Correcting hyphenation issues +\usepackage{ragged2e} +\usepackage{graphicx} +\usepackage{wrapfig} +\usepackage{float} % Allow floats in multicol environments +\usepackage{tcolorbox} +\usepackage[hidelinks]{hyperref} + diff --git a/parts/2-class.tex b/parts/2-class.tex new file mode 100644 index 0000000..238a79c --- /dev/null +++ b/parts/2-class.tex @@ -0,0 +1,74 @@ +%%% Page layout (half letter) %% Specific to Memoir class +% https://tex.stackexchange.com/a/758505/245702 +\setstocksize{8.5in}{5.5in} +\settrimmedsize{8.5in}{5.5in}{*} +\settrims{0mm}{0mm} +\setlrmarginsandblock{12mm}{15mm}{*} +\setulmarginsandblock{22mm}{20mm}{*} + +%%% Chapter titles %% Specific to Memoir class +\makechapterstyle{kchap}{ +\renewcommand*{\chapterheadstart}{\vspace*{\beforechapskip}} +\renewcommand*{\printchaptername}{} +\renewcommand*{\chapternamenum}{\space} +\renewcommand*{\printchapternum}{\hfill\chapnumfont Chapter \thechapter} +\renewcommand*{\afterchapternum}{\par\nobreak\vskip \midchapskip\hrule\vspace{5mm}} +\renewcommand*{\printchapternonum}{} +%\renewcommand*{\printchaptertitle}[1]{\chaptitlefont #1} +\renewcommand*{\afterchaptertitle}{\par\nobreak\vskip \afterchapskip} +\renewcommand*{\chapnamefont}{\normalfont\normalsize} +\renewcommand*{\chapnumfont}{\normalfont\large\itshape} +\renewcommand*{\chaptitlefont}{\normalfont\Huge\scshape} +\setlength{\beforechapskip}{0mm} +\setlength{\midchapskip}{2mm} +\setlength{\afterchapskip}{10mm} +} + +\makechapterstyle{kfront}{ +\renewcommand*{\chapterheadstart}{\vspace*{\beforechapskip}} +\renewcommand*{\printchaptername}{} +\renewcommand*{\chapternamenum}{\space} +%\renewcommand*{\printchapternum}{\hfill\chapnumfont Chapter \thechapter} +\renewcommand*{\afterchapternum}{\par\nobreak\vskip \midchapskip\hrule\vspace{5mm}} +\renewcommand*{\printchapternonum}{} +%\renewcommand*{\printchaptertitle}[1]{\chaptitlefont #1} +\renewcommand*{\afterchaptertitle}{\par\nobreak\vskip \afterchapskip} +\renewcommand*{\chapnamefont}{\normalfont\normalsize} +\renewcommand*{\chapnumfont}{\normalfont\large\itshape} +\renewcommand*{\chaptitlefont}{\normalfont\Huge\scshape} +\setlength{\beforechapskip}{0mm} +\setlength{\midchapskip}{2mm} +\setlength{\afterchapskip}{10mm} +} + +%%% Page styles %% Specific to Memoir class +%\newcommand{\kinfo}{{\footnotesize Chapter \thechapter{} • \S{} \rightmark{}}} +%\newcommand{\kinfo}{{\footnotesize Chapter \thechapter: \leftmark{} • \rightmark}} +\newcommand{\kinfo}{{\footnotesize Issue \kissue{} • Summer}} +\makepagestyle{kpage} +\makeevenhead{kpage}{\textsc{Walking}}{}{\kinfo} +\makeoddhead{kpage}{\kinfo}{}{\textsc{Walking}} +\makeevenfoot{kpage}{}{\thepage}{} +\makeoddfoot{kpage}{}{\thepage}{} +\makeheadrule{kpage}{\textwidth}{0.1mm} +\makefootrule{kpage}{\textwidth}{0.1mm}{2mm} +\makepsmarks{kpage}{ + \nouppercaseheads + \createmark {chapter}{left}{nonumber}{}{} + \createmark {section}{right}{nonumber}{}{} +} +\makeatother + + +%%% Other Memoir class settings +\setlength{\epigraphwidth}{16em} +% Section styling +\setsecheadstyle{\normalsize\bfseries} +\setbeforesecskip{0.5\baselineskip} +\setaftersecskip{0.5\baselineskip} +% Indent sections in TOC +\setlength{\cftsectionindent}{10mm} + +%%% required if you have changed the settings! %% Specific to Memoir class +\checkandfixthelayout + diff --git a/parts/3-variables.tex b/parts/3-variables.tex new file mode 100644 index 0000000..b93429a --- /dev/null +++ b/parts/3-variables.tex @@ -0,0 +1,7 @@ +%%% Variables +\def\kauthors{} +\def\ktitle{} +\def\kissue{1} +\def\kpubdate{August 2026} +\def\kpubyear{2026} + diff --git a/parts/4-commands.tex b/parts/4-commands.tex new file mode 100644 index 0000000..2c7c22d --- /dev/null +++ b/parts/4-commands.tex @@ -0,0 +1,50 @@ +%%% Multicolumns +\usepackage{multicol} +\setlength{\columnseprule}{0.5pt} +\def\columnseprulecolor{\color{gray7}} +\setlength{\columnsep}{5mm} + +%%% Poetry +\usepackage{verse} +\newcommand{\attrib}[1]{ + \nopagebreak{\raggedleft\footnotesize #1\par\vspace{\baselineskip}} + } +\renewcommand{\poemtitlefont}{\normalfont\large\itshape\centering} + +%%% Fonts +\usepackage{mathptmx} +%\usepackage{newtxtext,newtxmath} + +%%% Text decorations +\newcommand{\kdec}{ + \noindent{}\begin{center} + \pgfornament[scale=0.25,color=green6]{85} + \end{center} + } + +%%% Misc commands +%\setcounter{secnumdepth}{0} +\newcommand{\kskip}{\\\hphantom{xxx}} +% Make hrefs easier (must load package hyperref} +\newcommand\kref[2]{\href{#1}{{\texttt{#2}}}} +% Put unnumbered sections in TOC, also with idented second lines for Latin names +\newcommand{\ksecp}[3]{ + \section*{ +% \raggedright + {\small {#1}\kskip{}\textmd{({#2} • {\small \textsc{{#3}}}})} + } + \addcontentsline{toc}{section}{{\small {#1} ({#2} • {\small \textsc{\textmd{{#3}}}})}} + } +\newcommand{\ksecn}[1]{ + \section*{{#1}} + \addcontentsline{toc}{section}{{#1}} + } +% Where are our images? +\graphicspath{{images/}} +% Custom boxes for «tcolorbox» package +\newtcolorbox{kbox}{ + colback=white, + sharp corners=all, + boxrule=0.75pt, + colframe=gray8, +} \ No newline at end of file