[texhax] simple rotate/invert character
Matthew Leingang
leingang at math.harvard.edu
Tue Apr 1 14:33:06 CEST 2008
I sent this to Bryan yesterday, but I thought I'd resend to the list
because it also answers the alignment question. With the rotating
package you can rotate characters but keep the baseline where you
want it.
--Matt
On Mar 31, 2008, at 11:39 AM, Bryan W. Lepore wrote:
> is there a short command to rotate/invert a letter? so that without
> having to start a new environment, one could do something like :
>
> \invert{B}
>
> or
>
> \rotate{B}
>
> so the "B" gets inverted or rotated?
>
> -bryan
Dear Byran,
Good question. It's a little bit tricky because TeX is used to
putting characters on a page, and once you start rotating characters
they're not regular characters anymore. You need a graphical
solution, which then becomes dependent on the post-TeX processing
methods (e.g., dvips or pdftex).
If you use regular LaTeX and dvips, try the rotate package. In
pdfLaTeX, this works:
\documentclass{article}
\usepackage{rotating}% provides a rotate environment
\newcommand{\rotxc}[1]{\begin{sideways}#1\end{sideways}}
\newcommand{\invert}[1]{\rotxc{\rotxc{#1}}}
\begin{document}
\begin{itemize}
\item regular B
\item rotate \rotxc B
\item invert \invert B
\end{itemize}
\end{document}
Hope that helps!
--Matthew Leingang
--
Matthew Leingang
Preceptor in Mathematics
Harvard University
http://www.math.harvard.edu/~leingang/vCard.vcf
More information about the texhax
mailing list