summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2017-03-09 22:51:40 +0000
committerKarl Berry <karl@freefriends.org>2017-03-09 22:51:40 +0000
commit3c97af82d660bc556cc6517fbc3c214152a8c09f (patch)
tree88244f0722d5a036c85e8ac870b51423ca36ee95
parent07135271a2a6e50be6d964a0d941a18a177a7292 (diff)
ocgx2 (8mar17)
git-svn-id: svn://tug.org/texlive/trunk@43446 c570f23f-e606-0410-a88d-b1316a301751
-rw-r--r--Master/texmf-dist/doc/latex/ocgx2/ChangeLog5
-rw-r--r--Master/texmf-dist/doc/latex/ocgx2/README2
-rw-r--r--Master/texmf-dist/doc/latex/ocgx2/mailto.pngbin0 -> 962 bytes
-rw-r--r--Master/texmf-dist/tex/latex/ocgx2/ocgbase.sty9
-rw-r--r--Master/texmf-dist/tex/latex/ocgx2/ocgx2.sty56
5 files changed, 28 insertions, 44 deletions
diff --git a/Master/texmf-dist/doc/latex/ocgx2/ChangeLog b/Master/texmf-dist/doc/latex/ocgx2/ChangeLog
index 9b9338e40ac..339a2df82fc 100644
--- a/Master/texmf-dist/doc/latex/ocgx2/ChangeLog
+++ b/Master/texmf-dist/doc/latex/ocgx2/ChangeLog
@@ -1,3 +1,8 @@
+2017-03-09
+ * v0.19 : ocgx2.sty
+ * v0.7 : ocgbase.sty
+ * fix: minor code fixes
+
2017-03-07
* v0.18 : ocgx2.sty
* fix: workaround for A-Reader bug when placing OCG switches on OCGs
diff --git a/Master/texmf-dist/doc/latex/ocgx2/README b/Master/texmf-dist/doc/latex/ocgx2/README
index f8e57ece789..e50aae476c0 100644
--- a/Master/texmf-dist/doc/latex/ocgx2/README
+++ b/Master/texmf-dist/doc/latex/ocgx2/README
@@ -1,7 +1,7 @@
==================================
The `ocgx2' LaTeX Package
- Version 0.18 [2017/03/07]
+ Version 0.19 [2017/03/09]
(C) 2015--\today Alexander Grahn
==================================
diff --git a/Master/texmf-dist/doc/latex/ocgx2/mailto.png b/Master/texmf-dist/doc/latex/ocgx2/mailto.png
new file mode 100644
index 00000000000..12831c2410b
--- /dev/null
+++ b/Master/texmf-dist/doc/latex/ocgx2/mailto.png
Binary files differ
diff --git a/Master/texmf-dist/tex/latex/ocgx2/ocgbase.sty b/Master/texmf-dist/tex/latex/ocgx2/ocgbase.sty
index cf1cc3f94be..3646351314e 100644
--- a/Master/texmf-dist/tex/latex/ocgx2/ocgbase.sty
+++ b/Master/texmf-dist/tex/latex/ocgx2/ocgbase.sty
@@ -31,7 +31,7 @@
% #2: usage dict (may be empty), see PDF reference:
% http://wwwimages.adobe.com/content/dam/Adobe/en/devnet/pdf/pdfs/
% pdf_reference_1-7.pdf#G9.3858276
-% #3: initial visibility (1|0|true|false|on|off)
+% #3: initial visibility (1|0|true|false|on|off|visible|invisible)
%
% \ocgbase_last_ocg:
% \ocgbase@last@ocg (LaTeX2e version)
@@ -97,7 +97,7 @@
\RequirePackage{atenddvi}
\RequirePackage{pdfbase}
-\ProvidesExplPackage{ocgbase}{2016/03/11}{0.6}
+\ProvidesExplPackage{ocgbase}{2017/03/09}{0.7}
{support package for ocgx2.sty}
\tl_new:N\g_ocgbase_ocgs_tl %takes ocg object refs
@@ -212,13 +212,14 @@
%macro for inserting new OCG object
\cs_new_nopar:Nn\ocgbase_new_ocg:nnn{
\pbs_pdfobj:nnn{}{dict}{
- /Type/OCG/Name~(#1)~\tl_if_blank:oF{#2}{/Usage<<#2>>}
+ /Type/OCG/Name~(#1)~\str_if_eq_x:nnF{#2}{}{/Usage<<#2>>}
}
\tl_gput_right:Nx\g_ocgbase_ocgs_tl{~\pbs_pdflastobj:}
\bool_if:nT{
\str_if_eq_x_p:nn{#3}{0} ||
\str_if_eq_x_p:nn{#3}{off} ||
- \str_if_eq_x_p:nn{#3}{false}
+ \str_if_eq_x_p:nn{#3}{false} ||
+ \str_if_eq_x_p:nn{#3}{invisible}
}{
\ocgbase_add_to_off_list:n{\pbs_pdflastobj:}
}
diff --git a/Master/texmf-dist/tex/latex/ocgx2/ocgx2.sty b/Master/texmf-dist/tex/latex/ocgx2/ocgx2.sty
index 36db66b8cfd..3e1114c2eb9 100644
--- a/Master/texmf-dist/tex/latex/ocgx2/ocgx2.sty
+++ b/Master/texmf-dist/tex/latex/ocgx2/ocgx2.sty
@@ -37,7 +37,7 @@
\RequirePackage{xparse}
\RequirePackage{l3keys2e}
-\ProvidesExplPackage{ocgx2}{2017/03/07}{0.18}
+\ProvidesExplPackage{ocgx2}{2017/03/09}{0.19}
{ports `ocgx' functionality to dvips+ps2pdf, xelatex and dvipdfmx}
%creating global definitions
@@ -386,15 +386,9 @@
\IfValueTF{#2}{#2}{triggerocg=onmouseup}
}{#3}
\hbox_set:Nn\l_tmpa_box{#4}
- %dummy Widget, workaround for AR bug;
+ %dummy Widget, workaround for pre AR-DC bug;
%see https://forums.adobe.com/message/5787612#5787612
- \bool_if:nT{
- !\cs_if_exist:NTF\ocgxii@insert@OC{
- \tl_if_blank_p:V\ocgxii@insert@OC
- }{
- \c_true_bool
- }
- }{\pbs_pdfannot:nnnn{
+ \str_if_eq_x:nnF{\ocgxii@insert@OC}{}{\pbs_pdfannot:nnnn{
\dim_use:N\box_wd:N\l_tmpa_box}{
\dim_use:N\box_ht:N\l_tmpa_box}{
\dim_use:N\box_dp:N\l_tmpa_box
@@ -427,7 +421,7 @@
}{
\ocgxii_ocglist_process_idlist:nn{triggerocg=onmouseup}{#3}
\pbs_pdflink:nn{
- /Subtype/Link
+ /Subtype/Link\ocgxii@insert@OC
/A <</S/SetOCGState/State [
\str_if_eq:VnF\l_ocgxii_u_list_tl{}{/Toggle~\l_ocgxii_u_list_tl}]>>
/Border [0~0~0]
@@ -446,15 +440,9 @@
\IfValueTF{#2}{#2}{triggerocg=onmouseup}
}{#3}
\hbox_set:Nn\l_tmpa_box{#4}
- %dummy Widget, workaround for AR bug;
+ %dummy Widget, workaround for pre AR-DC bug;
%see https://forums.adobe.com/message/5787612#5787612
- \bool_if:nT{
- !\cs_if_exist:NTF\ocgxii@insert@OC{
- \tl_if_blank_p:V\ocgxii@insert@OC
- }{
- \c_true_bool
- }
- }{\pbs_pdfannot:nnnn{
+ \str_if_eq_x:nnF{\ocgxii@insert@OC}{}{\pbs_pdfannot:nnnn{
\dim_use:N\box_wd:N\l_tmpa_box}{
\dim_use:N\box_ht:N\l_tmpa_box}{
\dim_use:N\box_dp:N\l_tmpa_box
@@ -487,7 +475,7 @@
}{
\ocgxii_ocglist_process_idlist:nn{triggerocg=onmouseup}{#3}
\pbs_pdflink:nn{
- /Subtype/Link
+ /Subtype/Link\ocgxii@insert@OC
/A <</S/SetOCGState/State [
\str_if_eq:VnF\l_ocgxii_u_list_tl{}{/ON~\l_ocgxii_u_list_tl}]>>
/Border [0~0~0]
@@ -506,15 +494,9 @@
\IfValueTF{#2}{#2}{triggerocg=onmouseup}
}{#3}
\hbox_set:Nn\l_tmpa_box{#4}
- %dummy Widget, workaround for AR bug;
+ %dummy Widget, workaround for pre AR-DC bug;
%see https://forums.adobe.com/message/5787612#5787612
- \bool_if:nT{
- !\cs_if_exist:NTF\ocgxii@insert@OC{
- \tl_if_blank_p:V\ocgxii@insert@OC
- }{
- \c_true_bool
- }
- }{\pbs_pdfannot:nnnn{
+ \str_if_eq_x:nnF{\ocgxii@insert@OC}{}{\pbs_pdfannot:nnnn{
\dim_use:N\box_wd:N\l_tmpa_box}{
\dim_use:N\box_ht:N\l_tmpa_box}{
\dim_use:N\box_dp:N\l_tmpa_box
@@ -547,7 +529,7 @@
}{
\ocgxii_ocglist_process_idlist:nn{triggerocg=onmouseup}{#3}
\pbs_pdflink:nn{
- /Subtype/Link
+ /Subtype/Link\ocgxii@insert@OC
/A <</S/SetOCGState/State [
\str_if_eq:VnF\l_ocgxii_u_list_tl{}{/OFF~\l_ocgxii_u_list_tl}]>>
/Border [0~0~0]
@@ -584,15 +566,9 @@
\tl_set_eq:NN\l_ocgxii_tohide_d_tl\l_ocgxii_d_list_tl
\tl_set_eq:NN\l_ocgxii_tohide_u_tl\l_ocgxii_u_list_tl
\hbox_set:Nn\l_tmpa_box{#6}
- %dummy Widget, workaround for AR bug;
+ %dummy Widget, workaround for pre AR-DC bug;
%see https://forums.adobe.com/message/5787612#5787612
- \bool_if:nT{
- !\cs_if_exist:NTF\ocgxii@insert@OC{
- \tl_if_blank_p:V\ocgxii@insert@OC
- }{
- \c_true_bool
- }
- }{\pbs_pdfannot:nnnn{
+ \str_if_eq_x:nnF{\ocgxii@insert@OC}{}{\pbs_pdfannot:nnnn{
\dim_use:N\box_wd:N\l_tmpa_box}{
\dim_use:N\box_ht:N\l_tmpa_box}{
\dim_use:N\box_dp:N\l_tmpa_box
@@ -678,7 +654,7 @@
\ocgxii_ocglist_process_idlist:nn{triggerocg=onmouseup}{#5}
\tl_set_eq:NN\l_ocgxii_tohide_u_tl\l_ocgxii_u_list_tl
\pbs_pdflink:nn{
- /Subtype/Link
+ /Subtype/Link\ocgxii@insert@OC
/A <</S/SetOCGState
/State [
\str_if_eq:VnF{\l_ocgxii_toswitch_u_tl}{}{
@@ -841,7 +817,7 @@
\usetikzlibrary{calc}
% Copyright notice: The code that follows until the end of the file was
-% taken from Paul Gaborit's `tikzlibraryocgx.code.tex' with minor modification.
+% taken from Paul Gaborit's `tikzlibraryocgx.code.tex' with minor additions.
\tikzset{
ocg/.style={ocg/.cd,#1,/tikz/.cd},
ocg={
@@ -856,10 +832,12 @@
status/false/.style={visibility=0},
status/on/.style={visibility=1},
status/off/.style={visibility=0},
+ status/1/.style={visibility=1},
+ status/0/.style={visibility=0},
% default values
name=,
opts=,
- status=visible,
+ status=on,
% ref
ref/.style={
/tikz/execute at begin scope={%