diff options
Diffstat (limited to 'Master/texmf-dist/tex/latex/bidi/extarticle-xetex-bidi.def')
-rw-r--r-- | Master/texmf-dist/tex/latex/bidi/extarticle-xetex-bidi.def | 108 |
1 files changed, 50 insertions, 58 deletions
diff --git a/Master/texmf-dist/tex/latex/bidi/extarticle-xetex-bidi.def b/Master/texmf-dist/tex/latex/bidi/extarticle-xetex-bidi.def index 32a38795d65..8ecaf0619f7 100644 --- a/Master/texmf-dist/tex/latex/bidi/extarticle-xetex-bidi.def +++ b/Master/texmf-dist/tex/latex/bidi/extarticle-xetex-bidi.def @@ -9,24 +9,10 @@ %% %% \ProvidesFile{extarticle-xetex-bidi.def}[2010/07/25 v0.2 bidi adaptations for extarticle class for XeTeX engine] -\renewcommand*\l@part[2]{% - \ifnum \c@tocdepth >-2\relax - \addpenalty{-\@highpenalty}% - \addvspace{2.25em \@plus\p@}% - \begingroup - \parindent \z@ \if@RTL\leftskip\else\rightskip\fi \@pnumwidth - \parfillskip -\@pnumwidth - {\leavevmode - \large \bfseries #1\hfil \hb@xt@\@pnumwidth{\hss #2}}\par - \nobreak - \global\@nobreaktrue - \everypar{\global\@nobreakfalse\everypar{}}% - \endgroup - \fi} -\renewcommand*\l@chapter[2]{% - \ifnum \c@tocdepth >\m@ne - \addpenalty{-\@highpenalty}% - \vskip 1.0em \@plus\p@ +\renewcommand*\l@section[2]{% + \ifnum \c@tocdepth >\z@ + \addpenalty\@secpenalty + \addvspace{1.0em \@plus\p@}% \setlength\@tempdima{1.5em}% \begingroup \parindent \z@ \if@RTL\leftskip\else\rightskip\fi \@pnumwidth @@ -35,36 +21,53 @@ \advance\if@RTL\rightskip\else\leftskip\fi\@tempdima \hskip -\if@RTL\rightskip\else\leftskip\fi #1\nobreak\hfil \nobreak\hb@xt@\@pnumwidth{\hss #2}\par - \penalty\@highpenalty \endgroup \fi} -\def\@makechapterhead#1{% - \vspace*{50\p@}% - {\parindent \z@ \if@RTL\raggedleft\else\raggedright\fi \normalfont + \renewcommand*\l@part[2]{% + \ifnum \c@tocdepth >-2\relax + \addpenalty\@secpenalty + \addvspace{2.25em \@plus\p@}% + \begingroup + \setlength\@tempdima{3em}% + \parindent \z@ \if@RTL\leftskip\else\rightskip\fi \@pnumwidth + \parfillskip -\@pnumwidth + {\leavevmode + \large \bfseries #1\hfil \hb@xt@\@pnumwidth{\hss #2}}\par + \nobreak + \endgroup + \fi} + \def\@part[#1]#2{% \ifnum \c@secnumdepth >\m@ne - \if@mainmatter - \huge\bfseries \@chapapp\space \thechapter - \par\nobreak - \vskip 20\p@ - \fi + \refstepcounter{part}% + \addcontentsline{toc}{part}{\thepart\hspace{1em}#1}% + \else + \addcontentsline{toc}{part}{#1}% \fi - \interlinepenalty\@M - \Huge \bfseries #1\par\nobreak - \vskip 40\p@ - }} -\def\@makeschapterhead#1{% - \vspace*{50\p@}% - {\parindent \z@ \if@RTL\raggedleft\else\raggedright\fi - \normalfont - \interlinepenalty\@M - \Huge \bfseries #1\par\nobreak - \vskip 40\p@ - }} + {\parindent \z@ \if@RTL\raggedleft\else\raggedright\fi + \interlinepenalty \@M + \normalfont + \ifnum \c@secnumdepth >\m@ne + \Large\bfseries \partname~\thepart + \par\nobreak + \fi + \huge \bfseries #2% + \markboth{}{}\par}% + \nobreak + \vskip 3ex + \@afterheading} + \def\@spart#1{% + {\parindent \z@ \if@RTL\raggedleft\else\raggedright\fi + \interlinepenalty \@M + \normalfont + \huge \bfseries #1\par}% + \nobreak + \vskip 3ex + \@afterheading} \renewenvironment{thebibliography}[1] - {\chapter*{\bibname - \@mkboth{\MakeUppercase\bibname}{\MakeUppercase\bibname}}% - \if@RTL\if@LTRbibitems\@RTLfalse\else\fi\else\if@RTLbibitems\@RTLtrue\else\fi\fi - \list{\@biblabel{\@arabic\c@enumiv}}% + {\section*{\refname + \@mkboth{\MakeUppercase\refname}{\MakeUppercase\refname}}% + \if@RTL\if@LTRbibitems\@RTLfalse\else\fi\else\if@RTLbibitems\@RTLtrue\else\fi\fi + \list{\@biblabel{\@arabic\c@enumiv}}% {\settowidth\labelwidth{\@biblabel{#1}}% \leftmargin\labelwidth \advance\leftmargin\labelsep @@ -72,14 +75,11 @@ \usecounter{enumiv}% \let\p@enumiv\@empty \renewcommand\theenumiv{\@arabic\c@enumiv}}% - \sloppy - \clubpenalty4000 - \@clubpenalty \clubpenalty - \widowpenalty4000% + \sloppy\clubpenalty4000\widowpenalty4000% \sfcode`\.\@m} {\def\@noitemerr {\@latex@warning{Empty `thebibliography' environment}}% - \endlist} + \endlist} \renewcommand\left@footnote{% \kern-3\p@ \hrule\@width.4\columnwidth @@ -90,7 +90,7 @@ \kern-3\p@ \hrule\@width.4\columnwidth \kern2.6\p@}\hfil\endR}} - \if@titlepage + \if@titlepage \renewcommand\maketitle{\begin{titlepage}% \let\footnotesize\small \let\right@footnote\relax @@ -178,18 +178,10 @@ \par \vskip 1.5em} \fi -\renewcommand \thesection {\thechapter\@SepMark\@arabic\c@section} \renewcommand\thesubsection {\thesection\@SepMark\@arabic\c@subsection} \renewcommand\thesubsubsection{\thesubsection \@SepMark\@arabic\c@subsubsection} \renewcommand\theparagraph {\thesubsubsection\@SepMark\@arabic\c@paragraph} -\renewcommand\thesubparagraph {\theparagraph\@SepMark\@arabic\c@subparagraph} -\renewcommand\theequation - {\ifnum \c@chapter>\z@ \thechapter\@SepMark\fi \@arabic\c@equation} -\renewcommand \thefigure - {\ifnum \c@chapter>\z@ \thechapter\@SepMark\fi \@arabic\c@figure} -\renewcommand \thetable - {\ifnum \c@chapter>\z@ \thechapter\@SepMark\fi \@arabic\c@table} -%% +\renewcommand\thesubparagraph {\theparagraph\@SepMark\@arabic\c@subparagraph}%% %% Copyright © 2009-2010 by Vafa Khalighi <vafakh84@gmail.com> %% %% Distributable under the LaTeX Project Public License, |