diff options
author | Karl Berry <karl@freefriends.org> | 2010-11-25 23:32:40 +0000 |
---|---|---|
committer | Karl Berry <karl@freefriends.org> | 2010-11-25 23:32:40 +0000 |
commit | 160d4e9edc8db0aa14b4865744b6fca79846d78b (patch) | |
tree | 94bb345edbae57321cbae67cdcdc0e2ab2c1984d /Master/texmf-dist/tex/latex/hyperref/hpdftex.def | |
parent | e82be56a22fd2464132008f7cdd8c41eb906100e (diff) |
hyperref (25nov10)
git-svn-id: svn://tug.org/texlive/trunk@20566 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/tex/latex/hyperref/hpdftex.def')
-rw-r--r-- | Master/texmf-dist/tex/latex/hyperref/hpdftex.def | 249 |
1 files changed, 131 insertions, 118 deletions
diff --git a/Master/texmf-dist/tex/latex/hyperref/hpdftex.def b/Master/texmf-dist/tex/latex/hyperref/hpdftex.def index 8df0ed6e15e..96392393148 100644 --- a/Master/texmf-dist/tex/latex/hyperref/hpdftex.def +++ b/Master/texmf-dist/tex/latex/hyperref/hpdftex.def @@ -29,10 +29,14 @@ %% given in the file `manifest.txt'. %% \ProvidesFile{hpdftex.def} - [2010/10/30 v6.81t + [2010/11/22 v6.81u % Hyperref driver for pdfTeX] \Hy@VersionCheck{hpdftex.def} -\let\Hy@PutCatalog\pdfcatalog +\pdf@ifdraftmode{% + \let\Hy@PutCatalog\ltx@gobble +}{% + \let\Hy@PutCatalog\pdfcatalog +} \ifHy@pagelabels \def\HyPL@StorePageLabel#1{% \toks@\expandafter{\HyPL@Labels}% @@ -46,7 +50,6 @@ \HyPL@SetPageLabels }% \fi -\RequirePackage{pdftexcmds}[2009/04/10] \begingroup\expandafter\expandafter\expandafter\endgroup \expandafter\ifx\csname pdf@escapestring\endcsname\relax \begingroup @@ -144,77 +147,79 @@ } \Hy@DisableOption{pdfversion}% \ifHy@ocgcolorlinks - \immediate\pdfobj{% - <<% - /Type/OCG% - /Name(View)% - /Usage<<% - /Print<<% - /PrintState/OFF% - >>% - /View<<% - /ViewState/ON% - >>% - >>% - >>% - }% - \edef\OBJ@OCG@view{\the\pdflastobj\space 0 R}% - \immediate\pdfobj{% - <<% - /Type/OCG% - /Name(Print)% - /Usage<<% - /Print<<% - /PrintState/ON% - >>% - /View<<% - /ViewState/OFF% + \pdf@ifdraftmode{}{% + \immediate\pdfobj{% + <<% + /Type/OCG% + /Name(View)% + /Usage<<% + /Print<<% + /PrintState/OFF% + >>% + /View<<% + /ViewState/ON% + >>% >>% >>% - >>% - }% - \edef\OBJ@OCG@print{\the\pdflastobj\space 0 R}% - \immediate\pdfobj{% - [% - \OBJ@OCG@view\space\OBJ@OCG@print - ]% - }% - \edef\OBJ@OCGs{\the\pdflastobj\space 0 R}% - \pdfcatalog{% - /OCProperties<<% - /OCGs \OBJ@OCGs - /D<<% - /OFF[\OBJ@OCG@print]% - /AS[% - <<% - /Event/View% - /OCGs \OBJ@OCGs - /Category[/View]% - >>% - <<% - /Event/Print% - /OCGs \OBJ@OCGs - /Category[/Print]% + }% + \edef\OBJ@OCG@view{\the\pdflastobj\space 0 R}% + \immediate\pdfobj{% + <<% + /Type/OCG% + /Name(Print)% + /Usage<<% + /Print<<% + /PrintState/ON% >>% - <<% - /Event/Export% - /OCGs \OBJ@OCGs - /Category[/Print]% + /View<<% + /ViewState/OFF% >>% - ]% + >>% >>% - >>% - }% - \begingroup - \edef\x{\endgroup - \pdfpageresources{% - /Properties<<% - /OCView \OBJ@OCG@view - /OCPrint \OBJ@OCG@print + }% + \edef\OBJ@OCG@print{\the\pdflastobj\space 0 R}% + \immediate\pdfobj{% + [% + \OBJ@OCG@view\space\OBJ@OCG@print + ]% + }% + \edef\OBJ@OCGs{\the\pdflastobj\space 0 R}% + \pdfcatalog{% + /OCProperties<<% + /OCGs \OBJ@OCGs + /D<<% + /OFF[\OBJ@OCG@print]% + /AS[% + <<% + /Event/View% + /OCGs \OBJ@OCGs + /Category[/View]% + >>% + <<% + /Event/Print% + /OCGs \OBJ@OCGs + /Category[/Print]% + >>% + <<% + /Event/Export% + /OCGs \OBJ@OCGs + /Category[/Print]% + >>% + ]% >>% - }% + >>% }% - \x + \begingroup + \edef\x{\endgroup + \pdfpageresources{% + /Properties<<% + /OCView \OBJ@OCG@view + /OCPrint \OBJ@OCG@print + >>% + }% + }% + \x + }% \Hy@AtBeginDocument{% \def\Hy@colorlink#1{% \begingroup @@ -583,31 +588,33 @@ }% } \def\PDF@FinishDoc{% - \Hy@UseMaketitleInfos - \HyInfo@GenerateAddons - \pdfinfo{% - /Author(\@pdfauthor)% - /Title(\@pdftitle)% - /Subject(\@pdfsubject)% - /Creator(\@pdfcreator)% - \ifx\@pdfcreationdate\@empty - \else - /CreationDate(\@pdfcreationdate)% - \fi - \ifx\@pdfmoddate\@empty - \else - /ModDate(\@pdfmoddate)% - \fi - \ifx\@pdfproducer\relax - \else - /Producer(\@pdfproducer)% - \fi - /Keywords(\@pdfkeywords)% - \ifx\@pdftrapped\@empty - \else - /Trapped/\@pdftrapped - \fi - \HyInfo@Addons + \pdf@ifdraftmode{}{% + \Hy@UseMaketitleInfos + \HyInfo@GenerateAddons + \pdfinfo{% + /Author(\@pdfauthor)% + /Title(\@pdftitle)% + /Subject(\@pdfsubject)% + /Creator(\@pdfcreator)% + \ifx\@pdfcreationdate\@empty + \else + /CreationDate(\@pdfcreationdate)% + \fi + \ifx\@pdfmoddate\@empty + \else + /ModDate(\@pdfmoddate)% + \fi + \ifx\@pdfproducer\relax + \else + /Producer(\@pdfproducer)% + \fi + /Keywords(\@pdfkeywords)% + \ifx\@pdftrapped\@empty + \else + /Trapped/\@pdftrapped + \fi + \HyInfo@Addons + }% }% \Hy@DisableOption{pdfauthor}% \Hy@DisableOption{pdftitle}% @@ -690,10 +697,12 @@ \Hy@RemoveHidPageAttr#1#4\END \fi } -\g@addto@macro\Hy@EveryPageHook{% - \hyper@pagetransition - \hyper@pageduration - \hyper@pagehidden +\pdf@ifdraftmode{}{% + \g@addto@macro\Hy@EveryPageHook{% + \hyper@pagetransition + \hyper@pageduration + \hyper@pagehidden + }% } \Hy@AtBeginDocument{% \ifHy@setpagesize @@ -839,31 +848,35 @@ \def\@Form[#1]{% \@ifundefined{textcolor}{\let\textcolor\@gobble}{}% \kvsetkeys{Form}{#1}% - \Hy@FormObjects - \ifnum\pdftexversion>13 % - \pdfrefobj\OBJ@pdfdocencoding - \pdfrefobj\OBJ@ZaDb - \pdfrefobj\OBJ@Helv - \fi - \AtVeryEndDocument{% - \immediate\pdfobj{% - <<% - /Fields[\HyField@afields]% - /DR<<% - /Font<<% - /ZaDb \OBJ@ZaDb\space 0 R% - /Helv \OBJ@Helv\space 0 R% + \pdf@ifdraftmode{}{% + \Hy@FormObjects + \ifnum\pdftexversion>13 % + \pdfrefobj\OBJ@pdfdocencoding + \pdfrefobj\OBJ@ZaDb + \pdfrefobj\OBJ@Helv + \fi + \AtVeryEndDocument{% + \immediate\pdfobj{% + <<% + /Fields[\HyField@afields]% + /DR<<% + /Font<<% + /ZaDb \OBJ@ZaDb\space 0 R% + /Helv \OBJ@Helv\space 0 R% + >>% >>% + /DA(/Helv 10 Tf 0 g)% + \ifHy@pdfa + \else + \ifHyField@NeedAppearances + /NeedAppearances true% + \fi + \fi >>% - /DA(/Helv 10 Tf 0 g)% - \ifHy@pdfa - \else - /NeedAppearances true% - \fi - >>% + }% + \edef\OBJ@acroform{\the\pdflastobj}% + \pdfcatalog{/AcroForm \OBJ@acroform\space 0 R}% }% - \edef\OBJ@acroform{\the\pdflastobj}% - \pdfcatalog{/AcroForm \OBJ@acroform\space 0 R}% }% \MakeFieldObject{% \begingroup |