Added section about Flatland
This commit is contained in:
parent
9617c37cdd
commit
1b8ac2a57e
@ -102,7 +102,6 @@
|
||||
|
||||
|
||||
|
||||
|
||||
\author{Kenneth John Odle}
|
||||
\title{
|
||||
{\Huge the codex} \\
|
||||
@ -332,8 +331,12 @@ fg|afd^c d2ga|bged e2ga|(3bag (3agf gedB|(3cBA AG AcBA|!
|
||||
GABc dBde|~g3e dega|bage dBAB|G2G2 G2:|!
|
||||
\end{abc}
|
||||
|
||||
Obviously, I have a lot more research to do.
|
||||
|
||||
\section{Tablature}
|
||||
|
||||
Tablature is a way of indicating which strings to play on stringed instruments like guitars and basses. (There are arguments about whether it's worth using tabs, as they do leave out some information, but I won't get into that here. Suffice it to say that everything has its divisive issues. Personally, I find that if you already know the tune, tabs are generally enough.)
|
||||
|
||||
|
||||
\chapter{What's to Like About Linux}
|
||||
|
||||
@ -501,9 +504,92 @@ First, I downloaded the package and unpacked it. Then I copied its contents into
|
||||
|
||||
\begin{verbatim}
|
||||
$ cp * ~/texmf
|
||||
$ sudo ~/texmf
|
||||
$ texhash ~/texmf
|
||||
\end{verbatim}
|
||||
|
||||
Mischief managed!
|
||||
|
||||
\end{document}
|
||||
\section{What I learned About \LaTeX{} While Creating Something Else}
|
||||
|
||||
For reasons I don't understand I went down an internet rabbit hole reading about the book \textit{Flatland}, by Edwin A. Abbott. This is a book I had purchased years ago in my youth (thank you, Dover Thrift Editions!) but had never gotten around to reading. I found a copy in \LaTeX{} at \href{https://github.com/Ivesvdf/flatland}{\texttt{https://github.com/Ivesvdf/flatland}}. It was old---twelve years old, in fact---and it was set up as a single-sided A4 document. If you've been following this journey this far, you know that I'm pretty fond of booklets, and that I'm in North America, so everything has to be lettersize paper.\footnote{As an American citizen, I am bound by the U.S. Constitution to both completely disavow the metric system and be utterly confused by it, and to decry it as terribly confusing despite the fact that is based on the number 10. I do believe it is our sworn duty to vehemently oppose anything which makes sense and also makes life better, such as universal health care. I don't know, something about eagles and gravy and guns.}
|
||||
|
||||
So I downloaded it, and decided to play around with it to see how much I could make it look like an actual book. My original purpose for starting this zine was to learn how to typeset things in \LaTeX{}, but it can be limiting since I've already figured out the format. Since I learn best from projects, another project was in order. This one fell into my lap at the perfect time.
|
||||
|
||||
\subsection{Removing Page Numbers from ``Part'' Pages}
|
||||
|
||||
In the \texttt{report} document class, chapters can be grouped into ``parts'' using
|
||||
|
||||
\begin{verbatim}
|
||||
part[]{}
|
||||
\end{verbatim}
|
||||
|
||||
\noindent wherever you want a new part. The argument between the square brackets is optional and determines what goes in the table of contents. The argument in the curly brackets is required and is what is sent to the page. (If the first argument is omitted, this is also what goes in the table of contents.) Surprisingly, these pages still have page numbers, which I just find odd. You can remove them by adding the \texttt{nonumonpart} package.
|
||||
|
||||
\subsection{Adding Additional Text to ``Part'' Pages}
|
||||
|
||||
It's fairly easy to \textit{remove} page numbers from the ``Part'' pages, but it not nearly as easy as it is to \textit{add} text to them. And it should be! In actual books, these pages often contain some sort of epigraph.
|
||||
|
||||
As it turns out, you make the text an optional argument to the \verb|\part| command by adding this to the preamble:\footnote{As described by \href{https://tex.stackexchange.com/users/1090/david-carlisle}{David Carlisle} at \href{https://tex.stackexchange.com/questions/336361/how-to-write-text-after-part}{\texttt{https://tex.stackexchange.com/questions/336361/how-to-write-text-after-part}}.}
|
||||
|
||||
\begin{verbatim}
|
||||
\makeatletter
|
||||
\let\old@endpart\@endpart
|
||||
\renewcommand\@endpart[1][]{%
|
||||
\begin{quote}#1\end{quote}%
|
||||
\old@endpart}
|
||||
\makeatother
|
||||
\end{verbatim}
|
||||
|
||||
\texttt{makeatletter} changes the \texttt{@} to letter category code so that the current document has access to package internal macros. \texttt{makeatother} changes it back to a letter so you can use it in your document.\footnote{This gets into the internal workings of LaTeX and so is far beyond the scope of this zine. However, there is some good information at \href{https://tex.stackexchange.com/questions/8351/what-do-makeatletter-and-makeatother-do}{\texttt{https://tex.stackexchange.com/questions/8351/what-do-makeatletter-and-makeatother-do}} and at \href{https://www.tug.org/pipermail/tugindia/2002-January/000178.html}{\texttt{https://www.tug.org/pipermail/tugindi \\ a/2002-January/000178.html}} if you are interested. A complete list of category codes can be found at \href{https://en.wikibooks.org/wiki/TeX/catcode}{\texttt{https://en.wikibooks.org/wiki/TeX/catcode}}}
|
||||
|
||||
\verb|\let\old@endpart\@endpart| says ``take the old value for \texttt{endpart} (which is part of the \texttt{part} function) and give it this new value that I'm about to describe''.
|
||||
|
||||
The rest of it redefines the \texttt{endpart} to now include a \verb|\quote| environment, which is quite appropriate for an epigraph.
|
||||
|
||||
\subsection{Adjusting the Line Spacing}
|
||||
\LaTeX{} was designed to write documents; as such, its ability to fine-tune certain document parameters, such as line-spacing, is fairly limited out of the box.\footnote{As it should be! Remember, the Unix Principle is to do one thing and do it well, not to be a Swiss army knife.} But if you need something, chances are that someone else has needed it before you and created a package that will do just that. In this case, the package you need is the \texttt{setspace} package.
|
||||
|
||||
Add that to your preamble, and you can adjust the line spacing of your document by adding either \texttt{singlespacing}, \texttt{onehalfspacing}, or the \texttt{doublespacing} command to your preamble.
|
||||
|
||||
That gives you the versatility that you had with a typewriter. To set more precise line spacing, you can use the \texttt{setstretch} command in your preamble:
|
||||
|
||||
\begin{verbatim}
|
||||
\setstretch{1.1}
|
||||
\end{verbatim}
|
||||
|
||||
\noindent which sets a line spacing equivalent to 1.1 lines. If you want to change the line spacing for just a portion of your document, use the \texttt{spacing} environment:
|
||||
|
||||
\begin{verbatim}
|
||||
\begin{spacing}{2.5}
|
||||
Your widely spaced text goes here.
|
||||
\end{spacing}
|
||||
\end{verbatim}
|
||||
|
||||
This is a small, simple package, but one that I am sure I'll have a lot of use for down the road.
|
||||
|
||||
\subsection{Include Page Numbers on ``Chapter'' Pages}
|
||||
|
||||
I set up my version of \textit{Flatland} to have the page numbers in the header and to completely suppress the footers. But I wanted those headers to appear on the chapter pages (you'll notice in this zine that they don't appear), because this is how the book was originally typeset back in the nineteenth century. As it turns out, the \texttt{titlesec} package makes this very easy:
|
||||
|
||||
\begin{verbatim}
|
||||
\usepackage[]{titlesec}
|
||||
\assignpagestyle{\chapter}{fancy}
|
||||
\end{verbatim}
|
||||
|
||||
For what it's worth, if you want to \textit{omit} the headers and footers on a give page, just add
|
||||
|
||||
\begin{verbatim}
|
||||
\thispagestyle{empty}
|
||||
\end{verbatim}
|
||||
|
||||
somewhere \textit{after} the start of the page.
|
||||
|
||||
\subsection{A Few Little Things}
|
||||
\begin{itemize}
|
||||
\item Want \textsc{Small Caps}? Wrap them in \verb|textsc{ }|.
|
||||
\item Need to control the gap between the header and the rest of the text? Pass the \verb|headsep| argument to the \texttt{geometry} package and set it equal to the amount of space you need (i.e., \texttt{headsep=12pt}).
|
||||
\item If you want to add a degree symbol to inline text, the simplest way I've found (so far) is to just pop in and out of math mode with this: \verb|$^{\circ}$| which gives you this: $^{\circ}$
|
||||
\end{itemize}
|
||||
|
||||
|
||||
\end{document}
|
||||
|
Loading…
Reference in New Issue
Block a user