5

I would like to know if given a particular font size, if it is possible to vertically stretch the letters while maintaining the width size?

For example,

\documentclass{article}
\textwidth 5.25in
\begin{document}
\begin{center}
{\LARGE{THIS \, PART \, IS \, OK}}
\vskip 18pt
{\large{\scshape{but this part}}}
\vskip 27pt
{\LARGE{\bf IS TO BE VERTICALLY STRETCHED}}
\end{center}
\end{document}

produces the output:

enter image description here

If possible, I would like to increase the vertical length of the letters in the words: ``IS TO BE VERTICALLY STRETCHED''

2 Answers 2

5

An option it is use scalerel package. I have improved your old command: you can see \textsc and \textbf.

\documentclass{article}
\usepackage{scalerel}

\textwidth 5.25in
\begin{document}
\begin{center}
{\LARGE{THIS \, PART \, IS \, OK}}
\vskip 18pt
{\large{\textsc{but this part}}}
\vskip 27pt
\vstretch{3}{\textnormal{\textbf \LARGE{IS TO BE VERTICALLY STRETCHED}}}
\end{center}
\end{document}

With the option \vstretch{<number>}{...} you can increase vertically the text. Here there is the documentation of scalerel package that it contains many options.

enter image description here

5

graphicx provides \scalebox{<hfactor>}[<vfactor>]{<stuff>} to scale content either horizontally or vertically. A ?factor of 1 leaves <stuff> unscaled within that direction; less than 1 reduces it in that direction; greater than 1 enlarges it in that direction.

enter image description here

\documentclass{article}

\usepackage[margin=1in]{geometry}
\usepackage{graphicx}

\begin{document}

\begin{center}
  \makebox[.4\linewidth][s]{\LARGE THIS PART IS OK}
  
  \vspace{18pt}
  
  {\large\scshape but this part}
  
  \vspace{27pt}
  
  \scalebox{1}[4]{\LARGE\bfseries IS TO BE VERTICALLY STRETCHED}
\end{center}

\end{document}

If you want a width-specific stretching, you can use \resizebox{<width>}{<height>}{<stuff>}.

0

You must log in to answer this question.

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