[Tex/LaTex] How to force-move text

text manipulation

My question is simple: how can I force-move text to the left or right (or even outside of the margins)?

Some examples would be perfect.

Best Answer

Does this code illustrate what you mean? I force a text to go in the margins (math and text). The \fbox are here only to show what's happening.

\documentclass[a4paper, 12pt]{article}

\usepackage[utf8]{inputenc}
\usepackage[T1]{fontenc}
\usepackage{lmodern}
\usepackage[showframe, lmargin = 3cm, rmargin = 4cm, nomarginpar, , noheadfoot]{geometry}
\usepackage{mathtools}
\parindent = 0pt

\begin{document}
Example : \medskip\\
\llap{\fbox{A text} }inserted in the left margin, \dotfill And now another text inserted\rlap{ \fbox{in the right margin.} }\\\\
 $ \mathllap{a = b\ }$This formula went strolling in the left margin \hfill and this one the right one$ \mathrlap{\ u = v. } $\\\\
You also can superimpose two pieces ot text: \quad \clap{A}\clap{V}
\end{document}

Result:

enter image description here

Related Question