summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/source/xelatex
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2016-05-10 21:32:55 +0000
committerKarl Berry <karl@freefriends.org>2016-05-10 21:32:55 +0000
commit2bdc503b5e600981a5e34b591b90015d7485d086 (patch)
treeacca040d207ffcf1cace1db445b04bf9e365a33d /Master/texmf-dist/source/xelatex
parent54f636c57e0099a927e9c6093e67c97562a011a7 (diff)
bidi (10may16)
git-svn-id: svn://tug.org/texlive/trunk@41016 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/source/xelatex')
-rw-r--r--Master/texmf-dist/source/xelatex/bidi/bidi.dtx494
1 files changed, 340 insertions, 154 deletions
diff --git a/Master/texmf-dist/source/xelatex/bidi/bidi.dtx b/Master/texmf-dist/source/xelatex/bidi/bidi.dtx
index 7e28f0781c9..cf614a6080a 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
-v19.4
+v19.5
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: 2016/05/09
+Current version release date: 2016/05/10
___________________
Vafa Khalighi
@@ -322,7 +322,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 19.4}}
+%\large Documentation for \textcolor{blue!65!black}{version 19.5}}
% \author{Vafa Khalighi\\
% \url{persian-tex@tug.org}}
%\setcounter{page}{0}
@@ -333,7 +333,7 @@ by Vafa Khalighi.
%\textcolor{blue!65!black}{\Huge The \textsf{bidi} \textit{Package}}
%
%\Large
-%Documentation for \textcolor{blue!65!black}{version 19.4}}
+%Documentation for \textcolor{blue!65!black}{version 19.5}}
%
%\vskip 0pt plus 3fill
%\textit{\large to my Master, \textbf{Ferdowsi The Great}}
@@ -384,7 +384,7 @@ by Vafa Khalighi.
%*
%* Copyright (c) 2009--2016 Vafa Khalighi
%*
-%* 2016/05/09, v19.4
+%* 2016/05/10, v19.5
%*
%* License: LaTeX Project Public License, version
%* 1.3c or higher (your choice)
@@ -1141,7 +1141,7 @@ by Vafa Khalighi.
%\iffalse
%<*table>
%\fi
-%% \CheckSum{46457}
+%% \CheckSum{46913}
%% \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
@@ -2984,8 +2984,8 @@ by Vafa Khalighi.
% \subsection{\textsf{bidi.sty}}
% \begin{macrocode}
\NeedsTeXFormat{LaTeX2e}
-\def\bididate{2016/05/09}
-\def\bidiversion{v19.4}
+\def\bididate{2016/05/10}
+\def\bidiversion{v19.5}
\ProvidesPackage{bidi}[\bididate\space \bidiversion\space
Bidirectional typesetting in plain TeX and LaTeX]
\edef\@bidi@info{****************************************************^^J%
@@ -8135,20 +8135,40 @@ bidi implementation of tufte title]
%\fi
% \subsection{\textsf{cuted-xetex-bidi.def}}
% \begin{macrocode}
-\ProvidesFile{cuted-xetex-bidi.def}[2013/04/10 v0.3 bidi adaptations for cuted package for XeTeX engine]
+\ProvidesFile{cuted-xetex-bidi.def}[2016/05/10 v0.4 bidi adaptations for cuted package for XeTeX engine]
+
\def\RTL@outputdblcol{%
-\if@firstcolumn \global\@firstcolumnfalse
-\global\setbox\@leftcolumn \box\@outputbox
- \else
- \global\@firstcolumntrue
-\setbox\@outputbox \vbox {\hbox to\textwidth {%
-\hskip \columnwidth
-\hfil \vrule width\columnseprule \hfil
-\hbox to\columnwidth {\box\@leftcolumn \hss}%
-\hskip -\textwidth
-\hbox to\columnwidth{\box\@outputbox \hss}%
-\hskip \columnsep
-\hskip \columnwidth }}%
+ \if@firstcolumn
+ \global\@firstcolumnfalse
+ \global\setbox\@leftcolumn\copy\@outputbox
+ \splitmaxdepth\maxdimen
+ \vbadness\maxdimen
+ \setbox\@outputbox\vbox{\unvbox\@outputbox\unskip}%
+ \setbox\@outputbox\vsplit\@outputbox to\maxdimen
+ \toks@\expandafter{\topmark}%
+ \xdef\@firstcoltopmark{\the\toks@}%
+ \toks@\expandafter{\splitfirstmark}%
+ \xdef\@firstcolfirstmark{\the\toks@}%
+ \ifx\@firstcolfirstmark\@empty
+ \global\let\@setmarks\relax
+ \else
+ \gdef\@setmarks{%
+ \let\firstmark\@firstcolfirstmark
+ \let\topmark\@firstcoltopmark}%
+ \fi
+ \else
+ \global\@firstcolumntrue
+ \setbox\@outputbox\vbox{%
+ \hb@xt@\textwidth{%
+ \hskip \columnwidth
+ \hfil
+ {\normalcolor\vrule \@width\columnseprule}%
+ \hfil
+ \hb@xt@\columnwidth{\box\@leftcolumn \hss}%
+ \hskip -\textwidth
+ \hb@xt@\columnwidth{\box\@outputbox \hss}%
+ \hskip \columnsep
+ \hskip \columnwidth }}%
\ifvoid\hold@viper
\else
\setbox\@outputbox \vbox to\textheight{%
@@ -8157,10 +8177,14 @@ bidi implementation of tufte title]
\vss
}%
\fi
-\@combinedblfloats \@outputpage
-\begingroup \@dblfloatplacement \@startdblcolumn
-\@whilesw\if@fcolmade \fi
-{\@outputpage \@startdblcolumn }%
+ \@combinedblfloats
+ \@setmarks
+ \@outputpage
+ \begingroup
+ \@dblfloatplacement
+ \@startdblcolumn
+ \@whilesw\if@fcolmade \fi{\@outputpage
+ \@startdblcolumn}%
\ifvoid\@viper
\else
\global\setbox\@viper\vbox{%
@@ -8169,25 +8193,37 @@ bidi implementation of tufte title]
}%
\@viperoutput
\fi
-\endgroup
-\fi}
+ \endgroup
+ \fi}%
+
\def\LTR@outputdblcol{%
\if@firstcolumn
- \global \@firstcolumnfalse
- \global \setbox\@leftcolumn \box\@outputbox
- \else
- \global\@firstcolumntrue
- \setbox\@outputbox \vbox {%
- \hb@xt@\textwidth {%
- \hb@xt@\columnwidth {%
- \box\@leftcolumn \hss}%
- \hfil
- \vrule \@width\columnseprule
- \hfil
- \hb@xt@\columnwidth {%
- \box\@outputbox \hss}%
- }%
- }%
+ \global\@firstcolumnfalse
+ \global\setbox\@leftcolumn\copy\@outputbox
+ \splitmaxdepth\maxdimen
+ \vbadness\maxdimen
+ \setbox\@outputbox\vbox{\unvbox\@outputbox\unskip}%
+ \setbox\@outputbox\vsplit\@outputbox to\maxdimen
+ \toks@\expandafter{\topmark}%
+ \xdef\@firstcoltopmark{\the\toks@}%
+ \toks@\expandafter{\splitfirstmark}%
+ \xdef\@firstcolfirstmark{\the\toks@}%
+ \ifx\@firstcolfirstmark\@empty
+ \global\let\@setmarks\relax
+ \else
+ \gdef\@setmarks{%
+ \let\firstmark\@firstcolfirstmark
+ \let\topmark\@firstcoltopmark}%
+ \fi
+ \else
+ \global\@firstcolumntrue
+ \setbox\@outputbox\vbox{%
+ \hb@xt@\textwidth{%
+ \hb@xt@\columnwidth{\box\@leftcolumn \hss}%
+ \hfil
+ {\normalcolor\vrule \@width\columnseprule}%
+ \hfil
+ \hb@xt@\columnwidth{\box\@outputbox \hss}}}%
\ifvoid\hold@viper
\else
\setbox\@outputbox \vbox to\textheight{%
@@ -8196,14 +8232,14 @@ bidi implementation of tufte title]
\vss
}%
\fi
- \@combinedblfloats
+ \@combinedblfloats
+ \@setmarks
\@outputpage
\begingroup
\@dblfloatplacement
\@startdblcolumn
- \@whilesw\if@fcolmade \fi
- {\@outputpage
- \@startdblcolumn}%
+ \@whilesw\if@fcolmade \fi{\@outputpage
+ \@startdblcolumn}%
\ifvoid\@viper
\else
\global\setbox\@viper\vbox{%
@@ -8213,8 +8249,9 @@ bidi implementation of tufte title]
\@viperoutput
\fi
\endgroup
- \fi
- }
+ \fi}%
+
+
\def \@addviper {%
\if@firstcolumn
\@insertfalse
@@ -9525,7 +9562,7 @@ bidi implementation of tufte title]
%\fi
% \subsection{\textsf{extrafootnotefeatures-xetex-bidi.def}}
% \begin{macrocode}
-\ProvidesFile{extrafootnotefeatures-xetex-bidi.def}[2016/05/09 v0.9 bidi extra footnote features for XeTeX engine]
+\ProvidesFile{extrafootnotefeatures-xetex-bidi.def}[2016/05/10 v1 bidi extra footnote features for XeTeX engine]
\let\autofootnoterule\relax
\let\rightfootnoterule\relax
\let\leftfootnoterule\relax
@@ -9652,6 +9689,8 @@ bidi implementation of tufte title]
\bidi@ensure@newlength{\footmarksep}
\bidi@ensure@newlength{\footparindent}
\bidi@ensure@newcommand*{\footmarkstyle}[1]{\def\footscript##1{#1}}
+\bidi@ensure@newcommand*{\LTRfootmarkstyle}[1]{\def\LTRfootscript##1{#1}}
+\bidi@ensure@newcommand*{\RTLfootmarkstyle}[1]{\def\RTLfootscript##1{#1}}
\bidi@ensure@newcommand{\footfootmark}{%
\ifdim\footmarkwidth < \z@
\llap{\hb@xt@ -\footmarkwidth{%
@@ -9664,7 +9703,33 @@ bidi implementation of tufte title]
\hb@xt@\footmarkwidth{\hss\normalfont\footscript{\@thefnmark}}%
\fi
\fi}
+\bidi@ensure@newcommand{\LTRfootfootmark}{%
+ \ifdim\footmarkwidth < \z@
+ \llap{\hb@xt@ -\footmarkwidth{%
+ \hss\normalfont\LTRfootscript{\@thefnmark}}%
+ \hspace*{-\footmarkwidth}}%
+ \else
+ \ifdim\footmarkwidth = \z@
+ {\normalfont\LTRfootscript{\@thefnmark}}%
+ \else
+ \hb@xt@\footmarkwidth{\hss\normalfont\LTRfootscript{\@thefnmark}}%
+ \fi
+ \fi}
+\bidi@ensure@newcommand{\RTLfootfootmark}{%
+ \ifdim\footmarkwidth < \z@
+ \llap{\hb@xt@ -\footmarkwidth{%
+ \hss\normalfont\RTLfootscript{\@thefnmark}}%
+ \hspace*{-\footmarkwidth}}%
+ \else
+ \ifdim\footmarkwidth = \z@
+ {\normalfont\RTLfootscript{\@thefnmark}}%
+ \else
+ \hb@xt@\footmarkwidth{\hss\normalfont\RTLfootscript{\@thefnmark}}%
+ \fi
+ \fi}
\footmarkstyle{\textsuperscript{#1}}
+\LTRfootmarkstyle{\textsuperscript{#1}}
+\RTLfootmarkstyle{\textsuperscript{#1}}
\setlength{\footmarkwidth}{1em plus.4em minus.4em}
\setlength{\footparindent}{1em}
\bidi@ensure@newcommand{\m@mdoextrafeet}{\extrafeetins}
@@ -9795,10 +9860,10 @@ bidi implementation of tufte title]
{\footfootmark\strut {\foottextfont #1}\strut\par}\allowbreak}
\bidi@ensure@newcommand{\@twocolLTRfootfmt}[1]{%
\@preamtwofmt
- {\footfootmark\strut {\LTRfoottextfont #1}\strut\par}\allowbreak}
+ {\LTRfootfootmark\strut {\LTRfoottextfont #1}\strut\par}\allowbreak}
\bidi@ensure@newcommand{\@twocolRTLfootfmt}[1]{%
\@preamtwofmt
- {\footfootmark\strut {\RTLfoottextfont #1}\strut\par}\allowbreak}
+ {\RTLfootfootmark\strut {\RTLfoottextfont #1}\strut\par}\allowbreak}
\bidi@ensure@newcommand{\@mptwocolfootnotetext}[1]{%
\global\setbox\@mpfootinsv@r\vbox{\if@RTL@footnote\@RTLtrue\else\@RTLfalse\fi%
\unvbox\@mpfootinsv@r
@@ -9941,10 +10006,10 @@ bidi implementation of tufte title]
{\footfootmark\strut {\foottextfont #1}\strut\par}\allowbreak}
\bidi@ensure@newcommand{\@threecolLTRfootfmt}[1]{%
\@preamthreefmt
- {\footfootmark\strut {\LTRfoottextfont #1}\strut\par}\allowbreak}
+ {\LTRfootfootmark\strut {\LTRfoottextfont #1}\strut\par}\allowbreak}
\bidi@ensure@newcommand{\@threecolRTLfootfmt}[1]{%
\@preamthreefmt
- {\footfootmark\strut {\RTLfoottextfont #1}\strut\par}\allowbreak}
+ {\RTLfootfootmark\strut {\RTLfoottextfont #1}\strut\par}\allowbreak}
\bidi@ensure@newcommand{\@mpthreecolfootnotetext}[1]{%
\global\setbox\@mpfootinsv@r\vbox{\if@RTL@footnote\@RTLtrue\else\@RTLfalse\fi%
\unvbox\@mpfootinsv@r
@@ -10086,10 +10151,10 @@ bidi implementation of tufte title]
{\footfootmark\strut {\foottextfont #1}\strut\par}\allowbreak}
\bidi@ensure@newcommand{\@fourcolLTRfootfmt}[1]{%
\@preamfourfmt
- {\footfootmark\strut {\LTRfoottextfont #1}\strut\par}\allowbreak}
+ {\LTRfootfootmark\strut {\LTRfoottextfont #1}\strut\par}\allowbreak}
\bidi@ensure@newcommand{\@fourcolRTLfootfmt}[1]{%
\@preamfourfmt
- {\footfootmark\strut {\RTLfoottextfont #1}\strut\par}\allowbreak}
+ {\RTLfootfootmark\strut {\RTLfoottextfont #1}\strut\par}\allowbreak}
\bidi@ensure@newcommand{\@mpfourcolfootnotetext}[1]{%
\global\setbox\@mpfootinsv@r\vbox{\if@RTL@footnote\@RTLtrue\else\@RTLfalse\fi%
\unvbox\@mpfootinsv@r
@@ -10235,10 +10300,10 @@ bidi implementation of tufte title]
{\footfootmark\strut {\foottextfont #1}\strut\par}\allowbreak}
\bidi@ensure@newcommand{\@fivecolLTRfootfmt}[1]{%
\@preamfivefmt
- {\footfootmark\strut {\LTRfoottextfont #1}\strut\par}\allowbreak}
+ {\LTRfootfootmark\strut {\LTRfoottextfont #1}\strut\par}\allowbreak}
\bidi@ensure@newcommand{\@fivecolRTLfootfmt}[1]{%
\@preamfivefmt
- {\footfootmark\strut {\RTLfoottextfont #1}\strut\par}\allowbreak}
+ {\RTLfootfootmark\strut {\RTLfoottextfont #1}\strut\par}\allowbreak}
\bidi@ensure@newcommand{\@mpfivecolfootnotetext}[1]{%
\global\setbox\@mpfootinsv@r\vbox{\if@RTL@footnote\@RTLtrue\else\@RTLfalse\fi%
\unvbox\@mpfootinsv@r
@@ -10384,10 +10449,10 @@ bidi implementation of tufte title]
{\footfootmark\strut {\foottextfont #1}\strut\par}\allowbreak}
\bidi@ensure@newcommand{\@sixcolLTRfootfmt}[1]{%
\@preamsixfmt
- {\footfootmark\strut {\LTRfoottextfont #1}\strut\par}\allowbreak}
+ {\LTRfootfootmark\strut {\LTRfoottextfont #1}\strut\par}\allowbreak}
\bidi@ensure@newcommand{\@sixcolRTLfootfmt}[1]{%
\@preamsixfmt
- {\footfootmark\strut {\RTLfoottextfont #1}\strut\par}\allowbreak}
+ {\RTLfootfootmark\strut {\RTLfoottextfont #1}\strut\par}\allowbreak}
\bidi@ensure@newcommand{\@mpsixcolfootnotetext}[1]{\if@RTL@footnote\@RTLtrue\else\@RTLfalse\fi%
\global\setbox\@mpfootinsv@r\vbox{%
\unvbox\@mpfootinsv@r
@@ -10533,10 +10598,10 @@ bidi implementation of tufte title]
{\footfootmark\strut {\foottextfont #1}\strut\par}\allowbreak}
\bidi@ensure@newcommand{\@sevencolLTRfootfmt}[1]{%
\@preamsevenfmt
- {\footfootmark\strut {\LTRfoottextfont #1}\strut\par}\allowbreak}
+ {\LTRfootfootmark\strut {\LTRfoottextfont #1}\strut\par}\allowbreak}
\bidi@ensure@newcommand{\@sevencolRTLfootfmt}[1]{%
\@preamsevenfmt
- {\footfootmark\strut {\RTLfoottextfont #1}\strut\par}\allowbreak}
+ {\RTLfootfootmark\strut {\RTLfoottextfont #1}\strut\par}\allowbreak}
\bidi@ensure@newcommand{\@mpsevencolfootnotetext}[1]{\if@RTL@footnote\@RTLtrue\else\@RTLfalse\fi%
\global\setbox\@mpfootinsv@r\vbox{%
\unvbox\@mpfootinsv@r
@@ -10682,10 +10747,10 @@ bidi implementation of tufte title]
{\footfootmark\strut {\foottextfont #1}\strut\par}\allowbreak}
\bidi@ensure@newcommand{\@eightcolLTRfootfmt}[1]{%
\@preameightfmt
- {\footfootmark\strut {\LTRfoottextfont #1}\strut\par}\allowbreak}
+ {\LTRfootfootmark\strut {\LTRfoottextfont #1}\strut\par}\allowbreak}
\bidi@ensure@newcommand{\@eightcolRTLfootfmt}[1]{%
\@preameightfmt
- {\footfootmark\strut {\RTLfoottextfont #1}\strut\par}\allowbreak}
+ {\RTLfootfootmark\strut {\RTLfoottextfont #1}\strut\par}\allowbreak}
\bidi@ensure@newcommand{\@mpeightcolfootnotetext}[1]{%
\global\setbox\@mpfootinsv@r\vbox{\if@RTL@footnote\@RTLtrue\else\@RTLfalse\fi%
\unvbox\@mpfootinsv@r
@@ -10831,10 +10896,10 @@ bidi implementation of tufte title]
{\footfootmark\strut {\foottextfont #1}\strut\par}\allowbreak}
\bidi@ensure@newcommand{\@ninecolLTRfootfmt}[1]{%
\@preamninefmt
- {\footfootmark\strut {\LTRfoottextfont #1}\strut\par}\allowbreak}
+ {\LTRfootfootmark\strut {\LTRfoottextfont #1}\strut\par}\allowbreak}
\bidi@ensure@newcommand{\@ninecolRTLfootfmt}[1]{%
\@preamninefmt
- {\footfootmark\strut {\RTLfoottextfont #1}\strut\par}\allowbreak}
+ {\RTLfootfootmark\strut {\RTLfoottextfont #1}\strut\par}\allowbreak}
\bidi@ensure@newcommand{\@mpninecolfootnotetext}[1]{%
\global\setbox\@mpfootinsv@r\vbox{\if@RTL@footnote\@RTLtrue\else\@RTLfalse\fi%
\unvbox\@mpfootinsv@r
@@ -10980,10 +11045,10 @@ bidi implementation of tufte title]
{\footfootmark\strut {\foottextfont #1}\strut\par}\allowbreak}
\bidi@ensure@newcommand{\@tencolLTRfootfmt}[1]{%
\@preamtenfmt
- {\footfootmark\strut {\LTRfoottextfont #1}\strut\par}\allowbreak}
+ {\LTRfootfootmark\strut {\LTRfoottextfont #1}\strut\par}\allowbreak}
\bidi@ensure@newcommand{\@tencolRTLfootfmt}[1]{%
\@preamtenfmt
- {\footfootmark\strut {\RTLfoottextfont #1}\strut\par}\allowbreak}
+ {\RTLfootfootmark\strut {\RTLfoottextfont #1}\strut\par}\allowbreak}
\bidi@ensure@newcommand{\@mptencolfootnotetext}[1]{%
\global\setbox\@mpfootinsv@r\vbox{\if@RTL@footnote\@RTLtrue\else\@RTLfalse\fi%
\unvbox\@mpfootinsv@r
@@ -11180,11 +11245,11 @@ bidi implementation of tufte title]
\bidi@ensure@newcommand{\@paraLTRfootfmt}[1]{%
\parindent=\z@
\parfillskip=0pt \@plus 1fil
- {\footfootmark\strut {\LTRfoottextfont #1}\penalty-10}}
+ {\LTRfootfootmark\strut {\LTRfoottextfont #1}\penalty-10}}
\bidi@ensure@newcommand{\@paraRTLfootfmt}[1]{%
\parindent=\z@
\parfillskip=0pt \@plus 1fil
- {\footfootmark\strut {\RTLfoottextfont #1}\penalty-10}}
+ {\RTLfootfootmark\strut {\RTLfoottextfont #1}\penalty-10}}
\bidi@ensure@newcommand{\@mpparafootnotetext}[1]{%
\global\setbox\@mpfootinsv@r\vbox{%
\let\bidi@RTL@everypar\@empty%
@@ -12422,51 +12487,100 @@ bidi implementation of tufte title]
%\fi
% \subsection{\textsf{ftnright-xetex-bidi.def}}
% \begin{macrocode}
-\ProvidesFile{ftnright-xetex-bidi.def}[2013/04/10 v0.3 bidi adaptations for ftnright package for XeTeX engine]
-\def\LTR@outputdblcol{\if@firstcolumn
- \global\@firstcolumnfalse
- \global\setbox\@leftcolumn\box\@outputbox
- \global\count\footins\@m
- \global\skip\footins\rcol@footinsskip
- \else \preparefootins
- \global\@firstcolumntrue
- \setbox\@outputbox\vbox{\hbox to\textwidth
- {\hbox to\columnwidth
- {\box\@leftcolumn\hss}%
- \hfil\vrule\@width\columnseprule\hfil
- \hbox to\columnwidth
- {\box\@outputbox\hss}}}%
- \@combinedblfloats\@outputpage
- \begingroup
- \@dblfloatplacement\@startdblcolumn
- \@whilesw\if@fcolmade\fi
- {\@outputpage\@startdblcolumn}%
- \endgroup
- \fi}
- \def\RTL@outputdblcol{\if@firstcolumn
- \global\@firstcolumnfalse
- \global\setbox\@leftcolumn\box\@outputbox
- \global\count\footins\@m
- \global\skip\footins\rcol@footinsskip
- \else \preparefootins
- \global\@firstcolumntrue
- \setbox\@outputbox\vbox{\hbox to\textwidth
- {\hskip \columnwidth
- \hfil \vrule width\columnseprule \hfil
- \hbox to\columnwidth
- {\box\@leftcolumn\hss}%
- \hskip -\textwidth
- \hbox to\columnwidth
- {\box\@outputbox\hss}
- \hskip \columnsep
- \hskip \columnwidth}}%
- \@combinedblfloats\@outputpage
- \begingroup
- \@dblfloatplacement\@startdblcolumn
- \@whilesw\if@fcolmade\fi
- {\@outputpage\@startdblcolumn}%
- \endgroup
- \fi}
+\ProvidesFile{ftnright-xetex-bidi.def}[2016/05/10 v0.4 bidi adaptations for ftnright package for XeTeX engine]
+
+\def\LTR@outputdblcol{%
+ \if@firstcolumn
+ \global\@firstcolumnfalse
+ \global\setbox\@leftcolumn\copy\@outputbox
+ \global\count\footins\@m
+ \global\skip\footins\rcol@footinsskip
+ \splitmaxdepth\maxdimen
+ \vbadness\maxdimen
+ \setbox\@outputbox\vbox{\unvbox\@outputbox\unskip}%
+ \setbox\@outputbox\vsplit\@outputbox to\maxdimen
+ \toks@\expandafter{\topmark}%
+ \xdef\@firstcoltopmark{\the\toks@}%
+ \toks@\expandafter{\splitfirstmark}%
+ \xdef\@firstcolfirstmark{\the\toks@}%
+ \ifx\@firstcolfirstmark\@empty
+ \global\let\@setmarks\relax
+ \else
+ \gdef\@setmarks{%
+ \let\firstmark\@firstcolfirstmark
+ \let\topmark\@firstcoltopmark}%
+ \fi
+ \else
+ \preparefootins
+ \global\@firstcolumntrue
+ \setbox\@outputbox\vbox{%
+ \hb@xt@\textwidth{%
+ \hb@xt@\columnwidth{\box\@leftcolumn \hss}%
+ \hfil
+ {\normalcolor\vrule \@width\columnseprule}%
+ \hfil
+ \hb@xt@\columnwidth{\box\@outputbox \hss}}}%
+ \@combinedblfloats
+ \@setmarks
+ \@outputpage
+ \begingroup
+ \@dblfloatplacement
+ \@startdblcolumn
+ \@whilesw\if@fcolmade \fi{\@outputpage
+ \@startdblcolumn}%
+ \endgroup
+ \fi}%
+
+
+
+\def\RTL@outputdblcol{%
+ \if@firstcolumn
+ \global\@firstcolumnfalse
+ \global\setbox\@leftcolumn\copy\@outputbox
+ \global\count\footins\@m
+ \global\skip\footins\rcol@footinsskip
+ \splitmaxdepth\maxdimen
+ \vbadness\maxdimen
+ \setbox\@outputbox\vbox{\unvbox\@outputbox\unskip}%
+ \setbox\@outputbox\vsplit\@outputbox to\maxdimen
+ \toks@\expandafter{\topmark}%
+ \xdef\@firstcoltopmark{\the\toks@}%
+ \toks@\expandafter{\splitfirstmark}%
+ \xdef\@firstcolfirstmark{\the\toks@}%
+ \ifx\@firstcolfirstmark\@empty
+ \global\let\@setmarks\relax
+ \else
+ \gdef\@setmarks{%
+ \let\firstmark\@firstcolfirstmark
+ \let\topmark\@firstcoltopmark}%
+ \fi
+ \else
+ \preparefootins
+ \global\@firstcolumntrue
+ \setbox\@outputbox\vbox{%
+ \hb@xt@\textwidth{%
+ \hskip \columnwidth
+ \hfil
+ {\normalcolor\vrule \@width\columnseprule}%
+ \hfil
+ \hb@xt@\columnwidth{\box\@leftcolumn \hss}%
+ \hskip -\textwidth
+ \hb@xt@\columnwidth{\box\@outputbox \hss}%
+ \hskip \columnsep
+ \hskip \columnwidth }}%
+ \@combinedblfloats
+ \@setmarks
+ \@outputpage
+ \begingroup
+ \@dblfloatplacement
+ \@startdblcolumn
+ \@whilesw\if@fcolmade \fi{\@outputpage
+ \@startdblcolumn}%
+ \endgroup
+ \fi}%
+
+
+
\let\leftfootnoterule\@empty
\let\rightfootnoterule\@empty
\let\textwidthfootnoterule\@empty
@@ -14978,11 +15092,26 @@ bidi implementation of tufte title]
%\fi
% \subsection{\textsf{midfloat-xetex-bidi.def}}
% \begin{macrocode}
-\ProvidesFile{midfloat-xetex-bidi.def}[2013/04/10 v0.2 bidi adaptations for midfloat package for XeTeX engine]
+\ProvidesFile{midfloat-xetex-bidi.def}[2016/05/10 v0.3 bidi adaptations for midfloat package for XeTeX engine]
\def\RTL@outputdblcol{%
\if@firstcolumn
\global \@firstcolumnfalse
- \global \setbox\@leftcolumn \box\@outputbox
+ \global\setbox\@leftcolumn\copy\@outputbox
+ \splitmaxdepth\maxdimen
+ \vbadness\maxdimen
+ \setbox\@outputbox\vbox{\unvbox\@outputbox\unskip}%
+ \setbox\@outputbox\vsplit\@outputbox to\maxdimen
+ \toks@\expandafter{\topmark}%
+ \xdef\@firstcoltopmark{\the\toks@}%
+ \toks@\expandafter{\splitfirstmark}%
+ \xdef\@firstcolfirstmark{\the\toks@}%
+ \ifx\@firstcolfirstmark\@empty
+ \global\let\@setmarks\relax
+ \else
+ \gdef\@setmarks{%
+ \let\firstmark\@firstcolfirstmark
+ \let\topmark\@firstcoltopmark}%
+ \fi
\global\c@colht\@colht\global\c@addvipersep\z@
\ifnum\juo@sk>0
\remove@strip\juo@sar
@@ -15046,6 +15175,7 @@ bidi implementation of tufte title]
\hskip\columnsep}%
}%
\@combinedblfloats
+ \@setmarks
\@outputpage
\begingroup
\@dblfloatplacement
@@ -15064,7 +15194,22 @@ bidi implementation of tufte title]
\def\LTR@outputdblcol{%
\if@firstcolumn
\global \@firstcolumnfalse
- \global \setbox\@leftcolumn \box\@outputbox
+ \global\setbox\@leftcolumn\copy\@outputbox
+ \splitmaxdepth\maxdimen
+ \vbadness\maxdimen
+ \setbox\@outputbox\vbox{\unvbox\@outputbox\unskip}%
+ \setbox\@outputbox\vsplit\@outputbox to\maxdimen
+ \toks@\expandafter{\topmark}%
+ \xdef\@firstcoltopmark{\the\toks@}%
+ \toks@\expandafter{\splitfirstmark}%
+ \xdef\@firstcolfirstmark{\the\toks@}%
+ \ifx\@firstcolfirstmark\@empty
+ \global\let\@setmarks\relax
+ \else
+ \gdef\@setmarks{%
+ \let\firstmark\@firstcolfirstmark
+ \let\topmark\@firstcoltopmark}%
+ \fi
\global\c@colht\@colht\global\c@addvipersep\z@
\ifnum\juo@sk>0
\remove@strip\juo@sar
@@ -15125,6 +15270,7 @@ bidi implementation of tufte title]
}%
}%
\@combinedblfloats
+ \@setmarks
\@outputpage
\begingroup
\@dblfloatplacement
@@ -20340,7 +20486,7 @@ to\rtside{\box\bslice\hfil}}
%\fi
% \subsection{\textsf{latex-xetex-bidi.def}}
% \begin{macrocode}
-\ProvidesFile{latex-xetex-bidi.def}[2015/11/14 v1.2.4 bidi adaptations for `latex.ltx' for XeTeX engine]
+\ProvidesFile{latex-xetex-bidi.def}[2016/05/10 v1.2.5 bidi adaptations for `latex.ltx' for XeTeX engine]
\newcommand{\TeXXeTOn}{\TeXXeTstate=1 }
\newcommand{\TeXXeTOff}{\TeXXeTstate=0 }
\TeXXeTOn
@@ -20681,51 +20827,91 @@ $\@@underline{\hbox{#1}}\m@th$\relax\fi\fi}
\hb@xt@\@pnumwidth{{\hfil\normalfont \normalcolor #5}}%
\par}%
\fi}
+
+
\def\RTL@outputdblcol{%
-\if@firstcolumn \global\@firstcolumnfalse
-\global\setbox\@leftcolumn \box\@outputbox
-\else \global\@firstcolumntrue
-\setbox\@outputbox \vbox {\hbox to\textwidth {%
-\hskip \columnwidth
-\hfil \vrule width\columnseprule \hfil
-\hbox to\columnwidth {\box\@leftcolumn \hss}%
-\hskip -\textwidth
-\hbox to\columnwidth{\box\@outputbox \hss}%
-\hskip \columnsep
-\hskip \columnwidth }}%
-\@combinedblfloats \@outputpage
-\begingroup \@dblfloatplacement \@startdblcolumn
-\@whilesw\if@fcolmade \fi
-{\@outputpage \@startdblcolumn }\endgroup
-\fi}
+ \if@firstcolumn
+ \global\@firstcolumnfalse
+ \global\setbox\@leftcolumn\copy\@outputbox
+ \splitmaxdepth\maxdimen
+ \vbadness\maxdimen
+ \setbox\@outputbox\vbox{\unvbox\@outputbox\unskip}%
+ \setbox\@outputbox\vsplit\@outputbox to\maxdimen
+ \toks@\expandafter{\topmark}%
+ \xdef\@firstcoltopmark{\the\toks@}%
+ \toks@\expandafter{\splitfirstmark}%
+ \xdef\@firstcolfirstmark{\the\toks@}%
+ \ifx\@firstcolfirstmark\@empty
+ \global\let\@setmarks\relax
+ \else
+ \gdef\@setmarks{%
+ \let\firstmark\@firstcolfirstmark
+ \let\topmark\@firstcoltopmark}%
+ \fi
+ \else
+ \global\@firstcolumntrue
+ \setbox\@outputbox\vbox{%
+ \hb@xt@\textwidth{%
+ \hskip \columnwidth
+ \hfil
+ {\normalcolor\vrule \@width\columnseprule}%
+ \hfil
+ \hb@xt@\columnwidth{\box\@leftcolumn \hss}%
+ \hskip -\textwidth
+ \hb@xt@\columnwidth{\box\@outputbox \hss}%
+ \hskip \columnsep
+ \hskip \columnwidth }}%
+ \@combinedblfloats
+ \@setmarks
+ \@outputpage
+ \begingroup
+ \@dblfloatplacement
+ \@startdblcolumn
+ \@whilesw\if@fcolmade \fi{\@outputpage
+ \@startdblcolumn}%
+ \endgroup
+ \fi}%
+
\def\LTR@outputdblcol{%
\if@firstcolumn
- \global \@firstcolumnfalse
- \global \setbox\@leftcolumn \box\@outputbox
+ \global\@firstcolumnfalse
+ \global\setbox\@leftcolumn\copy\@outputbox
+ \splitmaxdepth\maxdimen
+ \vbadness\maxdimen
+ \setbox\@outputbox\vbox{\unvbox\@outputbox\unskip}%
+ \setbox\@outputbox\vsplit\@outputbox to\maxdimen
+ \toks@\expandafter{\topmark}%
+ \xdef\@firstcoltopmark{\the\toks@}%
+ \toks@\expandafter{\splitfirstmark}%
+ \xdef\@firstcolfirstmark{\the\toks@}%
+ \ifx\@firstcolfirstmark\@empty
+ \global\let\@setmarks\relax
+ \else
+ \gdef\@setmarks{%
+ \let\firstmark\@firstcolfirstmark
+ \let\topmark\@firstcoltopmark}%
+ \fi
\else
- \global \@firstcolumntrue
- \setbox\@outputbox \vbox {%
- \hb@xt@\textwidth {%
- \hb@xt@\columnwidth {%
- \box\@leftcolumn \hss}%
- \hfil
- {\normalcolor\vrule \@width\columnseprule}%
- \hfil
- \hb@xt@\columnwidth {%
- \box\@outputbox \hss}%
- }%
- }%
- \@combinedblfloats
+ \global\@firstcolumntrue
+ \setbox\@outputbox\vbox{%
+ \hb@xt@\textwidth{%
+ \hb@xt@\columnwidth{\box\@leftcolumn \hss}%
+ \hfil
+ {\normalcolor\vrule \@width\columnseprule}%
+ \hfil
+ \hb@xt@\columnwidth{\box\@outputbox \hss}}}%
+ \@combinedblfloats
+ \@setmarks
\@outputpage
\begingroup
\@dblfloatplacement
\@startdblcolumn
- \@whilesw\if@fcolmade \fi
- {\@outputpage
- \@startdblcolumn}%
+ \@whilesw\if@fcolmade \fi{\@outputpage
+ \@startdblcolumn}%
\endgroup
- \fi
-}
+ \fi}%
+
+
\renewcommand{\@outputdblcol}{\if@RTLmain\RTL@outputdblcol\else\LTR@outputdblcol\fi}
\newcommand{\RTLdblcol}{\renewcommand{\@outputdblcol}{\RTL@outputdblcol}}
\newcommand{\LTRdblcol}{\renewcommand{\@outputdblcol}{\LTR@outputdblcol}}