summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/source/eplain/base/test/pdftex.tex
diff options
context:
space:
mode:
Diffstat (limited to 'Master/texmf-dist/source/eplain/base/test/pdftex.tex')
-rw-r--r--Master/texmf-dist/source/eplain/base/test/pdftex.tex112
1 files changed, 112 insertions, 0 deletions
diff --git a/Master/texmf-dist/source/eplain/base/test/pdftex.tex b/Master/texmf-dist/source/eplain/base/test/pdftex.tex
new file mode 100644
index 00000000000..7aa765d2c89
--- /dev/null
+++ b/Master/texmf-dist/source/eplain/base/test/pdftex.tex
@@ -0,0 +1,112 @@
+\input ../eplain
+%\enablehyperlinks[nolinks]
+%\enablehyperlinks[pdftex]
+\enablehyperlinks
+
+\beginpackages
+\usepackage[dvipsnames]{color}
+\endpackages
+
+% Execute #1 then print it verbatim and indented.
+\def\c{\cf\indent\relax}
+% Same as \c, but do not indent and at the end say \hlend.
+\def\f{\cf\noindent\hlend}
+%
+\def\cf#1#2#3{%
+ \def\temp{#3}%
+ \edef\cftemp{\sanitize\temp}%
+ #1#3\expandafter\verbatim\cftemp\endverbatim#2\par
+}
+%
+\newcount\destcount
+% Execute `#1{d\the\destcount}' then print it (`#1', `{d', and `}' are printed
+% verbatim; `\the\destcount' is expanded).
+\def\d{\dl\relax}
+% Same as \d, but at the end also say \hlend.
+\def\l{\dl\hlend}
+%
+\def\dl#1#2{%
+ \global\advance\destcount by1
+ \toks0={#2}%
+ \edef\temp{\the\toks0{d\the\destcount}}%
+ \edef\dltemp{\sanitize\temp}%
+ \noindent#2{d\the\destcount}\expandafter\verbatim\dltemp\endverbatim#1\par
+}
+
+\pdfpagewidth=8.5in
+\pdfpageheight=11in
+
+
+
+\leftline{\bf Destinations}
+\medskip
+
+{\tt\global\parindent=4em}
+
+\d{\hldest{}{}}
+\c{\hldestopts{zoom=2345}}
+\d{\hldest{}{}}
+\medskip
+\c{\hldesttype{fitr}}
+\c{\hldestopts{width=\hsize}}
+\d{\hldest{}{}}
+\c{\def\myopts{width=.5\hsize,depth=.25\hsize}}
+\d{\hldest{}{\myopts,height=.25\hsize}}
+\medskip
+\c{\let\myopts\empty}
+\c{\hldestopts{raise=2\normalbaselineskip}}
+\d{\hldest{xyz}{\myopts,zoom=2500}}
+\d{\hldest{xyz}{raise=\ht\strutbox,zoom=3000}}
+\medskip
+\makeatletter
+\c{\def\mydest{\pdfdest name{\@hllabel} xyz}}
+\d{\hldest{raw}{cmd=mydest}}
+\resetatcatcode
+\medskip
+\d{\hldest{fit}{}}
+\d{\hldest{fith}{}}
+\d{\hldest{fitv}{}}
+\d{\hldest{fitb}{}}
+\d{\hldest{fitbh}{}}
+\d{\hldest{fitbv}{}}
+\vfil\eject
+
+
+
+\leftline{\bf Links}
+\medskip
+
+{\tt\global\parindent=4.5em}
+
+\destcount=0 % Reset destination count.
+\l{\hlstart{name}{}}
+\c{\hlopts{bstyle=U}}
+\l{\hlstart{name}{}}
+\l{\hlstart{}{bstyle=D,bdash=2 4,bcolor=1 0 0,hlight=I}}
+\l{\hlstart{}{bstyle=B,bwidth=3}}
+\c{\hlopts{bcolor=0 0 1}}
+\l{\hlstart{}{bstyle=I,bwidth=4}}
+\l{\hlstart{}{bstyle=U,bwidth=1}}
+\c{\hlopts{bstyle=S}}
+\l{\hlstart{}{hlight=I,bcolor=1 .2 .2,bwidth=2}}
+\l{\hlstart{}{hlight=N,bstyle=D,bwidth=3}}
+\l{\hlstart{}{hlight=O}}
+\l{\hlstart{}{hlight=P,bcolor=.3 .6 .7}}
+\l{\hlstart{}{bstyle=D,bdash=2 4 6}}
+\l{\hlstart{}{bwidth=0}}
+\l{\hlstart{}{bstyle=D,bdash=2 4 6 8}}
+\f{\hlstart{page}{pagefit=/FitH 600}{1}}
+\f{\hlstart{filename}{file=hlink.pdf,newwin=1}{eq1}}
+\f{\hlstart{filepage}{file=hlink.pdf,pagefit=/FitR 50 100 300 500}{1}}
+\f{\hlstart{filepage}{file=hlink.pdf,pagefit=/FitB}{2}}
+\f{\hlstart{url}{}{http://tug.org/eplain/}}
+\c{\def\mycmd{\pdfstartlink goto page 1 {/Fit}}}
+\f{\hlstart{raw}{cmd=mycmd}{}}
+
+
+
+\bye
+
+% Local variables:
+% compile-command: "(cd .. && make eplain.tex) && pdftex --interact=nonstopmode pdftex.tex"
+% End: