0

I would like to vertically and horizontally mirror every letter that I write from point A to point B in my document. In other words, something like a command \start and \end and everything in between, even inside tables, figures, etc. all letters get mirrored. Is there a way to do this? My guess would be to change this somehow in the font settings, but I don't know how -- anybody can link me at least to the right page where I can find this? :D

Btw. I know of the solution with graphicx package where I can mirror/reflect things (e.g.: \raisebox{\depth}{\rotatebox{180}{Hello World}), but that's not ideal, since I want every letter separately mirrored from paragraph A to wherever and not the whole thing "Hello World".

  • 1
    You could take a look this https://tex.stackexchange.com/questions/34713/mirror-effect-in-documents – Tom Jun 08 '22 at 06:17

1 Answers1

1

Not sure if this is what you are looking for. Notice that this is a "naive" solution. The \rotateeach command only works with plain text.

\documentclass{article}
\usepackage{graphicx}

\begin{document}

\ExplSyntaxOn \newcommand{\rotateeach}[1]{ \str_map_inline:nn {#1} { \raisebox{0.5\baselineskip}{\rotatebox{180}{##1}} } } \ExplSyntaxOff

this is normal text, and \rotateeach{this is not!}

\end{document}

Alan Xiang
  • 5,227
  • Firstly thanks. Yes this is something I already know. As you said yourself the problem is that such a solution only works for plain text and I would rather like something that I can use, like a command, so that all text that comes afterwards, be it inside an environment, a table, etc., is rotated until another command (or maybe let it be an environment) ends this behavior. :D – Yumina 弓那 Nirvalen Jun 28 '22 at 19:52