summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/tex/latex/bidi/arydshln-xetex-bidi.def
blob: a5ea2a272f6e81f1e2014ccaa44282aeb87d175f (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
%%
%% This is file `arydshln-xetex-bidi.def',
%% generated with the docstrip utility.
%%
%% The original source files were:
%%
%% bidi.dtx  (with options: `arydshln-xetex-bidi.def')
%% 
%%   ______________________________________
%%   Copyright © 2009–2011  VAFA KHALIGHI
%% 
%%   License information appended.
%% 
%% 
\ProvidesFile{arydshln-xetex-bidi.def}[2010/08/01 v0.2 bidi adaptations for arydshln package for XeTeX engine]
\def\endarray{\adl@endarray \egroup \adl@arrayrestore \if@RTLtab\egroup\endR\egroup\fi\egroup}
\def\endtabular{\endarray $\if@RTLtab\endR\fi\egroup\@RTLtabfalse}
\expandafter\let\csname endtabular*\endcsname\endtabular
\let\adl@array\@array
\def\@array{\adl@everyvbox\everyvbox
        \everyvbox{\adl@arrayinit \the\adl@everyvbox \everyvbox\adl@everyvbox}%
        \ifadl@inactive \adl@inactivate \else \adl@activate \fi
        \let\adl@noalign\noalign
        \adl@array}
\ifadl@usingarypkg
\def\@testpach{\@chclass
 \ifnum \@lastchclass=6 \@ne \@chnum \@ne \else
  \ifnum \@lastchclass=7 5 \else
   \ifnum \@lastchclass=8 \tw@ \else
    \ifnum \@lastchclass=9 \thr@@
   \else \z@
   \ifnum \@lastchclass = 10 \else
   \edef\@nextchar{\expandafter\string\@nextchar}%
   \@chnum
   \if \@nextchar c\z@ \else
    \if \@nextchar \if@RTLtab r\else l\fi\@ne \else
     \if \@nextchar \if@RTLtab l\else r\fi\tw@ \else
   \z@ \@chclass
   \if\@nextchar |\@ne \let\@arrayrule\adl@arrayrule \else
   \if\@nextchar :\@ne \let\@arrayrule\adl@arraydashrule \else
   \if\@nextchar ;\@ne \let\@arrayrule\adl@argarraydashrule \else
    \if \@nextchar !6 \else
     \if \@nextchar @7 \else
      \if \@nextchar <8 \else
       \if \@nextchar >9 \else
  10
  \@chnum
  \if \@nextchar m\thr@@\else
   \if \@nextchar p4 \else
    \if \@nextchar b5 \else
   \z@ \@chclass \z@ \@preamerr \z@ \fi \fi \fi \fi \fi \fi
   \fi \fi  \fi  \fi  \fi  \fi  \fi \fi \fi \fi \fi \fi}

\def\@classz{\@classx
   \@tempcnta \count@
   \prepnext@tok
   \@addtopreamble{\ifcase \@chnum
      \hfil
      \adl@putlrc{\d@llarbegin \insert@column \d@llarend}\hfil \or
      \hskip1sp\adl@putlrc{\d@llarbegin \insert@column \d@llarend}\hfil \or
      \hfil\hskip1sp\adl@putlrc{\d@llarbegin \insert@column \d@llarend}\or
   \setbox\adl@box\hbox \adl@startmbox{\@nextchar}\insert@column
        \adl@endmbox\or
   \setbox\adl@box\vtop \@startpbox{\@nextchar}\insert@column \@endpbox \or
   \setbox\adl@box\vbox \@startpbox{\@nextchar}\insert@column \@endpbox
  \fi}\prepnext@tok}
\def\adl@class@start{4}
\def\adl@class@iiiorvii{7}

\else
\def\@testpach#1{\@chclass \ifnum \@lastchclass=\tw@ 4\relax \else
        \ifnum \@lastchclass=\thr@@ 5\relax \else
                \z@ \if #1c\@chnum \z@ \else
                    \if \if@RTLtab#1r\else#1l\fi\@chnum \@ne \else
                    \if \if@RTLtab#1l\else#1r\fi\@chnum \tw@ \else
                \@chclass
                    \if #1|\@ne \let\@arrayrule\adl@arrayrule \else
                    \if #1:\@ne \let\@arrayrule\adl@arraydashrule \else
                    \if #1;\@ne \let\@arrayrule\adl@argarraydashrule \else
                    \if #1@\tw@ \else
                    \if #1p\thr@@ \else \z@ \@preamerr 0\fi
        \fi  \fi  \fi  \fi  \fi  \fi  \fi  \fi  \fi}

