summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/tex/latex/hyperref/hyperref.sty
diff options
context:
space:
mode:
Diffstat (limited to 'Master/texmf-dist/tex/latex/hyperref/hyperref.sty')
-rw-r--r--Master/texmf-dist/tex/latex/hyperref/hyperref.sty133
1 files changed, 67 insertions, 66 deletions
diff --git a/Master/texmf-dist/tex/latex/hyperref/hyperref.sty b/Master/texmf-dist/tex/latex/hyperref/hyperref.sty
index aa81645e0fe..8dee55e1f6d 100644
--- a/Master/texmf-dist/tex/latex/hyperref/hyperref.sty
+++ b/Master/texmf-dist/tex/latex/hyperref/hyperref.sty
@@ -25,7 +25,7 @@
%%
\NeedsTeXFormat{LaTeX2e}
\ProvidesPackage{hyperref}
- [2009/12/10 v6.79n
+ [2009/12/15 v6.79p
Hypertext links for LaTeX]
\begingroup
\@makeother\`%
@@ -478,12 +478,15 @@
\@ifundefined{StringEncodingConvertTest}{%
}{%
\EdefUnescapeString\HyPsd@temp#1%
- \StringEncodingConvertTest\HyPsd@temp\HyPsd@temp
- {utf16be}{pdfdoc}{%
- \EdefEscapeString\HyPsd@temp\HyPsd@temp
- \global\let#1\HyPsd@temp
- \Hy@unicodefalse
- }{}%
+ \ifxetex
+ \StringEncodingConvertTest\HyPsd@temp\HyPsd@temp
+ {utf16be}{ascii}{%
+ \EdefEscapeString\HyPsd@temp\HyPsd@temp
+ \global\let#1\HyPsd@temp
+ \Hy@unicodefalse
+ }{}%
+ \else
+ \fi
}%
\fi
\fi
@@ -1438,6 +1441,7 @@
\xdef#4{#4#1#2}%
\HyPsd@@ConvertToUnicode#3\END#4%
}
+\RequirePackage{intcalc}[2007/09/27]
\begingroup
\catcode0=9 %
\catcode`\^=7 %
@@ -1842,30 +1846,6 @@
\Hy@boolkey{final}{#1}%
}
\let\KV@Hyp@nolinks\KV@Hyp@draft
-\define@key{Hyp}{a4paper}[true]{%
- \def\special@paper{210mm,297mm}%
- \def\Hy@pageheight{842}%
-}
-\define@key{Hyp}{a5paper}[true]{%
- \def\special@paper{148mm,210mm}%
- \def\Hy@pageheight{595}%
-}
-\define@key{Hyp}{b5paper}[true]{%
- \def\special@paper{176mm,250mm}%
- \def\Hy@pageheight{709}%
-}
-\define@key{Hyp}{letterpaper}[true]{%
- \def\special@paper{8.5in,11in}%
- \def\Hy@pageheight{792}%
-}
-\define@key{Hyp}{legalpaper}[true]{%
- \def\special@paper{8.5in,14in}%
- \def\Hy@pageheight{1008}%
-}
-\define@key{Hyp}{executivepaper}[true]{%
- \def\special@paper{7.25in,10.5in}%
- \def\Hy@pageheight{720}%
-}
\define@key{Hyp}{setpagesize}[true]{%
\Hy@boolkey{setpagesize}{#1}%
}
@@ -2093,7 +2073,7 @@
\fi
}
\define@key{Hyp}{xetex}[true]{%
- \def\Hy@driver{hdvipdfm}%
+ \def\Hy@driver{hxetex}%
}
\define@key{Hyp}{pdfmark}[true]{%
\def\Hy@driver{hdvips}%
@@ -2733,10 +2713,36 @@
\define@key{Hyp}{pdfusetitle}[true]{%
\Hy@boolkey[pdfusetitle]{usetitle}{#1}%
}
-\define@key{Hyp}{pdftitle}{\pdfstringdef\@pdftitle{#1}}
-\define@key{Hyp}{pdfauthor}{\pdfstringdef\@pdfauthor{#1}}
-\define@key{Hyp}{pdfproducer}{\pdfstringdef\@pdfproducer{#1}}
-\define@key{Hyp}{pdfcreator}{\pdfstringdef\@pdfcreator{#1}}
+\def\HyXeTeX@CheckUnicode{%
+ \ifxetex
+ \ifHy@unicode
+ \else
+ \Hy@WarningNoLine{%
+ XeTeX driver only supports unicode.\MessageBreak
+ Enabling option `unicode'%
+ }%
+ \setkeys{Hyp}{unicode}%
+ \fi
+ \else
+ \let\HyXeTeX@CheckUnicode\relax
+ \fi
+}
+\define@key{Hyp}{pdftitle}{%
+ \HyXeTeX@CheckUnicode
+ \pdfstringdef\@pdftitle{#1}%
+}
+\define@key{Hyp}{pdfauthor}{%
+ \HyXeTeX@CheckUnicode
+ \pdfstringdef\@pdfauthor{#1}%
+}
+\define@key{Hyp}{pdfproducer}{%
+ \HyXeTeX@CheckUnicode
+ \pdfstringdef\@pdfproducer{#1}%
+}
+\define@key{Hyp}{pdfcreator}{%
+ \HyXeTeX@CheckUnicode
+ \pdfstringdef\@pdfcreator{#1}%
+}
\define@key{Hyp}{pdfcreationdate}{%
\begingroup
\Hy@unicodefalse
@@ -2749,8 +2755,14 @@
\pdfstringdef\@pdfmoddate{#1}%
\endgroup
}
-\define@key{Hyp}{pdfsubject}{\pdfstringdef\@pdfsubject{#1}}
-\define@key{Hyp}{pdfkeywords}{\pdfstringdef\@pdfkeywords{#1}}
+\define@key{Hyp}{pdfsubject}{%
+ \HyXeTeX@CheckUnicode
+ \pdfstringdef\@pdfsubject{#1}%
+}
+\define@key{Hyp}{pdfkeywords}{%
+ \HyXeTeX@CheckUnicode
+ \pdfstringdef\@pdfkeywords{#1}%
+}
\define@key{Hyp}{pdfview}{\calculate@pdfview#1 \\}
\define@key{Hyp}{pdflinkmargin}{\setpdflinkmargin{#1}}
\let\setpdflinkmargin\@gobble
@@ -2865,34 +2877,23 @@
\let\phantomsection\@empty
\let\special@paper\@empty
\def\HyperDestNameFilter#1{#1}
-\@ifundefined{stockwidth}{%
- \ifdim\paperwidth>\z@
- \ifdim\paperheight>\z@
- \edef\special@paper{\the\paperwidth,\the\paperheight}%
- \fi
- \fi
-}{%
- \ifdim\stockwidth>\z@
- \ifdim\stockheight>\z@
- \edef\special@paper{\the\stockwidth,\the\stockheight}%
+\AtBeginDocument{%
+ \begingroup
+ \edef\x{\@ifundefined{stockheight}\paperheight\stockheight}%
+ \dimen@=\x\relax
+ \ifdim\dimen@>\z@
+ \else
+ \dimen@=11in\relax
+ \Hy@WarningNoLine{%
+ Height of page (\expandafter\string\x) %
+ is invalid (\the\x),\MessageBreak
+ using 11in%
+ }%
\fi
- \fi
+ \dimen@=0.99626401\dimen@
+ \xdef\Hy@pageheight{\strip@pt\dimen@}%
+ \endgroup
}
-\begingroup
- \edef\x{\@ifundefined{stockheight}\paperheight\stockheight}%
- \dimen@=\x\relax
- \ifdim\dimen@>\z@
- \else
- \dimen@=11in\relax
- \Hy@WarningNoLine{%
- Height of page (\expandafter\string\x) %
- is invalid (\the\x),\MessageBreak
- using 11in%
- }%
- \fi
- \dimen@=0.99626401\dimen@
- \xdef\Hy@pageheight{\strip@pt\dimen@}%
-\endgroup
\def\HyInd@EncapChar{\|}
\def\hypersetup{\setkeys{Hyp}}
\let\hyper@normalise\ExecuteOptions
@@ -3106,7 +3107,7 @@
\fi
\ifx\Hy@driver\@empty
\else
- \def\Hy@temp{hdvipdfm}%
+ \def\Hy@temp{hxetex}%
\ifxetex
\ifx\Hy@driver\Hy@temp
\else
@@ -3149,7 +3150,7 @@
\def\Hy@driver{hpdftex}%
\else
\ifxetex
- \def\Hy@driver{hdvipdfm}%
+ \def\Hy@driver{hxetex}%
\else
\ifvtexhtml
\def\Hy@driver{hvtexhtm}%