Simple task: book-class
document, 12pt
font size, 6x9
page size. With the default book
settings (I don't really know what's the default line spacing in book-class
document) the document is typeset perfectly with no warnings. But it returns only 37 lines on page and a quiet wide line spacing for my needs. I'd prefer more lines (maybe 42) without changing the font size or the margins. The only way I see it done is by reducing the default line spacing that (to my liking) is too wide.
I tried all the methods suggested here Line spacing in book document class
but no matter what value I put in the text looks ugly and the code returns a lot of underfull \vbox (badness)
warnings. \linespread{}
doesn't seem to have an ability to decrease the line spacing, only to increase.
So what's the right (and simple) way to set a value (other than the default one) for the document's line spacing? In my case to decrease it. And preferably only for the \mainmatter
so the title
and all the pages before the \mainmatter
won't get affected. Here's the MWE.
% !TEX TS-program = LuaLaTeX
\documentclass[12pt,twoside,openany]{book}
\pagestyle{plain}
\usepackage[english, russian]{babel}
\usepackage{fontspec}
\setmainfont{EB Garamond}[
]
\usepackage{microtype}
\usepackage[shortcuts]{extdash}
\usepackage[pagewise]{lineno}
\linenumbers
\usepackage[
paperwidth=6in,
paperheight=9in,
inner=13mm,
top=15mm,
outer=20mm,
bottom=24mm, showframe,
heightrounded,
]{geometry}
\usepackage{lettrine}
\setcounter{DefaultLines}{3}
\renewcommand{\DefaultLoversize}{0.1}
\renewcommand{\DefaultLraise}{0}
\renewcommand{\LettrineTextFont}{}
\setlength{\DefaultFindent}{\fontdimen2\font}
\usepackage{lipsum}
\setlength{\parskip}{0pt}
\usepackage{graphicx}
\usepackage[dvipsnames]{xcolor}
\usepackage[pages=some]{background}
\usepackage{fancyhdr}
\fancyhf{}
\renewcommand{\headrulewidth}{0ex}
\fancyfoot[LE,RO]{\thepage}
\pagestyle{fancy}
\fancypagestyle{plain}{%
\fancyhf{}%
\renewcommand{\headrulewidth}{0ex}%
\fancyhf[lef,rof]{\thepage}%
}
\usepackage{etoolbox}
\makeatletter
\patchcmd{\chapter}{\if@openright\cleardoublepage\else\clearpage\fi}{\par}{}{}
\makeatother
%\raggedbottom % If used, it messes up the bottom line the way that its baseline hangs above the frame on some pages
\usepackage{titlesec}
\titleclass{\part}{top}
\titleformat{\part}{\vfil\penalty500\vfilneg\centering\normalfont\large}{\thepart.}{4ex}{\LARGE\centering}
\titlespacing*{\part}{0ex}{2ex plus 2ex minus 1ex}{0ex}
\titleclass{\chapter}{straight}
\titleformat{\chapter}{\vfil\penalty500\vfilneg\centering\normalfont\large}{\thechapter.}{4ex}{\large\centering}
\titlespacing*{\chapter} {0ex}{6ex plus 4ex minus 1ex}{2ex}
\setcounter{secnumdepth}{0}
\usepackage{tocloft}
\begin{document}
\pagestyle{plain}
\pagenumbering{gobble}
\addtocounter{page}{0}
\begin{titlepage}
\centering
{\large TITLE\par}
\vfill
\title{SOME TITLE}
\author{SOME AUTHOR}
\date{}
\end{titlepage}
\clearpage
\frontmatter
\mainmatter
\pagenumbering{arabic}
\part{PART ONE}
\begin{center}
\includegraphics[height=15ex,keepaspectratio]{example-image-a}
\end{center}
\chapter{CHAPTER ONE}
\begin{center}
\includegraphics[height=35ex,keepaspectratio]{example-image-b}
\end{center}
\lipsum[1-24]
\chapter{CHAPTER TWO}
\begin{center}
\includegraphics[height=35ex,keepaspectratio]{example-image-b}
\end{center}
\lipsum[1-24]
\chapter{CHAPTER THREE}
\begin{center}
\includegraphics[height=35ex,keepaspectratio]{example-image-b}
\end{center}
\lipsum[1-24]
\end{document}