summaryrefslogtreecommitdiff
path: root/texmf-dist/doc/latex/icon-appr/examples/pdfmark-drivers/icon-appr-eps.tex
diff options
context:
space:
mode:
authorNorbert Preining <norbert@preining.info>2020-06-18 22:01:30 +0900
committerNorbert Preining <norbert@preining.info>2020-06-18 22:01:30 +0900
commit6af429205482aaf19c0ae60c168ca32514cdce4d (patch)
tree62dd2385decd19a817a81ed546e8593f73bbfe1e /texmf-dist/doc/latex/icon-appr/examples/pdfmark-drivers/icon-appr-eps.tex
parentb0fe932570cf1005c4f0917bba091b6f5ae71a0b (diff)
icon-abbr
Diffstat (limited to 'texmf-dist/doc/latex/icon-appr/examples/pdfmark-drivers/icon-appr-eps.tex')
-rw-r--r--texmf-dist/doc/latex/icon-appr/examples/pdfmark-drivers/icon-appr-eps.tex29
1 files changed, 26 insertions, 3 deletions
diff --git a/texmf-dist/doc/latex/icon-appr/examples/pdfmark-drivers/icon-appr-eps.tex b/texmf-dist/doc/latex/icon-appr/examples/pdfmark-drivers/icon-appr-eps.tex
index 3f864ba5..52494864 100644
--- a/texmf-dist/doc/latex/icon-appr/examples/pdfmark-drivers/icon-appr-eps.tex
+++ b/texmf-dist/doc/latex/icon-appr/examples/pdfmark-drivers/icon-appr-eps.tex
@@ -1,9 +1,10 @@
\documentclass{article}
-
\usepackage[designv,tight]{web}
\usepackage{eforms}
\usepackage{graphicxsp}[2018/11/20]
-\usepackage{icon-appr}\previewOff
+\usepackage{icon-appr}
+
+%\previewOn\pmpvOn
\title{Creating icon appearances for button fields\texorpdfstring{\\[1ex]}{ }using EPS methods}
\author{D. P. Story}
@@ -28,7 +29,7 @@
\section{Introduction}
-For the \textsf{\textbf{pdfmark}}-type drivers (\textsf{dvips} and
+Forxx the \textsf{\textbf{pdfmark}}-type drivers (\textsf{dvips} and
\textsf{dvipsone}), there are two ways to create an icon appearance: (1)
JavaScript methods and (2) EPS methods. The JavaScript methods are
demonstrated in \texttt{icons-appr-pb.tex}. A shortcoming of the JavaScript
@@ -81,4 +82,26 @@ however, the buttons have the correct appearances, but are not functional.
\pushButton[\CA{Reset}\A{\JS{this.resetForm();}}]{reset}{}{11bp}
+\section{Icons in this document}
+
+Use the button below to cycle through all icons in this document.
+
+% Note, compare this code and fields with that of icon-appr-exmpl.tex
+% in the latter file, we include a caption, where here, we do not
+% include a caption.
+\begin{defineJS}{\cycleJS}
+if (typeof indexIcon == "undefined") var indexIcon=0;
+var oIconName=this.icons[indexIcon].name;
+var f=this.getField("iconContainer");
+var oIcon=this.getIcon(oIconName);
+f.buttonSetIcon(oIcon);
+indexIcon = (indexIcon+1) \% (this.icons.length);
+\end{defineJS}
+
+\begin{center}
+\pushButton[\BG{}\autoCenter{n}
+ \TP{1}\I{}\S{S}]{iconContainer}{100bp}{100bp}\vcgBdry[6bp]
+\pushButton[\CA{Cycle}\AAmouseup{\cycleJS}]{cycleBtn}{}{11bp}
+\end{center}
+
\end{document}