texlive[43446] Master/texmf-dist: ocgx2 (8mar17)
commits+karl at tug.org
commits+karl at tug.org
Thu Mar 9 23:51:41 CET 2017
Revision: 43446
http://tug.org/svn/texlive?view=revision&revision=43446
Author: karl
Date: 2017-03-09 23:51:40 +0100 (Thu, 09 Mar 2017)
Log Message:
-----------
ocgx2 (8mar17)
Modified Paths:
--------------
trunk/Master/texmf-dist/doc/latex/ocgx2/ChangeLog
trunk/Master/texmf-dist/doc/latex/ocgx2/README
trunk/Master/texmf-dist/tex/latex/ocgx2/ocgbase.sty
trunk/Master/texmf-dist/tex/latex/ocgx2/ocgx2.sty
Added Paths:
-----------
trunk/Master/texmf-dist/doc/latex/ocgx2/mailto.png
Modified: trunk/Master/texmf-dist/doc/latex/ocgx2/ChangeLog
===================================================================
--- trunk/Master/texmf-dist/doc/latex/ocgx2/ChangeLog 2017-03-09 22:51:29 UTC (rev 43445)
+++ trunk/Master/texmf-dist/doc/latex/ocgx2/ChangeLog 2017-03-09 22:51:40 UTC (rev 43446)
@@ -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
Modified: trunk/Master/texmf-dist/doc/latex/ocgx2/README
===================================================================
(Binary files differ)
Added: trunk/Master/texmf-dist/doc/latex/ocgx2/mailto.png
===================================================================
(Binary files differ)
Index: trunk/Master/texmf-dist/doc/latex/ocgx2/mailto.png
===================================================================
--- trunk/Master/texmf-dist/doc/latex/ocgx2/mailto.png 2017-03-09 22:51:29 UTC (rev 43445)
+++ trunk/Master/texmf-dist/doc/latex/ocgx2/mailto.png 2017-03-09 22:51:40 UTC (rev 43446)
Property changes on: trunk/Master/texmf-dist/doc/latex/ocgx2/mailto.png
___________________________________________________________________
Added: svn:mime-type
## -0,0 +1 ##
+application/octet-stream
\ No newline at end of property
Modified: trunk/Master/texmf-dist/tex/latex/ocgx2/ocgbase.sty
===================================================================
--- trunk/Master/texmf-dist/tex/latex/ocgx2/ocgbase.sty 2017-03-09 22:51:29 UTC (rev 43445)
+++ trunk/Master/texmf-dist/tex/latex/ocgx2/ocgbase.sty 2017-03-09 22:51:40 UTC (rev 43446)
@@ -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 at 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:}
}
Modified: trunk/Master/texmf-dist/tex/latex/ocgx2/ocgx2.sty
===================================================================
--- trunk/Master/texmf-dist/tex/latex/ocgx2/ocgx2.sty 2017-03-09 22:51:29 UTC (rev 43445)
+++ trunk/Master/texmf-dist/tex/latex/ocgx2/ocgx2.sty 2017-03-09 22:51:40 UTC (rev 43446)
@@ -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 at insert@OC{
- \tl_if_blank_p:V\ocgxii at insert@OC
- }{
- \c_true_bool
- }
- }{\pbs_pdfannot:nnnn{
+ \str_if_eq_x:nnF{\ocgxii at 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 at 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 at insert@OC{
- \tl_if_blank_p:V\ocgxii at insert@OC
- }{
- \c_true_bool
- }
- }{\pbs_pdfannot:nnnn{
+ \str_if_eq_x:nnF{\ocgxii at 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 at 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 at insert@OC{
- \tl_if_blank_p:V\ocgxii at insert@OC
- }{
- \c_true_bool
- }
- }{\pbs_pdfannot:nnnn{
+ \str_if_eq_x:nnF{\ocgxii at 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 at 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 at insert@OC{
- \tl_if_blank_p:V\ocgxii at insert@OC
- }{
- \c_true_bool
- }
- }{\pbs_pdfannot:nnnn{
+ \str_if_eq_x:nnF{\ocgxii at 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 at 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={%
More information about the tex-live-commits
mailing list