summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/source/xelatex
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2015-11-13 22:34:31 +0000
committerKarl Berry <karl@freefriends.org>2015-11-13 22:34:31 +0000
commit3a45a1fb1b8828638ab19aca6c84b78752232431 (patch)
tree4d691fff1de2c1e6b27227b6e32c16e24fc64dc8 /Master/texmf-dist/source/xelatex
parentc5e0cd049cb657a40e15cef1fddf373161d5615d (diff)
bidi (13nov15)
git-svn-id: svn://tug.org/texlive/trunk@38841 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/source/xelatex')
-rw-r--r--Master/texmf-dist/source/xelatex/bidi/bidi.dtx199
-rw-r--r--Master/texmf-dist/source/xelatex/bidi/bidi.ins3
2 files changed, 126 insertions, 76 deletions
diff --git a/Master/texmf-dist/source/xelatex/bidi/bidi.dtx b/Master/texmf-dist/source/xelatex/bidi/bidi.dtx
index 2257ad2123c..fd3acb065d5 100644
--- a/Master/texmf-dist/source/xelatex/bidi/bidi.dtx
+++ b/Master/texmf-dist/source/xelatex/bidi/bidi.dtx
@@ -5,7 +5,7 @@
%<*readme>
___________________
The bidi package
-v18.2
+v18.4
This package provides a convenient interface for typesetting
bidirectional texts in Plain TeX and LaTeX, using XeTeX engine.
@@ -25,7 +25,7 @@ a minimal working example showing the issue, and always choose the appropriate
label for your query (i.e. if you are reporting any bugs, choose `Bug' label).
-Current version release date: 2015/11/07
+Current version release date: 2015/11/14
___________________
Vafa Khalighi
@@ -147,7 +147,7 @@ by Vafa Khalighi.
\generate{\file{ntheorem-xetex-bidi.def}{\from{\jobname.dtx}{table,ntheorem-xetex-bidi.def}}}
\generate{\file{ntheorem-hyper-xetex-bidi.def}{\from{\jobname.dtx}{table,ntheorem-hyper-xetex-bidi.def}}}
\generate{\file{pdfpages-xetex-bidi.def}{\from{\jobname.dtx}{table,pdfpages-xetex-bidi.def}}}
-\generate{\file{pgf-xetex-bidi.def}{\from{\jobname.dtx}{table,pgf-xetex-bidi.def}}}
+\generate{\file{pgfcorescopes.code-xetex-bidi.def}{\from{\jobname.dtx}{table,pgfcorescopes.code-xetex-bidi.def}}}
\generate{\file{picinpar-xetex-bidi.def}{\from{\jobname.dtx}{table,picinpar-xetex-bidi.def}}}
\generate{\file{plain-xetex-bidi.def}{\from{\jobname.dtx}{table,plain-xetex-bidi.def}}}
\generate{\file{pstricks-xetex-bidi.def}{\from{\jobname.dtx}{table,pstricks-xetex-bidi.def}}}
@@ -170,7 +170,6 @@ by Vafa Khalighi.
\generate{\file{tabularx-xetex-bidi.def}{\from{\jobname.dtx}{table,tabularx-xetex-bidi.def}}}
\generate{\file{tabulary-xetex-bidi.def}{\from{\jobname.dtx}{table,tabulary-xetex-bidi.def}}}
\generate{\file{tc-xetex-bidi.def}{\from{\jobname.dtx}{table,tc-xetex-bidi.def}}}
-\generate{\file{tikz-xetex-bidi.def}{\from{\jobname.dtx}{table,tikz-xetex-bidi.def}}}
\generate{\file{titlesec-xetex-bidi.def}{\from{\jobname.dtx}{table,titlesec-xetex-bidi.def}}}
\generate{\file{titletoc-xetex-bidi.def}{\from{\jobname.dtx}{table,titletoc-xetex-bidi.def}}}
\generate{\file{tocbibind-xetex-bidi.def}{\from{\jobname.dtx}{table,tocbibind-xetex-bidi.def}}}
@@ -320,7 +319,7 @@ by Vafa Khalighi.
%\changes{v13.9}{2013/09/23}{Added implementaion of the package.}
% \title{\textcolor{blue!65!black}{\Huge The \textsf{bidi} \textit{Package}}\\
%\LARGE Bidirectional typesetting in plain \TeX{} and \LaTeX, using \XeTeX{} engine\\[5pt]
-%\large Documentation for \textcolor{blue!65!black}{version 18.2}}
+%\large Documentation for \textcolor{blue!65!black}{version 18.4}}
% \author{Vafa Khalighi\\
% \url{persian-tex@tug.org}}
%\setcounter{page}{0}
@@ -331,7 +330,7 @@ by Vafa Khalighi.
%\textcolor{blue!65!black}{\Huge The \textsf{bidi} \textit{Package}}
%
%\Large
-%Documentation for \textcolor{blue!65!black}{version 18.2}}
+%Documentation for \textcolor{blue!65!black}{version 18.4}}
%
%\vskip 0pt plus 3fill
%\textit{\large to my Master, \textbf{Ferdowsi The Great}}
@@ -382,7 +381,7 @@ by Vafa Khalighi.
%*
%* Copyright (c) 2009--2015 Vafa Khalighi
%*
-%* 2015/11/07, v18.2
+%* 2015/11/14, v18.4
%*
%* License: LaTeX Project Public License, version
%* 1.3c or higher (your choice)
@@ -1139,7 +1138,7 @@ by Vafa Khalighi.
%\iffalse
%<*table>
%\fi
-%% \CheckSum{44926}
+%% \CheckSum{45014}
%% \CharacterTable
%% {Upper-case \A\B\C\D\E\F\G\H\I\J\K\L\M\N\O\P\Q\R\S\T\U\V\W\X\Y\Z
%% Lower-case \a\b\c\d\e\f\g\h\i\j\k\l\m\n\o\p\q\r\s\t\u\v\w\x\y\z
@@ -2761,8 +2760,8 @@ by Vafa Khalighi.
% \subsection{\textsf{bidi.sty}}
% \begin{macrocode}
\NeedsTeXFormat{LaTeX2e}
-\def\bididate{2015/11/07}
-\def\bidiversion{v18.2}
+\def\bididate{2015/11/14}
+\def\bidiversion{v18.4}
\ProvidesPackage{bidi}[\bididate\space \bidiversion\space
Bidirectional typesetting in plain TeX and LaTeX]
\edef\@bidi@info{****************************************************^^J%
@@ -3680,7 +3679,7 @@ Bidirectional typesetting in plain TeX and LaTeX]
% \subsection{\textsf{biditools.sty}}
% \begin{macrocode}
\NeedsTeXFormat{LaTeX2e}
-\ProvidesPackage{biditools}[2015/10/31 v0.7 Programming tools for bidi package]
+\ProvidesPackage{biditools}[2015/11/14 v0.8 Programming tools for bidi package]
\providecommand{\@bidi@saveprimitive}[2]{\begingroup\escapechar`\\\relax
\edef\@tempa{\string#1}\edef\@tempb{\meaning#1}%
\ifx\@tempa\@tempb \global\let#2#1%
@@ -3768,8 +3767,10 @@ ill-advised in the old versions of bidi package.%
}
\def\@tagsextension{clo}
\def\@definitionfileextension{def}
+\def\@texfileextension{tex}
\def\@iftagsloaded{\@ifl@aded\@tagsextension}
\def\@ifdefinitionfileloaded{\@ifl@aded\@definitionfileextension}
+\def\@iftexfileloaded{\@ifl@aded\@texfileextension}
\def\eqnewif#1#2{%
\count@\escapechar \escapechar\m@ne
\let#1\iffalse
@@ -14656,20 +14657,77 @@ bidi implementation of tufte title]
% \end{macrocode}
% \iffalse
%</pdfpages-xetex-bidi.def>
-%<*pgf-xetex-bidi.def>
+%<*pgfcorescopes.code-xetex-bidi.def>
%\fi
-% \subsection{\textsf{pgf-xetex-bidi.def}}
+% \subsection{\textsf{pgfcorescopes.code-xetex-bidi.def}}
% \begin{macrocode}
-\ProvidesFile{pgf-xetex-bidi.def}[2014/11/21 v0.6 bidi adaptations for pgf package for XeTeX engine]
-\let\origin@pgfpicture=\pgfpicture
-\let\origin@endpgfpicture=\endpgfpicture
-\def\bidi@pgfpicture{\ifmmode\else\beginL\fi\origin@pgfpicture}
-\def\endbidi@pgfpicture{\origin@endpgfpicture\ifmmode\else\endL\fi}
-\def\pgfpicture{\ifmmode\else\LTR\noindent\beginL\fi\origin@pgfpicture}
-\def\endpgfpicture{\origin@endpgfpicture\ifmmode\else\endL\endLTR\fi}
+\ProvidesFile{pgfcorescopes.code-xetex-bidi.def}[2015/11/14 v0.1 bidi adaptations for pgf package for XeTeX engine]
+\def\pgfpicture{%
+ \begingroup%
+ \ifmmode\else\@RTLfalse\beginL\fi%
+ \pgfpicturetrue%
+ \global\advance\pgf@picture@serial@count by1\relax%
+ \edef\pgfpictureid{pgfid\the\pgf@picture@serial@count}%
+ \let\pgf@nodecallback=\pgfutil@gobble%
+ \pgf@picmaxx=-16000pt\relax%
+ \pgf@picminx=16000pt\relax%
+ \pgf@picmaxy=-16000pt\relax%
+ \pgf@picminy=16000pt\relax%
+ \pgf@relevantforpicturesizetrue%
+ \pgf@resetpathsizes%
+ \pgfutil@ifnextchar\bgroup\pgf@oldpicture\pgf@picture}
+\def\endpgfpicture{%
+ \ifpgfrememberpicturepositiononpage%
+ \hbox to0pt{\pgfsys@markposition{\pgfpictureid}}%
+ \fi%
+ % ok, now let's position the box
+ \ifdim\pgf@picmaxx=-16000pt\relax%
+ % empty picture. make size 0.
+ \global\pgf@picmaxx=0pt\relax%
+ \global\pgf@picminx=0pt\relax%
+ \global\pgf@picmaxy=0pt\relax%
+ \global\pgf@picminy=0pt\relax%
+ \fi%
+ % Shift baseline outside:
+ \pgf@relevantforpicturesizefalse%
+ \pgf@process{\pgf@baseline}%
+ \xdef\pgf@shift@baseline{\the\pgf@y}%
+ %
+ \pgf@process{\pgf@trimleft}%
+ \global\advance\pgf@x by-\pgf@picminx
+ % prepare \hskip\pgf@trimleft@final.
+ % note that \pgf@trimleft@final is also queried
+ % by the pgf image externalization.
+ \xdef\pgf@trimleft@final{-\the\pgf@x}%
+ %
+ \pgf@process{\pgf@trimright}%
+ \global\advance\pgf@x by-\pgf@picmaxx
+ % prepare \hskip\pgf@trimright@final.
+ % note that \pgf@trimright@final is also queried
+ % by the pgf image externalization.
+ \xdef\pgf@trimright@final{\the\pgf@x}%
+ %
+ \pgf@remember@layerlist@globally
+ \endgroup%
+ \hss%
+ \egroup%
+ \pgf@restore@layerlist@from@global
+ \pgf@insertlayers%
+ \endgroup%
+ \pgfsys@discardpath%
+ \endgroup%
+ \pgfsys@endscope%
+ \pgfsys@endpicture%
+ \endgroup%
+ \hss
+ \egroup%
+ \pgfsys@typesetpicturebox\pgfpic%
+ \ifmmode\else\endL\fi%
+ \endgroup%
+}
% \end{macrocode}
% \iffalse
-%</pgf-xetex-bidi.def>
+%</pgfcorescopes.code-xetex-bidi.def>
%<*picinpar-xetex-bidi.def>
%\fi
% \subsection{\textsf{picinpar-xetex-bidi.def}}
@@ -14901,11 +14959,45 @@ to\rtside{\box\bslice\hfil}}
%\fi
% \subsection{\textsf{pstricks-xetex-bidi.def}}
% \begin{macrocode}
-\ProvidesFile{pstricks-xetex-bidi.def}[2010/07/25 v0.3 bidi adaptations for pstricks package for XeTeX engine]
-\let\origin@pspicture=\pspicture
-\let\origin@endpspicture=\endpspicture
-\def\pspicture{\ifmmode\else\LTR\beginL\fi\origin@pspicture}
-\def\endpspicture{\origin@endpspicture\ifmmode\else\endL\endLTR\fi}
+\ProvidesFile{pstricks-xetex-bidi.def}[2015/11/14 v0.4 bidi adaptations for pstricks package for XeTeX engine]
+\def\pspicture{\begingroup\ifmmode\else\@RTLfalse\beginL\fi\pst@ifstar\pst@picture}
+\def\endpspicture{%
+ \ifshowgrid\ifnum\showgridp@s>0
+ \psgrid[xunit=\sh@wgridXunit,yunit=\sh@wgridYunit,style=gridstyle]\fi\fi%
+ \pst@killglue
+% \global\pst@shift=\pst@shift% in fact of the following endgroup
+ \endgroup
+ \egroup
+ \ifdim\wd\pst@hbox=\z@\else
+ %\@pstrickserr{Extraneous space in the pspicture environment}%
+ %{Type \space <return> \space to proceed.}%
+ \fi
+ \ht\pst@hbox=\pst@dimd
+ \dp\pst@hbox=-\pst@dimb
+ \setbox\pst@hbox=\hbox{%
+ \kern-\pst@dima
+% Orig version ----------
+%\ifx\pst@tempa\@empty\else
+%\advance\pst@dimd-\pst@dimb
+%\pst@dimd=\pst@tempa\pst@dimd
+%\advance\pst@dimd\pst@dimb
+%\lower\pst@dimd
+%\fi
+%----- end Orig
+ \ifPst@shift@star%\typeout{==pstricks== old behaviour of the shift option}% shift=*
+ \advance\pst@dimd-\pst@dimb
+ \pst@dimd=0.5\pst@dimd
+ \else\pst@dimd-\pst@shift\fi
+ \advance\pst@dimd\pst@dimb
+ \lower\pst@dimd%
+ \box\pst@hbox%
+ \kern\pst@dimc}%
+ \if@star\setbox\pst@hbox=\hbox{\clipbox@@\z@}\fi%
+ \leavevmode\box\pst@hbox%
+ \ifmmode\else\endL\fi%
+ \endgroup%
+ \psset[pstricks]{shift=0}% reset value
+}
% \end{macrocode}
% \iffalse
%</pstricks-xetex-bidi.def>
@@ -18178,46 +18270,6 @@ to\rtside{\box\bslice\hfil}}
% \end{macrocode}
% \iffalse
%</tc-xetex-bidi.def>
-%<*tikz-xetex-bidi.def>
-%\fi
-% \subsection{\textsf{tikz-xetex-bidi.def}}
-% \begin{macrocode}
-\ProvidesFile{tikz-xetex-bidi.def}[2014/11/20 v0.1 bidi adaptations for tikz package for XeTeX engine]
-\def\bidi@tikzpicture{%
- \begingroup%
- \tikz@startup@env%
- \pgfutil@ifnextchar[\bidi@tikz@picture{\bidi@tikz@picture[]}}%}
-\def\bidi@tikz@picture[#1]{%
- \bidi@pgfpicture%
- \let\tikz@atbegin@picture=\pgfutil@empty%
- \let\tikz@atend@picture=\pgfutil@empty%
- \let\tikz@transform=\relax%
- \def\tikz@time{.5}%
- \tikz@installcommands%
- \scope[every picture,#1]%
- \iftikz@handle@active@code%
- \tikz@switchoff@shorthands%
- \fi%
- \expandafter\tikz@atbegin@picture%
- \tikz@lib@scope@check%
-}
-\def\endbidi@tikzpicture{%
- \tikz@atend@picture%
- \global\let\pgf@shift@baseline@smuggle=\pgf@baseline%
- \global\let\pgf@trimleft@final@smuggle=\pgf@trimleft%
- \global\let\pgf@trimright@final@smuggle=\pgf@trimright%
- \global\let\pgf@remember@smuggle=\ifpgfrememberpicturepositiononpage%
- \pgf@remember@layerlist@globally
- \endscope%
- \let\pgf@baseline=\pgf@shift@baseline@smuggle%
- \let\pgf@trimleft=\pgf@trimleft@final@smuggle%
- \let\pgf@trimright=\pgf@trimright@final@smuggle%
- \let\ifpgfrememberpicturepositiononpage=\pgf@remember@smuggle%
- \pgf@restore@layerlist@from@global
- \endbidi@pgfpicture\endgroup}
-% \end{macrocode}
-% \iffalse
-%</tikz-xetex-bidi.def>
%<*titlesec-xetex-bidi.def>
%\fi
% \subsection{\textsf{titlesec-xetex-bidi.def}}
@@ -19003,7 +19055,7 @@ to\rtside{\box\bslice\hfil}}
{\par\noindent\begin{tikzpicture}[remember picture]%
\draw node[inlinenotestyle] {};\end{tikzpicture}\par}%
\else%
- {\par\noindent\begin{bidi@tikzpicture}[remember picture]%
+ {\par\noindent\begin{tikzpicture}[remember picture]%
\if@bidi@todonotes@textdirection@RTL\else\setLTR\fi%
\draw node[inlinenotestyle,font=\@todonotes@sizecommand,align=\@bidi@todonotes@align]{%
\if@todonotes@authorgiven%
@@ -19011,12 +19063,12 @@ to\rtside{\box\bslice\hfil}}
\else%
{\noindent \@todonotes@sizecommand \@todonotes@text}%
\fi};%
- \end{bidi@tikzpicture}\par}%
+ \end{tikzpicture}\par}%
\fi}%
\renewcommand{\@todonotes@drawMarginNoteWithLine}{%
-\begin{bidi@tikzpicture}[remember picture, overlay, baseline=-0.75ex]%
+\begin{tikzpicture}[remember picture, overlay, baseline=-0.75ex]%
\node [coordinate] (inText) {};%
-\end{bidi@tikzpicture}%
+\end{tikzpicture}%
\marginpar[{% Draw note in left margin
\@todonotes@drawMarginNote%
\if@RTL\@todonotes@drawLineToRightMargin\else\@todonotes@drawLineToLeftMargin\fi%
@@ -19299,7 +19351,7 @@ to\rtside{\box\bslice\hfil}}
%\fi
% \subsection{\textsf{latex-xetex-bidi.def}}
% \begin{macrocode}
-\ProvidesFile{latex-xetex-bidi.def}[2015/11/07 v1.2.3 bidi adaptations for `latex.ltx' for XeTeX engine]
+\ProvidesFile{latex-xetex-bidi.def}[2015/11/14 v1.2.4 bidi adaptations for `latex.ltx' for XeTeX engine]
\newcommand{\TeXXeTOn}{\TeXXeTstate=1 }
\newcommand{\TeXXeTOff}{\TeXXeTstate=0 }
\TeXXeTOn
@@ -19997,8 +20049,8 @@ $\@@underline{\hbox{#1}}\m@th$\relax\fi\fi}
\@ifpackageloaded{pdfpages}{\input{pdfpages-xetex-bidi.def}}{}
\@ifpackageloaded{lettrine}{\input{lettrine-xetex-bidi.def}}{}
\@ifpackageloaded{listings}{\input{listings-xetex-bidi.def}}{}
-\@ifpackageloaded{pstricks}{\input{pstricks-xetex-bidi.def}}{}
-\@ifpackageloaded{pgf}{\input{pgf-xetex-bidi.def}}{}
+\@iftexfileloaded{pstricks}{\input{pstricks-xetex-bidi.def}}{}
+\@iftexfileloaded{pgfcorescopes.code}{\input{pgfcorescopes.code-xetex-bidi.def}}{}
\@ifpackageloaded{titlesec}{\input{titlesec-xetex-bidi.def}}{}
\@ifpackageloaded{titletoc}{\input{titletoc-xetex-bidi.def}}{}
\@ifpackageloaded{array}{\input{array-xetex-bidi.def}}{}
@@ -20046,7 +20098,6 @@ $\@@underline{\hbox{#1}}\m@th$\relax\fi\fi}
\@ifpackageloaded{tocbibind}{\@ifclassloaded{memoir}{}{\input{tocbibind-xetex-bidi.def}}}{}
\@ifpackageloaded{tocloft}{\@ifclassloaded{memoir}{}{\input{tocloft-xetex-bidi.def}}}{}
\@ifdefinitionfileloaded{tc-xetex}{\input{tc-xetex-bidi.def}}{}
-\@ifpackageloaded{tikz}{\input{tikz-xetex-bidi.def}}{}
\@ifpackageloaded{todonotes}{\input{todonotes-xetex-bidi.def}}{}
% \end{macrocode}
% \iffalse
diff --git a/Master/texmf-dist/source/xelatex/bidi/bidi.ins b/Master/texmf-dist/source/xelatex/bidi/bidi.ins
index a2f05af7f8b..97d676f3d8b 100644
--- a/Master/texmf-dist/source/xelatex/bidi/bidi.ins
+++ b/Master/texmf-dist/source/xelatex/bidi/bidi.ins
@@ -119,7 +119,7 @@
\generate{\file{ntheorem-xetex-bidi.def}{\from{\jobname.dtx}{table,ntheorem-xetex-bidi.def}}}
\generate{\file{ntheorem-hyper-xetex-bidi.def}{\from{\jobname.dtx}{table,ntheorem-hyper-xetex-bidi.def}}}
\generate{\file{pdfpages-xetex-bidi.def}{\from{\jobname.dtx}{table,pdfpages-xetex-bidi.def}}}
-\generate{\file{pgf-xetex-bidi.def}{\from{\jobname.dtx}{table,pgf-xetex-bidi.def}}}
+\generate{\file{pgfcorescopes.code-xetex-bidi.def}{\from{\jobname.dtx}{table,pgfcorescopes.code-xetex-bidi.def}}}
\generate{\file{picinpar-xetex-bidi.def}{\from{\jobname.dtx}{table,picinpar-xetex-bidi.def}}}
\generate{\file{plain-xetex-bidi.def}{\from{\jobname.dtx}{table,plain-xetex-bidi.def}}}
\generate{\file{pstricks-xetex-bidi.def}{\from{\jobname.dtx}{table,pstricks-xetex-bidi.def}}}
@@ -142,7 +142,6 @@
\generate{\file{tabularx-xetex-bidi.def}{\from{\jobname.dtx}{table,tabularx-xetex-bidi.def}}}
\generate{\file{tabulary-xetex-bidi.def}{\from{\jobname.dtx}{table,tabulary-xetex-bidi.def}}}
\generate{\file{tc-xetex-bidi.def}{\from{\jobname.dtx}{table,tc-xetex-bidi.def}}}
-\generate{\file{tikz-xetex-bidi.def}{\from{\jobname.dtx}{table,tikz-xetex-bidi.def}}}
\generate{\file{titlesec-xetex-bidi.def}{\from{\jobname.dtx}{table,titlesec-xetex-bidi.def}}}
\generate{\file{titletoc-xetex-bidi.def}{\from{\jobname.dtx}{table,titletoc-xetex-bidi.def}}}
\generate{\file{tocbibind-xetex-bidi.def}{\from{\jobname.dtx}{table,tocbibind-xetex-bidi.def}}}