summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/doc
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2018-06-30 21:05:48 +0000
committerKarl Berry <karl@freefriends.org>2018-06-30 21:05:48 +0000
commit04e12813c532714126644d39d0c355baca9e1ccd (patch)
tree14173a37425c74e6e8f4bdf0a3001e2a0acc9e1d /Master/texmf-dist/doc
parentffcff21880425e124f4f923c1ba306000c81b392 (diff)
xbmks (30jun18)
git-svn-id: svn://tug.org/texlive/trunk@48116 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/doc')
-rw-r--r--Master/texmf-dist/doc/latex/xbmks/README.md6
-rw-r--r--Master/texmf-dist/doc/latex/xbmks/docs/xbmks.pdfbin90233 -> 107353 bytes
-rw-r--r--Master/texmf-dist/doc/latex/xbmks/docs/xbmksman.pdfbin200688 -> 213144 bytes
-rw-r--r--Master/texmf-dist/doc/latex/xbmks/docs/xbmksman.tex181
-rw-r--r--Master/texmf-dist/doc/latex/xbmks/examples/doc1.pdfbin13348 -> 32892 bytes
-rw-r--r--Master/texmf-dist/doc/latex/xbmks/examples/doc1.tex10
-rw-r--r--Master/texmf-dist/doc/latex/xbmks/examples/doc2.pdfbin11984 -> 31324 bytes
-rw-r--r--Master/texmf-dist/doc/latex/xbmks/examples/doc2.tex9
-rw-r--r--Master/texmf-dist/doc/latex/xbmks/examples/master.pdfbin15811 -> 47430 bytes
-rw-r--r--Master/texmf-dist/doc/latex/xbmks/examples/master.tex56
-rw-r--r--Master/texmf-dist/doc/latex/xbmks/examples/stand-alone.tex12
11 files changed, 226 insertions, 48 deletions
diff --git a/Master/texmf-dist/doc/latex/xbmks/README.md b/Master/texmf-dist/doc/latex/xbmks/README.md
index fc53fd66899..c74431f82ef 100644
--- a/Master/texmf-dist/doc/latex/xbmks/README.md
+++ b/Master/texmf-dist/doc/latex/xbmks/README.md
@@ -1,6 +1,6 @@
The xbmks Package
Author: D. P. Story
-Dated: 2018/06/13
+Dated: 2018/06/25
Short description: Create a cross-document bookmark tree.
@@ -15,6 +15,10 @@ the bundle.
PDF Creator: no restrictions, use dvips->distiller|ps2pdf, pdflatex,
lualatex, or xelatex.
+
+What's New (2018/06/25) Defined new commands for creating bookmarks for which
+arbitrary actions, color and style can be applied. These commands build on
+hyperref's bookmark commands.
What's New (2018/06/13) Corrected a misspelling in the driver specification
for pdfmark. Now allow the docbundle key to be empty or missing; in this
diff --git a/Master/texmf-dist/doc/latex/xbmks/docs/xbmks.pdf b/Master/texmf-dist/doc/latex/xbmks/docs/xbmks.pdf
index 4cbeca1dd3d..85e05e14400 100644
--- a/Master/texmf-dist/doc/latex/xbmks/docs/xbmks.pdf
+++ b/Master/texmf-dist/doc/latex/xbmks/docs/xbmks.pdf
Binary files differ
diff --git a/Master/texmf-dist/doc/latex/xbmks/docs/xbmksman.pdf b/Master/texmf-dist/doc/latex/xbmks/docs/xbmksman.pdf
index c6fd8d39a0c..cfbd36a2e44 100644
--- a/Master/texmf-dist/doc/latex/xbmks/docs/xbmksman.pdf
+++ b/Master/texmf-dist/doc/latex/xbmks/docs/xbmksman.pdf
Binary files differ
diff --git a/Master/texmf-dist/doc/latex/xbmks/docs/xbmksman.tex b/Master/texmf-dist/doc/latex/xbmks/docs/xbmksman.tex
index 149e707b375..aadc17e76a5 100644
--- a/Master/texmf-dist/doc/latex/xbmks/docs/xbmksman.tex
+++ b/Master/texmf-dist/doc/latex/xbmks/docs/xbmksman.tex
@@ -17,7 +17,9 @@
%\usepackage{calibri}
\usepackage[altbullet]{lucidbry}
-\xbmksetup{colors={intdoc=red},style={intbf}}
+\DeclareInitView{layoutmag={navitab:UseOutlines}}
+
+\xbmksetup{colors={int=red},styles={intbf}}
\addtolength{\marginparwidth}{20pt}
@@ -39,7 +41,7 @@
\def\echgCurrLblName#1{\edef\@currentlabelname{#1}}
\makeatother
-\getDimsFromGraphic{graphics/dpsweb}{\dpswebW}{\dpswebH}
+%\getDimsFromGraphic{graphics/dpsweb}{\dpswebW}{\dpswebH}
%\urlstyle{rm}
@@ -47,7 +49,8 @@
\let\uif\textsf
\let\app\textsf
\def\psf#1{\textbf{\textsf{#1}}}
-\let\amtIndent\leftmargini
+%\let\amtIndent\leftmargini
+\edef\amtIndent{\the\parindent}
\renewcommand*\descriptionlabel[1]{\hspace\labelsep
\normalfont #1}
@@ -56,13 +59,13 @@
\DeclareDocInfo
{
university={Acro\negthinspace\TeX.Net},
- title={The \textsf{xbmks} package\texorpdfstring{\\}{:}Cross-document bookmarks},
+ title={The \textsf{xbmks} package\texorpdfstring{\\}{: }Cross-document bookmarks},
author={D. P. Story},
email={dpstory@acrotex.net},
- subject={Documentation for the richtext package from AcroTeX},
+ subject={Documentation for the xbmks package from AcroTeX: cross-document bookmarks},
talksite={\url{www.acrotex.net}},
- version={v1.1, 2018/06/13},
- keywords={AcroTeX, rich text strings},
+ version={2.0.1, 2018/06/25},
+ Keywords={AcroTeX, bookmarks, cross-document, document bundle},
copyrightStatus=True,
copyrightNotice={Copyright (C) \the\year, D. P. Story},
copyrightInfoURL={http://www.acrotex.net}
@@ -132,6 +135,15 @@ _path=_path.substring(0,pos)+"/"+manualfilename;
\maketitle
+\pdfbookmarkx[1]{Title Page}[action={\Named{FirstPage}}]{TitlePage}
+\pdfbookmarkx[1]{Links to AcroTeX.Net}[action={/S/GoTo/D(undefined)},%
+ color=magenta,style={bf}]{acrotex}
+\belowpdfbookmarkx{http://www.acrotex.net}[action={\URI{http://www.acrotex.net}},%
+ color=magenta,style={bf}]{home}
+\belowpdfbookmarkx{http://blog.acrotex.net}[action={\URI{http://blog.acrotex.net}},%
+ color=magenta,style={bf}]{blog}
+
+
\selectColors{linkColor=black}
\tableofcontents
\selectColors{linkColor=webgreen}
@@ -143,7 +155,6 @@ _path=_path.substring(0,pos)+"/"+manualfilename;
\hypersetup{linktocpage}
-
\section{Introduction}
It has been more than a couple decades ago (counting back from 2018), I wrote
@@ -175,15 +186,15 @@ need to be used. The package auto-detects \app{pdftex} and \app{xetex}, and
\opt{dvips} is the default, so there is actually no need to pass the driver
option.
-\section{The preamble command \texorpdfstring{\protect\cs{xbmksetup}}{\textbackslash{xbmksetup}}}
+\section{The preamble command \texorpdfstring{\protect\cs{xbmksetup}}{\textbackslash{xbmksetup}}}\label{s:xbmksetup}
The only user command is \cs{xbmksetup}:
-\bVerb\def\1{\qquad}\takeMeasure{\1colors=\darg{intdoc=\ameta{color},extdoc=\ameta{color}},}%
+\bVerb\def\1{\qquad}\takeMeasure{\1docbundle=\darg{\ameta{doc\SUB1},\ameta{doc\SUB2},...,\ameta{doc\SUB{n}}},}%
\begin{dCmd}[commandchars=!()]{\bxSize}
\xbmksetup{%
!1docbundle={!ameta(doc!SUB1),!ameta(doc!SUB2),...,!ameta(doc!SUB(n))},
-!1colors={intdoc=!ameta(color),extdoc=!ameta(color)},
-!1style={intbf,extbf,intit,extit}
+!1colors={int=!ameta(color),ext=!ameta(color)},
+!1styles={intbf,extbf,intit,extit}
}
\end{dCmd}
\eVerb You have a collection of files (as specified by the \texttt{docbundle}
@@ -222,38 +233,38 @@ to check the spelling of each file listed.
\textbf{Empty or missing \texttt{docbundle} key.} If this key is missing,
then it is assigned a value of \cs{jobname}. As a result, normal bookmarks
are generated for the document \cs{jobname}; however, as an extra benefit,
-the other keys are obeyed (\texttt{colors} and \texttt{style}). See the
+the other keys are obeyed (\texttt{colors} and \texttt{styles}). See the
sample file \texttt{stand-alone.tex} found in the \texttt{examples} file.
This manual uses the \pkg{xbmks} package with,
\begin{Verbatim}[xleftmargin=\amtIndent]
-\xbmksetup{colors={intdoc=red},style={intbf}}
+\xbmksetup{colors={int=red},styles={intbf}}
\end{Verbatim}
\item[\texttt{colors}] (Optional) For any given document in the bundle,
there are two types of links in the bookmarks, a link to an item in
the current (or internal) document, or a link to an external document
(within the bundle of documents).
\begin{itemize}
- \item \texttt{intdoc=\ameta{color}}, where \ameta{color} is an rgb
+ \item \texttt{int=\ameta{color}}, where \ameta{color} is an rgb
color. This specifies the color of the link for an internal
jump within the current document. Specify the color
using the syntax \texttt{\darg{[rgb]{\ameta{r},\ameta{g},\ameta{b}}}};
for example,
\begin{Verbatim}[xleftmargin=\amtIndent]
-colors={intdoc={[rgb]{0,.6,0}}
+colors={int={[rgb]{0,.6,0}}
\end{Verbatim}
or, if the \pkg{xcolor} package is loaded, \emph{named colors} may be used.
- \item\texttt{extdoc=\ameta{color}}, where \ameta{color} is an rgb
+ \item\texttt{ext=\ameta{color}}, where \ameta{color} is an rgb
color. This specifies the color of the link for an external jump
to another member of the document bundle. Color specification is the
- same as for \texttt{intdoc}:
+ same as for \texttt{int}:
\begin{Verbatim}[xleftmargin=\amtIndent]
-colors={intdoc=red,extdoc=blue}
+colors={int=red,ext=blue}
\end{Verbatim}
In the above example, we assume \pkg{xcolor} is loaded and specify the
colors accordingly.
-\textbf{The default color.} If you declare \texttt{intdoc} (or
-\texttt{extdoc}) without a value, you get the default, which is the color
+\textbf{The default color.} If you declare \texttt{int} (or
+\texttt{ext}) without a value, you get the default, which is the color
key is not specified within the PDF document. The \texttt{color} key is
optional, in which case, you get the default color. What is the default
color? Well, its either white or black, depending on the \textsf{Display
@@ -263,34 +274,33 @@ automatically switch colors when the theme is changed).
When you specify a color, be aware that what looks good in the \emph{light
theme} may not be so visible in a \emph{dark theme}.
\end{itemize}
- \item[\texttt{style}] (Optional) The Adobe PDF viewer applications also
+ \item[\texttt{styles}] (Optional) The Adobe PDF viewer applications also
support a bold and italics style. These can be specified for the
internal and external documents.
\begin{itemize}
- \item Internal style (valueless) keys are \texttt{intbf} and \texttt{intit}; zero, one, or
+ \item Internal styles (valueless) keys are \texttt{intbf} and \texttt{intit}; zero, one, or
two of these may be specified,
\begin{Verbatim}[xleftmargin=\amtIndent,commandchars=!()]
-style={intbf} % !normalfont(bold font)
-style={intit} % !normalfont(italics font)
-style={intbf,intit} % !normalfont(bold and italics font)
+styles={intbf} % !normalfont(bold font)
+styles={intit} % !normalfont(italics font)
+styles={intbf,intit} % !normalfont(bold and italics font)
\end{Verbatim}
- \item External style (valueless) keys are \texttt{extbf} and \texttt{extit}; zero, one, or
+ \item External styles (valueless) keys are \texttt{extbf} and \texttt{extit}; zero, one, or
two of these may be specified,
\begin{Verbatim}[xleftmargin=\amtIndent,commandchars=!()]
-style={extbf} % !normalfont(bold font)
-style={extit} % !normalfont(italics font)
-style={extbf,extit} % !normalfont(bold and italics font)
+styles={extbf} % !normalfont(bold font)
+styles={extit} % !normalfont(italics font)
+styles={extbf,extit} % !normalfont(bold and italics font)
\end{Verbatim}
\end{itemize}
-Of course, all these keys are specified or not, in the \texttt{style} key:
+Of course, all these keys are specified or not, in the \texttt{styles} key:
\begin{Verbatim}[xleftmargin=\amtIndent]
-style={intbf,extit}
+styles={intbf,extit}
\end{Verbatim}
Here, we specify bold font for the current document and an italics for an
internal document.
\end{description}
-
\newtopic\noindent\textbf{Point of personal preference.} After experimenting with
various combinations of colors and styles with combinations of themes
(light and dark) I prefer no color specified with bold font for the current
@@ -300,11 +310,114 @@ external. The bold font tells the same story independent of theme. Thus,\def\1{\
\begin{Verbatim}[xleftmargin=\amtIndent,commandchars=!()]
\xbmksetup{%
!1docbundle={!ameta(doc!SUB1),!ameta(doc!SUB2),...,!ameta(doc!SUB(n))},
-!1style={intbf}
+!1styles={intbf}
}
\end{Verbatim}
seems to be a reasonable choice of key-values.
+\section{Creating bookmarks with other actions}
+
+The \pkg{hyperref} package provides commands (\cs{pdfbookmark},
+\cs{currentpdfbookmark}, \cs{subpdfbookmark}, and \cs{belowpdfbookmark})
+designed to create bookmarks that jump to a specified destination in the
+current document. The \pkg{xbmks} package now defines similar commands in
+which arbitrary actions may be defined.
+\bVerb\def\1{\qquad}\takeMeasure{\string\pdfbookmarkx[\ameta{level}]\darg{\ameta{text}}[\ameta{KV-pairs}]\darg{\ameta{name}}}%
+\begin{dCmd}[commandchars=!()]{\bxSize}
+\pdfbookmarkx[!ameta(level)]{!ameta(text)}[!ameta(KV-pairs)]{!ameta(name)}
+\currentpdfbookmarkx{!ameta(text)}[!ameta(KV-pairs)]{!ameta(name)}
+\subpdfbookmarkx{!ameta(text)}[!ameta(KV-pairs)]{!ameta(name)}
+\belowpdfbookmarkx{!ameta(text)}[!ameta(KV-pairs)]{!ameta(name)}
+\end{dCmd}
+\bVerb If the optional \ameta{KV-pairs} argument is not present, the command
+behaves just like its \pkg{hyperref} counterpart; \ameta{name} is used to
+create a destination (or anchor) for the ordinary bookmark link. If
+\ameta{KV-pairs} is specified, no anchor is created, but \ameta{name} is used
+to associate the \ameta{action} with the bookmark.
+
+\paragraph*{Description of the commands}\leavevmode
+\begin{aebDescript}
+ \item[\cs{pdfbookmarkx}] Creates a bookmark at level \ameta{level} in the
+ outline tree hierarchy.
+ \item[\cs{currentpdfbookmarkx}] The command creates a bookmark at the current
+ bookmark level in the outline tree.
+ \item[\cs{subpdfbookmarkx}] Reduces the current bookmark level by one,
+ then creates the bookmark at that level. The reduced level is the
+ new current bookmark level.
+ \item[\cs{belowpdfbookmarkx}] Creates a bookmark at one level below the
+ current bookmark level without changing the value of the current
+ bookmark level.
+\end{aebDescript}
+
+\paragraph*{Description of the \ameta{KV-pairs} argument.} The \ameta{KV-pairs} argument
+accepts up to three key-value pairs:
+\begin{Verbatim}[xleftmargin=\amtIndent,commandchars=!()]
+action=!ameta(PDF-action),color=!ameta(color),style=!ameta(!upshape(bf|it))
+\end{Verbatim}
+Notice that \texttt{color} and \texttt{style} are in the singular, as opposed to the plural
+as they were in description of the key-value pairs for \cs{xbmksetup}, back on page~\pageref{s:xbmksetup}.
+\begin{aebDescript}
+ \item[\texttt{action=\ameta{PDF-action}}] \ameta{PDF-action}
+is raw PDF action code. I decided to just keep it simple. Consult Section 8.5 titled `Actions',
+in particular, read Section~8.5.3 on `Action Types' of the \textsl{PDF Reference Sixth Edition, Version 1.7}.\footnote
+{\url{https://www.adobe.com/devnet/pdf/pdf_reference_archive.html}} A general
+syntax for the \ameta{action} is,
+\begin{Verbatim}[xleftmargin=\amtIndent,commandchars=!()]
+/S!ameta(action-type)!ameta(other-key-values)
+\end{Verbatim}
+Common action-types are \texttt{/URI}, \texttt{/JavaScript}, \texttt{/Named}, and \texttt{/GoToR}.
+Below are some examples, the ones that appear in the demo files.
+\begin{Verbatim}[xleftmargin=\amtIndent,fontsize=\small]
+\belowpdfbookmarkx{http://www.acrotex.net}
+ [action={/S/URI/URI(http://www.acrotex.net)}]{home}
+\currentpdfbookmarkx{Current: Hello world!}
+ [action={/S/JavaScript/JS(app.alert("Hello World!");)}]{bmk1}
+\subpdfbookmarkx{Sub: First Page}[/S/Named/N/FirstPage]{bmk2}
+\belowpdfbookmarkx{Go to doc1, page 1}
+ [action={/S/GoToR/F(doc1.pdf)/D[1 /Fit]}]{gotor}
+\end{Verbatim}
+
+\textbf{When \pkg{eforms} is loaded.} The \pkg{eforms} package defines
+some helper commands for common action types, these are \cs{URI}, \cs{JS},
+\cs{Named}, and \cs{GoToR}. The above examples are then written as,
+\begin{Verbatim}[xleftmargin=\amtIndent,fontsize=\small]
+\belowpdfbookmarkx{http://www.acrotex.net}
+ [action={\URI{http://www.acrotex.net}}]{home}
+\currentpdfbookmarkx{Current: Hello world!}
+ [action={\JS{app.alert("Hello World!");}}]{bmk1}
+\subpdfbookmarkx{Sub: First Page}
+ [action={\Named{FirstPage}{]{bmk2}
+\belowpdfbookmarkx{Go to doc1, page 1}
+ [action={\GoToR/F(doc1.pdf)/D[1 /Fit]}]{gotor}
+\end{Verbatim}
+
+\item[\texttt{color=\ameta{color}}] The value of this key determines the
+ color of the link. The value of \ameta{color} was described in the
+ \texttt{colors} key. If this key is not specified, the value \texttt{int}
+ or \texttt{ext} of the \texttt{colors} key is used, as appropriate. When
+ the value of the \texttt{color} key is specified, the link receives the
+ \ameta{color} across all documents in the bundle.
+
+\item[\texttt{style=\ameta{\upshape{bf|it}}}] The value of this key
+ determines the style (\texttt{bf} -- bold, \texttt{it} -- italics); the
+ keys may be used together \texttt{style=\darg{bf,it}} gives bold italics
+ font. When \texttt{style} is not specified, the value of the \texttt{styles}
+ key is used. When \texttt{style} is specified, the same style is assigned
+ across all documents in the bundle.
+\begin{Verbatim}[xleftmargin=\amtIndent,fontsize=\small]
+\belowpdfbookmarkx{http://www.acrotex.net}
+ [action={\URI{http://www.acrotex.net}},
+ color=magenta,style=bf]{home}
+\end{Verbatim}
+This bookmark is colored magenta in bold across all documents in the bundle.
+\begin{Verbatim}[xleftmargin=\amtIndent,fontsize=\small]
+\belowpdfbookmarkx{http://www.acrotex.net}
+ [action={\URI{http://www.acrotex.net}}]{home}
+\end{Verbatim}
+This bookmark takes on the colors and styles declared by the \texttt{colors}
+and \texttt{styles} keys.
+\end{aebDescript}
+
\section{Workflow}
Given that you have a collection of files that are to contain a common set of
diff --git a/Master/texmf-dist/doc/latex/xbmks/examples/doc1.pdf b/Master/texmf-dist/doc/latex/xbmks/examples/doc1.pdf
index df5d6497a3a..77ef2e1ccc2 100644
--- a/Master/texmf-dist/doc/latex/xbmks/examples/doc1.pdf
+++ b/Master/texmf-dist/doc/latex/xbmks/examples/doc1.pdf
Binary files differ
diff --git a/Master/texmf-dist/doc/latex/xbmks/examples/doc1.tex b/Master/texmf-dist/doc/latex/xbmks/examples/doc1.tex
index e45c5d894b5..1c5da0183c2 100644
--- a/Master/texmf-dist/doc/latex/xbmks/examples/doc1.tex
+++ b/Master/texmf-dist/doc/latex/xbmks/examples/doc1.tex
@@ -1,7 +1,7 @@
\documentclass[12pt]{article}
\usepackage{xcolor}
%\usepackage{xr-hyper}
-\usepackage[bookmarksopen]{hyperref}
+\usepackage[bookmarksopen,bookmarksnumbered]{hyperref}
\usepackage{xbmks}
@@ -10,7 +10,8 @@
%\externaldocument[m-]{master}
%\externaldocument[d2-]{doc2}
-
+% just for laughs, we transfer the last section number from master
+\setcounter{section}{2}
\begin{document}
@@ -18,6 +19,11 @@
Some content goes here.
+\belowpdfbookmarkx{Home page}[action={/S/URI/URI(http://www.acrotex.net)},%
+ color=magenta,style={it}
+]{home}
+
+
\newpage
\subsection{Doc 1: subSec 1}
diff --git a/Master/texmf-dist/doc/latex/xbmks/examples/doc2.pdf b/Master/texmf-dist/doc/latex/xbmks/examples/doc2.pdf
index 331bffa81d9..8870ca29400 100644
--- a/Master/texmf-dist/doc/latex/xbmks/examples/doc2.pdf
+++ b/Master/texmf-dist/doc/latex/xbmks/examples/doc2.pdf
Binary files differ
diff --git a/Master/texmf-dist/doc/latex/xbmks/examples/doc2.tex b/Master/texmf-dist/doc/latex/xbmks/examples/doc2.tex
index 9f033fefe80..8bc8ebb8337 100644
--- a/Master/texmf-dist/doc/latex/xbmks/examples/doc2.tex
+++ b/Master/texmf-dist/doc/latex/xbmks/examples/doc2.tex
@@ -1,9 +1,13 @@
\documentclass[12pt]{article}
\usepackage{xcolor}
%\usepackage{xr-hyper}
-\usepackage[bookmarksopen]{hyperref}
+\usepackage[bookmarksopen,bookmarksnumbered]{hyperref}
\usepackage{xbmks}
+% just for laughs, we transfer the last section number from doc2
+\setcounter{section}{4}
+
+
% the xr-hyper package may also be used if you have
% cross document links within the body of the doc
%\externaldocument[m-]{master}
@@ -13,6 +17,9 @@
\section{Doc 2: Sec 1}
+\belowpdfbookmarkx{Home page}[action={/S/URI/URI(http://www.acrotex.net)},%
+ color=magenta,style={bf}]{home}
+
Some content goes here.
\newpage
diff --git a/Master/texmf-dist/doc/latex/xbmks/examples/master.pdf b/Master/texmf-dist/doc/latex/xbmks/examples/master.pdf
index 63d6ad0cc0c..433ff95ac33 100644
--- a/Master/texmf-dist/doc/latex/xbmks/examples/master.pdf
+++ b/Master/texmf-dist/doc/latex/xbmks/examples/master.pdf
Binary files differ
diff --git a/Master/texmf-dist/doc/latex/xbmks/examples/master.tex b/Master/texmf-dist/doc/latex/xbmks/examples/master.tex
index 1b0806a3ad6..5dc32e59675 100644
--- a/Master/texmf-dist/doc/latex/xbmks/examples/master.tex
+++ b/Master/texmf-dist/doc/latex/xbmks/examples/master.tex
@@ -1,7 +1,8 @@
\documentclass[12pt]{article}
\usepackage{xcolor}
%\usepackage{xr-hyper}
-\usepackage[bookmarksopen]{hyperref}
+\usepackage[bookmarksopen,bookmarksnumbered]{hyperref}
+%\usepackage{eforms}
\usepackage{xbmks}
% the xr-hyper package may also be used if you have
@@ -18,22 +19,70 @@
% of option choices.
\xbmksetup{%
docbundle={master,doc1,doc2},
- colors={intdoc=red,extdoc},
- style={intbf}
+ colors={int=red,ext},
+ styles={intbf}
}
\begin{document}
\maketitle
+\tableofcontents
+
+% color and style specified. This will be how these entries are displayed across
+% all documents in the bundle
+\pdfbookmarkx[1]{http://blog.acrotex.net}[action={/S/URI/URI(http://blog.acrotex.net)},%
+ color=magenta,style={bf}]{blog}
+\currentpdfbookmarkx{http://www.acrotex.net}[action={/S/URI/URI(http://www.acrotex.net)},%
+ color=magenta,style={bf}]{home}
+\currentpdfbookmarkx{First page}[action={/S/Named/N/FirstPage},%
+ color=magenta,style={bf}]{First}
+\currentpdfbookmarkx{Last page}[action={/S/Named/N/LastPage},%
+ color=magenta,style={bf}]{Last}
+
+% the eforms versions of the above
+%\pdfbookmarkx[1]{http://blog.acrotex.net}[action={\URI{http://blog.acrotex.net}},%
+% color=magenta,style={bf}]{blog}
+%\currentpdfbookmarkx{http://www.acrotex.net}[action={\URI{http://www.acrotex.net}},%
+% color=magenta,style={bf}]{home}
+%\currentpdfbookmarkx{First page}[action={\Named{FirstPage}},%
+% color=magenta,style={bf}]{First}
+%\currentpdfbookmarkx{Last page}[action={\Named{LastPage}},%
+% color=magenta,style={bf}]{Last}
+
\section{Master One}
Some content goes here.
+% color and style not specified, this bookmark will take on the default
+% color and style as declared in the \xbmksetup command.
+\belowpdfbookmarkx{JavaScript Action}[%
+ action={/S/JavaScript/JS(app.alert("Hello World!\\n\\nAnnounced from the document "
+ + this.documentFileName);)}]{jsa}
+
+% eforms version
+%\belowpdfbookmarkx{JavaScript Action}[
+% action={\JS{app.alert("Hello World!\\n\\nAnnounced from the document "
+% + this.documentFileName);}]{jsa}
+
+% color and style not specified, this bookmark will take on the default
+% color and style as declared in the \xbmksetup command.
+\belowpdfbookmarkx{Go to doc1, page 2}[action={/S/GoToR/F(doc1.pdf)/D[1 /Fit]}]{gotor1}
+% eforms version
+%\belowpdfbookmarkx{Go to doc1, page 2}[action={\GoToR/F(doc1.pdf)/D[1 /Fit]}]{gotor}
+
+\hypersetup{bookmarksopen=false}
+% This next bookmark is a title only, the actions is to jump to an destination not defined
+\subpdfbookmarkx{Sub: Optional Bookmarks}[action={/S/GoTo/D(undefined)}]{optBmks}
+\belowpdfbookmarkx{doc1, page 3}[action={/S/GoToR/F(doc1.pdf)/D[2 /Fit]}]{gotor2}
+\belowpdfbookmarkx{doc2, page 2}[action={/S/GoToR/F(doc2.pdf)/D[1 /Fit]}]{gotor3}
+\hypersetup{bookmarksopen=true}
+
\subsection{Master One: subSec 1}
Some content goes here.
+
\newpage
@@ -41,7 +90,6 @@ Some content goes here.
Some content goes here.
-
\subsection{Master Two: subSec 1}
Some content goes here.
diff --git a/Master/texmf-dist/doc/latex/xbmks/examples/stand-alone.tex b/Master/texmf-dist/doc/latex/xbmks/examples/stand-alone.tex
index cb2a34fe0b6..44cf83374d6 100644
--- a/Master/texmf-dist/doc/latex/xbmks/examples/stand-alone.tex
+++ b/Master/texmf-dist/doc/latex/xbmks/examples/stand-alone.tex
@@ -8,8 +8,8 @@
\xbmksetup{%
% docbundle={\jobname},
- colors={intdoc=red,extdoc},
- style={intbf}
+ colors={int=red,ext},
+ styles={intbf}
}
\begin{document}
@@ -18,11 +18,11 @@
\section{Section One}
-When the \texttt{docbundle} key is either empty or is not present, \textsf{xbmks} sets it
-to \verb~\jobname~. No cross-document bookmarks are generated because there was no specification
-for creating (multiple values for \texttt{docbundle}); instead, we obtain a standard document
+When the \texttt{docbundle} key is either empty or is not present, \textsf{xbmks} sets its value
+to \verb~\jobname~. No cross-document bookmarks are generated because there is no ``bundle'' specified
+(multiple values for \texttt{docbundle} are needed); instead, we obtain a standard document
with bookmarks, but the color and style of of the bookmarks are controlled by the \texttt{colors}
-and \texttt{style} keys, as seen in the preamble.
+and \texttt{styles} keys, as seen in the preamble.
\subsection{Section One: subSec 1}