| 1 |
% |
| 2 |
% Pointing at things |
| 3 |
% |
| 4 |
% Each macro points in a different direction. The arrow is at the |
| 5 |
% logical corner, e.g. if I \pointUpRight, the arrow is in the upper |
| 6 |
% right corner. |
| 7 |
% |
| 8 |
% \pointRight{..text..} |
| 9 |
% \pointLeft{..text..} |
| 10 |
% \pointDown{..text..} |
| 11 |
% \pointUp{..text..} |
| 12 |
% |
| 13 |
% \pointUpRight{..text..} |
| 14 |
% \pointUpLeft{..text..} |
| 15 |
% \pointDownRight{..text..} |
| 16 |
% \pointDownLeft{..text..} |
| 17 |
% |
| 18 |
% No global boxes are used. Each macro is grouped and uses box0. |
| 19 |
% |
| 20 |
% Dirk Grunwald Apr 20 1988 |
| 21 |
% |
| 22 |
\def\pointRight#1{{#1$\rightarrow$}} |
| 23 |
\def\pointLeft#1{{$\leftarrow$#1}} |
| 24 |
% |
| 25 |
\def\pointUpRight#1{% |
| 26 |
\begingroup\offinterlineskip% |
| 27 |
\setbox0=\hbox{#1}% |
| 28 |
\vbox{\hbox{\hskip\wd0$\nearrow$}\copy0}\endgroup} |
| 29 |
% |
| 30 |
\def\pointUpLeft#1{% |
| 31 |
\begingroup\offinterlineskip% |
| 32 |
\setbox0=\hbox{$\nwarrow$}% |
| 33 |
\vbox{\copy0\hbox{\hskip\wd0{}#1}}\endgroup} |
| 34 |
% |
| 35 |
\def\pointDownRight#1{% |
| 36 |
\begingroup\offinterlineskip% |
| 37 |
\setbox0=\hbox{#1}% |
| 38 |
\vbox{\copy0\hbox{\hskip\wd0$\searrow$}}\endgroup} |
| 39 |
% |
| 40 |
\def\pointDownLeft#1{% |
| 41 |
\begingroup\offinterlineskip% |
| 42 |
\setbox0=\hbox{$\swarrow$}% |
| 43 |
\vbox{\hbox{\hskip\wd0{}#1}\copy0}\endgroup} |
| 44 |
% |
| 45 |
\def\pointDown#1{% |
| 46 |
\begingroup\offinterlineskip% |
| 47 |
\setbox0=\hbox{#1}% |
| 48 |
\vbox{\copy0\hbox to \wd0{\hfill$\downarrow$\hfill}}\endgroup} |
| 49 |
% |
| 50 |
\def\pointUp#1{% |
| 51 |
\begingroup\offinterlineskip% |
| 52 |
\setbox0=\hbox{#1}% |
| 53 |
\vbox{\hbox to \wd0{\hfill$\uparrow$\hfill}\copy0}\endgroup} |