4

I recently switched my Xmas mailing labels from MS Word to LaTeX using the following, and was wondering if anyone knew a better solution. I will admit that this is a more general solution, but I still have a nearly full box of Avery 5160 labels.

\documentclass[letterpaper]{article}% Avery 5160
\usepackage[top=0.5in, bottom=0.5in, left=0.125in, right=0.125in, noheadfoot]{geometry}
\usepackage{varwidth}

\newenvironment{cell}{\minipage[c][1in][c]{2.75in}\centering% Avery 5160 described as 1in by 2.625in \varwidth{2.625in}\raggedright}% but measures 2.75in wide {\endvarwidth\endminipage\allowbreak\ignorespaces}

\parindent=0pt \pagestyle{empty}

\begin{document} \large% set font etc. \begin{cell} Name\ Address\ City, State Zip\ extra line if needed \end{cell} \begin{cell} Name\ Address\ Very wide city name, State Zip \end{cell} \begin{cell} Name\ Address\ City, State Zip \end{cell} \begin{cell} Name\ Address\ City, State Zip \end{cell} \end{document}

John Kormylo
  • 79,712
  • 3
  • 50
  • 120

1 Answers1

3

Here's how I setup and do mine, which will need adapting to a multi-label-width page, since mine are Avery 4013, "3.5" x 15/16" One Across". It is basically a strip of 12 labels on a single column. My \setlabel tunes the vertical extent of the content to fit the label space. If you think it is too big, add a blank line. In the preamble, I highlight some of the parameters that can be tweaked if I change label format.

Format can be adjusted to multi-label-width format by specifying a wider paper, removing blank lines between \setlabel entries on the same row, and by removing the \par from the definition of \setlabel. SEE BELOW 1ST SOLUTION.

\documentclass[12pt]{article}
\usepackage[paperwidth=4.3275in,paperheight=12in,left=0.4in,right=0.4in,
  top=.63in,bottom=.12in]{geometry}% top= tuned to your printer
\usepackage{scalerel}
\usepackage[usestackEOL]{stackengine}
\parindent 0in
\parskip .24in% Related to label width
\usepackage{Palatino}% Pick a font with good stroke width
\newlength\htone
\newlength\httwo
\htone=.73in% related to label height
\httwo=.73in% related to label height

\renewcommand\stackalignment{l} \strutlongstacks{T}

\def\setlabel#1{\hfil% \rule[-\dp\strutbox]{0in}{\htone}\scaleto{\Longstack{#1}}{\httwo}% \par% } \frenchspacing \begin{document}

\setlabel{ Pastor Theophilus Jones\ St. Luke Lutheran Church}% Wife Betsy

\setlabel{ Dr. & Mrs. Greg Lastname & Family\ 908 Streetname Dr.\ Lancaster, PA 17601}% Liz + Kenny and Susie

\setlabel{ Herr Doktor Johann Schmidt\ Birkenstrasse 27\ 86240 Biburg\ GERMANY}% Mom's Uncle \end{document}

enter image description here


MULTI-WIDTH

\documentclass[12pt]{article}
\usepackage[paperwidth=10in,paperheight=12in,left=0.4in,right=0.4in,
  top=.63in,bottom=.12in]{geometry}% top= tuned to your printer
\usepackage{scalerel}
\usepackage[usestackEOL]{stackengine}
\parindent 0in
\parskip .24in% Related to label width
\usepackage{Palatino}% Pick a font with good stroke width
\newlength\htone
\newlength\httwo
\htone=.73in% related to label height
\httwo=.73in% related to label height

\renewcommand\stackalignment{l} \strutlongstacks{T}

\def\setlabel#1{\hfil% \rule[-\dp\strutbox]{0in}{\htone}\scaleto{\Longstack{#1}}{\httwo}% % \par% } \frenchspacing \begin{document}

\setlabel{ Pastor Theophilus Jones\ St. Luke Lutheran Church}% Wife Betsy \setlabel{ Dr. & Mrs. Greg Lastname & Family\ 908 Streetname Dr.\ Lancaster, PA 17601}% Liz + Kenny and Susie

\setlabel{ Herr Doktor Johann Schmidt\ Birkenstrasse 27\ 86240 Biburg\ GERMANY}% Mom's Uncle \setlabel{ Frau Doktor Johanna Schmidt\ Birkenstrasse 27\ 86240 Biburg\ GERMANY}% Mom's Uncle \end{document}

enter image description here