\def\@arrayclassz{\ifcase \@lastchclass \@acolampacol \or \@ampacol \or
                \or \or \@addamp \or
                \@acolampacol \or \@firstampfalse \@acol \fi
        \edef\@preamble{\@preamble
                \ifcase \@chnum
                    \hfil\adl@putlrc{$\relax\@sharp$}\hfil
                \or \adl@putlrc{$\relax\@sharp$}\hfil
                \or \hfil\adl@putlrc{$\relax\@sharp$}\fi}}
\def\@tabclassz{\ifcase \@lastchclass \@acolampacol \or \@ampacol \or
                \or \or \@addamp \or
                \@acolampacol \or \@firstampfalse \@acol \fi
        \edef\@preamble{\@preamble
        \ifcase \@chnum
                    \hfil\adl@putlrc{\@sharp\unskip}\hfil
                \or \adl@putlrc{\@sharp\unskip}\hfil
                \or \hfil\hskip\z@ \adl@putlrc{\@sharp\unskip}\fi}}
\def\adl@class@start{6}
\def\adl@class@iiiorvii{3}
\fi
\@ifpackageloaded{colortbl}{%
\def\adl@inactivate{\adl@org@inactivate \let\CT@setup\adl@CT@setup}
\def\adl@activate{\adl@org@activate \let\CT@setup\adl@act@CT@setup
        \let\@endpbox\adl@org@endpbox}
\let\adl@CT@setup\CT@setup
\def\CT@setup{\adl@CT@setup
        \@tempdima\ht\z@ \advance\@tempdima\minrowclearance
        \ifdim\adl@height<\@tempdima \global\adl@height\@tempdima \fi
        \ifdim\adl@depth<\dp\z@ \global\adl@depth\dp\z@\fi}
\let\adl@act@CT@setup\CT@setup
\def\@classz{\@classx
        \@tempcnta\count@ \prepnext@tok
        \expandafter\CT@extract\the\toks\@tempcnta\columncolor!\@nil
        \expandafter\adl@extract@arc\the\toks\@tempcnta\arrayrulecolor!\@nil
        \expandafter\adl@extract@drsc
                \the\toks\@tempcnta\doublerulesepcolor!\@nil
        \expandafter\adl@extract@dgc\the\toks\@tempcnta\dashgapcolor!\@nil
        \@addtopreamble{\if@RTL\beginL\fi%
                \setbox\z@\hbox\bgroup\bgroup\if@RTL\beginR\fi
                \ifcase \@chnum
                        \hskip\stretch{.5}\kern\z@
                        \d@llarbegin
                        \insert@column
                        \d@llarend\hskip\stretch{.5}%
                \or \d@llarbegin \insert@column \d@llarend \hfill
                \or \hfill \kern\z@ \d@llarbegin \insert@column \d@llarend
                \or  $\vcenter
                        \@startpbox{\@nextchar}\insert@column \@endpbox $%
                \or  \vtop \@startpbox{\@nextchar}\insert@column \@endpbox
                \or  \vbox \@startpbox{\@nextchar}\insert@column \@endpbox
                \fi
                \if@RTL\endR\fi\egroup\egroup
                \begingroup
                        \CT@setup
                        \CT@column@color
                        \CT@row@color
                        \CT@cell@color
                        \CT@do@color
                \endgroup
                \@tempdima\ht\z@
                \advance\@tempdima\minrowclearance
                \vrule\@height\@tempdima\@width\z@
                \unhbox\z@\if@RTL\endL\fi}%
        \prepnext@tok}
\let\adl@act@classz\@classz
\let\adl@org@classz\@classz
}{}
%% 
%% Copyright © 2009–2011  VAFA KHALIGHI <vafaklg@gmail.com>
%% 
%% It may be distributed and/or modified under the LaTeX Project Public License,
%% version 1.3c or higher (your choice). The latest version of
%% this license is at: http://www.latex-project.org/lppl.txt
%% 
%% This work is “author-maintained” (as per LPPL maintenance status)
%% by VAFA KHALIGHI.
%% 
%% 
%% 
%%
%% End of file `arydshln-xetex-bidi.def'.