0

I am using the following code to try and produce a uniform looking sequence of periods and red asterisk.

\documentclass[10pt]{article}
\usepackage[paperheight=11in,paperwidth=8.5in,margin=.5in]{geometry}
\usepackage{xcolor}
\usepackage{seqsplit}
\begin{document}
\linespread{.3}
\noindent
\begin{center}
{\small\seqsplit{.......{\textcolor{red}{\raisebox{-0.15cm}{*}}}.{\textcolor{red}{\raisebox{-0.15cm}{*}}}..............................................................................................................................................................................................................................................................................{\textcolor{red}{\raisebox{-0.15cm}{*}}}.....{\textcolor{red}{\raisebox{-0.15cm}{*}}}.....{\textcolor{red}{\raisebox{-0.15cm}{*}}}{\textcolor{red}{\raisebox{-0.15cm}{*}}}................{\textcolor{red}{\raisebox{-0.15cm}{*}}}.......{\textcolor{red}{\raisebox{-0.15cm}{*}}}.................................................................................................................................................................................{\textcolor{red}{\raisebox{-0.15cm}{*}}}..............{\textcolor{red}{\raisebox{-0.15cm}{*}}}.............{\textcolor{red}{\raisebox{-0.15cm}{*}}}....................................................................................................................................................................................{\textcolor{red}{\raisebox{-0.15cm}{*}}}........................{\textcolor{red}{\raisebox{-0.15cm}{*}}}{\textcolor{red}{\raisebox{-0.15cm}{*}}}.{\textcolor{red}{\raisebox{-0.15cm}{*}}}..........................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................\\\\}}
\end{center}
\end{document}

But that code produces inconsistent line spacing. I would like all lines to be squished together.

Seqsplit section with inconsistent line spacing

How can I get consistent line spacing?

1

1 Answer 1

0

TeX increases distance between lines because it tries to fit your stars. If you tell it that the stars have zero height and zero depth, it will not do this. Fortunately the command \raisebox has optional parameters just for this: \raisebox{amount}[height][depth]{stuff}. So this works:

\documentclass[10pt]{article}
\usepackage[paperheight=11in,paperwidth=8.5in,margin=.5in]{geometry}
\usepackage{xcolor}
\usepackage{seqsplit}
\begin{document}
\pagestyle{empty}
\linespread{.3}
\noindent
\begin{center}
{\small\seqsplit{.......{\textcolor{red}{\raisebox{-0.15cm}[0pt][0pt]{*}}}.{\textcolor{red}{\raisebox{-0.15cm}[0pt][0pt]{*}}}..............................................................................................................................................................................................................................................................................{\textcolor{red}{\raisebox{-0.15cm}[0pt][0pt]{*}}}.....{\textcolor{red}{\raisebox{-0.15cm}[0pt][0pt]{*}}}.....{\textcolor{red}{\raisebox{-0.15cm}[0pt][0pt]{*}}}{\textcolor{red}{\raisebox{-0.15cm}[0pt][0pt]{*}}}................{\textcolor{red}{\raisebox{-0.15cm}[0pt][0pt]{*}}}.......{\textcolor{red}{\raisebox{-0.15cm}[0pt][0pt]{*}}}.................................................................................................................................................................................{\textcolor{red}{\raisebox{-0.15cm}[0pt][0pt]{*}}}..............{\textcolor{red}{\raisebox{-0.15cm}[0pt][0pt]{*}}}.............{\textcolor{red}{\raisebox{-0.15cm}[0pt][0pt]{*}}}....................................................................................................................................................................................{\textcolor{red}{\raisebox{-0.15cm}[0pt][0pt]{*}}}........................{\textcolor{red}{\raisebox{-0.15cm}[0pt][0pt]{*}}}{\textcolor{red}{\raisebox{-0.15cm}[0pt][0pt]{*}}}.{\textcolor{red}{\raisebox{-0.15cm}[0pt][0pt]{*}}}..........................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................................\\\\}}
\end{center}
\end{document}

enter image description here

1
  • Worked like a charm and I learned something new. Thanks.
    – KBoehme
    Commented Mar 18, 2017 at 4:00

You must log in to answer this question.

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