3

I'm currently making my CV with Latex and am still learning how to use Latex. Under my name, I want to have my local address, contact info, and permanent address in the following way:enter image description here

So I can have three columns and each one I can put separate text in. Right now what I'm trying to do is

\usepackage{multicol}

\begin{multicols}{3}
\underline{Local Address} \\
Address line 1 \\
Address line 2 \vfill
\columnbreak
\underline{Contact Information} \\
Phone number \\
email 1 \\
email 2 \vfill
\columnbreak
\underline{Permanent Address} \\
address 1 \\
address 2
\end{multicols}

but this is not centering it on the page and has everything to the right. I suspect this is because I am also using \documentclass[margin, 10pt]{res}

4 Answers4

1

Here is a way of obtaining what you want, I think:

 \documentclass{article}
\usepackage[showframe]{geometry}
 \usepackage{tabularx, makecell}
\renewcommand\theadfont{\normalsize\bfseries}
\renewcommand\theadalign{lc}
\usepackage{url}

\begin{document}

\noindent\sffamily
\begin{tabularx}{\linewidth}{@{}XXX@{}}
   \thead{Local} & \thead{Contact} & \thead{Permanent} \\
    address line 1 & phone number & address line 1 \\
    address line 2 & \url{email address} & address line 2
\end{tabularx}

\end{document} 

enter image description here

However, you should consider using one of the cv classes (e.g. moderncv).

Bernard
  • 271,350
0

Another way would to create a regular table.

Code:

\documentclass{amsart}
\begin{document}
\begin{center}
\begin{tabular}{p{1.75in}p{1.75in}p{1.75in} }
Local&Contact&Permanent\\
address line 1&phone number&address line 1\\
address line 2&email address&address line 2\\
\end{tabular}
\end{center}
\end{document}

This yields:

enter image description here

You can adjust the width of the columns quite easily.

Dan
  • 3,699
0

Two possibilities. In the first (more complex) one, the center column is exactly centered with respect to the margins. The second solution instead uses equal spaces between the blocks.

Take your pick. The border lines are just to show the margins, just remove the call of showframe for getting rid of them.

\documentclass{article}

\usepackage{showframe} % just for the example

\begin{document}

\noindent
\makebox[\textwidth][s]{%
  \makebox[0pt][l]{%
    \begin{tabular}[t]{@{}l@{}}
    \textbf{Local} \\
    address line 1 \\
    address line 2
    \end{tabular}%
  }\hfill
  \begin{tabular}[t]{@{}l@{}}
  \textbf{Contact} \\
  phone number \\
  email address
  \end{tabular}\hfill
  \makebox[0pt][r]{%
    \begin{tabular}[t]{@{}l@{}}
    \textbf{Permanent} \\
    address first line \\
    address second line
    \end{tabular}%
  }%
}

\bigskip

\noindent
\begin{tabular}[t]{@{}l@{}}
  \textbf{Local} \\
  address line 1 \\
  address line 2
\end{tabular}\hfill
\begin{tabular}[t]{@{}l@{}}
  \textbf{Contact} \\
  phone number \\
  email address
\end{tabular}\hfill
\begin{tabular}[t]{@{}l@{}}
  \textbf{Permanent} \\
  address first line \\
  address second line
\end{tabular}

\end{document}

enter image description here

egreg
  • 1,121,712
  • Is there a way to move this to the left? I have my margins to the right because I have headings to the left of the margin. Right now, for centering something I have \moveleft.5\hoffset\centerline{Address}. So, can I move an entire tabular section like .5 to the left? – TheStrangeQuark Nov 07 '16 at 01:12
  • @TheStrangeQuark Since \hoffset should be zero, I can't see a usage for that \moveright. If you're setting \hoffset, you're doing wrong. – egreg Nov 07 '16 at 07:49
0

In the res document class, the margins are pushed over to the right to make room for \sections. This margin shift is given by \sectionwidth, as suggested in Left justify parts of resume using res.cls. Once the content is moved over to the left, you can distribute them evenly across the text block:

enter image description here

\documentclass[margin,10pt]{res}

\usepackage{lipsum}

\begin{document}
\name{A Person}
\opening

\hspace*{-\sectionwidth}%
\makebox[0pt][l]{\begin{tabular}[t]{ @{} l }
  \textbf{Local} \\
  address line 1 \\
  address line 2
\end{tabular}}\hfill
\begin{tabular}[t]{ l }
  \textbf{Contact} \\
  phone number \\
  email address
\end{tabular}\hfill
\makebox[0pt][r]{\begin{tabular}[t]{ l @{} }
  \textbf{Permanent} \\
  address first line \\
  address second line
\end{tabular}}

\lipsum[1]

\end{document}

I would completely advise against using the res class.

Werner
  • 603,163