diff options
Diffstat (limited to 'Master/texmf-dist/source/latex/l3kernel/l3drivers-pdf.dtx')
-rw-r--r-- | Master/texmf-dist/source/latex/l3kernel/l3drivers-pdf.dtx | 52 |
1 files changed, 23 insertions, 29 deletions
diff --git a/Master/texmf-dist/source/latex/l3kernel/l3drivers-pdf.dtx b/Master/texmf-dist/source/latex/l3kernel/l3drivers-pdf.dtx index 50215d5bf8f..62a3bea1119 100644 --- a/Master/texmf-dist/source/latex/l3kernel/l3drivers-pdf.dtx +++ b/Master/texmf-dist/source/latex/l3kernel/l3drivers-pdf.dtx @@ -43,7 +43,7 @@ % }^^A % } % -% \date{Released 2019-05-09} +% \date{Released 2019-05-28} % % \maketitle % @@ -630,6 +630,19 @@ def /driver.breaklink.write { + counttomark ~ 1 ~ sub ~ + index /_objdef ~ eq + { + counttomark ~ -2 ~ roll ~ + dup ~ wcheck ~ + { + readonly ~ + counttomark ~ 2 ~ roll + } + { pop ~ pop } + ifelse + } + if ~ counttomark ~ 1 ~ add ~ copy ~ pop ~ driver.currentrect /ANN ~ pdfmark @@ -645,8 +658,7 @@ % driver.pdfmark.good , % driver.outerbox , % driver.baselineskip , -% driver.pdfmark.dict , -% driver.pdfmark.obj +% driver.pdfmark.dict % } % The business end of breaking links starts by hooking into |pdfmarks|. % Unlike \pkg{hypdvips}, we avoid altering any links we have not created @@ -676,11 +688,9 @@ Rect ~ 1 ~ get ~ sub ~ driver.baselineskip ~ div ~ round ~ cvi ~ 0 ~ gt { driver.breaklink } - { driver.pdfmark.obj } - ifelse + if } - { driver.pdfmark.obj } - ifelse ~ + if ~ end ~ SDict /driver.outerbox ~ undef ~ SDict /driver.baselineskip ~ undef ~ @@ -713,8 +723,6 @@ loop } def - /driver.pdfmark.obj - { /_objdef ~ exch ~ driver.link.obj ~ exch } def } % \end{macrocode} % \end{macro} @@ -835,22 +843,18 @@ % \end{macrocode} % \end{variable} % -% \begin{variable}{\l_@@_breaklink_obj_tl, \l_@@_breaklink_pdfmark_tl} +% \begin{variable}{\l_@@_breaklink_pdfmark_tl} % Swappable content for link breaking. % \begin{macrocode} -\tl_new:N \l_@@_breaklink_obj_tl -\tl_set:Nn \l_@@_breaklink_obj_tl - { /_objdef ~ { driver.obj \int_use:N \g_@@_pdf_link_int } } \tl_new:N \l_@@_breaklink_pdfmark_tl \tl_set:Nn \l_@@_breaklink_pdfmark_tl { pdfmark } % \end{macrocode} % \end{variable} % -% \begin{macro}{\@@_breaklink_postscript:n, \@@_breaklink_postscript:x} +% \begin{macro}{\@@_breaklink_postscript:n} % To allow dropping material unless link breaking is active. % \begin{macrocode} \cs_new_protected:Npn \@@_breaklink_postscript:n #1 { } -\cs_generate_variant:Nn \@@_breaklink_postscript:n { x } % \end{macrocode} % \end{macro} % @@ -861,7 +865,6 @@ % \end{macrocode} % \end{macro} % -% % \begin{macro}{\driver_pdf_link_begin_goto:nnw, \driver_pdf_link_begin_user:nnw} % \begin{macro}{\@@_pdf_link:nw, \@@_pdf_link_aux:nw} % \begin{macro}{\driver_pdf_link_end:, \@@_pdf_link_end:} @@ -875,7 +878,6 @@ % driver.llx, driver.lly , % driver.ury, driver.ury , % driver.link.dict , -% driver.link.obj , % driver.outerbox , % driver.baselineskip % } @@ -912,7 +914,6 @@ \cs_new_protected:Npn \@@_pdf_link_begin_aux:nw #1 { \bool_gset_true:N \g_@@_pdf_link_bool - \@@_pdf_annotation:nnnn { 3pt } { 3pt } { 0pt } { } \@@_postscript:n { /driver.link.dict ( #1 ) def } \tl_gset:Nn \g_@@_pdf_link_dict_tl {#1} @@ -961,18 +962,10 @@ } \int_gincr:N \g_@@_pdf_object_int \int_gset_eq:NN \g_@@_pdf_link_int \g_@@_pdf_object_int - \@@_breaklink_postscript:x - { - /driver.link.obj - { - { driver.obj \int_use:N \g_@@_pdf_link_int \c_space_tl driver.cvs } - } - def - } \@@_postscript:x { mark - \l_@@_breaklink_obj_tl + /_objdef { driver.obj \int_use:N \g_@@_pdf_link_int } \g_@@_pdf_link_dict_tl \c_space_tl driver.rect /ANN ~ \l_@@_breaklink_pdfmark_tl @@ -1088,7 +1081,6 @@ } } } - \tl_clear:N \l_@@_breaklink_obj_tl \tl_set:Nn \l_@@_breaklink_pdfmark_tl { driver.pdfmark } \cs_set_eq:NN \@@_breaklink_postscript:n \@@_postscript:n \cs_set_eq:NN \@@_breaklink_usebox:N \hbox_unpack:N @@ -1397,7 +1389,7 @@ { \@@_tmp:w { \tex_pdfextension:D obj ~ } - { \exp_not:N \tex_pdffeedback:D lastobj \scan_stop: } + { \exp_not:N \tex_pdffeedback:D lastobj } } { \@@_tmp:w { \tex_pdfobj:D } { \tex_pdflastobj:D } } \group_end: @@ -1457,6 +1449,7 @@ % \begin{macrocode} \cs_new_protected:Npx \driver_pdf_compresslevel:n #1 { + \exp_not:N \tex_global:D \cs_if_exist:NTF \tex_pdfcompresslevel:D { \tex_pdfcompresslevel:D } { \tex_pdfvariable:D compresslevel } @@ -1470,6 +1463,7 @@ } \cs_new_protected:Npx \@@_pdf_objcompresslevel:n #1 { + \exp_not:N \tex_global:D \cs_if_exist:NTF \tex_pdfobjcompresslevel:D { \tex_pdfobjcompresslevel:D } { \tex_pdfvariable:D objcompresslevel } |