summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/tex/generic/pictex/pointers.tex
diff options
context:
space:
mode:
Diffstat (limited to 'Master/texmf-dist/tex/generic/pictex/pointers.tex')
-rw-r--r--Master/texmf-dist/tex/generic/pictex/pointers.tex53
1 files changed, 53 insertions, 0 deletions
diff --git a/Master/texmf-dist/tex/generic/pictex/pointers.tex b/Master/texmf-dist/tex/generic/pictex/pointers.tex
new file mode 100644
index 00000000000..5c2204478a7
--- /dev/null
+++ b/Master/texmf-dist/tex/generic/pictex/pointers.tex
@@ -0,0 +1,53 @@
+%
+% Pointing at things
+%
+% Each macro points in a different direction. The arrow is at the
+% logical corner, e.g. if I \pointUpRight, the arrow is in the upper
+% right corner.
+%
+% \pointRight{..text..}
+% \pointLeft{..text..}
+% \pointDown{..text..}
+% \pointUp{..text..}
+%
+% \pointUpRight{..text..}
+% \pointUpLeft{..text..}
+% \pointDownRight{..text..}
+% \pointDownLeft{..text..}
+%
+% No global boxes are used. Each macro is grouped and uses box0.
+%
+% Dirk Grunwald Apr 20 1988
+%
+\def\pointRight#1{{#1$\rightarrow$}}
+\def\pointLeft#1{{$\leftarrow$#1}}
+%
+\def\pointUpRight#1{%
+\begingroup\offinterlineskip%
+\setbox0=\hbox{#1}%
+\vbox{\hbox{\hskip\wd0$\nearrow$}\copy0}\endgroup}
+%
+\def\pointUpLeft#1{%
+\begingroup\offinterlineskip%
+\setbox0=\hbox{$\nwarrow$}%
+\vbox{\copy0\hbox{\hskip\wd0{}#1}}\endgroup}
+%
+\def\pointDownRight#1{%
+\begingroup\offinterlineskip%
+\setbox0=\hbox{#1}%
+\vbox{\copy0\hbox{\hskip\wd0$\searrow$}}\endgroup}
+%
+\def\pointDownLeft#1{%
+\begingroup\offinterlineskip%
+\setbox0=\hbox{$\swarrow$}%
+\vbox{\hbox{\hskip\wd0{}#1}\copy0}\endgroup}
+%
+\def\pointDown#1{%
+\begingroup\offinterlineskip%
+\setbox0=\hbox{#1}%
+\vbox{\copy0\hbox to \wd0{\hfill$\downarrow$\hfill}}\endgroup}
+%
+\def\pointUp#1{%
+\begingroup\offinterlineskip%
+\setbox0=\hbox{#1}%
+\vbox{\hbox to \wd0{\hfill$\uparrow$\hfill}\copy0}\endgroup}