diff options
author | Karl Berry <karl@freefriends.org> | 2011-10-09 23:43:27 +0000 |
---|---|---|
committer | Karl Berry <karl@freefriends.org> | 2011-10-09 23:43:27 +0000 |
commit | 09ab3a5d73d4bd916aa1fdfd114753087c851fe4 (patch) | |
tree | 540cfc9b0a7e5a530bdc9f8bc52fe9dbf4b50a92 /Master/texmf-dist/tex/latex/bidi/hyperref-xetex-bidi.def | |
parent | 0b310accd4feabf084b43f1c0286ea6d78eceae9 (diff) |
bidi (9oct11)
git-svn-id: svn://tug.org/texlive/trunk@24248 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/tex/latex/bidi/hyperref-xetex-bidi.def')
-rw-r--r-- | Master/texmf-dist/tex/latex/bidi/hyperref-xetex-bidi.def | 16 |
1 files changed, 11 insertions, 5 deletions
diff --git a/Master/texmf-dist/tex/latex/bidi/hyperref-xetex-bidi.def b/Master/texmf-dist/tex/latex/bidi/hyperref-xetex-bidi.def index bc1ed7b683a..24b9666fc57 100644 --- a/Master/texmf-dist/tex/latex/bidi/hyperref-xetex-bidi.def +++ b/Master/texmf-dist/tex/latex/bidi/hyperref-xetex-bidi.def @@ -12,7 +12,7 @@ %% License information appended. %% %% -\ProvidesFile{hyperref-xetex-bidi.def}[2010/07/25 v0.4 bidi adaptations for hyperref package for XeTeX engine] +\ProvidesFile{hyperref-xetex-bidi.def}[2012/01/01 v0.5 bidi adaptations for hyperref package for XeTeX engine] \AtBeginDocument{% \def\contentsline#1#2#3#4{% \ifx\\#4\\% @@ -223,10 +223,7 @@ \def\hyper@link#1#2#3{% \beginL\hyper@linkstart{#1}{#2}\if@RTL\beginR\fi#3\if@RTL\endR\fi\hyper@linkend\endL } -\let\origin@href=\href -\renewcommand\href[2]{\beginL\origin@href{#1}{\if@RTL\beginR\fi#2\if@RTL\endR\fi}\endL} -\let\origin@url=\url -\renewcommand\url[1]{\beginL\origin@url{#1}\endL}% +\def\url@#1{\beginL\hyper@linkurl{\Hurl{#1}}{#1}\endL} \def\hyper@natlinkstart#1{% \Hy@backout{#1}% \beginL\hyper@linkstart{cite}{cite.#1}\if@RTL\beginR\fi% @@ -239,6 +236,15 @@ \if@RTL\endR\fi\hyper@linkend\endL#1\beginL\hyper@linkstart{cite}{cite.#2}\if@RTL\beginR\fi% }% } +\begingroup + \catcode`\$=6 % + \catcode`\#=12 % + \gdef\href@$1{\expandafter\href@split$1##\\}% + \gdef\href@split$1#$2#$3\\$4{% + \beginL\hyper@@link{$1}{$2}{\if@RTL\beginR\fi$4\if@RTL\endR\fi}\endL% + \endgroup + }% +\endgroup %% %% Copyright © 2009–2012 Vafa Khalighi <vafaklg@gmail.com> %% |