3

There are a few questions asking how to change line spacing in table or equation environments, for example. The usual solution is to do something like

\makeatletter
\patchcmd{\env@cases}{1.2}{0.72}{}{}
\makeatother

Unfortunately the \cfrac command is not an environment, so this doesn't work. Is there a similar solution to the above using patchcmd? My thesis style file uses a baselineskip of 1.6 if that matters, and this makes cfractions way too vertically spaced.

I'm using the article class with 11pt font and the style file has the line

\renewcommand{\baselinestretch}{1.7}

Also the style file changes back to single spacing in figures and footnotes using such code as

\def\@xfloat#1[#2]{\ifhmode \@bsphack\@floatpenalty -\@Mii\else
   \@floatpenalty-\@Miii\fi\def\@captype{#1}\ifinner
      \@parmoderr\@floatpenalty\z@
    \else\@next\@currbox\@freelist{\@tempcnta\csname ftype@#1\endcsname
       \multiply\@tempcnta\@xxxii\advance\@tempcnta\sixt@@n
       \@tfor \@tempa :=#2\do
                        {\if\@tempa h\advance\@tempcnta \@ne\fi
                         \if\@tempa t\advance\@tempcnta \tw@\fi
                         \if\@tempa b\advance\@tempcnta 4\relax\fi
                         \if\@tempa p\advance\@tempcnta 8\relax\fi
         }\global\count\@currbox\@tempcnta}\@fltovf\fi
    \global\setbox\@currbox\vbox\bgroup 
    \def\baselinestretch{1}\@normalsize
    \boxmaxdepth\z@
    \hsize\columnwidth \@parboxrestore}

Hopefully there's a way to do something like this for cfractions.

2
  • Please tell us which document class you employ and how you're modifying \baselineskip (or maybe \baselinestretch?) at present.
    – Mico
    Commented May 3, 2021 at 7:26
  • It's the article class and the command in the style file is \renewcommand{\baselinestretch}{1.7}. I just updated my question to this effect and gave additional style file information.
    – Jason D.
    Commented May 3, 2021 at 7:29

1 Answer 1

0

This produces the attached output, but I reduced the space 'manually'. Maybe you can make a macro of it.

\documentclass{article}%
\usepackage{amsmath}
\usepackage{setspace}
\begin{document}%
\setstretch{2.6}

This is a long text. This is a long text. This is a long text. This is a long text. This is a long text.\

\textbf{This is a long text. This is a long text. This is a long text. This is a long text. This is a long text.}\\

{$\setstretch{1.2}
\cfrac[r]{a}{b}$}\\
abeeeee deeeee fkkkkkkkk abeeeee deeeee fkkkkkkkk abeeeee deeeee fkkkkkkkk abeeeee deeeee fkkkkkkkk abeeeee deeeee fkkkkkkkk%
\end{document}%

setstretch

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .