From 8df732286e6f6d11222d83f90b15ec42f7059d7c Mon Sep 17 00:00:00 2001 From: Karl Berry Date: Tue, 6 Apr 2010 12:57:38 +0000 Subject: bidi update (5apr10) git-svn-id: svn://tug.org/texlive/trunk@17733 c570f23f-e606-0410-a88d-b1316a301751 --- Master/texmf-dist/doc/xelatex/bidi/README | 12 +- Master/texmf-dist/doc/xelatex/bidi/bidi-doc.pdf | Bin 153141 -> 322849 bytes Master/texmf-dist/doc/xelatex/bidi/bidi-doc.tex | 118 +++--- .../texmf-dist/doc/xelatex/bidi/bidisample2e.pdf | Bin 0 -> 39027 bytes Master/texmf-dist/doc/xelatex/bidi/bidismall2e.pdf | Bin 0 -> 16532 bytes Master/texmf-dist/doc/xelatex/bidi/picture.jpg | Bin 0 -> 1693 bytes .../doc/xelatex/bidi/presentation-sample.pdf | Bin 0 -> 39748 bytes .../doc/xelatex/bidi/presentation-sample.tex | 6 +- .../texmf-dist/doc/xelatex/bidi/test-arydshln.pdf | Bin 0 -> 11023 bytes .../texmf-dist/doc/xelatex/bidi/test-arydshln.tex | 27 ++ Master/texmf-dist/doc/xelatex/bidi/test-bidi.pdf | Bin 0 -> 16009 bytes .../texmf-dist/doc/xelatex/bidi/test-brochure.pdf | Bin 0 -> 52113 bytes .../texmf-dist/doc/xelatex/bidi/test-brochure.tex | 360 +++++++++++++++++ .../texmf-dist/doc/xelatex/bidi/test-casualcv.pdf | Bin 0 -> 59545 bytes .../texmf-dist/doc/xelatex/bidi/test-casualcv.tex | 71 ++++ .../texmf-dist/doc/xelatex/bidi/test-classiccv.pdf | Bin 0 -> 57591 bytes .../texmf-dist/doc/xelatex/bidi/test-classiccv.tex | 71 ++++ Master/texmf-dist/doc/xelatex/bidi/test-color.pdf | Bin 0 -> 23982 bytes Master/texmf-dist/doc/xelatex/bidi/test-color.tex | 44 ++ .../doc/xelatex/bidi/test-supertabular.pdf | Bin 0 -> 24818 bytes .../doc/xelatex/bidi/test-supertabular.tex | 4 +- .../texmf-dist/doc/xelatex/bidi/test-tabular.pdf | Bin 0 -> 24715 bytes .../texmf-dist/doc/xelatex/bidi/test-tabular.tex | 2 +- .../texmf-dist/doc/xelatex/bidi/test-tabularx.pdf | Bin 0 -> 18883 bytes .../texmf-dist/doc/xelatex/bidi/test-tabularx.tex | 2 +- .../texmf-dist/doc/xelatex/bidi/test-tabulary.pdf | Bin 0 -> 11034 bytes .../texmf-dist/doc/xelatex/bidi/test1-colortbl.pdf | Bin 0 -> 18966 bytes .../texmf-dist/doc/xelatex/bidi/test1-colortbl.tex | 47 +++ .../texmf-dist/doc/xelatex/bidi/test1-wrapfig.pdf | Bin 0 -> 10310 bytes .../texmf-dist/doc/xelatex/bidi/test2-colortbl.pdf | Bin 0 -> 27868 bytes .../texmf-dist/doc/xelatex/bidi/test2-colortbl.tex | 28 ++ .../texmf-dist/doc/xelatex/bidi/test2-wrapfig.pdf | Bin 0 -> 7437 bytes .../texmf-dist/doc/xelatex/bidi/test3-wrapfig.pdf | Bin 0 -> 773628 bytes Master/texmf-dist/tex/xelatex/bidi/amsart-bidi.def | 112 ------ .../tex/xelatex/bidi/amsart-xetex-bidi.def | 98 +++++ .../texmf-dist/tex/xelatex/bidi/amsbook-bidi.def | 122 ------ .../tex/xelatex/bidi/amsbook-xetex-bidi.def | 104 +++++ .../texmf-dist/tex/xelatex/bidi/amsmath-bidi.def | 50 --- .../tex/xelatex/bidi/amsmath-xetex-bidi.def | 50 +++ Master/texmf-dist/tex/xelatex/bidi/amsthm-bidi.def | 27 -- .../tex/xelatex/bidi/amsthm-xetex-bidi.def | 27 ++ Master/texmf-dist/tex/xelatex/bidi/array-bidi.def | 108 ----- .../tex/xelatex/bidi/array-xetex-bidi.def | 108 +++++ .../texmf-dist/tex/xelatex/bidi/article-bidi.def | 221 ----------- .../tex/xelatex/bidi/article-xetex-bidi.def | 160 ++++++++ .../texmf-dist/tex/xelatex/bidi/arydshln-bidi.def | 160 -------- .../tex/xelatex/bidi/arydshln-xetex-bidi.def | 160 ++++++++ Master/texmf-dist/tex/xelatex/bidi/bidi.sty | 411 +------------------ Master/texmf-dist/tex/xelatex/bidi/bidicode.sty | 85 +--- .../texmf-dist/tex/xelatex/bidi/bidimoderncv.cls | 273 +++++++++++++ Master/texmf-dist/tex/xelatex/bidi/bidipoem.sty | 2 +- Master/texmf-dist/tex/xelatex/bidi/book-bidi.def | 240 ----------- .../tex/xelatex/bidi/book-xetex-bidi.def | 177 +++++++++ .../texmf-dist/tex/xelatex/bidi/bookest-bidi.def | 90 ----- .../tex/xelatex/bidi/bookest-xetex-bidi.def | 58 +++ Master/texmf-dist/tex/xelatex/bidi/breqn-bidi.def | 80 ---- .../tex/xelatex/bidi/breqn-xetex-bidi.def | 80 ++++ .../tex/xelatex/bidi/caption-xetex-bidi.def | 27 ++ Master/texmf-dist/tex/xelatex/bidi/color-bidi.def | 66 --- .../tex/xelatex/bidi/color-xetex-bidi.def | 66 +++ .../texmf-dist/tex/xelatex/bidi/colortbl-bidi.def | 63 --- .../tex/xelatex/bidi/colortbl-xetex-bidi.def | 63 +++ .../tex/xelatex/bidi/cvthemebidicasual.sty | 124 ++++++ .../tex/xelatex/bidi/cvthemebidiclassic.sty | 131 ++++++ .../tex/xelatex/bidi/draftwatermark-bidi.def | 28 -- .../tex/xelatex/bidi/draftwatermark-xetex-bidi.def | 28 ++ .../texmf-dist/tex/xelatex/bidi/extbook-bidi.def | 239 ----------- .../tex/xelatex/bidi/extbook-xetex-bidi.def | 176 ++++++++ .../texmf-dist/tex/xelatex/bidi/fancyhdr-bidi.def | 36 -- .../tex/xelatex/bidi/fancyhdr-xetex-bidi.def | 36 ++ Master/texmf-dist/tex/xelatex/bidi/fleqn-bidi.def | 55 --- .../tex/xelatex/bidi/fleqn-xetex-bidi.def | 55 +++ .../texmf-dist/tex/xelatex/bidi/flowfram-bidi.def | 155 -------- .../tex/xelatex/bidi/flowfram-xetex-bidi.def | 155 ++++++++ .../texmf-dist/tex/xelatex/bidi/footnote-bidi.def | 256 ------------ .../tex/xelatex/bidi/footnote-luatex-bidi.def | 26 ++ .../tex/xelatex/bidi/footnote-xetex-bidi.def | 256 ++++++++++++ .../texmf-dist/tex/xelatex/bidi/graphicx-bidi.def | 130 ------ .../tex/xelatex/bidi/graphicx-xetex-bidi.def | 130 ++++++ .../texmf-dist/tex/xelatex/bidi/hyperref-bidi.def | 252 ------------ .../tex/xelatex/bidi/hyperref-xetex-bidi.def | 252 ++++++++++++ Master/texmf-dist/tex/xelatex/bidi/leqno-bidi.def | 29 -- .../tex/xelatex/bidi/leqno-xetex-bidi.def | 29 ++ Master/texmf-dist/tex/xelatex/bidi/letter-bidi.def | 39 -- .../tex/xelatex/bidi/letter-xetex-bidi.def | 39 ++ .../texmf-dist/tex/xelatex/bidi/listings-bidi.def | 34 -- .../tex/xelatex/bidi/listings-xetex-bidi.def | 44 ++ .../tex/xelatex/bidi/loadingorder-bidi.def | 14 +- .../texmf-dist/tex/xelatex/bidi/longtable-bidi.def | 36 -- .../tex/xelatex/bidi/longtable-xetex-bidi.def | 36 ++ Master/texmf-dist/tex/xelatex/bidi/luatex-bidi.def | 30 ++ Master/texmf-dist/tex/xelatex/bidi/memoir-bidi.def | 80 ---- .../tex/xelatex/bidi/memoir-xetex-bidi.def | 177 +++++++++ .../texmf-dist/tex/xelatex/bidi/minitoc-bidi.def | 63 --- .../tex/xelatex/bidi/minitoc-xetex-bidi.def | 63 +++ .../texmf-dist/tex/xelatex/bidi/multicol-bidi.def | 171 -------- .../tex/xelatex/bidi/multicol-xetex-bidi.def | 171 ++++++++ .../texmf-dist/tex/xelatex/bidi/pdfpages-bidi.def | 73 ---- .../tex/xelatex/bidi/pdfpages-xetex-bidi.def | 73 ++++ .../texmf-dist/tex/xelatex/bidi/pgf-xetex-bidi.def | 30 ++ .../texmf-dist/tex/xelatex/bidi/pstricks-bidi.def | 27 -- .../tex/xelatex/bidi/pstricks-xetex-bidi.def | 27 ++ .../texmf-dist/tex/xelatex/bidi/ragged2e-bidi.def | 111 ------ .../tex/xelatex/bidi/ragged2e-xetex-bidi.def | 111 ++++++ .../texmf-dist/tex/xelatex/bidi/rapport3-bidi.def | 253 ------------ .../tex/xelatex/bidi/rapport3-xetex-bidi.def | 253 ++++++++++++ Master/texmf-dist/tex/xelatex/bidi/refrep-bidi.def | 158 -------- .../tex/xelatex/bidi/refrep-xetex-bidi.def | 158 ++++++++ Master/texmf-dist/tex/xelatex/bidi/report-bidi.def | 225 ----------- .../tex/xelatex/bidi/report-xetex-bidi.def | 167 ++++++++ .../texmf-dist/tex/xelatex/bidi/scrartcl-bidi.def | 264 ------------ .../tex/xelatex/bidi/scrartcl-xetex-bidi.def | 264 ++++++++++++ .../texmf-dist/tex/xelatex/bidi/scrbook-bidi.def | 320 --------------- .../tex/xelatex/bidi/scrbook-xetex-bidi.def | 320 +++++++++++++++ .../texmf-dist/tex/xelatex/bidi/scrreprt-bidi.def | 277 ------------- .../tex/xelatex/bidi/scrreprt-xetex-bidi.def | 277 +++++++++++++ .../texmf-dist/tex/xelatex/bidi/stabular-bidi.def | 52 --- .../tex/xelatex/bidi/stabular-xetex-bidi.def | 52 +++ .../tex/xelatex/bidi/subfigure-xetex-bidi.def | 30 ++ Master/texmf-dist/tex/xelatex/bidi/tabls-bidi.def | 60 --- .../tex/xelatex/bidi/tabls-xetex-bidi.def | 60 +++ .../texmf-dist/tex/xelatex/bidi/tabulary-bidi.def | 55 --- .../tex/xelatex/bidi/tabulary-xetex-bidi.def | 55 +++ Master/texmf-dist/tex/xelatex/bidi/tikz-bidi.def | 30 -- .../tex/xelatex/bidi/tikz-xetex-bidi.def | 30 ++ .../texmf-dist/tex/xelatex/bidi/tocbibind-bidi.def | 55 --- .../tex/xelatex/bidi/tocbibind-xetex-bidi.def | 55 +++ .../texmf-dist/tex/xelatex/bidi/tocloft-bidi.def | 332 ---------------- .../tex/xelatex/bidi/tocloft-xetex-bidi.def | 332 ++++++++++++++++ .../texmf-dist/tex/xelatex/bidi/tocstyle-bidi.def | 271 ------------- .../tex/xelatex/bidi/tocstyle-xetex-bidi.def | 271 +++++++++++++ .../texmf-dist/tex/xelatex/bidi/wrapfig-bidi.def | 101 ----- .../tex/xelatex/bidi/wrapfig-xetex-bidi.def | 101 +++++ Master/texmf-dist/tex/xelatex/bidi/xcolor-bidi.def | 127 ------ .../tex/xelatex/bidi/xcolor-xetex-bidi.def | 127 ++++++ Master/texmf-dist/tex/xelatex/bidi/xetex-bidi.def | 441 +++++++++++++++++++++ .../texmf-dist/tex/xelatex/bidi/xltxtra-bidi.def | 30 -- .../tex/xelatex/bidi/xltxtra-xetex-bidi.def | 30 ++ 138 files changed, 7445 insertions(+), 6295 deletions(-) create mode 100644 Master/texmf-dist/doc/xelatex/bidi/bidisample2e.pdf create mode 100644 Master/texmf-dist/doc/xelatex/bidi/bidismall2e.pdf create mode 100644 Master/texmf-dist/doc/xelatex/bidi/picture.jpg create mode 100644 Master/texmf-dist/doc/xelatex/bidi/presentation-sample.pdf create mode 100644 Master/texmf-dist/doc/xelatex/bidi/test-arydshln.pdf create mode 100644 Master/texmf-dist/doc/xelatex/bidi/test-arydshln.tex create mode 100644 Master/texmf-dist/doc/xelatex/bidi/test-bidi.pdf create mode 100644 Master/texmf-dist/doc/xelatex/bidi/test-brochure.pdf create mode 100644 Master/texmf-dist/doc/xelatex/bidi/test-brochure.tex create mode 100644 Master/texmf-dist/doc/xelatex/bidi/test-casualcv.pdf create mode 100644 Master/texmf-dist/doc/xelatex/bidi/test-casualcv.tex create mode 100644 Master/texmf-dist/doc/xelatex/bidi/test-classiccv.pdf create mode 100644 Master/texmf-dist/doc/xelatex/bidi/test-classiccv.tex create mode 100644 Master/texmf-dist/doc/xelatex/bidi/test-color.pdf create mode 100644 Master/texmf-dist/doc/xelatex/bidi/test-color.tex create mode 100644 Master/texmf-dist/doc/xelatex/bidi/test-supertabular.pdf create mode 100644 Master/texmf-dist/doc/xelatex/bidi/test-tabular.pdf create mode 100644 Master/texmf-dist/doc/xelatex/bidi/test-tabularx.pdf create mode 100644 Master/texmf-dist/doc/xelatex/bidi/test-tabulary.pdf create mode 100644 Master/texmf-dist/doc/xelatex/bidi/test1-colortbl.pdf create mode 100644 Master/texmf-dist/doc/xelatex/bidi/test1-colortbl.tex create mode 100644 Master/texmf-dist/doc/xelatex/bidi/test1-wrapfig.pdf create mode 100644 Master/texmf-dist/doc/xelatex/bidi/test2-colortbl.pdf create mode 100644 Master/texmf-dist/doc/xelatex/bidi/test2-colortbl.tex create mode 100644 Master/texmf-dist/doc/xelatex/bidi/test2-wrapfig.pdf create mode 100644 Master/texmf-dist/doc/xelatex/bidi/test3-wrapfig.pdf delete mode 100644 Master/texmf-dist/tex/xelatex/bidi/amsart-bidi.def create mode 100644 Master/texmf-dist/tex/xelatex/bidi/amsart-xetex-bidi.def delete mode 100644 Master/texmf-dist/tex/xelatex/bidi/amsbook-bidi.def create mode 100644 Master/texmf-dist/tex/xelatex/bidi/amsbook-xetex-bidi.def delete mode 100644 Master/texmf-dist/tex/xelatex/bidi/amsmath-bidi.def create mode 100644 Master/texmf-dist/tex/xelatex/bidi/amsmath-xetex-bidi.def delete mode 100644 Master/texmf-dist/tex/xelatex/bidi/amsthm-bidi.def create mode 100644 Master/texmf-dist/tex/xelatex/bidi/amsthm-xetex-bidi.def delete mode 100644 Master/texmf-dist/tex/xelatex/bidi/array-bidi.def create mode 100644 Master/texmf-dist/tex/xelatex/bidi/array-xetex-bidi.def delete mode 100644 Master/texmf-dist/tex/xelatex/bidi/article-bidi.def create mode 100644 Master/texmf-dist/tex/xelatex/bidi/article-xetex-bidi.def delete mode 100644 Master/texmf-dist/tex/xelatex/bidi/arydshln-bidi.def create mode 100644 Master/texmf-dist/tex/xelatex/bidi/arydshln-xetex-bidi.def create mode 100644 Master/texmf-dist/tex/xelatex/bidi/bidimoderncv.cls delete mode 100644 Master/texmf-dist/tex/xelatex/bidi/book-bidi.def create mode 100644 Master/texmf-dist/tex/xelatex/bidi/book-xetex-bidi.def delete mode 100644 Master/texmf-dist/tex/xelatex/bidi/bookest-bidi.def create mode 100644 Master/texmf-dist/tex/xelatex/bidi/bookest-xetex-bidi.def delete mode 100644 Master/texmf-dist/tex/xelatex/bidi/breqn-bidi.def create mode 100644 Master/texmf-dist/tex/xelatex/bidi/breqn-xetex-bidi.def create mode 100644 Master/texmf-dist/tex/xelatex/bidi/caption-xetex-bidi.def delete mode 100644 Master/texmf-dist/tex/xelatex/bidi/color-bidi.def create mode 100644 Master/texmf-dist/tex/xelatex/bidi/color-xetex-bidi.def delete mode 100644 Master/texmf-dist/tex/xelatex/bidi/colortbl-bidi.def create mode 100644 Master/texmf-dist/tex/xelatex/bidi/colortbl-xetex-bidi.def create mode 100644 Master/texmf-dist/tex/xelatex/bidi/cvthemebidicasual.sty create mode 100644 Master/texmf-dist/tex/xelatex/bidi/cvthemebidiclassic.sty delete mode 100644 Master/texmf-dist/tex/xelatex/bidi/draftwatermark-bidi.def create mode 100644 Master/texmf-dist/tex/xelatex/bidi/draftwatermark-xetex-bidi.def delete mode 100644 Master/texmf-dist/tex/xelatex/bidi/extbook-bidi.def create mode 100644 Master/texmf-dist/tex/xelatex/bidi/extbook-xetex-bidi.def delete mode 100644 Master/texmf-dist/tex/xelatex/bidi/fancyhdr-bidi.def create mode 100644 Master/texmf-dist/tex/xelatex/bidi/fancyhdr-xetex-bidi.def delete mode 100644 Master/texmf-dist/tex/xelatex/bidi/fleqn-bidi.def create mode 100644 Master/texmf-dist/tex/xelatex/bidi/fleqn-xetex-bidi.def delete mode 100644 Master/texmf-dist/tex/xelatex/bidi/flowfram-bidi.def create mode 100644 Master/texmf-dist/tex/xelatex/bidi/flowfram-xetex-bidi.def delete mode 100644 Master/texmf-dist/tex/xelatex/bidi/footnote-bidi.def create mode 100644 Master/texmf-dist/tex/xelatex/bidi/footnote-luatex-bidi.def create mode 100644 Master/texmf-dist/tex/xelatex/bidi/footnote-xetex-bidi.def delete mode 100644 Master/texmf-dist/tex/xelatex/bidi/graphicx-bidi.def create mode 100644 Master/texmf-dist/tex/xelatex/bidi/graphicx-xetex-bidi.def delete mode 100644 Master/texmf-dist/tex/xelatex/bidi/hyperref-bidi.def create mode 100644 Master/texmf-dist/tex/xelatex/bidi/hyperref-xetex-bidi.def delete mode 100644 Master/texmf-dist/tex/xelatex/bidi/leqno-bidi.def create mode 100644 Master/texmf-dist/tex/xelatex/bidi/leqno-xetex-bidi.def delete mode 100644 Master/texmf-dist/tex/xelatex/bidi/letter-bidi.def create mode 100644 Master/texmf-dist/tex/xelatex/bidi/letter-xetex-bidi.def delete mode 100644 Master/texmf-dist/tex/xelatex/bidi/listings-bidi.def create mode 100644 Master/texmf-dist/tex/xelatex/bidi/listings-xetex-bidi.def delete mode 100644 Master/texmf-dist/tex/xelatex/bidi/longtable-bidi.def create mode 100644 Master/texmf-dist/tex/xelatex/bidi/longtable-xetex-bidi.def create mode 100644 Master/texmf-dist/tex/xelatex/bidi/luatex-bidi.def delete mode 100644 Master/texmf-dist/tex/xelatex/bidi/memoir-bidi.def create mode 100644 Master/texmf-dist/tex/xelatex/bidi/memoir-xetex-bidi.def delete mode 100644 Master/texmf-dist/tex/xelatex/bidi/minitoc-bidi.def create mode 100644 Master/texmf-dist/tex/xelatex/bidi/minitoc-xetex-bidi.def delete mode 100644 Master/texmf-dist/tex/xelatex/bidi/multicol-bidi.def create mode 100644 Master/texmf-dist/tex/xelatex/bidi/multicol-xetex-bidi.def delete mode 100644 Master/texmf-dist/tex/xelatex/bidi/pdfpages-bidi.def create mode 100644 Master/texmf-dist/tex/xelatex/bidi/pdfpages-xetex-bidi.def create mode 100644 Master/texmf-dist/tex/xelatex/bidi/pgf-xetex-bidi.def delete mode 100644 Master/texmf-dist/tex/xelatex/bidi/pstricks-bidi.def create mode 100644 Master/texmf-dist/tex/xelatex/bidi/pstricks-xetex-bidi.def delete mode 100644 Master/texmf-dist/tex/xelatex/bidi/ragged2e-bidi.def create mode 100644 Master/texmf-dist/tex/xelatex/bidi/ragged2e-xetex-bidi.def delete mode 100644 Master/texmf-dist/tex/xelatex/bidi/rapport3-bidi.def create mode 100644 Master/texmf-dist/tex/xelatex/bidi/rapport3-xetex-bidi.def delete mode 100644 Master/texmf-dist/tex/xelatex/bidi/refrep-bidi.def create mode 100644 Master/texmf-dist/tex/xelatex/bidi/refrep-xetex-bidi.def delete mode 100644 Master/texmf-dist/tex/xelatex/bidi/report-bidi.def create mode 100644 Master/texmf-dist/tex/xelatex/bidi/report-xetex-bidi.def delete mode 100644 Master/texmf-dist/tex/xelatex/bidi/scrartcl-bidi.def create mode 100644 Master/texmf-dist/tex/xelatex/bidi/scrartcl-xetex-bidi.def delete mode 100644 Master/texmf-dist/tex/xelatex/bidi/scrbook-bidi.def create mode 100644 Master/texmf-dist/tex/xelatex/bidi/scrbook-xetex-bidi.def delete mode 100644 Master/texmf-dist/tex/xelatex/bidi/scrreprt-bidi.def create mode 100644 Master/texmf-dist/tex/xelatex/bidi/scrreprt-xetex-bidi.def delete mode 100644 Master/texmf-dist/tex/xelatex/bidi/stabular-bidi.def create mode 100644 Master/texmf-dist/tex/xelatex/bidi/stabular-xetex-bidi.def create mode 100644 Master/texmf-dist/tex/xelatex/bidi/subfigure-xetex-bidi.def delete mode 100644 Master/texmf-dist/tex/xelatex/bidi/tabls-bidi.def create mode 100644 Master/texmf-dist/tex/xelatex/bidi/tabls-xetex-bidi.def delete mode 100644 Master/texmf-dist/tex/xelatex/bidi/tabulary-bidi.def create mode 100644 Master/texmf-dist/tex/xelatex/bidi/tabulary-xetex-bidi.def delete mode 100644 Master/texmf-dist/tex/xelatex/bidi/tikz-bidi.def create mode 100644 Master/texmf-dist/tex/xelatex/bidi/tikz-xetex-bidi.def delete mode 100644 Master/texmf-dist/tex/xelatex/bidi/tocbibind-bidi.def create mode 100644 Master/texmf-dist/tex/xelatex/bidi/tocbibind-xetex-bidi.def delete mode 100644 Master/texmf-dist/tex/xelatex/bidi/tocloft-bidi.def create mode 100644 Master/texmf-dist/tex/xelatex/bidi/tocloft-xetex-bidi.def delete mode 100644 Master/texmf-dist/tex/xelatex/bidi/tocstyle-bidi.def create mode 100644 Master/texmf-dist/tex/xelatex/bidi/tocstyle-xetex-bidi.def delete mode 100644 Master/texmf-dist/tex/xelatex/bidi/wrapfig-bidi.def create mode 100644 Master/texmf-dist/tex/xelatex/bidi/wrapfig-xetex-bidi.def delete mode 100644 Master/texmf-dist/tex/xelatex/bidi/xcolor-bidi.def create mode 100644 Master/texmf-dist/tex/xelatex/bidi/xcolor-xetex-bidi.def create mode 100644 Master/texmf-dist/tex/xelatex/bidi/xetex-bidi.def delete mode 100644 Master/texmf-dist/tex/xelatex/bidi/xltxtra-bidi.def create mode 100644 Master/texmf-dist/tex/xelatex/bidi/xltxtra-xetex-bidi.def diff --git a/Master/texmf-dist/doc/xelatex/bidi/README b/Master/texmf-dist/doc/xelatex/bidi/README index f33ff8852d9..e81b5d56b1f 100644 --- a/Master/texmf-dist/doc/xelatex/bidi/README +++ b/Master/texmf-dist/doc/xelatex/bidi/README @@ -1,19 +1,17 @@ _________________ The bidi package -v1.0.4 +v1.0.5 This package provides a convenient interface for typesetting bidirectional texts with XeLaTeX. -This version fixes all the bugs that were present in v1.0.3 and in -addition it provides new features explained in the documentation. -The support for bidibeamer and bidimoderncv is removed in this version -and it will be back in version 1.0.5 (hopefully ready for MiKTeX 2.9 -and TeXLive 2010). - +This version fixes almost most of the bugs that were present in v1.0.4. +The support for bidimoderncv is back in this version. To get help, please subscribe to the XeTeX mailing list and ask your question there. +The next release is planned to be ready for MikTeX 2.9 and TeXLive 2010. + ______________ Vafa Khalighi vafa@users.berlios.de diff --git a/Master/texmf-dist/doc/xelatex/bidi/bidi-doc.pdf b/Master/texmf-dist/doc/xelatex/bidi/bidi-doc.pdf index a1623eab8f4..a1745aaf9d5 100644 Binary files a/Master/texmf-dist/doc/xelatex/bidi/bidi-doc.pdf and b/Master/texmf-dist/doc/xelatex/bidi/bidi-doc.pdf differ diff --git a/Master/texmf-dist/doc/xelatex/bidi/bidi-doc.tex b/Master/texmf-dist/doc/xelatex/bidi/bidi-doc.tex index f7d3bdb3034..e4f6815b678 100644 --- a/Master/texmf-dist/doc/xelatex/bidi/bidi-doc.tex +++ b/Master/texmf-dist/doc/xelatex/bidi/bidi-doc.tex @@ -1,12 +1,9 @@ -\documentclass{article} -\usepackage{fontspec} +\documentclass{artikel3} \usepackage{calc} \usepackage{pifont} \usepackage{bbding} -\usepackage[left=2.5cm,right=2.5cm,top=2.5cm,bottom=2.5cm,nohead]{geometry} \usepackage[colorlinks=true,linkcolor=mybrown,urlcolor=mygreen]{hyperref} \usepackage{bidicode} -\usepackage{bidi} \newcounter{local} \renewcommand\theenumi{\protect\setcounter{local}% {201+\the\value{enumi}}\protect\ding{\value{local}}} @@ -18,41 +15,31 @@ \definecolor{mybrown}{rgb}{.6,0,0} \definecolor{mygreen}{rgb}{0,.43,0} \definecolor{Orange}{rgb}{1,.4,.2} +\newcommand\XeTeX{Xe\TeX} +\newcommand\XeLaTeX{Xe\LaTeX} \title{The \textsf{bidi} Package\\ \href{http://bidi.berlios.de}{\texttt{http://bidi.berlios.de}}} \author{Vafa Khalighi\\ \href{mailto:vafa@users.berlios.de}{\texttt{vafa@users.berlios.de}}} -\date{Version 1.0.4} +\date{Version 1.0.5} \begin{document} \maketitle \tableofcontents -\lstlistoflistings \section{Introduction} \textsf{bidi} provides a convenient interface for typesetting bidirectional texts with \XeLaTeX. The package includes adaptations for use with many other commonly-used packages. -The \textsf{bidi} package at the moment only works with \XeTeX\ engine, but we will support Lua\TeX\ engine as well in our next release. +The \textsf{bidi} package at the moment only works with \XeTeX\ engine, but we will support other \TeX\ engines as well in the future. \subsection{\textsf{bidi} Info On The Terminal and In The Log File} If you use \textsf{bidi} package to write any input \TeX\ document, and then run \texttt{xelatex} on your document, \textsf{bidi} writes some information about itself to the terminal and to the log file. The information is something like: -\begin{center} -\colorbox{lightgray}{\begin{minipage}{0.9\textwidth}\ttfamily -bidi package (Support for bidirectional typesetting with XeLaTeX)\\ -Description: A convenient interface for typesetting bidirectional\\ -texts with XeLaTeX. The package includes adaptations for use\\ -with many other commonly-used packages.\\ -Copyright © 2009-2010 Vafa Khalighi\\ -\bidiversion, <\bidirevision>, \bididate\\ -License: LaTeX Project Public License, version 1.3c or higher (your choice)\\ -Home: http://bidi.berlios.de\\ +\begin{lstlisting}[numbers=none,backgroundcolor=\color{skugga}] +bidi package (Support for bidirectional typesetting with XeLaTeX and LuaLaTeX) +Description: A convenient interface for typesetting bidirectional +texts with XeLaTeX and LuaLaTeX. The package includes adaptations for use +with many other commonly-used packages. +Copyright (c) 2009-2010 Vafa Khalighi +v1.0.5, , 2010/07/25 +License: LaTeX Project Public License, version 1.3c or higher (your choice) +Home: http://bidi.berlios.de Location on CTAN: /macros/xetex/latex/bidi -\end{minipage}} -\end{center} -\subsection{PDF Creator of \textsf{bidi} Documents} -If you use \textsf{bidi} package to produce a PDF file, the \textsf{bidi} package writes itself to the Application field of the PDF file and hyperref would have no effect since this is done at the beggining of the document. Thus if you produce a PDF file using the \textsf{bidi} package and then you look at the application field in the properties of the PDF file, you will see this: - -\begin{center} -\colorbox{yellow}{\begin{minipage}{0.6\textwidth}% -Bidi \bidiversion\ <\bidirevision> Copyright © 2009-2010 Vafa Khalighi -\end{minipage}} -\end{center} -Check out the properties of this document to verify this. +\end{lstlisting} \section{Basics} \subsection{Loading The Package} You can load the package in the ordinary way; @@ -63,13 +50,13 @@ Where \texttt{options} of the package are explained later in \autoref{options}. When loading the package, it is important to know that: \begin{enumerate} -\item \textsf{bidi} should be the last package that you loade, because otherwise you are certainly going to overwrite \textsf{bidi}'s definitions and consequently, you will not get the expected output. +\item \textsf{bidi} should be the last package that you load, because otherwise you are certainly going to overwrite \textsf{bidi}'s definitions and consequently, you will not get the expected output. \item In fact, \textsf{bidi} makes sure that some specific packages are loaded before \textsf{bidi}; these are those packages that \textsf{bidi} modifies them for bidirectional typesetting. If you load \textsf{bidi} before any of these packages, then you will get an error saying that you should load \textsf{bidi} as your last package. For instance, consider the following minimal example: -\begin{lstlisting}[caption={Wrong Order Of Loading \textsf{bidi} Package},captionpos=t] +\begin{lstlisting} \documentclass{minimal} \usepackage{bidi} \usepackage{graphicx} @@ -78,7 +65,7 @@ This is just a test. \end{document} \end{lstlisting} Where \textsf{graphicx} is loaded after \textsf{bidi}. If you run \texttt{xelatex} on this document, you will get an error which looks like this: -\begin{lstlisting}[numbers=none] +\begin{lstlisting}[numbers=none,backgroundcolor=\color{skugga}] ! Package bidi Error: Oops! you have loaded package graphicx after bidi package . Please load package graphicx before bidi package, and then try to run xelatex on your document again. @@ -102,7 +89,7 @@ l.4 \begin{document} \item \Lcs{bidirevision} gives the current subversion revision of the package. \item \Lcs{bididate} gives the current date of the package. \end{itemize} -\begin{lstlisting}[morekeywords={bidiversion,bidirevision,bididate},captionpos=t,caption={Version, SVN Revision and Date Commands}] +\begin{lstlisting}[morekeywords={bidiversion,bidirevision,bididate}] \documentclass{article} \usepackage{bidi} \begin{document} @@ -122,15 +109,19 @@ It is clear that if you do not pass any of these options to the package, you wil \item With any of the commands in the first row, you can typeset LTR paragraphs. \item With any of the commands in the second row, you can typeset RTL paragraphs. \end{itemize} -\begin{lstlisting}[morekeywords={setRTL,setLTR},captionpos=t,caption={Paragraph Direction Switching}] +\begin{lstlisting} \documentclass{article} \usepackage{bidi} \begin{document} \setRTL% -Anyone who reads Old and Middle English literary texts will be familiar with the mid-brown volumes of the EETS, with the symbol of Alfred's jewel embossed on the front cover. +Anyone who reads Old and Middle English literary texts will be + familiar with the mid-brown volumes of the EETS, with the symbol + of Alfred's jewel embossed on the front cover. \setLTR% Notice the blank line before \setLTR -Anyone who reads Old and Middle English literary texts will be familiar with the mid-brown volumes of the EETS, with the symbol of Alfred's jewel embossed on the front cover. +Anyone who reads Old and Middle English literary texts will be + familiar with the mid-brown volumes of the EETS, with the symbol + of Alfred's jewel embossed on the front cover. \end{document} \end{lstlisting} \subsection{Pargraph Switching Environments} @@ -142,14 +133,18 @@ Anyone who reads Old and Middle English literary texts will be familiar with the \item With \texttt{LTR} environment, you can typeset LTR paragraphs. \item With \texttt{RTL} environment, you can typeset RTL paragraphs. \end{itemize} -\begin{lstlisting}[captionpos=t,caption={\texttt{RTL} and \texttt{LTR} Environments}] +\begin{lstlisting} \documentclass{article} \usepackage{bidi} \begin{document} \begin{RTL} -Anyone who reads Old and Middle English literary texts will be familiar with the mid-brown volumes of the EETS, with the symbol of Alfred's jewel embossed on the front cover. +Anyone who reads Old and Middle English literary texts will be familiar + with the mid-brown volumes of the EETS, with the symbol + of Alfred's jewel embossed on the front cover. \begin{LTR} -Anyone who reads Old and Middle English literary texts will be familiar with the mid-brown volumes of the EETS, with the symbol of Alfred's jewel embossed on the front cover. +Anyone who reads Old and Middle English literary texts will be familiar + with the mid-brown volumes of the EETS, with the symbol + of Alfred's jewel embossed on the front cover. \end{LTR} And we are still typesetting RTL. \end{RTL} @@ -164,20 +159,26 @@ And we are still typesetting RTL. \item With any of the commands in the first row, you can typeset short LTR text inside RTL paragraphs. \item With any of the commands in the second row, you can typeset short RTL text inside LTR paragraphs. \end{itemize} -\begin{lstlisting}[morekeywords={LRE,RLE},captionpos=t,caption={Typesetting Short LTR and RTL texts}] +\begin{lstlisting} \begin{document} \begin{RTL} -Anyone who reads Old and Middle English \LRE{Short LTR text} literary texts will be familiar with the mid-brown volumes of the EETS, with the symbol of Alfred's jewel embossed on the front cover. +Anyone who reads Old and Middle English \LRE{Short LTR text} literary texts will be familiar + with the mid-brown volumes of the EETS, with the symbol + of Alfred's jewel embossed on the front cover. \begin{LTR} -Anyone who reads Old and Middle English \RLE{Short RTL text} literary texts will be familiar with the mid-brown volumes of the EETS, with the symbol of Alfred's jewel embossed on the front cover. +Anyone who reads Old and Middle English \RLE{Short RTL text} literary texts will be familiar + with the mid-brown volumes of the EETS, with the symbol + of Alfred's jewel embossed on the front cover. \end{LTR} \end{RTL} \end{document} \end{lstlisting} \subsection{Footnotes} \begin{BDef} -\Lcs{footnote}\OptArg{num}\Largb{\Larga{text}}\quad\Lcs{LTRfootnote}\OptArg{num}\Largb{\Larga{text}}\quad\Lcs{RTLfootnote}\OptArg{num}\Largb{\Larga{text}}\\ -\Lcs{setfootnoteRL}\quad\Lcs{setfootnoteLR}\quad\Lcs{unsetfootnoteRL}\\ +\Lcs{footnote}\OptArg{num}\Largb{\Larga{text}}\quad\Lcs{LTRfootnote}\OptArg{num}\Largb{\Larga{text}}\\ +\Lcs{RTLfootnote}\OptArg{num}\Largb{\Larga{text}}\quad +\Lcs{setfootnoteRL}\quad\Lcs{setfootnoteLR}\\ +\Lcs{unsetfootnoteRL}\quad \Lcs{thanks}\Largb{\Larga{text}}\quad\Lcs{LTRthanks}\Largb{\Larga{text}}\quad\Lcs{RTLthanks}\Largb{\Larga{text}} \end{BDef} \begin{itemize} @@ -191,7 +192,8 @@ Anyone who reads Old and Middle English \RLE{Short RTL text} literary texts will \item \Lcs{RTLthanks} (to be used only inside \Lcs{author} or \Lcs{title} argument) will always produce an RTL footnote, independent on the current mode. \end{itemize} \begin{BDef} -\Lcs{footnotetext}\OptArg{num}\Largb{\Larga{text}}\quad\Lcs{LTRfootnotetext}\OptArg{num}\Largb{\Larga{text}}\quad\Lcs{RTLfootnotetext}\OptArg{num}\Largb{\Larga{text}} +\Lcs{footnotetext}\OptArg{num}\Largb{\Larga{text}}\quad\Lcs{LTRfootnotetext}\OptArg{num}\Largb{\Larga{text}}\\ +\Lcs{RTLfootnotetext}\OptArg{num}\Largb{\Larga{text}} \end{BDef} \begin{itemize} \item \Lcs{footnotetext} used in conjunction with \Lcs{footnotemark}, in RTL mode produces an RTL footnote while in LTR mode it produces an LTR footnote. @@ -218,10 +220,10 @@ If you pass the \texttt{twocolumn} option to the class file and if the main dire \subsection{RTL cases} \begin{BDef} \Lcs{rcases}\Largb{\Lcs{text}\Largb{\Larga{brach1}}\Lcs{cr}\Lcs{text}\Largb{\Larga{brach2}}\Lcs{cr}% -\Lcs{text}\Largb{\Larga{brach3}}\ldots}\Lcs{text}\Largb{\Larga{main}} +\Lcs{text}\Largb{\Larga{brach3}}\ldots}\\\Lcs{text}\Largb{\Larga{main}} \end{BDef} \Lcs{rcases} is defined in bidi for typesetting RTL cases. \Lcs{text} is defined in \textsf{amsmath} package, so this means that you need to load \textsf{amsmath} package too. -\begin{lstlisting}[morekeywords={setRTL,rcases,text},captionpos=t,caption={RTL Cases}] +\begin{lstlisting}[morekeywords={rcases,text}] \documentclass{article} \usepackage{amsmath} \usepackage{bidi} @@ -242,7 +244,7 @@ If you pass the \texttt{twocolumn} option to the class file and if the main dire \Lcs{SepMark}\Largb{\Larga{mark}}\quad\Lcs{@SepMark} \end{BDef} Generally in Standard \LaTeX, dot is used for separation between section numbers, equation numbers any anything else which needs to be seperated. You can use \Lcs{SepMark} to use any other mark as the seperation mark instead a dot. -\begin{lstlisting}[morekeywords={SepMark,subsection,subsubsection},captionpos=t,caption={Using A Dash Instead A Dot For Seperation Marks}] +\begin{lstlisting}[morekeywords={SepMark,subsection,subsubsection}] \documentclass{article} \usepackage{bidi} \SepMark{-} @@ -255,7 +257,7 @@ Generally in Standard \LaTeX, dot is used for separation between section numbers If you decide to change the numbering of chapters, sections, subsections, equations, figures and \ldots, you should either load \textsf{amsmath} package and use \Lcs{numberwithin} macro to do this or do the ordinary way, but instead dot write \Lcs{@SepMark}. Using dot instead \Lcs{@SepMark} will certainly make trouble. -\begin{lstlisting}[morekeywords={SepMark,theequation,thesection},captionpos=t,caption={Redefining \Lcs{theequation}}] +\begin{lstlisting}[morekeywords={theequation,thesection,SepMark}] \documentclass{article} \usepackage{bidi} \SepMark{-} @@ -273,14 +275,12 @@ x^2+y^2=z^2 \Lcs{raggedright} command and \texttt{flushleft} environment put the text on the left hand side and \Lcs{raggedleft} command and \texttt{flushright} environment put the text on the right hand side, independent on the current mode. \subsection{Typesetting of Headers and Footers} If the main direction of the document is RTL, then headers and footers are typeset RTL and if the main direction of the document is LTR, then headers and footers are typeset LTR. - -Please note that if you would like to define any page style for headers and footers such as \Lcs{pagestyle}\Largb{headings}, you should do it after loading \textsf{bidi} package because \textsf{bidi} for proper direction typesetting of headers and footers redefines page styles for headers and footers and so if you change your headers and footers before loading \textsf{bidi} package, your definitions for headers and footers would have no effect at all. \subsection{Tabular Typesetting} In RTL mode, tabular are typeset RTL and in LTR mode, tabular are typeset LTR. \subsection{Equation Numbers} For \texttt{reqno}, equation numbers are on the right hand side and for \texttt{leqno}, equation numbers are on the left hand side, independent on the current mode. \section{Support For Various Packages and Classes} -The \textsf{bidi} package supports \textsf{amsmath}, \textsf{amsthm}, \textsf{array}, \textsf{arydshln}, \textsf{breqn}, \textsf{color}, \textsf{colortbl}, \textsf{draftwatermark}, \textsf{fancyhdr}, \textsf{flowfram}, \textsf{graphicx}, \textsf{hyperref}, \textsf{listings}, \textsf{minitoc}, \textsf{multicol}, \textsf{pdfpages}, \textsf{pstricks}, \textsf{ragged2e}, \textsf{stabular}, \textsf{supertabular}, \textsf{xtab}, \textsf{tabls}, \textsf{tabulary}, \textsf{PGF \&\ TIKZ}, \textsf{tocbibind}, \textsf{tocloft}, \textsf{tocstyle}, \textsf{wrapfig}, \textsf{xcolor}, \textsf{xltxtra} packages, \textsf{amsart}, \textsf{amsbook}, \textsf{standrad article}, \textsf{standard book}, \textsf{bookest}, \textsf{extbook}, \textsf{standard letter}, \textsf{memoir}, \textsf{rapport3}, \textsf{refrep}, \textsf{standard report}, \textsf{scartcl}, \textsf{scrbook}, \textsf{scrreprt} classes and any other packages and classes that relies on these packages and classes. This means, you can use all these packages and classes in addition to other packages and classes that rely on these packages and classes and use their functionality fully for your bidirectional documents. +The \textsf{bidi} package supports \textsf{amsmath}, \textsf{amsthm}, \textsf{array}, \textsf{arydshln}, \textsf{breqn}, \textsf{caption}, \textsf{color}, \textsf{colortbl}, \textsf{draftwatermark}, \textsf{fancyhdr}, \textsf{flowfram}, \textsf{graphicx}, \textsf{hyperref}, \textsf{listings}, \textsf{minitoc}, \textsf{multicol}, \textsf{pdfpages}, \textsf{pstricks}, \textsf{ragged2e}, \textsf{stabular}, \textsf{subfigure}, \textsf{supertabular}, \textsf{xtab}, \textsf{tabls}, \textsf{tabulary}, \textsf{PGF \&\ TIKZ}, \textsf{tocbibind}, \textsf{tocloft}, \textsf{tocstyle}, \textsf{wrapfig}, \textsf{xcolor}, \textsf{xltxtra} packages, \textsf{amsart}, \textsf{amsbook}, \textsf{standrad article}, \textsf{standard book}, \textsf{bookest}, \textsf{extbook}, \textsf{standard letter}, \textsf{memoir}, \textsf{rapport3}, \textsf{refrep}, \textsf{standard report}, \textsf{scartcl}, \textsf{scrbook}, \textsf{scrreprt} classes and any other packages and classes that relies on these packages and classes. This means, you can use all these packages and classes in addition to other packages and classes that rely on these packages and classes and use their functionality fully for your bidirectional documents. We now give some details that you should know about the supported packages or classes. \subsection{Color} @@ -292,8 +292,7 @@ For having coloured tabular, you can use \textsf{colortbl} package. \subsection{Hyperref} The \textsf{hyperref} package works fine with bidirectional documents if and only if, your link will not span more than a line. If your link spans more than a line, then your whole document, or page or paragraph may be linked. -\subsection{\textsf{fancyhdr} Package} -When using \textsf{fancyhdr} package, any commands of \textsf{fancyhdr} package such as \Lcs{pagestyle}\Largb{fancy}, should be done after loading \textsf{bidi} package. + \subsection{\textsf{flowfram} Package} You can use \textsf{flowfram} package for your bidirectional documents. Please note that \textsf{flowfram} package provides support for bidirectional column typesetting, for details, see its manual. \subsection{Multicolumn Typesetting} @@ -330,6 +329,8 @@ If you need to change the default distance between two verses, you can do just t \ldots\\ \LEND{traditionalpoem*} \end{BDef} +\subsection{Typesetting Resum\'e} +The \textsf{bidi} package provides \textsf{bidimoderncv}\footnote{This class is the modified version of \textsf{moderncv} class.} class for typesetting resum\'es. There are two examples, namely \texttt{test-casualcv.tex} and \texttt{test-classiccv.tex}, in the \textsf{doc} folder than you can look and learn how you can use it. \subsection{Print Two Pages On A Single Page} \textsf{bidi} package provides \textsf{bidi2in1} package for printing two pages on a single (landscape) A4 page. Page numbers appear on the included pages, and not on the landscape 'container' page. @@ -356,7 +357,7 @@ The class is used with article class will be appropriate for a presentation class, e. g. twocolumn. A simple example document: -\begin{lstlisting}[caption={\textsf{bidipresentation} Sample},morekeywords={AddToShipoutPicture,includegraphics,distance}] +\begin{lstlisting}[morekeywords={AddToShipoutPicture,includegraphics,distance}] \documentclass[12pt]{bidipresentation} \usepackage{eso-pic} \usepackage[RTLdocument]{bidi} @@ -433,12 +434,14 @@ If the main direction of the document is RTL, \Lcs{if@RTLmain} is true and if th \Lcs{if@Latin} inside any environment that uses Latin font is true and inside any environment that uses RTL font is false. \subsection{Tags Internal Macro} \begin{BDef} -\Lcs{@iftagsloaded}\Largb{\Larga{tags name}}\Largb{\Larga{do thing(s) if the tag is loaded}}\Largb{\Larga{do thing(s) if the tag is not loaded}} +\Lcs{@iftagsloaded}\Largb{\Larga{tags name}}\Largb{\Larga{do thing(s) if the tag is loaded}}\\ +\Largb{\Larga{do thing(s) if the tag is not loaded}} \end{BDef} As you can see, the syntax of \Lcs{@iftagsloaded} is exactly the same as the syntax of \Lcs{@ifpackageloaded} and \Lcs{@ifclassloaded}. By tags, we mean things like \texttt{leqno} or \texttt{reqno}. Please note that in the argument \Larga{tags name}, the extension \texttt{clo} should not be given. \subsection{Definition File Loaded Internal Macro} \begin{BDef} -\Lcs{@ifdefinitionfileloaded}\Largb{\Larga{definition file name}}\Largb{\Larga{do thing(s) if the definition file is loaded}}\\ +\Lcs{@ifdefinitionfileloaded}\Largb{\Larga{definition file name}}\\ +\Largb{\Larga{do thing(s) if the definition file is loaded}}\\ \Largb{\Larga{do thing(s) if the definition file is not loaded}} \end{BDef} As you can see, the syntax of \Lcs{@ifdefinitionfileloaded} is exactly the same as the syntax of \Lcs{@ifpackageloaded} and \Lcs{@ifclassloaded}. By definition file, we mean things like \texttt{hyperref-bidi.def} or \texttt{wrapfig-bidi.def}. Please note that in the argument \Larga{definition file name}, the extension \texttt{def} should not be given. @@ -454,7 +457,8 @@ If the tabular is typeset RTL, \Lcs{if@RTLtab} is true and if the tabular is typ When footnotes are typeset RTL, \Lcs{if@RTL@footnote} is true and when footnotes are typeset LTR, \Lcs{if@RTL@footnote} is false. \subsection{Direction Ensuring Macros} \begin{BDef} -\Lcs{@ensure@RTL}\Largb{\Larga{text}}\quad\Lcs{@ensure@RL}\Largb{\Larga{text}}\quad\Lcs{@ensure@LTR}\Largb{\Larga{text}}\quad\Lcs{@ensure@LR}\Largb{\Larga{text}}\\ +\Lcs{@ensure@RTL}\Largb{\Larga{text}}\quad\Lcs{@ensure@RL}\Largb{\Larga{text}}\quad\Lcs{@ensure@LTR}\Largb{\Larga{text}}\\ +\Lcs{@ensure@LR}\Largb{\Larga{text}}\quad \Lcs{@ensure@dir}\Largb{\Larga{text}}\quad\Lcs{@ensure@maindir}\Largb{\Larga{text}} \end{BDef} \begin{itemize} diff --git a/Master/texmf-dist/doc/xelatex/bidi/bidisample2e.pdf b/Master/texmf-dist/doc/xelatex/bidi/bidisample2e.pdf new file mode 100644 index 00000000000..a4bb1e0d994 Binary files /dev/null and b/Master/texmf-dist/doc/xelatex/bidi/bidisample2e.pdf differ diff --git a/Master/texmf-dist/doc/xelatex/bidi/bidismall2e.pdf b/Master/texmf-dist/doc/xelatex/bidi/bidismall2e.pdf new file mode 100644 index 00000000000..4961db4e01a Binary files /dev/null and b/Master/texmf-dist/doc/xelatex/bidi/bidismall2e.pdf differ diff --git a/Master/texmf-dist/doc/xelatex/bidi/picture.jpg b/Master/texmf-dist/doc/xelatex/bidi/picture.jpg new file mode 100644 index 00000000000..ef48e69ce85 Binary files /dev/null and b/Master/texmf-dist/doc/xelatex/bidi/picture.jpg differ diff --git a/Master/texmf-dist/doc/xelatex/bidi/presentation-sample.pdf b/Master/texmf-dist/doc/xelatex/bidi/presentation-sample.pdf new file mode 100644 index 00000000000..a8dd715930a Binary files /dev/null and b/Master/texmf-dist/doc/xelatex/bidi/presentation-sample.pdf differ diff --git a/Master/texmf-dist/doc/xelatex/bidi/presentation-sample.tex b/Master/texmf-dist/doc/xelatex/bidi/presentation-sample.tex index b7464609633..e562e9d83e9 100644 --- a/Master/texmf-dist/doc/xelatex/bidi/presentation-sample.tex +++ b/Master/texmf-dist/doc/xelatex/bidi/presentation-sample.tex @@ -1,13 +1,9 @@ \documentclass[12pt,twoside]{bidipresentation} -\usepackage{eso-pic} -\usepackage{graphicx} \usepackage{fontspec} \setmainfont[Script=Arabic,Mapping=farsidigits]{XB Niloofar} \usepackage[RTLdocument]{bidi} \pagestyle{pres} -\AddToShipoutPicture{ -\includegraphics{gradient.png} -} + \begin{document} \begin{titlepage} diff --git a/Master/texmf-dist/doc/xelatex/bidi/test-arydshln.pdf b/Master/texmf-dist/doc/xelatex/bidi/test-arydshln.pdf new file mode 100644 index 00000000000..5a250e1d019 Binary files /dev/null and b/Master/texmf-dist/doc/xelatex/bidi/test-arydshln.pdf differ diff --git a/Master/texmf-dist/doc/xelatex/bidi/test-arydshln.tex b/Master/texmf-dist/doc/xelatex/bidi/test-arydshln.tex new file mode 100644 index 00000000000..a19c6994bd1 --- /dev/null +++ b/Master/texmf-dist/doc/xelatex/bidi/test-arydshln.tex @@ -0,0 +1,27 @@ +\documentclass{article} +\usepackage{arydshln} +\usepackage{bidi} +\title{Testing \textsf{arydshln} Package in LTR and RTL modes} +\author{} +\date{} +\begin{document} +\maketitle +\section{LTR Mode} +\begin{center} +\begin{tabular}{|l::c;{2pt/2pt}r|}\hline +A&B&C\\\hdashline[1pt/1pt] +AAA&BBB&CCC\\\cdashline{1-2}[.4pt/1pt] +\multicolumn{2}{|l;{2pt/2pt}}{AB}&C\\\hdashline\hdashline +\end{tabular} +\end{center} +\section{RTL Mode} +\begin{RTL} +\begin{center} +\begin{tabular}{|r::c;{2pt/2pt}l|}\hline +A&B&C\\\hdashline[1pt/1pt] +AAA&BBB&CCC\\\cdashline{1-2}[.4pt/1pt] +\multicolumn{2}{|r;{2pt/2pt}}{AB}&C\\\hdashline\hdashline +\end{tabular} +\end{center} +\end{RTL} +\end{document} \ No newline at end of file diff --git a/Master/texmf-dist/doc/xelatex/bidi/test-bidi.pdf b/Master/texmf-dist/doc/xelatex/bidi/test-bidi.pdf new file mode 100644 index 00000000000..7f2a8336f4f Binary files /dev/null and b/Master/texmf-dist/doc/xelatex/bidi/test-bidi.pdf differ diff --git a/Master/texmf-dist/doc/xelatex/bidi/test-brochure.pdf b/Master/texmf-dist/doc/xelatex/bidi/test-brochure.pdf new file mode 100644 index 00000000000..42956be42c8 Binary files /dev/null and b/Master/texmf-dist/doc/xelatex/bidi/test-brochure.pdf differ diff --git a/Master/texmf-dist/doc/xelatex/bidi/test-brochure.tex b/Master/texmf-dist/doc/xelatex/bidi/test-brochure.tex new file mode 100644 index 00000000000..3066e0e4b41 --- /dev/null +++ b/Master/texmf-dist/doc/xelatex/bidi/test-brochure.tex @@ -0,0 +1,360 @@ +\documentclass[a4paper]{report} + +\usepackage[landscape,margin=1in]{geometry} +\usepackage{color} +\usepackage[RL]{flowfram}% we enable `RL' option for RTL multicolumn typesetting (see flowfram package documentation) +\usepackage[colorlinks,setpagesize=false]{hyperref} + +\usepackage[RTLdocument]{bidi} +% adjust \textheight so that it is an integer multiple of +% \baselineskip +\adjustheight{\textheight} + +% set up pagelayout. One column for title page +% two columns for the rest. +\onecolumninarea[1,2]{0.6\textwidth}{\textheight}{0.4\textwidth}{0pt} +\twocolumninarea[>2]{0.6\textwidth}{\textheight}{0.4\textwidth}{0pt} + +% Set up dynamic frame on the left. This is where +% the headings will go. + +\newdynamicframe{0.4\textwidth}{\textheight}{0pt}{0pt}[left] + +% put the chapter headings in this frame +\dfchaphead*{left} +% Modify the default style +\renewcommand{\DFchapterstyle}[1]{% +\raggedright\Huge\slshape\MakeUppercase{#1}\par} + +% Make static frames for background (only for page 1) +\vtwotone[1]{0.6\paperwidth}{[cmyk]{0.65,0.13,0,0}}{backleft}% +{0.4\paperwidth}{[cmyk]{0.94,0.54,0,0}}{backright} + +% Make a border along the top of each page +\vtwotonetop{1cm}{0.6\paperwidth}{[cmyk]{0.65,0.13,0,0}}{topleft}% +{0.4\paperwidth}{[cmyk]{0.94,0.54,0,0}}{topright} + +% make a static frame for the logo +\newstaticframe{0.2\textwidth}{0.25\textheight}{0pt}{0pt}[logo] + +% empty page style, because I am going to make my own +\pagestyle{empty} + +% Each new chapter sets \thispagestyle{\chapterfirstpagestyle}, change this empty as well +\renewcommand{\chapterfirstpagestyle}{empty} + +% Now make a frame in which to put my own customized footer +\newdynamicframe[>1]{\textwidth}{\headheight}{0pt}{-\footskip}[footer] + +% set the contents of the frame: +\setdynamiccontents*{footer}{% +School of Computing Sciences, University of East Anglia\hfill +http://www.cmp.uea.ac.uk/\hfill +page \thepage\ of \pageref*{lastpage}} + + +\newcommand{\env}[1]{\texttt{#1}} +\newcommand{\cmdname}[1]{\texttt{\symbol{92}#1}} +\newcommand{\meta}[1]{\textnormal{\textless\textit{#1}\textgreater}} + +\begin{document} + +% not a very interesting logo +\setstaticcontents*{logo}{\sffamily{\Huge\slshape FLF} Flowfram} + +{\noindent +\slshape\Huge\MakeUppercase{A Sample Brochure}\par +\vskip0.5in +\noindent\large\MakeUppercase{Nicola Talbot}\\ +} + + +\chapter{Introduction} + +The \textsl{flowfram} package is designed to enable you to create +frames in a document such that the +contents of the \env{document} environment flow from one +frame to the next in the order that they were defined. +This is useful for creating posters +or magazines or any other form of document that does not +conform to the standard one or two column layout. + +This is a modified version of the manual for the \textsl{flowfram} package. +It is intended to illustrated what can be done. See the full +manual (ffuserguide.pdf) for +a comprehensive description, as some parts of this document +may now be out of date. +If the columns are very narrow, it may be better to +use \cmdname{raggedright}, otherwise \TeX\ may have a +problem working out the line breaks. + +This is column~\thedisplayedframe. + +The main type of frame is the flow frame. This is described on +column~\ref{flow:flowframe} on page~\pageref{flow:flowframe}. +The order used to draw the contents of each frame on the page +is described in column~\ref{flow:stacking} on +page~\pageref{flow:stacking}. Floats are describe in +column~\ref{flow:floats} on page~\pageref{flow:floats}. + +\chapter{Setting up Frames} + +This is column~\thedisplayedframe. + +The \textsl{flowfram} package provides three types of frame: +{flow frames}, {static +frames} and {dynamic frames}. + +\section*{Flow Frames} + +\labelflow{flow:flowframe} +The flow frame is the principle type of frame. +The text of the \env{document} environment will flow from +one frame to the next in order of definition. Each +flow frame has an associated width, height, +position on the page, and optionally a border. + +It is recommended that all the flow frames in a document +have the same width, otherwise problems may occur +when a paragraph spans to flow frames of unequal +widths. This is because \TeX's output routine does not +register the change in \cmdname{hsize} until it reaches +a paragraph break. If it is absolutely necessary for +flow frames to have unequal widths, judicious use of +\cmdname{framebreak} is required. + +\section*{Static Frames} + +A static frame is a rectangular area in which text neither +flows into, nor flows out of. The contents must be set +explicitly, and once set, the contents of the static frame will +remain the same on each page until it is explicitly +changed. Thus, a static frame can be used, for example, to make +a company logo appear in the same place on every page. + +\section*{Dynamic Frames} + +A dynamic frame is similar to a static frame, but its contents +are re-typeset on each page. (A static frame stores its +contents in a savebox, whereas a dynamic frame stores its +contents in a macro). + +This is column~\thedisplayedframe. + +\chapter{Frame Attributes} +\label{sec:modattr} + +Once you have defined the {flow frames}, {static frames} and +{dynamic frames}, their attributes can be changed. +The three types of frame mostly have the +same set of attributes, but some are specific to a certain type. +The available attributes are as follows +(\textsuperscript{\textbf{F}} indicates the key is +only available for {flow frames}, +\textsuperscript{\textbf{S}} indicates the key is only available +for {static frames} +and \textsuperscript{\textbf{D}} indicates the key +is only available for {dynamic frames}): + +\begin{description} +\item[width=\meta{length}]\mbox{}\par The width of the frame. + +\item[height=\meta{length}]\mbox{}\par The height of the frame. + +\item[x=\meta{length}]\mbox{}\par The x-coordinate of the frame. + +\item[y=\meta{length}]\mbox{}\par The y-coordinate of the frame. + +\item[border=\meta{style}]\mbox{}\par The style of the border around the +frame, this can take the values: \texttt{none} (no border), +\texttt{plain} (plain border) or the name of a \LaTeX\ +frame making command without the preceding backslash. +The value \texttt{fbox} is equivalent to \texttt{plain}. + +\item[offset=\meta{offset}]\mbox{}\par The border offset, if it is a +user-defined border. This is the distance from the outer +edge of the left hand border to the left edge of the +bounding box of the text inside the border. The \textsl{flowfram} +package is able to compute the border for +known frame making commands. +If you define your own frame making command, you may need to +specify the offset explicitly, or the frames +may end up shifted to the right or left. + +\item[bordercolor=\meta{colour}]\mbox{}\par The colour of the border +if you are using a standard frame making command. +The colour can either be specified as, e.g.\ \texttt{green}, +or including the colour model, for example +\verb/[rgb]{0,1,0}/. + +\item[textcolor=\meta{colour}]\mbox{}\par The text colour for that +frame. Again, the colour can either be specified as, +e.g.\ \texttt{green}, or including the colour model, +for example \verb/[rgb]{0,1,0}/. + +\item[pages=\meta{page list}]\mbox{}\par The {list of +pages} for which the frame +should appear. This can either have the values: \texttt{all}, +\texttt{even}, \texttt{odd} or \texttt{none} (the latter +removes the frame from that point on---useful if you +have multiple pages with the same number), or it can be a +comma-separated list of single pages, or +{page ranges}. + +\item[margin=\meta{side}\textsuperscript{F}]\mbox{}\par The side of +the flow frame that its corresponding margin should go on. This +can take the values \texttt{left} or \texttt{right}. + +\item[clear=\meta{boolean}\textsuperscript{S}] If this value +is set, the static frame will be cleared at the start of the +next page. + +\item[style=\meta{cmd}\textsuperscript{D}]\mbox{}\par This should be +the name of a command \emph{without} the preceding backslash, +to be applied to the contents of the specified dynamic frame. +The command may either be a declaration, for example \verb/style=large/ +which will set the contents of all the dynamic frames in a +large font, or it can be a command that takes a single argument, +for example \verb/style=textbf/ +which will make the text for all the dynamic frames come out in +bold. To unset a style, do \verb/style=none/. + +\end{description} + +\chapter{Miscellaneous} + +\section*{Page Layout} + +The \textsl{flowfram} package has the package option \texttt{draft} +which will draw the {bounding boxes} for +each frame defined. At the bottom right of each +bounding box (except for the bounding box denoting the +typeblock), a marker will be shown to indictate the type +of frame, its IDN and its IDL. + +You can see the layout for the current page (irrespective of +whether or not the \texttt{draft} option has been set) using +the command:\newline +\cmdname{flowframeshowlayout} + +The headers and footers will appear as usual (but will not +be shown in draft mode), according to the format given by +\cmdname{pagestyle}. + +\section*{Frame Stacking Order} + +\labelflow{flow:stacking} +The material on each page is placed in the following order: +\begin{enumerate} +\item Each static frame defined for that page in ascending +order of IDN. + +\item Each flow frame defined for that page in ascending +order of IDN. + +\item Each dynamic frame defined for that page in ascending +order of IDN. + +\item {Bounding boxes} if the \texttt{draft} +package option has been used. +\end{enumerate} + +This ordering can be used to determine if you want something +to overlay or underlay everything else on the page. + +\section*{Prematurely Ending a Flow Frame} + +You can force text to move immediately to the next defined +flow frame using one of the standard \LaTeX\ page breaking commands +which work in an analogous way to the way they +work in standard two column mode. + +The command \cmdname{framebreak} is provided for situations +where a paragraph spans two flow frames +of different widths, as \TeX's output routine does not +adjust to the new value of \cmdname{hsize} until the last +paragraph of the previous frame has ended. As a +result, the end of the paragraph at the beginning of the new +flow frame retains the width of the previous flow frame. + +If you want to start a new page, rather than simply move to the +next frame, use the command\newline +\cmdname{finishthispage}. + +\section*{Floats} + +\labelflow{flow:floats} +Since floats (such as figures and tables) can only go in +{flow frames}, this package provides +the additional environments: +\env{staticfigure} and +\env{statictable} which can be used in static frames +and dynamic frames. Unlike their \env{figure} and +\env{table} counterparts, they are fixed in place, and +so do not take an optional placement specifier. The +\cmdname{caption} and \cmdname{label} commands can +be used within \env{staticfigure} and \env{statictable} as +usual. + +The standard \env{figure} and \env{table} commands will +behave as usual in the flow frames, but their starred versions, +\env{figure*} and \env{table*} behave no differently +from \env{figure} and \env{table}. + +\section*{Global Values} + +The following macros can be changed using\linebreak \cmdname{renewcommand}: + +\begin{itemize} +\item \cmdname{setffdraftcolor} + +This sets the colour of the bounding box +when it is displayed in draft mode. + +\item +\cmdname{setffdrafttypeblockcolor} + +This sets the colour of +the bounding box of the typeblock when it is displayed +in draft mode. + +\item \cmdname{fflabelfont} + +This sets the font size for the bounding box markers in +draft mode. + +\end{itemize} + +The following are lengths, which can be changed using +\cmdname{setlength}: + +\begin{itemize} +\item \cmdname{fflabelsep} + +This is the distance from the right hand side of the +bounding box at which to place the bounding box marker. + +\item \cmdname{flowframesep} + +This is the gap between the text of the frame and +its border, for the standard border types. + +\item \cmdname{flowframerule} + +This is the width of the frame's border, if using +a border given by a frame making command that uses \cmdname{fboxsep} +to set its border width. + +\item \cmdname{columnsep} + +This is the horizontal distance between flow frames when using one of the +\cmdname{Ncolumn} type of commands + +\item \cmdname{vcolumnsep} + +This is the vertical distance between the flow frames and the static or +dynamic frame when using one of the \cmdname{Ncolumntop} type of commands. +\end{itemize} + +\label{lastpage} +\end{document} diff --git a/Master/texmf-dist/doc/xelatex/bidi/test-casualcv.pdf b/Master/texmf-dist/doc/xelatex/bidi/test-casualcv.pdf new file mode 100644 index 00000000000..6578ceb310d Binary files /dev/null and b/Master/texmf-dist/doc/xelatex/bidi/test-casualcv.pdf differ diff --git a/Master/texmf-dist/doc/xelatex/bidi/test-casualcv.tex b/Master/texmf-dist/doc/xelatex/bidi/test-casualcv.tex new file mode 100644 index 00000000000..7e6c03378e1 --- /dev/null +++ b/Master/texmf-dist/doc/xelatex/bidi/test-casualcv.tex @@ -0,0 +1,71 @@ +\documentclass[11pt,a4paper]{bidimoderncv} +\cvtheme[orange]{bidicasual} % you can use orange, red, green and blue as options +\usepackage[scale=0.8]{geometry} +\usepackage{fontspec} +\usepackage[RTLdocument]{bidi} +\def\refname{تألیفات} +\setmainfont[Script=Arabic,Mapping=parsidigits]{XB Niloofar} +\newfontfamily\rmfamily[Mapping=tex-text]{Linux Libertine} +\AtBeginDocument{\recomputelengths} +\resumename{رزومه} +\firstname{سید محمد} +\familyname{یزدی اصفهانی} +\title{رزومهٔ من} +\address{تهران، خیابان آزادی پلاک ۹} +\mobile{۰۹۱۸۹۶۹۴۹۶} +\phone{۹۸۹۰۸۳۴۱} +\fax{۹۸۹۰۸۳۴۲} +\email{vafa@users.berlios.de} +\extrainfo{اطلاعات اضافی} +\photo[64pt]{picture} +\quote{نقل قول} +\begin{document} +\maketitle +\section{تحصیلات} +\cventry{سال--سال}{درجه}{دانشگاه}{شهر}{\textit{نمره}}{توضیح} % arguments 3 to 6 are optional +\cventry{سال--سال}{درجه}{دانشگاه}{شهر}{\textit{نمره}}{توضیح} % arguments 3 to 6 are optional + +\section{پایان‌نامهٔ کارشناسی ارشد} +\cvline{عنوان}{\emph{عنوان}} +\cvline{استاد راهنما}{استاد راهنما} +\cvline{توضیح}{\small چکیده کوچک پایان‌نامه} + +\section{تجربیات} +\subsection{عنوان} +\cventry{سال--سال}{نام شغل}{صاحب کار}{شهر}{}{توضیح} % arguments 3 to 6 are optional +\cventry{سال--سال}{نام شغل}{صاحب کار}{شهر}{}{توضیح} % arguments 3 to 6 are optional +\subsection{متفرقه} +\cventry{سال--سال}{نام شغل}{صاحب کار}{شهر}{}{توضیح خط ۱\newline{}توضیح خط ۲}% arguments 3 to 6 are optional + +\section{زبانها} +\cvlanguage{زبان ۱}{درجه مهارت}{نظر} +\cvlanguage{زبان ۲}{درجه مهارت}{نظر} +\cvlanguage{زبان ۳}{درجه مهارت}{نظر} + +\section{مهارتهای رایانه‌ای} +\cvcomputer{طبقه ۱}{یک، دو، سه}{طبقه ۴}{یک، دو، سه} +\cvcomputer{طبقه ۲}{یک، دو، سه}{طبقه ۵}{یک، دو، سه} +\cvcomputer{طبقه ۳}{یک، دو، سه}{طبقه ۶}{یک، دو، سه} + +\section{علاقه‌ها} +\cvline{علاقه ۱}{\small توضیح} +\cvline{علاقه ۲}{\small توضیح} +\cvline{علاقه ۳}{\small توضیح} + +\renewcommand{\listitemsymbol}{-} % change the symbol for lists + +\section{بعدی ۱} +\cvlistitem{شماره ۱} +\cvlistitem{شماره ۲} +\cvlistitem[+]{شماره ۳} % optional other symbol + +\section{بعدی ۲} +\cvlistdoubleitem[\Neutral]{شماره ۱}{شماره ۴} +\cvlistdoubleitem[\Neutral]{شماره ۲}{شماره ۵} +\cvlistdoubleitem[\Neutral]{شماره ۳}{} + +\nocite{*} +\bibliographystyle{plain} +\bibliography{publications} % 'publications' is the name of a BibTeX file + +\end{document} diff --git a/Master/texmf-dist/doc/xelatex/bidi/test-classiccv.pdf b/Master/texmf-dist/doc/xelatex/bidi/test-classiccv.pdf new file mode 100644 index 00000000000..1764e6a5a11 Binary files /dev/null and b/Master/texmf-dist/doc/xelatex/bidi/test-classiccv.pdf differ diff --git a/Master/texmf-dist/doc/xelatex/bidi/test-classiccv.tex b/Master/texmf-dist/doc/xelatex/bidi/test-classiccv.tex new file mode 100644 index 00000000000..a1fdd2c3437 --- /dev/null +++ b/Master/texmf-dist/doc/xelatex/bidi/test-classiccv.tex @@ -0,0 +1,71 @@ +\documentclass[11pt,a4paper]{bidimoderncv} +\cvtheme[green]{bidiclassic} % you can use orange, red, green, grey and blue as options +\usepackage[scale=0.8]{geometry} +\usepackage{fontspec} +\setmainfont[Script=Arabic,Mapping=parsidigits]{XB Zar} +\newfontfamily\rmfamily[Mapping=tex-text]{Linux Libertine} +\def\refname{تألیفات} +\usepackage[RTLdocument]{bidi} +\AtBeginDocument{\recomputelengths} +\resumename{رزومه} +\firstname{وفا} +\familyname{خلیقی} +\title{رزومهٔ من} +\address{تهران، خیابان آزادی پلاک ۹} +\mobile{۰۹۱۸۹۶۹۴۹۶} +\phone{۹۸۹۰۸۳۴۱} +\fax{۹۸۹۰۸۳۴۲} +\email{me@you.com} +\extrainfo{اطلاعات اضافی} +\photo[64pt]{picture} +\quote{نقل قول} +\begin{document} +\maketitle +\section{تحصیلات} +\cventry{سال--سال}{درجه}{دانشگاه}{شهر}{\textit{نمره}}{توضیح} % arguments 3 to 6 are optional +\cventry{سال--سال}{درجه}{دانشگاه}{شهر}{\textit{نمره}}{توضیح} % arguments 3 to 6 are optional + +\section{پایان‌نامهٔ کارشناسی ارشد} +\cvline{عنوان}{\emph{عنوان}} +\cvline{استاد راهنما}{استاد راهنما} +\cvline{توضیح}{\small چکیده کوچک پایان‌نامه} + +\section{تجربیات} +\subsection{عنوان} +\cventry{سال--سال}{نام شغل}{صاحب کار}{شهر}{}{توضیح} % arguments 3 to 6 are optional +\cventry{سال--سال}{نام شغل}{صاحب کار}{شهر}{}{توضیح} % arguments 3 to 6 are optional +\subsection{متفرقه} +\cventry{سال--سال}{نام شغل}{صاحب کار}{شهر}{}{توضیح خط ۱\newline{}توضیح خط ۲}% arguments 3 to 6 are optional + +\section{زبانها} +\cvlanguage{زبان ۱}{درجه مهارت}{نظر} +\cvlanguage{زبان ۲}{درجه مهارت}{نظر} +\cvlanguage{زبان ۳}{درجه مهارت}{نظر} + +\section{مهارتهای رایانه‌ای} +\cvcomputer{طبقه ۱}{یک، دو، سه}{طبقه ۴}{یک، دو، سه} +\cvcomputer{طبقه ۲}{یک، دو، سه}{طبقه ۵}{یک، دو، سه} +\cvcomputer{طبقه ۳}{یک، دو، سه}{طبقه ۶}{یک، دو، سه} + +\section{علاقه‌ها} +\cvline{علاقه ۱}{\small توضیح} +\cvline{علاقه ۲}{\small توضیح} +\cvline{علاقه ۳}{\small توضیح} + +\renewcommand{\listitemsymbol}{-} % change the symbol for lists + +\section{بعدی ۱} +\cvlistitem{شماره ۱} +\cvlistitem{شماره ۲} +\cvlistitem[+]{شماره ۳} % optional other symbol + +\section{بعدی ۲} +\cvlistdoubleitem[\Neutral]{شماره ۱}{شماره ۴} +\cvlistdoubleitem[\Neutral]{شماره ۲}{شماره ۵} +\cvlistdoubleitem[\Neutral]{شماره ۳}{} + +\nocite{*} +\bibliographystyle{plain} +\bibliography{publications} % 'publications' is the name of a BibTeX file + +\end{document} diff --git a/Master/texmf-dist/doc/xelatex/bidi/test-color.pdf b/Master/texmf-dist/doc/xelatex/bidi/test-color.pdf new file mode 100644 index 00000000000..22232053af4 Binary files /dev/null and b/Master/texmf-dist/doc/xelatex/bidi/test-color.pdf differ diff --git a/Master/texmf-dist/doc/xelatex/bidi/test-color.tex b/Master/texmf-dist/doc/xelatex/bidi/test-color.tex new file mode 100644 index 00000000000..f2a9dcd7395 --- /dev/null +++ b/Master/texmf-dist/doc/xelatex/bidi/test-color.tex @@ -0,0 +1,44 @@ +\documentclass{article} +\usepackage{fontspec} +\usepackage{xecolour} % for RTL coloured texts that spans more than a line +\usepackage{fullpage} +\usepackage{colortbl} +\setmainfont[Scale=1,Script=Arabic,Mapping=farsidigits]{XB Kayhan} +\usepackage{xcolor} +\usepackage[RTLdocument]{bidi} +\begin{document} +این یک آزمایش است. + +\bigskip +\fcolorbox{red}{yellow}{\begin{minipage}{0.8\textwidth} +این یک متن است که من آن را داخل یک جعبهٔ زردرنگ قرار می‌دهم. این یک متن است که من آن را داخل یک جعبهٔ زردرنگ قرار می‌دهم +\end{minipage}} + +این {\color{red} رنگ قرمز} است و این هم \textcolor{blue}{رنگ آبی} است همانطور که می‌بینید. + +\bigskip +من اسم خودم {\color{red} وفا خلیقی} را با رنگ قرمز می‌نویسم. + +\bigskip +من اسم خودم \textcolor{blue}{وفا خلیقی} را با رنگ آبی می‌نویسم. + +\bigskip +\colorbox{yellow}{\begin{minipage}{0.8\textwidth} +این یک متن است که من آن را داخل یک جعبهٔ زردرنگ قرار می‌دهم. این یک متن است که من آن را داخل یک جعبهٔ زردرنگ قرار می‌دهم +\end{minipage}} + +\bigskip +این یک پاراگراف با \blue{رنگ آبی اول است و همینطور و همینطور ما می‌توانیم از رنگاهی مختلف استفاده کنیم} و حالا +\red{این روزها حجم اخبار و مطالب مرتبط با ایران و مسایل مربوط به آن بسیار زیاد شده وابزارهایی مانند گوگل ریدر برای مرور لیست بلند بالایی از سایتها و وبلاگ های به روز شده ، بیشتر مورد استفاده قرار میگیرد.} و حالا هم +\darkred{یکی از مشکلاتی که در استفاده از گوگل ریدر داشتم، نامناسب بودن فونت فارسی آن بود. اگر چه عمده وبلاگها و سایتها از فونت تاهوما (مانند فونتی که این مطالب با آن نوشته شده است) استفاده می کنند اما تعدادی از وبلاگها از فونتهای دیگری که بعضی وقتها خیلی ریز هم هستند }استفاده می کنند که خواندن آن در گوگل ریدر بسیار دشوار است. متاسفانه در گوگل ریدر بخشی برای تغییر فونت وجود ندارد و نمیتوان نوع فونت یا اندازه مطالب آن را تغییر داد. بعد از کمی جستجو بر روی اینترنت راه حل جالبی را پیدا کردم که با کمی تغییر برای مطالب فارسی هم قابل استفاده است. +اگر از فایرفاکس برای مرور مطالب جدید در گوگل ریدر استفاده می کنید، این راه حل را باری حل این مشکل به شما پیشنهاد میکنم + +\bigskip +حالا نوبت جعبه‌های رنگی است یعنی مثلاً \colorbox{red}{{\color{white}سلام}} و \fcolorbox{yellow}{red}{{\color{white}این یک متن داخل جعبه رنگی است که کمی طولانی است}} + + + + + + +\end{document} diff --git a/Master/texmf-dist/doc/xelatex/bidi/test-supertabular.pdf b/Master/texmf-dist/doc/xelatex/bidi/test-supertabular.pdf new file mode 100644 index 00000000000..d6c4539b883 Binary files /dev/null and b/Master/texmf-dist/doc/xelatex/bidi/test-supertabular.pdf differ diff --git a/Master/texmf-dist/doc/xelatex/bidi/test-supertabular.tex b/Master/texmf-dist/doc/xelatex/bidi/test-supertabular.tex index 5e43860b849..af040d23c2c 100644 --- a/Master/texmf-dist/doc/xelatex/bidi/test-supertabular.tex +++ b/Master/texmf-dist/doc/xelatex/bidi/test-supertabular.tex @@ -65,9 +65,9 @@ zeta & GREEK SMALL LETTER ZETA & 03B6\\ \tablehead {\bfseries Entity&\bfseries Unicode Name&\bfseries Unicode\\ \hline} \tabletail - {\hline \multicolumn{3}{r}{\emph{Continued on next page}}\\} + {\hline \multicolumn{3}{l}{\emph{Continued on next page}}\\} \tablelasttail{\hline} -\begin{supertabular}{lll} +\begin{supertabular}{rrr} alpha & GREEK SMALL LETTER ALPHA & 03B1\\ beta & GREEK SMALL LETTER BETA & 03B2\\ chi & GREEK SMALL LETTER CHI & 03C7\\ diff --git a/Master/texmf-dist/doc/xelatex/bidi/test-tabular.pdf b/Master/texmf-dist/doc/xelatex/bidi/test-tabular.pdf new file mode 100644 index 00000000000..6da31ff5b8d Binary files /dev/null and b/Master/texmf-dist/doc/xelatex/bidi/test-tabular.pdf differ diff --git a/Master/texmf-dist/doc/xelatex/bidi/test-tabular.tex b/Master/texmf-dist/doc/xelatex/bidi/test-tabular.tex index ffc08ac933a..826f38c3515 100644 --- a/Master/texmf-dist/doc/xelatex/bidi/test-tabular.tex +++ b/Master/texmf-dist/doc/xelatex/bidi/test-tabular.tex @@ -36,7 +36,7 @@ In this document we test \LaTeX's default tabular in \textsf{RTL} and \textsf{LT \setRTL \begin{center}\small -\begin{tabular}{|l||c|l|c|l|c|l|} +\begin{tabular}{|r||c|r|c|r|c|r|} \hline & \multicolumn{2}{c|}{6.15--7.15 pm} & \multicolumn{2}{c|}{7.20--8.20 pm} & \multicolumn{2}{c|}{8.30--9.30 pm} \\ \cline{2-7} diff --git a/Master/texmf-dist/doc/xelatex/bidi/test-tabularx.pdf b/Master/texmf-dist/doc/xelatex/bidi/test-tabularx.pdf new file mode 100644 index 00000000000..0e95eaa1d03 Binary files /dev/null and b/Master/texmf-dist/doc/xelatex/bidi/test-tabularx.pdf differ diff --git a/Master/texmf-dist/doc/xelatex/bidi/test-tabularx.tex b/Master/texmf-dist/doc/xelatex/bidi/test-tabularx.tex index 2867c7cd17a..719c266896f 100644 --- a/Master/texmf-dist/doc/xelatex/bidi/test-tabularx.tex +++ b/Master/texmf-dist/doc/xelatex/bidi/test-tabularx.tex @@ -23,7 +23,7 @@ Lion & Yellow & Elephants & Tartare \\\cline{4-4} \section{RTL} \setRTL -\begin{tabularx}{\linewidth}{|l|p{1.25cm}|p{1.5cm}|X|}\hline +\begin{tabularx}{\linewidth}{|r|p{1.25cm}|p{1.5cm}|X|}\hline \multicolumn{1}{|c|}{\textbf{Animal}} & \textbf{Hair Colour} & \multicolumn{2}{c|}{\textbf{Favourite foods}} \\\hline\hline diff --git a/Master/texmf-dist/doc/xelatex/bidi/test-tabulary.pdf b/Master/texmf-dist/doc/xelatex/bidi/test-tabulary.pdf new file mode 100644 index 00000000000..425eb03bfc7 Binary files /dev/null and b/Master/texmf-dist/doc/xelatex/bidi/test-tabulary.pdf differ diff --git a/Master/texmf-dist/doc/xelatex/bidi/test1-colortbl.pdf b/Master/texmf-dist/doc/xelatex/bidi/test1-colortbl.pdf new file mode 100644 index 00000000000..ddb4b770f07 Binary files /dev/null and b/Master/texmf-dist/doc/xelatex/bidi/test1-colortbl.pdf differ diff --git a/Master/texmf-dist/doc/xelatex/bidi/test1-colortbl.tex b/Master/texmf-dist/doc/xelatex/bidi/test1-colortbl.tex new file mode 100644 index 00000000000..97f20871db1 --- /dev/null +++ b/Master/texmf-dist/doc/xelatex/bidi/test1-colortbl.tex @@ -0,0 +1,47 @@ +\documentclass{article} +\usepackage{fontspec} +\setmainfont[Mapping=farsidigits,Script=Arabic]{XB Kayhan} +\usepackage{hhline} +\usepackage{colortbl} +\usepackage[RTLdocument]{bidi} +\begin{document} +این فقط یک آزمایش است +\begin{center} +\setlength\arrayrulewidth{5pt} +\setlength\doublerulesep{5pt} + \renewcommand{\arraystretch}{2} + \definecolor{orange}{cmyk}{0,0.61,0.87,0} + \definecolor{indigo}{cmyk}{0.8,0.9,0,0} + \definecolor{violet}{cmyk}{0.6,0.9,0,0} + \newcommand\rainbowline[1]{% + \hhline{% + >{\arrayrulecolor {red}\doublerulesepcolor[rgb]{.3,.3,1}}% + |#1:=% + >{\arrayrulecolor{orange}\doublerulesepcolor[rgb]{.4,.4,1}}% + =% + >{\arrayrulecolor{yellow}\doublerulesepcolor[rgb]{.5,.5,1}}% + =% + >{\arrayrulecolor {green}\doublerulesepcolor[rgb]{.6,.6,1}}% + =% + >{\arrayrulecolor {blue}\doublerulesepcolor[rgb]{.7,.7,1}}% + =% + >{\arrayrulecolor{indigo}\doublerulesepcolor[rgb]{.8,.8,1}}% + =% + >{\arrayrulecolor{violet}\doublerulesepcolor[rgb]{.9,.9,1}}% + =:#1|% + }} + \arrayrulecolor{red} + \doublerulesepcolor[rgb]{.3,.3,1} + \begin{tabular}{||*7{>{\columncolor[gray]{.9}}c}||} + \rainbowline{t}% + \arrayrulecolor{violet}\doublerulesepcolor[rgb]{.9,.9,1} + وفا&خلیقی&یک&دانشجوی&ریاضی&است& + \multicolumn{1}{>{\columncolor[gray]{.9}}c||}{حرف آخر}\\ + \rainbowline{}% + 1&2&3&4&5&6& + \multicolumn{1}{>{\columncolor[gray]{.9}}c||}{7}\\ + \rainbowline{b}% + \end{tabular} + \end{center} +این صرفاً یک آزمایش است +\end{document} diff --git a/Master/texmf-dist/doc/xelatex/bidi/test1-wrapfig.pdf b/Master/texmf-dist/doc/xelatex/bidi/test1-wrapfig.pdf new file mode 100644 index 00000000000..2e2047a40aa Binary files /dev/null and b/Master/texmf-dist/doc/xelatex/bidi/test1-wrapfig.pdf differ diff --git a/Master/texmf-dist/doc/xelatex/bidi/test2-colortbl.pdf b/Master/texmf-dist/doc/xelatex/bidi/test2-colortbl.pdf new file mode 100644 index 00000000000..d682c51ce15 Binary files /dev/null and b/Master/texmf-dist/doc/xelatex/bidi/test2-colortbl.pdf differ diff --git a/Master/texmf-dist/doc/xelatex/bidi/test2-colortbl.tex b/Master/texmf-dist/doc/xelatex/bidi/test2-colortbl.tex new file mode 100644 index 00000000000..63b50618837 --- /dev/null +++ b/Master/texmf-dist/doc/xelatex/bidi/test2-colortbl.tex @@ -0,0 +1,28 @@ +\documentclass{article} +\usepackage{fullpage} +\usepackage{fontspec} +\usepackage{colortbl} +\setmainfont[Scale=1,Script=Arabic,Mapping=farsidigits]{XB Kayhan} +\usepackage[RTLdocument]{bidi} +\begin{document} +این فقط یک آزمایش است + +\setlength{\extrarowheight}{2mm} +\setlength{\tabcolsep}{2mm} +\begin{center} +\begin{tabular}{|l|% +>{\columncolor{yellow}}c|c|>{\columncolor{yellow}}c|c|% +>{\columncolor{red}\bfseries}c<{\textsc{GBP}}|} +\hline +\multicolumn{3}{>{\columncolor{red}}r}{\color{white}\textbf{لَنْدَنْ}} +&\multicolumn{3}{>{\columncolor{red}}l}{\color{white}\textbf{قیمت}} +\\[1pt] +\hline +سیدنی & OG4G &سشنبه ۱۰ اکتبر &دوشنبه ۲۱ اکتبر یا ۲۸‌ام &11 یا ۱۸ روز &999\\ +& &سشنبه ۱۷ اکتبر &دوشنبه ۲۱ اکتبر یا ۲۸‌ام & 4 یا ۱۱ روز &999\\ +& OG7A &یکشنبه ۱۱ اکتبر &دوشنبه ۲۱ اکتبر یا ۲۸‌ام & 8 یا ۱۵ روز &999\\ +& &یکشنبه ۲۰ اکتبر &دوشنبه ۲۸ اکتبر & 8 روز &999\\ +\hline +\end{tabular} +\end{center} +\end{document} diff --git a/Master/texmf-dist/doc/xelatex/bidi/test2-wrapfig.pdf b/Master/texmf-dist/doc/xelatex/bidi/test2-wrapfig.pdf new file mode 100644 index 00000000000..e915bd611be Binary files /dev/null and b/Master/texmf-dist/doc/xelatex/bidi/test2-wrapfig.pdf differ diff --git a/Master/texmf-dist/doc/xelatex/bidi/test3-wrapfig.pdf b/Master/texmf-dist/doc/xelatex/bidi/test3-wrapfig.pdf new file mode 100644 index 00000000000..cf73f50ea25 Binary files /dev/null and b/Master/texmf-dist/doc/xelatex/bidi/test3-wrapfig.pdf differ diff --git a/Master/texmf-dist/tex/xelatex/bidi/amsart-bidi.def b/Master/texmf-dist/tex/xelatex/bidi/amsart-bidi.def deleted file mode 100644 index 4eaa7ac72ed..00000000000 --- a/Master/texmf-dist/tex/xelatex/bidi/amsart-bidi.def +++ /dev/null @@ -1,112 +0,0 @@ -%% -%% This is file `amsart-bidi.def', - -%% -%% __________________________________ -%% Copyright © 2009-2010 Vafa Khalighi -%% -%% License information appended. -%% -%% -\ProvidesFile{amsart-bidi.def}[2010/03/01 v0.3 adaptations for amsart class] -\def\@tocline#1#2#3#4#5#6#7{\relax - \ifnum #1>\c@tocdepth % then omit - \else - \par \addpenalty\@secpenalty\addvspace{#2}% - \begingroup \hyphenpenalty\@M - \@ifempty{#4}{% - \@tempdima\csname r@tocindent\number#1\endcsname\relax - }{% - \@tempdima#4\relax - }% - \parindent\z@ \if@RTL\rightskip\else\leftskip\fi#3\relax \advance\if@RTL\rightskip\else\leftskip\fi\@tempdima\relax - \if@RTL\leftskip\else\rightskip\fi\@pnumwidth plus4em \parfillskip-\@pnumwidth - #5\leavevmode\hskip-\@tempdima #6\nobreak\relax - \hfil\hbox to\@pnumwidth{\@tocpagenum{#7}}\par - \nobreak - \endgroup - \fi} -\renewcommand\thesubsection {\thesection\@SepMark\arabic{subsection}} -\renewcommand\thesubsubsection {\thesubsection \@SepMark\arabic{subsubsection}} -\renewcommand\theparagraph {\thesubsubsection\@SepMark\arabic{paragraph}} -\renewcommand\thesubparagraph {\theparagraph\@SepMark\arabic{subparagraph}} -\def\part{\@startsection{part}{0}% - \z@{\linespacing\@plus\linespacing}{.5\linespacing}% - {\normalfont\bfseries\if@RTL\raggedleft\else\raggedright\fi}} -\renewenvironment{thebibliography}[1]{% - \@bibtitlestyle - \normalfont\bibliofont\labelsep .5em\relax - \renewcommand\theenumiv{\arabic{enumiv}}\let\p@enumiv\@empty - \list{\@biblabel{\theenumiv}}{\settowidth\labelwidth{\@biblabel{#1}}% - \leftmargin\labelwidth \advance\leftmargin\labelsep - \rightmargin\labelwidth \advance\rightmargin\labelsep - \usecounter{enumiv}}% - \sloppy \clubpenalty\@M \widowpenalty\clubpenalty - \sfcode`\.=\@m -}{% - \def\@noitemerr{\@latex@warning{Empty `thebibliography' environment}}% - \endlist -} -\def\right@footnote{% - \hbox to \columnwidth - {\beginR \vbox{\kern-.4\p@ - \hrule\@width 5pc\kern11\p@\kern-\footnotesep}\hfil\endR}} -\def\left@footnote{\kern-.4\p@ - \hrule\@width 5pc\kern11\p@\kern-\footnotesep} -\long\def\@footnotetext#1{% - \begingroup - \setbox\footins - \vbox{\if@RTL@footnote\@RTLtrue\else\@RTLfalse\fi\reset@font\footnotesize - \interlinepenalty\interfootnotelinepenalty - \splittopskip\footnotesep - \splitmaxdepth \dp\strutbox \floatingpenalty \@MM - \hsize\columnwidth \@parboxrestore \parindent\normalparindent \sloppy - \bidi@footnotetext@dir{#1}% - \protected@edef\@currentlabel{\csname p@footnote\endcsname\@thefnmark}\@makefntext - {\rule{\z@}{\footnotesep}\ignorespaces#1\unskip\strut\par}}% - \bidi@footnotetext@after - \insert\footins{\unvbox\footins}% - \endgroup} -\long\def\@RTLfootnotetext#1{% - \begingroup - \setbox\footins - \vbox{\@RTLtrue\reset@font\footnotesize - \interlinepenalty\interfootnotelinepenalty - \splittopskip\footnotesep - \splitmaxdepth \dp\strutbox \floatingpenalty \@MM - \hsize\columnwidth \@parboxrestore \parindent\normalparindent \sloppy - \bidi@footnotetext@dir{#1}% - \protected@edef\@currentlabel{\csname p@footnote\endcsname\@thefnmark}\@makefntext - {\rule{\z@}{\footnotesep}\ignorespaces #1\unskip\strut\par}}% - \bidi@footnotetext@after - \insert\footins{\unvbox\footins}% - \endgroup} -\long\def\@LTRfootnotetext#1{% - \begingroup - \setbox\footins - \vbox{\@RTLfalse\reset@font\footnotesize - \interlinepenalty\interfootnotelinepenalty - \splittopskip\footnotesep - \splitmaxdepth \dp\strutbox \floatingpenalty \@MM - \hsize\columnwidth \@parboxrestore \parindent\normalparindent \sloppy - \bidi@footnotetext@dir{#1}% - \protected@edef\@currentlabel{\csname p@footnote\endcsname\@thefnmark}\@makefntext - {\rule{\z@}{\footnotesep}\ignorespaces #1\unskip\strut\par}}% - \bidi@footnotetext@after - \insert\footins{\unvbox\footins}% - \endgroup} -%% -%% Copyright © 2009-2010 by Vafa Khalighi -%% -%% Distributable 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 "maintained" (as per LPPL maintenance status) -%% by Vafa Khalighi. -%% -%% -%% -%% -%% -%% End of file `amsart-bidi.def'. diff --git a/Master/texmf-dist/tex/xelatex/bidi/amsart-xetex-bidi.def b/Master/texmf-dist/tex/xelatex/bidi/amsart-xetex-bidi.def new file mode 100644 index 00000000000..eff5ffc15e6 --- /dev/null +++ b/Master/texmf-dist/tex/xelatex/bidi/amsart-xetex-bidi.def @@ -0,0 +1,98 @@ +%% +%% This is file `amsart-xetex-bidi.def', + +%% +%% __________________________________ +%% Copyright © 2009-2010 Vafa Khalighi +%% +%% License information appended. +%% +%% +\ProvidesFile{amsart-xetex-bidi.def}[2010/07/25 v0.4 bidi adaptations for amsart class for XeTeX engine] +\def\@tocline#1#2#3#4#5#6#7{\relax + \ifnum #1>\c@tocdepth % then omit + \else + \par \addpenalty\@secpenalty\addvspace{#2}% + \begingroup \hyphenpenalty\@M + \@ifempty{#4}{% + \@tempdima\csname r@tocindent\number#1\endcsname\relax + }{% + \@tempdima#4\relax + }% + \parindent\z@ \if@RTL\rightskip\else\leftskip\fi#3\relax \advance\if@RTL\rightskip\else\leftskip\fi\@tempdima\relax + \if@RTL\leftskip\else\rightskip\fi\@pnumwidth plus4em \parfillskip-\@pnumwidth + #5\leavevmode\hskip-\@tempdima #6\nobreak\relax + \hfil\hbox to\@pnumwidth{\@tocpagenum{#7}}\par + \nobreak + \endgroup + \fi} +\renewcommand\thesubsection {\thesection\@SepMark\arabic{subsection}} +\renewcommand\thesubsubsection {\thesubsection \@SepMark\arabic{subsubsection}} +\renewcommand\theparagraph {\thesubsubsection\@SepMark\arabic{paragraph}} +\renewcommand\thesubparagraph {\theparagraph\@SepMark\arabic{subparagraph}} +\def\part{\@startsection{part}{0}% + \z@{\linespacing\@plus\linespacing}{.5\linespacing}% + {\normalfont\bfseries\if@RTL\raggedleft\else\raggedright\fi}} +\def\right@footnote{% + \hbox to \columnwidth + {\beginR \vbox{\kern-.4\p@ + \hrule\@width 5pc\kern11\p@\kern-\footnotesep}\hfil\endR}} +\def\left@footnote{\kern-.4\p@ + \hrule\@width 5pc\kern11\p@\kern-\footnotesep} +\long\def\@footnotetext#1{% + \begingroup + \setbox\footins + \vbox{\if@RTL@footnote\@RTLtrue\else\@RTLfalse\fi\reset@font\footnotesize + \interlinepenalty\interfootnotelinepenalty + \splittopskip\footnotesep + \splitmaxdepth \dp\strutbox \floatingpenalty \@MM + \hsize\columnwidth \@parboxrestore \parindent\normalparindent \sloppy + \bidi@footnotetext@dir{#1}% + \protected@edef\@currentlabel{\csname p@footnote\endcsname\@thefnmark}\@makefntext + {\rule{\z@}{\footnotesep}\ignorespaces#1\unskip\strut\par}}% + \bidi@footnotetext@after + \insert\footins{\unvbox\footins}% + \endgroup} +\long\def\@RTLfootnotetext#1{% + \begingroup + \setbox\footins + \vbox{\@RTLtrue\reset@font\footnotesize + \interlinepenalty\interfootnotelinepenalty + \splittopskip\footnotesep + \splitmaxdepth \dp\strutbox \floatingpenalty \@MM + \hsize\columnwidth \@parboxrestore \parindent\normalparindent \sloppy + \bidi@footnotetext@dir{#1}% + \protected@edef\@currentlabel{\csname p@footnote\endcsname\@thefnmark}\@makefntext + {\rule{\z@}{\footnotesep}\ignorespaces #1\unskip\strut\par}}% + \bidi@footnotetext@after + \insert\footins{\unvbox\footins}% + \endgroup} +\long\def\@LTRfootnotetext#1{% + \begingroup + \setbox\footins + \vbox{\@RTLfalse\reset@font\footnotesize + \interlinepenalty\interfootnotelinepenalty + \splittopskip\footnotesep + \splitmaxdepth \dp\strutbox \floatingpenalty \@MM + \hsize\columnwidth \@parboxrestore \parindent\normalparindent \sloppy + \bidi@footnotetext@dir{#1}% + \protected@edef\@currentlabel{\csname p@footnote\endcsname\@thefnmark}\@makefntext + {\rule{\z@}{\footnotesep}\ignorespaces #1\unskip\strut\par}}% + \bidi@footnotetext@after + \insert\footins{\unvbox\footins}% + \endgroup} +%% +%% Copyright © 2009-2010 by Vafa Khalighi +%% +%% Distributable 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 "maintained" (as per LPPL maintenance status) +%% by Vafa Khalighi. +%% +%% +%% +%% +%% +%% End of file `amsart-xetex-bidi.def'. diff --git a/Master/texmf-dist/tex/xelatex/bidi/amsbook-bidi.def b/Master/texmf-dist/tex/xelatex/bidi/amsbook-bidi.def deleted file mode 100644 index 04bbebd7966..00000000000 --- a/Master/texmf-dist/tex/xelatex/bidi/amsbook-bidi.def +++ /dev/null @@ -1,122 +0,0 @@ -%% -%% This is file `amsbook-bidi.def', - -%% -%% __________________________________ -%% Copyright © 2009-2010 Vafa Khalighi -%% -%% License information appended. -%% -%% -\ProvidesFile{amsbook-bidi.def}[2010/03/01 v0.3 adaptations for amsbook class] -\def\@tocline#1#2#3#4#5#6#7{\relax - \ifnum #1>\c@tocdepth % then omit - \else - \par \addpenalty\@secpenalty\addvspace{#2}% - \begingroup \hyphenpenalty\@M - \@ifempty{#4}{% - \@tempdima\csname r@tocindent\number#1\endcsname\relax - }{% - \@tempdima#4\relax - }% - \parindent\z@ \if@RTL\rightskip\else\leftskip\fi#3\relax \advance\if@RTL\rightskip\else\leftskip\fi\@tempdima\relax - \if@RTL\leftskip\else\rightskip\fi\@pnumwidth plus4em \parfillskip-\@pnumwidth - #5\leavevmode\hskip-\@tempdima #6\nobreak\relax - \hfil\hbox to\@pnumwidth{\@tocpagenum{#7}}\par - \nobreak - \endgroup - \fi} -\renewcommand\thesubsection {\thesection\@SepMark\arabic{subsection}} -\renewcommand\thesubsubsection {\thesubsection \@SepMark\arabic{subsubsection}} -\renewcommand\theparagraph {\thesubsubsection\@SepMark\arabic{paragraph}} -\renewcommand\thesubparagraph {\theparagraph\@SepMark\arabic{subparagraph}} -\renewenvironment{thebibliography}[1]{% - \@bibtitlestyle - \normalfont\bibliofont\labelsep .5em\relax - \renewcommand\theenumiv{\arabic{enumiv}}\let\p@enumiv\@empty - \list{\@biblabel{\theenumiv}}{\settowidth\labelwidth{\@biblabel{#1}}% - \rightmargin\labelwidth \advance\rightmargin\labelsep - \leftmargin\labelwidth \advance\leftmargin\labelsep - \usecounter{enumiv}}% - \sloppy \clubpenalty\@M \widowpenalty\clubpenalty - \sfcode`\.=\@m -}{% - \def\@noitemerr{\@latex@warning{Empty `thebibliography' environment}}% - \endlist -} -\def\theindex{\@restonecoltrue\if@twocolumn\@restonecolfalse\fi -\columnseprule\z@ \columnsep 35\p@ -\@indextitlestyle -\thispagestyle{plain}% -\let\item\@idxitem -\parindent\z@ \parskip\z@\@plus.3\p@\relax -\raggedleft -\hyphenpenalty\@M -\footnotesize} - -\def\@idxitem{\par\hangindent -2em} -\def\subitem{\par\hangindent -2em\hspace*{1em}} -\def\subsubitem{\par\hangindent -3em\hspace*{2em}} -\def\right@footnote{% - \hbox to \columnwidth - {\beginR \vbox{\kern-.4\p@ - \hrule\@width 5pc\kern11\p@\kern-\footnotesep}\hfil\endR}} -\def\left@footnote{\kern-.4\p@ - \hrule\@width 5pc\kern11\p@\kern-\footnotesep} -\long\def\@footnotetext#1{% - \begingroup - \setbox\footins - \vbox{\if@RTL@footnote\@RTLtrue\else\@RTLfalse\fi\reset@font\footnotesize - \interlinepenalty\interfootnotelinepenalty - \splittopskip\footnotesep - \splitmaxdepth \dp\strutbox \floatingpenalty \@MM - \hsize\columnwidth \@parboxrestore \parindent\normalparindent \sloppy - \bidi@footnotetext@dir{#1}% - \protected@edef\@currentlabel{\csname p@footnote\endcsname\@thefnmark}\@makefntext - {\rule{\z@}{\footnotesep}\ignorespaces#1\unskip\strut\par}}% - \bidi@footnotetext@after - \insert\footins{\unvbox\footins}% - \endgroup} -\long\def\@RTLfootnotetext#1{% - \begingroup - \setbox\footins - \vbox{\@RTLtrue\reset@font\footnotesize - \interlinepenalty\interfootnotelinepenalty - \splittopskip\footnotesep - \splitmaxdepth \dp\strutbox \floatingpenalty \@MM - \hsize\columnwidth \@parboxrestore \parindent\normalparindent \sloppy - \bidi@footnotetext@dir{#1}% - \protected@edef\@currentlabel{\csname p@footnote\endcsname\@thefnmark}\@makefntext - {\rule{\z@}{\footnotesep}\ignorespaces #1\unskip\strut\par}}% - \bidi@footnotetext@after - \insert\footins{\unvbox\footins}% - \endgroup} -\long\def\@LTRfootnotetext#1{% - \begingroup - \setbox\footins - \vbox{\@RTLfalse\reset@font\footnotesize - \interlinepenalty\interfootnotelinepenalty - \splittopskip\footnotesep - \splitmaxdepth \dp\strutbox \floatingpenalty \@MM - \hsize\columnwidth \@parboxrestore \parindent\normalparindent \sloppy - \bidi@footnotetext@dir{#1}% - \protected@edef\@currentlabel{\csname p@footnote\endcsname\@thefnmark}\@makefntext - {\rule{\z@}{\footnotesep}\ignorespaces #1\unskip\strut\par}}% - \bidi@footnotetext@after - \insert\footins{\unvbox\footins}% - \endgroup} -%% -%% Copyright © 2009-2010 by Vafa Khalighi -%% -%% Distributable 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 "maintained" (as per LPPL maintenance status) -%% by Vafa Khalighi. -%% -%% -%% -%% -%% -%% End of file `amsbook-bidi.def'. diff --git a/Master/texmf-dist/tex/xelatex/bidi/amsbook-xetex-bidi.def b/Master/texmf-dist/tex/xelatex/bidi/amsbook-xetex-bidi.def new file mode 100644 index 00000000000..c0f19fc0727 --- /dev/null +++ b/Master/texmf-dist/tex/xelatex/bidi/amsbook-xetex-bidi.def @@ -0,0 +1,104 @@ +%% +%% This is file `amsbook-xetex-bidi.def', + +%% +%% __________________________________ +%% Copyright © 2009-2010 Vafa Khalighi +%% +%% License information appended. +%% +%% +\ProvidesFile{amsbook-xetex-bidi.def}[2010/07/25 v0.5 bidi adaptations for amsbook class for XeTeX engine] +\def\@tocline#1#2#3#4#5#6#7{\relax + \ifnum #1>\c@tocdepth % then omit + \else + \par \addpenalty\@secpenalty\addvspace{#2}% + \begingroup \hyphenpenalty\@M + \@ifempty{#4}{% + \@tempdima\csname r@tocindent\number#1\endcsname\relax + }{% + \@tempdima#4\relax + }% + \parindent\z@ \if@RTL\rightskip\else\leftskip\fi#3\relax \advance\if@RTL\rightskip\else\leftskip\fi\@tempdima\relax + \if@RTL\leftskip\else\rightskip\fi\@pnumwidth plus4em \parfillskip-\@pnumwidth + #5\leavevmode\hskip-\@tempdima #6\nobreak\relax + \hfil\hbox to\@pnumwidth{\@tocpagenum{#7}}\par + \nobreak + \endgroup + \fi} +\renewcommand\thesubsection {\thesection\@SepMark\arabic{subsection}} +\renewcommand\thesubsubsection {\thesubsection \@SepMark\arabic{subsubsection}} +\renewcommand\theparagraph {\thesubsubsection\@SepMark\arabic{paragraph}} +\renewcommand\thesubparagraph {\theparagraph\@SepMark\arabic{subparagraph}} +\def\theindex{\@restonecoltrue\if@twocolumn\@restonecolfalse\fi + \columnseprule\z@ \columnsep 35\p@ + \@indextitlestyle + \thispagestyle{plain}% + \let\item\@idxitem + \parindent\z@ \parskip\z@\@plus.3\p@\relax + \if@RTL\raggedleft\else\raggedright\fi + \hyphenpenalty\@M + \footnotesize} +\def\right@footnote{% + \hbox to \columnwidth + {\beginR \vbox{\kern-.4\p@ + \hrule\@width 5pc\kern11\p@\kern-\footnotesep}\hfil\endR}} +\def\left@footnote{\kern-.4\p@ + \hrule\@width 5pc\kern11\p@\kern-\footnotesep} +\long\def\@footnotetext#1{% + \begingroup + \setbox\footins + \vbox{\if@RTL@footnote\@RTLtrue\else\@RTLfalse\fi\reset@font\footnotesize + \interlinepenalty\interfootnotelinepenalty + \splittopskip\footnotesep + \splitmaxdepth \dp\strutbox \floatingpenalty \@MM + \hsize\columnwidth \@parboxrestore \parindent\normalparindent \sloppy + \bidi@footnotetext@dir{#1}% + \protected@edef\@currentlabel{\csname p@footnote\endcsname\@thefnmark}\@makefntext + {\rule{\z@}{\footnotesep}\ignorespaces#1\unskip\strut\par}}% + \bidi@footnotetext@after + \insert\footins{\unvbox\footins}% + \endgroup} +\long\def\@RTLfootnotetext#1{% + \begingroup + \setbox\footins + \vbox{\@RTLtrue\reset@font\footnotesize + \interlinepenalty\interfootnotelinepenalty + \splittopskip\footnotesep + \splitmaxdepth \dp\strutbox \floatingpenalty \@MM + \hsize\columnwidth \@parboxrestore \parindent\normalparindent \sloppy + \bidi@footnotetext@dir{#1}% + \protected@edef\@currentlabel{\csname p@footnote\endcsname\@thefnmark}\@makefntext + {\rule{\z@}{\footnotesep}\ignorespaces #1\unskip\strut\par}}% + \bidi@footnotetext@after + \insert\footins{\unvbox\footins}% + \endgroup} +\long\def\@LTRfootnotetext#1{% + \begingroup + \setbox\footins + \vbox{\@RTLfalse\reset@font\footnotesize + \interlinepenalty\interfootnotelinepenalty + \splittopskip\footnotesep + \splitmaxdepth \dp\strutbox \floatingpenalty \@MM + \hsize\columnwidth \@parboxrestore \parindent\normalparindent \sloppy + \bidi@footnotetext@dir{#1}% + \protected@edef\@currentlabel{\csname p@footnote\endcsname\@thefnmark}\@makefntext + {\rule{\z@}{\footnotesep}\ignorespaces #1\unskip\strut\par}}% + \bidi@footnotetext@after + \insert\footins{\unvbox\footins}% + \endgroup} +%% +%% Copyright © 2009-2010 by Vafa Khalighi +%% +%% Distributable 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 "maintained" (as per LPPL maintenance status) +%% by Vafa Khalighi. +%% +%% +%% +%% +%% +%% End of file `amsbook-xetex-bidi.def'. diff --git a/Master/texmf-dist/tex/xelatex/bidi/amsmath-bidi.def b/Master/texmf-dist/tex/xelatex/bidi/amsmath-bidi.def deleted file mode 100644 index e148fc0fc4d..00000000000 --- a/Master/texmf-dist/tex/xelatex/bidi/amsmath-bidi.def +++ /dev/null @@ -1,50 +0,0 @@ -%% -%% This is file `amsmath-bidi.def', - -%% -%% __________________________________ -%% Copyright © 2009-2010 Vafa Khalighi -%% -%% License information appended. -%% -%% -\ProvidesFile{amsmath-bidi.def}[2010/03/01 v0.2 adaptations for amsmath package] -\renewenvironment{equation}{% - \incr@eqnum - \mathdisplay@push - \st@rredfalse \global\@eqnswtrue - \beginL\mathdisplay{equation}% -}{% - \endmathdisplay{equation}\endL% - \mathdisplay@pop - \ignorespacesafterend -} - -\renewcommand{\numberwithin}[3][\arabic]{% - \@ifundefined{c@#2}{\@nocounterr{#2}}{% - \@ifundefined{c@#3}{\@nocnterr{#3}}{% - \@addtoreset{#2}{#3}% - \@xp\xdef\csname the#2\endcsname{% - \@xp\@nx\csname the#3\endcsname \@SepMark\@nx#1{#2}}}}% -} -\def\tagform@#1{\maketag@@@{\if@RTL\beginR\fi(\ignorespaces#1\unskip\@@italiccorr)\if@RTL\endR\fi}} -\renewcommand{\eqref}[1]{\beginL\textup{\tagform@{\ref{#1}}}\endL} -\let\@@text=\text -\def\text#1{\@@text{\if@RTL\beginR\fi#1\if@RTL\endR\fi}} -\DeclareRobustCommand{\[}{\begin{equation*}} -\DeclareRobustCommand{\]}{\end{equation*}} -%% -%% Copyright © 2009-2010 by Vafa Khalighi -%% -%% Distributable 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 "maintained" (as per LPPL maintenance status) -%% by Vafa Khalighi. -%% -%% -%% -%% -%% -%% End of file `amsmath-bidi.def'. diff --git a/Master/texmf-dist/tex/xelatex/bidi/amsmath-xetex-bidi.def b/Master/texmf-dist/tex/xelatex/bidi/amsmath-xetex-bidi.def new file mode 100644 index 00000000000..656b0c7999e --- /dev/null +++ b/Master/texmf-dist/tex/xelatex/bidi/amsmath-xetex-bidi.def @@ -0,0 +1,50 @@ +%% +%% This is file `amsmath-xetex-bidi.def', + +%% +%% __________________________________ +%% Copyright © 2009-2010 Vafa Khalighi +%% +%% License information appended. +%% +%% +\ProvidesFile{amsmath-xetex-bidi.def}[2010/07/25 v0.2 bidi adaptations for amsmath package for XeTeX engine] +\renewenvironment{equation}{% + \incr@eqnum + \mathdisplay@push + \st@rredfalse \global\@eqnswtrue + \beginL\mathdisplay{equation}% +}{% + \endmathdisplay{equation}\endL% + \mathdisplay@pop + \ignorespacesafterend +} + +\renewcommand{\numberwithin}[3][\arabic]{% + \@ifundefined{c@#2}{\@nocounterr{#2}}{% + \@ifundefined{c@#3}{\@nocnterr{#3}}{% + \@addtoreset{#2}{#3}% + \@xp\xdef\csname the#2\endcsname{% + \@xp\@nx\csname the#3\endcsname \@SepMark\@nx#1{#2}}}}% +} +\def\tagform@#1{\maketag@@@{\if@RTL\beginR\fi(\ignorespaces#1\unskip\@@italiccorr)\if@RTL\endR\fi}} +\renewcommand{\eqref}[1]{\beginL\textup{\tagform@{\ref{#1}}}\endL} +\let\@@text=\text +\def\text#1{\@@text{\if@RTL\beginR\fi#1\if@RTL\endR\fi}} +\DeclareRobustCommand{\[}{\begin{equation*}} +\DeclareRobustCommand{\]}{\end{equation*}} +%% +%% Copyright © 2009-2010 by Vafa Khalighi +%% +%% Distributable 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 "maintained" (as per LPPL maintenance status) +%% by Vafa Khalighi. +%% +%% +%% +%% +%% +%% End of file `amsmath-xetex-bidi.def'. diff --git a/Master/texmf-dist/tex/xelatex/bidi/amsthm-bidi.def b/Master/texmf-dist/tex/xelatex/bidi/amsthm-bidi.def deleted file mode 100644 index a51a758c584..00000000000 --- a/Master/texmf-dist/tex/xelatex/bidi/amsthm-bidi.def +++ /dev/null @@ -1,27 +0,0 @@ -%% -%% This is file `amsthm-bidi.def', - -%% -%% __________________________________ -%% Copyright © 2009-2010 Vafa Khalighi -%% -%% License information appended. -%% -%% -\ProvidesFile{amsthm-bidi.def}[2010/03/01 v0.1 adaptations for amsthm package] -\def\@thmcountersep{\@SepMark} -%% -%% Copyright © 2009-2010 by Vafa Khalighi -%% -%% Distributable 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 "maintained" (as per LPPL maintenance status) -%% by Vafa Khalighi. -%% -%% -%% -%% -%% -%% End of file `amsthm-bidi.def'. diff --git a/Master/texmf-dist/tex/xelatex/bidi/amsthm-xetex-bidi.def b/Master/texmf-dist/tex/xelatex/bidi/amsthm-xetex-bidi.def new file mode 100644 index 00000000000..8857b937aed --- /dev/null +++ b/Master/texmf-dist/tex/xelatex/bidi/amsthm-xetex-bidi.def @@ -0,0 +1,27 @@ +%% +%% This is file `amsthm-xetex-bidi.def', + +%% +%% __________________________________ +%% Copyright © 2009-2010 Vafa Khalighi +%% +%% License information appended. +%% +%% +\ProvidesFile{amsthm-xetex-bidi.def}[2010/07/25 v0.1 bidi adaptations for amsthm package for XeTeX engine] +\def\@thmcountersep{\@SepMark} +%% +%% Copyright © 2009-2010 by Vafa Khalighi +%% +%% Distributable 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 "maintained" (as per LPPL maintenance status) +%% by Vafa Khalighi. +%% +%% +%% +%% +%% +%% End of file `amsthm-xetex-bidi.def'. diff --git a/Master/texmf-dist/tex/xelatex/bidi/array-bidi.def b/Master/texmf-dist/tex/xelatex/bidi/array-bidi.def deleted file mode 100644 index cf1986e1aaa..00000000000 --- a/Master/texmf-dist/tex/xelatex/bidi/array-bidi.def +++ /dev/null @@ -1,108 +0,0 @@ -%% -%% This is file `array-bidi.def', - -%% -%% __________________________________ -%% Copyright © 2009-2010 Vafa Khalighi -%% -%% License information appended. -%% -%% -\ProvidesFile{array-bidi.def}[2010/03/01 v0.1 adaptations for array package] -\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 \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} -\def\tabular{\gdef\@halignto{}\@tabular} -\def\@tabular{\if@RTL\global\@RTLtabtrue\fi% - \leavevmode - \hbox\bgroup \if@RTLtab\beginR \fi - $% - \@tabularinit - \@array -} -\renewcommand\@array[2][c]{% - \@tempdima \ht \strutbox - \advance \@tempdima by\extrarowheight - \setbox \@arstrutbox \hbox{% - \vrule \@height \arraystretch \@tempdima - \@depth \arraystretch \dp \strutbox - \@width \z@ - }% - \begingroup - \@mkpream{#2}% - \xdef\@preamble{% - \noexpand \ialign \@halignto - \bgroup \@arstrut \@preamble - \tabskip \z@ \cr - }% - \endgroup - \@arrayleft - \if #1t\vtop \else \if#1b\vbox \else \vcenter \fi \fi - \bgroup - \@arrayinit - \if@RTLtab\hbox\bgroup\beginR\vbox\bgroup\fi - \@preamble - % indent -} -%% environment body goes here -\def\endtabular{% - \crcr - \egroup % \bgroup from \@preamble - \if@RTLtab\egroup\endR\egroup\fi % \vbox\hbox - \egroup - \gdef\@preamble{}% - $\if@RTLtab\endR\fi% - \egroup % original \hbox -\global\@RTLtabfalse} -\def\@tabularinit{% - \col@sep\tabcolsep - \let \d@llarbegin \begingroup - \let \d@llarend \endgroup -} -\def\@arrayinit{% - \let \@sharp ## - \let \protect \relax - \lineskip \z@ - \baselineskip \z@ - \m@th - \let \\ \@arraycr - \let \tabularnewline \\% - \let \par \@empty -} -%% -%% Copyright © 2009-2010 by Vafa Khalighi -%% -%% Distributable 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 "maintained" (as per LPPL maintenance status) -%% by Vafa Khalighi. -%% -%% -%% -%% -%% -%% End of file `array-bidi.def'. diff --git a/Master/texmf-dist/tex/xelatex/bidi/array-xetex-bidi.def b/Master/texmf-dist/tex/xelatex/bidi/array-xetex-bidi.def new file mode 100644 index 00000000000..b9e310e3107 --- /dev/null +++ b/Master/texmf-dist/tex/xelatex/bidi/array-xetex-bidi.def @@ -0,0 +1,108 @@ +%% +%% This is file `array-xetex-bidi.def', + +%% +%% __________________________________ +%% Copyright © 2009-2010 Vafa Khalighi +%% +%% License information appended. +%% +%% +\ProvidesFile{array-xetex-bidi.def}[2010/07/25 v0.1 bidi adaptations for array package for XeTeX engine] +\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 \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} +\def\tabular{\gdef\@halignto{}\@tabular} +\def\@tabular{\if@RTL\global\@RTLtabtrue\fi% + \leavevmode + \hbox\bgroup \if@RTLtab\beginR \fi + $% + \@tabularinit + \@array +} +\renewcommand\@array[2][c]{% + \@tempdima \ht \strutbox + \advance \@tempdima by\extrarowheight + \setbox \@arstrutbox \hbox{% + \vrule \@height \arraystretch \@tempdima + \@depth \arraystretch \dp \strutbox + \@width \z@ + }% + \begingroup + \@mkpream{#2}% + \xdef\@preamble{% + \noexpand \ialign \@halignto + \bgroup \@arstrut \@preamble + \tabskip \z@ \cr + }% + \endgroup + \@arrayleft + \if #1t\vtop \else \if#1b\vbox \else \vcenter \fi \fi + \bgroup + \@arrayinit + \if@RTLtab\hbox\bgroup\beginR\vbox\bgroup\fi + \@preamble + % indent +} +%% environment body goes here +\def\endtabular{% + \crcr + \egroup % \bgroup from \@preamble + \if@RTLtab\egroup\endR\egroup\fi % \vbox\hbox + \egroup + \gdef\@preamble{}% + $\if@RTLtab\endR\fi% + \egroup % original \hbox +\global\@RTLtabfalse} +\def\@tabularinit{% + \col@sep\tabcolsep + \let \d@llarbegin \begingroup + \let \d@llarend \endgroup +} +\def\@arrayinit{% + \let \@sharp ## + \let \protect \relax + \lineskip \z@ + \baselineskip \z@ + \m@th + \let \\ \@arraycr + \let \tabularnewline \\% + \let \par \@empty +} +%% +%% Copyright © 2009-2010 by Vafa Khalighi +%% +%% Distributable 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 "maintained" (as per LPPL maintenance status) +%% by Vafa Khalighi. +%% +%% +%% +%% +%% +%% End of file `array-xetex-bidi.def'. diff --git a/Master/texmf-dist/tex/xelatex/bidi/article-bidi.def b/Master/texmf-dist/tex/xelatex/bidi/article-bidi.def deleted file mode 100644 index 328d17fcee1..00000000000 --- a/Master/texmf-dist/tex/xelatex/bidi/article-bidi.def +++ /dev/null @@ -1,221 +0,0 @@ -%% -%% This is file `article-bidi.def', - -%% -%% __________________________________ -%% Copyright © 2009-2010 Vafa Khalighi -%% -%% License information appended. -%% -%% -\ProvidesFile{article-bidi.def}[2010/03/01 v0.2 adaptations for standard article class] -\if@titlepage - \renewcommand\maketitle{\begin{titlepage}% - \let\footnotesize\small - \let\footnoterule\relax - \let \footnote \thanks - \let \LTRfootnote \LTRthanks - \let \RTLfootnote \RTLthanks - \null\vfil - \vskip 60\p@ - \begin{center}% - {\LARGE \@title \par}% - \vskip 3em% - {\large - \lineskip .75em% - \begin{tabular}[t]{c}% - \@author - \end{tabular}\par}% - \vskip 1.5em% - {\large \@date \par}% % Set date in \large size. - \end{center}\par - \@thanks - \vfil\null - \end{titlepage}% - \setcounter{footnote}{0}% - \global\let\thanks\relax - \global\let\LTRthanks\relax - \global\let\RTLthanks\relax - \global\let\maketitle\relax - \global\let\@thanks\@empty - \global\let\@author\@empty - \global\let\@date\@empty - \global\let\@title\@empty - \global\let\title\relax - \global\let\author\relax - \global\let\date\relax - \global\let\and\relax -} -\else -\renewcommand\maketitle{\par - \begingroup - \renewcommand\thefootnote{\@fnsymbol\c@footnote}% - \def\@makefnmark{\rlap{\@textsuperscript{\normalfont\@thefnmark}}}% - \long\def\@makefntext##1{\parindent 1em\noindent - \hb@xt@1.8em{% - \hss\@textsuperscript{\normalfont\@thefnmark}}##1}% - \if@twocolumn - \ifnum \col@number=\@ne - \@maketitle - \else - \twocolumn[\@maketitle]% - \fi - \else - \newpage - \global\@topnum\z@ % Prevents figures from going at top of page. - \@maketitle - \fi - \thispagestyle{plain}\@thanks - \endgroup - \setcounter{footnote}{0}% - \global\let\thanks\relax - \global\let\LTRthanks\relax - \global\let\RTLthanks\relax - \global\let\maketitle\relax - \global\let\@maketitle\relax - \global\let\@thanks\@empty - \global\let\@author\@empty - \global\let\@date\@empty - \global\let\@title\@empty - \global\let\title\relax - \global\let\author\relax - \global\let\date\relax - \global\let\and\relax -} -\def\@maketitle{% - \newpage - \null - \vskip 2em% - \begin{center}% - \let \footnote \thanks - \let \LTRfootnote \LTRthanks - \let \RTLfootnote \RTLthanks - {\LARGE \@title \par}% - \vskip 1.5em% - {\large - \lineskip .5em% - \begin{tabular}[t]{c}% - \@author - \end{tabular}\par}% - \vskip 1em% - {\large \@date}% - \end{center}% - \par - \vskip 1.5em} -\fi -\renewcommand*\l@part[2]{% - \ifnum \c@tocdepth >-2\relax - \addpenalty\@secpenalty - \addvspace{2.25em \@plus\p@}% - \setlength\@tempdima{3em}% - \begingroup - \parindent \z@ \if@RTL\leftskip\else\rightskip\fi \@pnumwidth - \parfillskip -\@pnumwidth - {\leavevmode - \large \bfseries #1\hfil \hb@xt@\@pnumwidth{\hss #2}}\par - \nobreak - \if@compatibility - \global\@nobreaktrue - \everypar{\global\@nobreakfalse\everypar{}}% - \fi - \endgroup - \fi} -\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} -\def\@part[#1]#2{% - \ifnum \c@secnumdepth >\m@ne - \refstepcounter{part}% - \addcontentsline{toc}{part}{\thepart\hspace{1em}#1}% - \else - \addcontentsline{toc}{part}{#1}% - \fi - {\parindent \z@ \if@RTL\raggedleft\else\raggedright\fi - \interlinepenalty \@M - \normalfont - \ifnum \c@secnumdepth >\m@ne - \Large\bfseries \partname\nobreakspace\thepart - \par\nobreak - \fi - \huge \bfseries #2% - \markboth{}{}\par}% - \nobreak - \vskip 3ex - \@afterheading} - \def\ps@plain{\ps@empty -\def\@oddfoot{\hfil\thepage\hfil}% -\let\@evenfoot\@oddfoot -} -\renewenvironment{thebibliography}[1] - {\section*{\refname}% - \@mkboth{\MakeUppercase\refname}{\MakeUppercase\refname}% - \list{\@biblabel{\@arabic\c@enumiv}}% - {\settowidth\labelwidth{\@biblabel{#1}}% - \rightmargin\labelwidth \advance\rightmargin\labelsep - \@openbib@code - \usecounter{enumiv}% - \let\p@enumiv\@empty - \renewcommand\theenumiv{\@arabic\c@enumiv}}% - \sloppy - \clubpenalty4000 - \@clubpenalty \clubpenalty - \widowpenalty4000% - \sfcode`\.\@m} - {\def\@noitemerr - {\@latex@warning{Empty `thebibliography' environment}}% - \endlist} -\if@twoside - \def\ps@headings{% - \let\@oddfoot\@empty\let\@evenfoot\@empty - \def\@evenhead{\sl\if@RTLmain\beginR\fi\leftmark\if@RTLmain\endR\fi\hfil\thepage}% - \def\@oddhead{\sl\thepage\hfil\if@RTLmain\beginR\fi\rightmark\if@RTLmain\endR\fi}% - \let\@mkboth\markboth - \def\sectionmark##1{% - \markboth {\MakeUppercase{% - \ifnum \c@secnumdepth >\z@ - \thesection\quad - \fi - \if@RTLmain\beginR\fi##1\if@RTLmain\endR\fi}}{}}% - \def\subsectionmark##1{% - \markright {% - \ifnum \c@secnumdepth >\@ne - \if@RTLmain\beginR\fi\thesubsection\quad\if@RTLmain\endR\fi - \fi - \if@RTLmain\beginR\fi##1\if@RTLmain\endR\fi}}} -\else - \def\ps@headings{% - \let\@oddfoot\@empty - \def\@oddhead{\sl\thepage\hfil\if@RTLmain\beginR\fi\rightmark\if@RTLmain\endR\fi}% - \let\@mkboth\markboth - \def\sectionmark##1{% - \markright {\MakeUppercase{% - \ifnum \c@secnumdepth >\m@ne - \if@RTLmain\beginR\fi\thesection\quad\if@RTLmain\endR\fi - \fi - \if@RTLmain\beginR\fi##1\if@RTLmain\endR\fi}}}} -\fi -\def\ps@myheadings{% - \let\@oddfoot\@empty\let\@evenfoot\@empty - \def\@evenhead{\sl\thepage\hfil\if@RTLmain\beginR\fi\leftmark\if@RTLmain\endR\fi}% - \def\@oddhead{\sl\if@RTLmain\beginR\fi\rightmark\if@RTLmain\endR\fi\hfil\thepage}% - \let\@mkboth\@gobbletwo - \let\sectionmark\@gobble - \let\subsectionmark\@gobble - } -\pagestyle{plain} -%% -%% Copyright © 2009-2010 by Vafa Khalighi -%% -%% Distributable 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 "maintained" (as per LPPL maintenance status) -%% by Vafa Khalighi. -%% -%% -%% -%% -%% -%% End of file `article-bidi.def'. diff --git a/Master/texmf-dist/tex/xelatex/bidi/article-xetex-bidi.def b/Master/texmf-dist/tex/xelatex/bidi/article-xetex-bidi.def new file mode 100644 index 00000000000..9248fdf0489 --- /dev/null +++ b/Master/texmf-dist/tex/xelatex/bidi/article-xetex-bidi.def @@ -0,0 +1,160 @@ +%% +%% This is file `article-xetex-bidi.def', + +%% +%% __________________________________ +%% Copyright © 2009-2010 Vafa Khalighi +%% +%% License information appended. +%% +%% +\ProvidesFile{article-xetex-bidi.def}[2010/07/25 v0.3 bidi adaptations for standard article class for XeTeX engine] +\if@titlepage + \renewcommand\maketitle{\begin{titlepage}% + \let\footnotesize\small + \let\footnoterule\relax + \let \footnote \thanks + \let \LTRfootnote \LTRthanks + \let \RTLfootnote \RTLthanks + \null\vfil + \vskip 60\p@ + \begin{center}% + {\LARGE \@title \par}% + \vskip 3em% + {\large + \lineskip .75em% + \begin{tabular}[t]{c}% + \@author + \end{tabular}\par}% + \vskip 1.5em% + {\large \@date \par}% % Set date in \large size. + \end{center}\par + \@thanks + \vfil\null + \end{titlepage}% + \setcounter{footnote}{0}% + \global\let\thanks\relax + \global\let\LTRthanks\relax + \global\let\RTLthanks\relax + \global\let\maketitle\relax + \global\let\@thanks\@empty + \global\let\@author\@empty + \global\let\@date\@empty + \global\let\@title\@empty + \global\let\title\relax + \global\let\author\relax + \global\let\date\relax + \global\let\and\relax +} +\else +\renewcommand\maketitle{\par + \begingroup + \renewcommand\thefootnote{\@fnsymbol\c@footnote}% + \def\@makefnmark{\rlap{\@textsuperscript{\normalfont\@thefnmark}}}% + \long\def\@makefntext##1{\parindent 1em\noindent + \hb@xt@1.8em{% + \hss\@textsuperscript{\normalfont\@thefnmark}}##1}% + \if@twocolumn + \ifnum \col@number=\@ne + \@maketitle + \else + \twocolumn[\@maketitle]% + \fi + \else + \newpage + \global\@topnum\z@ % Prevents figures from going at top of page. + \@maketitle + \fi + \thispagestyle{plain}\@thanks + \endgroup + \setcounter{footnote}{0}% + \global\let\thanks\relax + \global\let\LTRthanks\relax + \global\let\RTLthanks\relax + \global\let\maketitle\relax + \global\let\@maketitle\relax + \global\let\@thanks\@empty + \global\let\@author\@empty + \global\let\@date\@empty + \global\let\@title\@empty + \global\let\title\relax + \global\let\author\relax + \global\let\date\relax + \global\let\and\relax +} +\def\@maketitle{% + \newpage + \null + \vskip 2em% + \begin{center}% + \let \footnote \thanks + \let \LTRfootnote \LTRthanks + \let \RTLfootnote \RTLthanks + {\LARGE \@title \par}% + \vskip 1.5em% + {\large + \lineskip .5em% + \begin{tabular}[t]{c}% + \@author + \end{tabular}\par}% + \vskip 1em% + {\large \@date}% + \end{center}% + \par + \vskip 1.5em} +\fi +\renewcommand*\l@part[2]{% + \ifnum \c@tocdepth >-2\relax + \addpenalty\@secpenalty + \addvspace{2.25em \@plus\p@}% + \setlength\@tempdima{3em}% + \begingroup + \parindent \z@ \if@RTL\leftskip\else\rightskip\fi \@pnumwidth + \parfillskip -\@pnumwidth + {\leavevmode + \large \bfseries #1\hfil \hb@xt@\@pnumwidth{\hss #2}}\par + \nobreak + \if@compatibility + \global\@nobreaktrue + \everypar{\global\@nobreakfalse\everypar{}}% + \fi + \endgroup + \fi} +\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} +\def\@part[#1]#2{% + \ifnum \c@secnumdepth >\m@ne + \refstepcounter{part}% + \addcontentsline{toc}{part}{\thepart\hspace{1em}#1}% + \else + \addcontentsline{toc}{part}{#1}% + \fi + {\parindent \z@ \if@RTL\raggedleft\else\raggedright\fi + \interlinepenalty \@M + \normalfont + \ifnum \c@secnumdepth >\m@ne + \Large\bfseries \partname\nobreakspace\thepart + \par\nobreak + \fi + \huge \bfseries #2% + \markboth{}{}\par}% + \nobreak + \vskip 3ex + \@afterheading} +%% +%% Copyright © 2009-2010 by Vafa Khalighi +%% +%% Distributable 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 "maintained" (as per LPPL maintenance status) +%% by Vafa Khalighi. +%% +%% +%% +%% +%% +%% End of file `article-xetex-bidi.def'. diff --git a/Master/texmf-dist/tex/xelatex/bidi/arydshln-bidi.def b/Master/texmf-dist/tex/xelatex/bidi/arydshln-bidi.def deleted file mode 100644 index 5021c938aaf..00000000000 --- a/Master/texmf-dist/tex/xelatex/bidi/arydshln-bidi.def +++ /dev/null @@ -1,160 +0,0 @@ -%% -%% This is file `arydshln-bidi.def', - -%% -%% __________________________________ -%% Copyright © 2009-2010 Vafa Khalighi -%% -%% License information appended. -%% -%% -\ProvidesFile{arydshln-bidi.def}[2010/03/01 v0.1 adaptations for arydshln package] -\def\endarray{\adl@endarray \egroup \adl@arrayrestore \if@RTLtab\egroup\endR\egroup\fi\egroup} -\def\endtabular{\endarray $\if@RTLtab\endR\fi\egroup\global\@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-2010 by Vafa Khalighi -%% -%% Distributable 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 "maintained" (as per LPPL maintenance status) -%% by Vafa Khalighi. -%% -%% -%% -%% -%% -%% End of file `arydshln-bidi.def'. diff --git a/Master/texmf-dist/tex/xelatex/bidi/arydshln-xetex-bidi.def b/Master/texmf-dist/tex/xelatex/bidi/arydshln-xetex-bidi.def new file mode 100644 index 00000000000..66940c279c8 --- /dev/null +++ b/Master/texmf-dist/tex/xelatex/bidi/arydshln-xetex-bidi.def @@ -0,0 +1,160 @@ +%% +%% This is file `arydshln-xetex-bidi.def', + +%% +%% __________________________________ +%% Copyright © 2009-2010 Vafa Khalighi +%% +%% License information appended. +%% +%% +\ProvidesFile{arydshln-xetex-bidi.def}[2010/07/25 v0.1 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\global\@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-2010 by Vafa Khalighi +%% +%% Distributable 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 "maintained" (as per LPPL maintenance status) +%% by Vafa Khalighi. +%% +%% +%% +%% +%% +%% End of file `arydshln-xetex-bidi.def'. diff --git a/Master/texmf-dist/tex/xelatex/bidi/bidi.sty b/Master/texmf-dist/tex/xelatex/bidi/bidi.sty index 89f18c2000e..e64ebb0c867 100644 --- a/Master/texmf-dist/tex/xelatex/bidi/bidi.sty +++ b/Master/texmf-dist/tex/xelatex/bidi/bidi.sty @@ -9,18 +9,15 @@ %% %% \NeedsTeXFormat{LaTeX2e} -\def\bididate{2010/03/01} -\def\bidiversion{v1.0.4} -\def\bidirevision{revision 202} +\def\bididate{2010/07/25} +\def\bidiversion{v1.0.5} +\def\bidirevision{revision 253} \ProvidesPackage{bidi}[\bididate\space \bidiversion\space <\bidirevision> -Bidirectional typesetting in XeLaTeX] -\AtBeginDocument{\special{pdf: docinfo << -/Creator (Bidi \bidiversion\space <\bidirevision> Copyright © 2009-2010 Vafa Khalighi) - >>}} +Bidirectional typesetting in XeLaTeX and LuaLaTeX] \edef\bidiinfo{% -bidi package (Support for bidirectional typesetting with XeLaTeX)^^J +bidi package (Support for bidirectional typesetting with XeLaTeX and LuaLaTeX)^^J Description: A convenient interface for typesetting bidirectional^^J -texts with XeLaTeX. The package includes adaptations for use^^J +texts with XeLaTeX and LuaLaTeX. The package includes adaptations for use^^J with many other commonly-used packages.^^J Copyright © 2009-2010 Vafa Khalighi^^J \bidiversion, <\bidirevision>, \bididate^^J @@ -30,12 +27,15 @@ Location on CTAN: /macros/xetex/latex/bidi} \typeout{\bidiinfo} \edef\bidi@everyjob{\the\everyjob} \everyjob{\bidi@everyjob\typeout{\bidiinfo}} +\RequirePackage{ifxetex} +\RequirePackage{ifluatex} \def\@tagsextension{clo} \def\@definitionfileextension{def} \def\@iftagsloaded{\@ifl@aded\@tagsextension} \def\@ifdefinitionfileloaded{\@ifl@aded\@definitionfileextension} \newif\if@RTLmain \newif\if@RTL +\newif\if@RTLmaths \newif\if@Latin \newif\if@RTLtab \newif\if@sentdir @@ -53,16 +53,6 @@ Location on CTAN: /macros/xetex/latex/bidi} \let\@tab@rltrue=\@RTLtabtrue \let\@tab@rlfalse=\@RTLtabfalse \@RTLmainfalse -\ifx\TeXXeTstate\undefined\else% - \TeXXeTstate=1 -\fi -\ifx\beginR\@undefined% - \newlinechar`\^^J - \typeout{^^JTo avoid this error message,^^J% - run TeX--XeT or e-TeX engine instead of regular TeX.^^J} - \errmessage{Right-to-Left Support Error: use TeX--XeT or e-TeX - engine}% -\fi \AtBeginDocument{% \if@RTLmain\else \if@RTL\@RTLmaintrue% @@ -70,392 +60,25 @@ Location on CTAN: /macros/xetex/latex/bidi} \fi% \fi% } -\def\Bidi@RTL@everypar{\if@RTL{\setbox\z@\lastbox\beginR\usebox\z@}\fi} - \let\o@everypar=\everypar - \newtoks\n@everypar - \n@everypar\expandafter{\the\o@everypar} - \o@everypar{\Bidi@RTL@everypar\the\n@everypar} - \let\everypar=\n@everypar \let\n@xt=\ \def\LRE{\protect\pLRE}% \def\pLRE{\protect\afterassignment\moreLRE \let\n@xt= } -\def\moreLRE{\bracetext \aftergroup\endL \beginL\@RTLfalse} \def\RLE{\protect\pRLE} \def\pRLE{\protect\afterassignment\moreRLE \let\n@xt= } -\def\moreRLE{\bracetext \aftergroup\endR \beginR\@RTLtrue} \def\bracetext{\ifcat\n@xt{\else\ifcat\n@xt}\fi \errmessage{Missing left brace has been substituted}\fi \bgroup} -\def\lr#1{\begingroup\beginL\rmfamily#1\endL\endgroup} -\def\LTR{\bgroup\par\@RTLfalse\@RTL@footnotefalse} -\def\endLTR{\par\egroup} -\def\RTL{\bgroup\par\@RTLtrue\@RTL@footnotetrue} -\def\endRTL{\par\egroup} -\def\ltr{\if@RTL\par\@RTLfalse\@RTL@footnotefalse\fi} -\def\rtl{\if@RTL\relax\else\par\@RTLtrue\@RTL@footnotetrue\fi} -\def\setRTL{\@RTLtrue\@RTL@footnotetrue} -\def\setLTR{\@RTLfalse\@RTL@footnotefalse} -\let\unsetRTL=\setLTR -\let\unsetLTR=\setRTL -\let\LR=\LRE -\let\RL=\RLE -\def\@ensure@RTL#1{\if@RTL#1\else\RLE{#1}\fi} -\def\@ensure@LTR#1{\if@RTL\LRE{#1}\else#1\fi} -\let\@ensure@RL=\@ensure@RTL -\let\@ensure@LR=\@ensure@LTR -\def\@ensure@dir#1{\if@RTL\RLE{#1}\else{#1}\fi} -\let\@ensure@maindir=\@ensure@dir -\def\@@RTL{RTL} -\def\@@LTR{LTR} -\def\save@dir{\if@RTL\gdef\saved@@dir{RTL}\else\gdef\saved@@dir{LTR}\fi} -\def\reset@dir{\ifx\saved@@dir\@@RTL\setRTL\else\ifx\saved@@dir\@@LTR\setLTR\else\relax\fi\fi} -\let\@@TeX\TeX -\def\TeX{\@ensure@LTR{\@@TeX}} -\let\@@LaTeX\LaTeX -\def\LaTeX{\@ensure@LTR{\@@LaTeX}} -\let\@@LaTeXe\LaTeXe -\def\LaTeXe{\@ensure@LTR{\@@LaTeXe}} -\def\reflect#1{{\setbox0=\hbox{#1}\rlap{\kern0.5\wd0 - \special{x:gsave}\special{x:scale -1 1}}\box0 \special{x:grestore}}} -\def\XeTeX{\LR{\leavevmode$\smash{\hbox{X\lower.5ex - \hbox{\kern-.125em\reflect{E}}\kern-.1667em \TeX}}$}} -\def\XeLaTeX{\LR{\leavevmode$\smash{\hbox{X\lower.5ex - \hbox{\kern-.125em\reflect{E}}\kern-.1667em \LaTeX}}$}} -\let\setRL=\setRTL -\let\setLR=\setLTR -\let\unsetRL=\setLTR -\DeclareOption{RTLdocument}{\@RTLtrue\@RTL@footnotetrue\autofootnoterule} -\DeclareOption{rldocument}{\@RTLtrue\@RTL@footnotetrue\autofootnoterule} -\def\rcases#1{\left.\vcenter{\normalbaselines\m@th - \ialign{$##\hfil$&\quad{##}\hfil\crcr#1\crcr}}\,\right\}} -\def\SepMark#1{\gdef\@SepMark{\if@RTL\beginR\fi#1\if@RTL\endR\fi}} -\SepMark{.} -\def\@thmcountersep{\@SepMark} -\def\list#1#2{% - \ifnum \@listdepth >5\relax - \@toodeep - \else - \global\advance\@listdepth\@ne - \fi - \rightmargin\z@ - \listparindent\z@ - \itemindent\z@ - \csname @list\romannumeral\the\@listdepth\endcsname - \def\@itemlabel{#1}% - \let\makelabel\@mklab - \@nmbrlistfalse - #2\relax - \@trivlist - \parskip\parsep - \parindent\listparindent - \advance\linewidth -\rightmargin - \advance\linewidth -\leftmargin - \if@RTL - \advance\@totalleftmargin \rightmargin - \else - \advance\@totalleftmargin \leftmargin - \fi - \parshape \@ne \@totalleftmargin \linewidth - \ignorespaces} -\def\raggedright{% - \let\\\@centercr - \leftskip\z@skip\rightskip\@flushglue - \parindent\z@\parfillskip\z@skip} -\let\@@raggedleft=\raggedleft -\let\@@raggedright=\raggedright -\renewcommand\raggedleft{\if@RTL\@@raggedright% - \else\@@raggedleft\fi} -\renewcommand\raggedright{\if@RTL\@@raggedleft% - \else\@@raggedright\fi} -\def\raggedright{% - \let\\\@centercr - \rightskip\z@skip\rightskip\@flushglue - \parindent\z@\parfillskip\z@skip} -\renewcommand\raggedleft{\@@raggedleft} -\renewcommand\raggedright{\@@raggedright} -\def\centerline#1{% -\if@RTL\@@line{\hss\beginR#1\endR\hss} -\else\@@line{\hss#1\hss}\fi} -\def\leftline#1{% -\if@RTL\@@line{\beginR#1\endR\hss} -\else\@@line{#1\hss}\fi} -\def\rightline#1{% -\if@RTL\@@line{\hss\beginR#1\endR} -\else\@@line{\hss#1}\fi} -\def\narrower{% - \advance\if@RTL\rightskip\else\leftskip\fi\parindent - \advance\if@RTL\leftskip\else\rightskip\fi\parindent} -\def\leftmark{\if@RTLmain\beginR\fi\expandafter\@leftmark\botmark\@empty\@empty\if@RTLmain\endR\fi} -\def\rightmark{\if@RTLmain\beginR\fi\expandafter\@rightmark\firstmark\@empty\@empty\if@RTLmain\endR\fi} -\def\underline#1{% - \relax - \ifmmode\@@underline{#1}% - \else -\if@RTL $\@@underline{\hbox{\beginR#1\endR}}\m@th$\relax +\input{loadingorder-bidi.def} +\ifxetex + \input{xetex-bidi.def} \else -$\@@underline{\hbox{#1}}\m@th$\relax\fi\fi} -\if@compatibility - \let\undertext=\underline -\fi -\global\@RTLtabfalse -\def\@tabular{\if@RTL\global\@RTLtabtrue\fi - \leavevmode \hbox \bgroup \if@RTLtab\beginR \fi - $\let\@acol\@tabacol - \let\@classz\@tabclassz - \let\@classiv\@tabclassiv \let\\\@tabularcr\@tabarray} -\def\endtabular{\crcr\egroup\if@RTLtab\egroup\endR\egroup\fi - \egroup $\if@RTLtab\endR\fi\egroup - \global\@RTLtabfalse} -\expandafter \let \csname endtabular*\endcsname = \endtabular -\def\@array[#1]#2{% - \if #1t\vtop \else \if#1b\vbox \else \vcenter \fi\fi - \bgroup - \setbox\@arstrutbox\hbox{% - \vrule \@height\arraystretch\ht\strutbox - \@depth\arraystretch \dp\strutbox - \@width\z@}% - \@mkpream{#2}% - \edef\@preamble{% - \ialign \noexpand\@halignto - \bgroup \@arstrut \@preamble \tabskip\z@skip \cr}% - \let\@startpbox\@@startpbox \let\@endpbox\@@endpbox - \let\tabularnewline\\% - \let\par\@empty - \let\@sharp##% - \set@typeset@protect - \lineskip\z@skip\baselineskip\z@skip - \ifhmode \@preamerr\z@ \@@par\fi - \if@RTLtab\hbox\bgroup\beginR\vbox\bgroup\fi - \@preamble} -\def\@testpach#1{\@chclass \ifnum \@lastchclass=\tw@ 4 \else - \ifnum \@lastchclass=3 5 \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 \else - \if #1@\tw@ \else - \if #1p3 \else \z@ \@preamerr 0\fi - \fi \fi \fi \fi \fi \fi -\fi} -\def\@dottedtocline#1#2#3#4#5{% - \ifnum #1>\c@tocdepth \else - \vskip \z@ \@plus.2\p@ - {\if@RTL\rightskip\else\leftskip\fi #2\relax \if@RTL\leftskip\else\rightskip\fi \@tocrmarg \parfillskip -\if@RTL\leftskip\else\rightskip\fi - \parindent #2\relax\@afterindenttrue - \interlinepenalty\@M - \leavevmode - \@tempdima #3\relax - \advance\if@RTL\rightskip\else\leftskip\fi \@tempdima \null\nobreak\hskip -\if@RTL\rightskip\else\leftskip\fi - {#4}\nobreak - \leaders\hbox{$\m@th - \mkern \@dotsep mu\hbox{.}\mkern \@dotsep - mu$}\hfill - \nobreak - \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{% - \hbox to\columnwidth{\box\@outputbox \hss}% - \hfil \vrule width\columnseprule\hfil - \hbox to\columnwidth{\box\@leftcolumn \hss}% - }}\@combinedblfloats -\@outputpage \begingroup \@dblfloatplacement -\@startdblcolumn -\@whilesw\if@fcolmade \fi -{\@outputpage\@startdblcolumn}\endgroup - \fi} -\def\LTR@outputdblcol{\if@firstcolumn -\global\@firstcolumnfalse - \global\setbox\@leftcolumn\box\@outputbox - \else \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} -\renewcommand{\@outputdblcol}{\if@RTLmain\RTL@outputdblcol\else\LTR@outputdblcol\fi} -\newcommand{\RTLdblcol}{\renewcommand{\@outputdblcol}{\RTL@outputdblcol}} -\newcommand{\LTRdblcol}{\renewcommand{\@outputdblcol}{\LTR@outputdblcol}} -\def\@addmarginpar{\@next\@marbox\@currlist{\@cons\@freelist\@marbox - \@cons\@freelist\@currbox}\@latexbug\@tempcnta\@ne - \if@twocolumn - \if@firstcolumn \@tempcnta\m@ne \fi - \else - \if@mparswitch - \ifodd\c@page \else\@tempcnta\m@ne \fi - \fi - \if@reversemargin \@tempcnta -\@tempcnta \fi - \fi - \ifnum\@tempcnta <\z@ \global\setbox\@marbox\box\@currbox \fi - \@tempdima\@mparbottom - \advance\@tempdima -\@pageht - \advance\@tempdima\ht\@marbox - \ifdim\@tempdima >\z@ - \@latex@warning@no@line {Marginpar on page \thepage\space moved}% - \else - \@tempdima\z@ - \fi - \global\@mparbottom\@pageht - \global\advance\@mparbottom\@tempdima - \global\advance\@mparbottom\dp\@marbox - \global\advance\@mparbottom\marginparpush - \advance\@tempdima -\ht\@marbox - \global\setbox \@marbox - \vbox {\vskip \@tempdima - \box \@marbox}% - \global \ht\@marbox \z@ - \global \dp\@marbox \z@ - \kern -\@pagedp - \nointerlineskip - \hb@xt@\columnwidth - {\if@RTL\beginR\fi\ifnum \@tempcnta >\z@ - \hskip\columnwidth \hskip\marginparsep - \else - \hskip -\marginparsep \hskip -\marginparwidth - \fi - \box\@marbox \hss\if@RTL\endR\fi}% - \nointerlineskip - \hbox{\vrule \@height\z@ \@width\z@ \@depth\@pagedp}} -\def\@stopline{\unskip\@stopfield\if@rjfield \global\@rjfieldfalse - \@tempdima\@totalleftmargin \advance\@tempdima\linewidth -\hbox to\@tempdima{\if@RTL\beginR\fi\@itemfudge\hskip\dimen\@curtabmar - \box\@curline\hfil\box\@curfield\if@RTL\endR\fi}\else\@addfield - \hbox to\linewidth{\if@RTL\beginR\fi\@itemfudge - \hskip\dimen\@curtabmar\box\@curline\hfil\if@RTL\endR\fi}% -\fi} -\def\@outputpage{% -\begingroup % the \endgroup is put in by \aftergroup - \let \protect \noexpand - \@resetactivechars - \global\let\@@if@newlist\if@newlist - \global\@newlistfalse - \@parboxrestore - \shipout \vbox{% - \set@typeset@protect - \aftergroup \endgroup - \aftergroup \set@typeset@protect - % correct? or just restore by ending - % the group? - \if@specialpage - \global\@specialpagefalse\@nameuse{ps@\@specialstyle}% - \fi - \if@twoside - \ifodd\count\z@ \let\@thehead\@oddhead \let\@thefoot\@oddfoot - \let\@themargin\oddsidemargin - \else \let\@thehead\@evenhead - \let\@thefoot\@evenfoot \let\@themargin\evensidemargin - \fi - \ifx\@thehead\@empty \let\@thehead\hfil \fi - \ifx\@thefoot\@empty \let\@thefoot\hfil \fi - \else %% not @twoside - \ifx\@oddhead\@empty \let\@thehead\hfil \fi - \ifx\@oddfoot\@empty \let\@thefoot\hfil \fi - \fi - \reset@font - \normalsize - \normalsfcodes - \let\label\@gobble - \let\index\@gobble - \let\glossary\@gobble - \baselineskip\z@skip \lineskip\z@skip \lineskiplimit\z@ - \@begindvi - \vskip \topmargin - \moveright\@themargin \vbox {% - \setbox\@tempboxa \vbox to\headheight{% - \vfil - \color@hbox - \normalcolor - \hb@xt@\textwidth{\if@RTLmain\beginR\fi\@thehead\if@RTLmain\endR\fi}% - \color@endbox - }% %% 22 Feb 87 - \dp\@tempboxa \z@ - \box\@tempboxa - \vskip \headsep - \box\@outputbox - \baselineskip \footskip - \color@hbox - \normalcolor - \hb@xt@\textwidth{\if@RTLmain\beginR\fi\@thefoot\if@RTLmain\endR\fi}% - \color@endbox - }% - }% - \global\let\if@newlist\@@if@newlist - \global \@colht \textheight - \stepcounter{page}% - \let\firstmark\botmark -} -\long\def\@makecaption#1#2{% - \vskip\abovecaptionskip - \sbox\@tempboxa{#1: #2}% - \ifdim \wd\@tempboxa >\hsize - \if@RTL\beginR\fi#1: #2\if@RTL\endR\fi\par + \ifluatex + \input{luatex-bidi.def} \else - \global \@minipagefalse - \hb@xt@\hsize{\if@RTL\beginR\fi\hfil\box\@tempboxa\hfil\if@RTL\endR\fi}% + \PackageError{bidi}{TeX engines other than XeTeX and LuaTeX are not yet supported} \fi - \vskip\belowcaptionskip} -\def\equation{\beginL$$\refstepcounter{equation}} -\def\endequation{\eqno \hbox{\@eqnnum}$$\endL\@ignoretrue} -\def\@eqnnum{{\normalfont \normalcolor \if@RTL\beginR\fi(\theequation)\if@RTL\endR\fi}} -\input{footnote-bidi.def} -\input{loadingorder-bidi.def} -\@iftagsloaded{leqno}{\input{leqno-bidi.def}}{} -\@iftagsloaded{fleqn}{\input{fleqn-bidi.def}}{} -\@ifpackageloaded{amsmath}{\input{amsmath-bidi.def}}{} -\@ifpackageloaded{amsthm}{\input{amsthm-bidi.def}}{} -\@ifpackageloaded{breqn}{\input{breqn-bidi.def}}{} -\@ifpackageloaded{color}{\input{color-bidi.def}}{} -\@ifpackageloaded{xcolor}{\input{xcolor-bidi.def}}{} -\@ifpackageloaded{colortbl}{\input{colortbl-bidi.def}}{} -\@ifpackageloaded{flowfram}{\input{flowfram-bidi.def}}{} -\@ifpackageloaded{xltxtra}{\input{xltxtra-bidi.def}}{} -\@ifpackageloaded{wrapfig}{\input{wrapfig-bidi.def}}{} -\@ifpackageloaded{graphicx}{\input{graphicx-bidi.def}}{} -\@ifpackageloaded{hyperref}{\input{hyperref-bidi.def}}{} -\@ifpackageloaded{fancyhdr}{\input{fancyhdr-bidi.def}}{} -\@ifpackageloaded{draftwatermark}{\input{draftwatermark-bidi.def}}{} -\@ifpackageloaded{pdfpages}{\input{pdfpages-bidi.def}}{} -\@ifpackageloaded{listings}{\input{listings-bidi.def}}{} -\@ifpackageloaded{pstricks}{\input{pstricks-bidi.def}}{} -\@ifpackageloaded{tikz}{\input{tikz-bidi.def}}{} -\@ifpackageloaded{array}{\input{array-bidi.def}}{} -\@ifpackageloaded{stabular}{\input{stabular-bidi.def}}{} -\@ifpackageloaded{longtable}{\input{longtable-bidi.def}}{} -\@ifpackageloaded{arydshln}{\input{arydshln-bidi.def}}{} -\@ifpackageloaded{multicol}{\input{multicol-bidi.def}}{} -\@ifpackageloaded{minitoc}{\input{minitoc-bidi.def}}{} -\@ifpackageloaded{ragged2e}{\input{ragged2e-bidi.def}}{} -\@ifpackageloaded{tabls}{\input{tabls-bidi.def}}{} -\@ifpackageloaded{tabulary}{\input{tabulary-bidi.def}}{} -\@ifpackageloaded{tocstyle}{\input{tocstyle-bidi.def}}{} -\@ifclassloaded{article}{\input{article-bidi.def}}{} -\@ifclassloaded{amsart}{\input{amsart-bidi.def}}{} -\@ifclassloaded{letter}{\input{letter-bidi.def}}{} -\@ifclassloaded{memoir}{\input{memoir-bidi.def}}{} -\@ifclassloaded{refrep}{\input{refrep-bidi.def}}{} -\@ifclassloaded{report}{\@ifpackageloaded{flowfram}{}{\input{report-bidi.def}}}{} -\@ifclassloaded{rapport3}{\input{rapport3-bidi.def}}{} -\@ifclassloaded{scrartcl}{\input{scrartcl-bidi.def}}{} -\@ifclassloaded{scrbook}{\input{scrbook-bidi.def}}{} -\@ifclassloaded{scrreprt}{\input{scrreprt-bidi.def}}{} -\@ifclassloaded{amsbook}{\input{amsbook-bidi.def}}{} -\@ifclassloaded{bookest}{\input{bookest-bidi.def}}{} -\@ifclassloaded{extbook}{\input{extbook-bidi.def}}{} -\@ifclassloaded{book}{\@ifpackageloaded{flowfram}{}{\input{book-bidi.def}}}{} -\@ifpackageloaded{tocbibind}{\@ifclassloaded{memoir}{}{\input{tocbibind-bidi.def}}}{} -\@ifpackageloaded{tocloft}{\@ifclassloaded{memoir}{}{\input{tocloft-bidi.def}}}{} -\ProcessOptions +\fi +\ProcessOptions %% %% Copyright © 2009-2010 by Vafa Khalighi %% diff --git a/Master/texmf-dist/tex/xelatex/bidi/bidicode.sty b/Master/texmf-dist/tex/xelatex/bidi/bidicode.sty index 7a8dd0b3768..dcb383f932e 100644 --- a/Master/texmf-dist/tex/xelatex/bidi/bidicode.sty +++ b/Master/texmf-dist/tex/xelatex/bidi/bidicode.sty @@ -26,79 +26,38 @@ \lstset{% language=[LaTeX]TEX,% float=hbp,% - basicstyle=\ttfamily, % + basicstyle=\ttfamily\small, % identifierstyle=\color{black}, % keywordstyle=\color{mygreen}, % stringstyle=\color{blue}, % commentstyle=\color{blue}, % columns=flexible, % + tabsize=4, % + frame=single, % extendedchars=true, % showspaces=false, % showstringspaces=false, % + numbers=left, + numbersep=12pt, + numberstyle=\tiny, % breaklines=true, % breakautoindent=true, - captionpos=t, - explpreset={columns=flexible,language=[LaTeX]TEX}, + captionpos=b, + xleftmargin=1em, + breaklines=true, + backgroundcolor=\color{mybackground}, + breakautoindent=true, + rframe={}, + explpreset={numbers=left,numberstyle=\tiny,numbersep=12pt, + xleftmargin=1em,columns=flexible,language=[LaTeX]TEX}, morekeywords={setLTR,setLR,setRTL,setRL,LRE,LR,RLE,RL,lr} } -\lstdefinestyle{syntax}{backgroundcolor=\color{blue!20}} -\lstdefinestyle{code}{backgroundcolor=\color{red!20}} +\lstdefinestyle{syntax}{backgroundcolor=\color{blue!20},numbers=none,xleftmargin=0pt,xrightmargin=0pt, + frame=single} +\lstdefinestyle{code}{backgroundcolor=\color{red!20},numbers=left,xleftmargin=0pt,xrightmargin=0pt, + frame=single} \lst@UserCommand\lstlistlistingname{List of Examples} % \lstlistoflistings \lst@UserCommand\lstlistingname{Example} - -\def\lst@Init#1{% - \begingroup\if@RTL\@RTLfalse\fi - \ifx\lst@float\relax\else - \edef\@tempa{\noexpand\lst@beginfloat{lstlisting}[\lst@float]}% - \expandafter\@tempa - \fi - \ifx\lst@multicols\@empty\else - \edef\lst@next{\noexpand\multicols{\lst@multicols}} - \expandafter\lst@next - \fi - \ifhmode\ifinner \lst@boxtrue \fi\fi - \lst@ifbox - \lsthk@BoxUnsafe - \hbox to\z@\bgroup - $\if t\lst@boxpos \vtop - \else \if b\lst@boxpos \vbox - \else \vcenter \fi\fi - \bgroup \par\noindent - \else - \lst@ifdisplaystyle - \lst@EveryDisplay - \par\penalty-50\relax - \vspace\lst@aboveskip - \fi - \fi - \normalbaselines - \abovecaptionskip\lst@abovecaption\relax - \belowcaptionskip\lst@belowcaption\relax - \lst@MakeCaption t% - \lsthk@PreInit \lsthk@Init - \lst@ifdisplaystyle - \global\let\lst@ltxlabel\@empty - \if@inlabel - \lst@ifresetmargins - \leavevmode - \else - \xdef\lst@ltxlabel{\the\everypar}% - \lst@AddTo\lst@ltxlabel{% - \global\let\lst@ltxlabel\@empty - \everypar{\lsthk@EveryLine\lsthk@EveryPar}}% - \fi - \fi - \everypar\expandafter{\lst@ltxlabel - \lsthk@EveryLine\lsthk@EveryPar}% - \else - \everypar{}\let\lst@NewLine\@empty - \fi - \lsthk@InitVars \lsthk@InitVarsBOL - \lst@Let{13}\lst@MProcessListing - \let\lst@Backslash#1% - \lst@EnterMode{\lst@Pmode}{\lst@SelectCharTable}% - \lst@InitFinalize} - \newcommand\Larg [1]{{\normalfont\itshape#1\/}} \newcommand\Larga[1]{$\langle$\Larg{#1}$\rangle$} \newcommand\Largb[1]{\lcb\Larg{#1}\rcb} @@ -139,7 +98,7 @@ \newsavebox{\boxdef} \newenvironment{BDef} {\begin{lrbox}\boxdef - \def\arraystretch{1.0}\if@RTL\@RTLfalse\fi + \def\arraystretch{1.0} \begin{tabular}{@{}l@{}l@{}l@{}} } {\end{tabular}\end{lrbox} @@ -150,7 +109,7 @@ \newenvironment{BDef*} {\begin{lrbox}\boxdef - \def\arraystretch{1.0}\if@RTL\@RTLfalse\fi + \def\arraystretch{1.0} \begin{tabular}{@{}l@{}l@{}l@{}} } {\end{tabular}\end{lrbox} @@ -161,7 +120,7 @@ \@beginparpenalty-\@lowpenalty \topsep\BDefaboveskip \fboxsep3pt - \flushleft\if@RTL\@RTLfalse\fi} + \flushleft} {\@endparpenalty\@M \@topsepadd\BDefbelowskip \endflushleft} @@ -170,7 +129,7 @@ \@beginparpenalty\@M \topsep\BDefinlineskip \fboxsep3pt - \flushleft\if@RTL\@RTLfalse\fi} + \flushleft} {\@endparpenalty5000 \endflushleft} diff --git a/Master/texmf-dist/tex/xelatex/bidi/bidimoderncv.cls b/Master/texmf-dist/tex/xelatex/bidi/bidimoderncv.cls new file mode 100644 index 00000000000..f6692b218c4 --- /dev/null +++ b/Master/texmf-dist/tex/xelatex/bidi/bidimoderncv.cls @@ -0,0 +1,273 @@ +%% +%% This is file `bidimoderncv.cls', + +%% +%% __________________________________ +%% Copyright © 2009-2010 Vafa Khalighi +%% +%% License information appended. +%% +%% +\NeedsTeXFormat{LaTeX2e} +\ProvidesClass{bidimoderncv} +\newif\if@DEBUG\@DEBUGfalse +\DeclareOption{a4paper}{ + \setlength\paperheight{297mm} + \setlength\paperwidth{210mm}} +\DeclareOption{a5paper}{ + \setlength\paperheight{210mm} + \setlength\paperwidth{148mm}} +\DeclareOption{b5paper}{ + \setlength\paperheight{250mm} + \setlength\paperwidth{176mm}} +\DeclareOption{letterpaper}{ + \setlength\paperheight{11in} + \setlength\paperwidth{8.5in}} +\DeclareOption{legalpaper}{ + \setlength\paperheight{14in} + \setlength\paperwidth{8.5in}} +\DeclareOption{executivepaper}{ + \setlength\paperheight{10.5in} + \setlength\paperwidth{7.25in}} +\DeclareOption{landscape}{ + \setlength\@tempdima{\paperheight} + \setlength\paperheight{\paperwidth} + \setlength\paperwidth{\@tempdima}} +\newcommand\@ptsize{} +\DeclareOption{10pt}{\renewcommand\@ptsize{0}} +\DeclareOption{11pt}{\renewcommand\@ptsize{1}} +\DeclareOption{12pt}{\renewcommand\@ptsize{2}} +\DeclareOption{draft}{\setlength\overfullrule{5pt}} +\DeclareOption{final}{\setlength\overfullrule{0pt}} +\newif\if@colour\@colourtrue +\DeclareOption{nocolour}{\@colourfalse} +\ExecuteOptions{a4paper,11pt,colour,final} +\ProcessOptions\relax +\input{size1\@ptsize.clo} +\RequirePackage{color} +\RequirePackage{graphicx} +\RequirePackage{ifthen} +\RequirePackage{marvosym} +\addtolength{\oddsidemargin}{-54pt} +\addtolength{\textwidth}{109pt} +\addtolength{\topmargin}{-70pt} +\addtolength{\textheight}{122pt} +\addtolength{\marginparsep}{-5pt} +\addtolength{\marginparwidth}{-10pt} +\RequirePackage{url} +\RequirePackage{hyperref} +\hypersetup{% + breaklinks, + baseurl = http://,% + pdfborder = 0 0 0,% + pdfpagemode = UseNone,% + pdfstartpage = 1} +\AtEndOfClass{% + \AtBeginDocument{% + \hypersetup{% + pdfauthor = \@firstname~\@familyname,% + pdftitle = \@title,% + pdfsubject = \@firstname~\@familyname,% + pdfkeywords = \@resumename~\@firstname~\@familyname}}} +\urlstyle{tt} +\RequirePackage{fancyhdr} +\fancypagestyle{plain}{% + \renewcommand{\headrulewidth}{0pt} + \renewcommand{\footrulewidth}{0pt} + \fancyhf{}} +\pagestyle{plain} +\setlength\lineskip{1\p@} +\setlength\normallineskip{1\p@} +\renewcommand\baselinestretch{} +\setlength{\parindent}{0pt} +\setlength{\parskip}{0pt} +\setlength\columnsep{10\p@} +\setlength\columnseprule{0\p@} +\pagestyle{empty} +\pagenumbering{arabic} +\raggedbottom +\onecolumn +\providecommand*{\listitemsymbol}{\textbullet} +\providecommand*{\addresssymbol}{} +\providecommand*{\mobilesymbol}{\Mobilefone} +\providecommand*{\phonesymbol}{\Telefon} +\providecommand*{\faxsymbol}{\FAX} +\providecommand*{\emailsymbol}{\Letter} +\definecolor{firstnamecolor}{rgb}{0,0,0} +\def\firstnamecolour#1{\gdef\@firstnamecolour{\addfontfeature{Color=#1}}} +\def\familynamecolour#1{\gdef\@familynamecolour{\addfontfeature{Color=#1}}} +\def\titlecolour#1{\gdef\@titlecolour{\addfontfeature{Color=#1}}} +\def\addresscolour#1{\gdef\@addresscolour{\addfontfeature{Color=#1}}} +\def\quotecolour#1{\gdef\@quotecolour{\addfontfeature{Color=#1}}} +\def\sectiontitlecolour#1{\gdef\@sectiontitlecolour{\addfontfeature{Color=#1}}} +\definecolor{sectionrectanglecolor}{rgb}{0,0,0} +\def\subsectioncolour#1{\gdef\@subsectioncolour{\addfontfeature{Color=#1}}} +\def\hintcolour#1{\gdef\@hintcolour{\addfontfeature{Color=#1}}} +\providecommand*{\firstnamefont}{} +\providecommand*{\familynamefont}{} +\providecommand*{\titlefont}{} +\providecommand*{\addressfont}{} +\providecommand*{\quotefont}{} +\providecommand*{\sectionfont}{} +\providecommand*{\subsectionfont}{} +\providecommand*{\hintfont}{\small} +\providecommand*{\firstnamestyle}[1]{{\firstnamefont\@firstnamecolour#1}} +\providecommand*{\familynamestyle}[1]{{\familynamefont\@familynamecolour#1}} +\providecommand*{\titlestyle}[1]{{\titlefont\@titlecolour#1}} +\providecommand*{\addresstyle}[1]{{\addressfont\@addresscolour#1}} +\providecommand*{\quotestyle}[1]{{\quotefont\@quotecolour#1}} +\providecommand*{\sectionstyle}[1]{{\sectionfont\@sectiontitlecolour#1}} +\providecommand*{\subsectionstyle}[1]{{\subsectionfont\@subsectioncolour#1}} +\providecommand*{\hintstyle}[1]{{\hintfont\@hintcolour#1}} +\newcommand*{\cvtheme}[2][]{ + \def\@cvtheme{#2} + \def\@cvthemeoptions{#1}} +\cvtheme{bidi-casual} +\AtBeginDocument{\RequirePackage[\@cvthemeoptions]{cvtheme\@cvtheme}} +\newcommand*{\resumename}[1]{\def\@resumename{#1}} +\newcommand*{\firstname}[1]{\def\@firstname{#1}} +\newcommand*{\familyname}[1]{\def\@familyname{#1}} +\renewcommand*{\title}[1]{\def\@title{#1}} +\newcommand*{\address}[1]{\def\@address{#1}} +\newcommand*{\mobile}[1]{\def\@mobile{#1}} +\newcommand*{\phone}[1]{\def\@phone{#1}} +\renewcommand*{\fax}[1]{\def\@fax{#1}} +\newcommand*{\email}[1]{\def\@email{#1}} +\newcommand*{\extrainfo}[1]{\def\@extrainfo{#1}} +\def\@photowidth{0pt} +\newcommand*{\photo}[2][64pt]{\def\@photowidth{#1}\def\@photo{#2}} +\newcommand*{\quote}[1]{\def\@quote{#1}} +\newlength{\quotewidth} +\newlength{\hintscolumnwidth} +\newlength{\separatorcolumnwidth} +\setlength{\separatorcolumnwidth}{0.025\textwidth} +\newlength{\maincolumnwidth} +\newlength{\doubleitemmaincolumnwidth} +\newlength{\listitemsymbolwidth} +\settowidth{\listitemsymbolwidth}{\listitemsymbol{}~} +\newlength{\listitemmaincolumnwidth} +\newlength{\listdoubleitemmaincolumnwidth} +\newcommand*{\recomputethemelengths}{} +\newcommand*{\recomputelengths}{% +\setlength{\quotewidth}{0.65\textwidth}% +\setlength{\maincolumnwidth}{\textwidth}% +\addtolength{\maincolumnwidth}{-\separatorcolumnwidth}% +\addtolength{\maincolumnwidth}{-\hintscolumnwidth}% +\setlength{\listitemmaincolumnwidth}{\maincolumnwidth}% +\addtolength{\listitemmaincolumnwidth}{-\listitemsymbolwidth}% +\setlength{\doubleitemmaincolumnwidth}{\maincolumnwidth}% +\addtolength{\doubleitemmaincolumnwidth}{-\hintscolumnwidth}% +\addtolength{\doubleitemmaincolumnwidth}{-\separatorcolumnwidth}% +\setlength{\doubleitemmaincolumnwidth}{0.5\doubleitemmaincolumnwidth}% +\setlength{\listdoubleitemmaincolumnwidth}{\maincolumnwidth}% +\addtolength{\listdoubleitemmaincolumnwidth}{-\listitemsymbolwidth}% +\setlength{\listdoubleitemmaincolumnwidth}{0.475\listdoubleitemmaincolumnwidth}% +\renewcommand{\headwidth}{\textwidth}% +\recomputethemelengths} +\setlength{\hintscolumnwidth}{0.15\textwidth} +\recomputelengths +\title{} +\renewcommand*{\maketitle}{} +\newcommand*{\section}[1]{% +\vspace*{2.5ex \@plus 1ex \@minus .2ex}% + \phantomsection{}% + \addcontentsline{toc}{part}{#1}% + \parbox[m]{\hintscolumnwidth}{\raggedleft\hintfont{\leavevmode\color{sectionrectanglecolor}\rule{\hintscolumnwidth}{1ex}}}% + \hspace{\separatorcolumnwidth}% + \parbox[m]{\maincolumnwidth}{\sectionstyle{#1}}\\[1ex]} +\newcommand*{\subsection}[1]{% + \cvline[0.45em]{}{\subsectionstyle{#1}}} +\newcommand*{\cvline}[3][.25em]{% + \begin{tabular}{@{}p{\hintscolumnwidth}@{\hspace{\separatorcolumnwidth}}p{\maincolumnwidth}@{}}% + \raggedleft\hintfont{#2} &{#3}% + \end{tabular}\\[#1]} +\newcommand*{\cvdoubleitem}[4]{% + \cvline{#1}{\begin{minipage}[t]{\doubleitemmaincolumnwidth}#2\end{minipage}% + \hfill% + \begin{minipage}[t]{\hintscolumnwidth}\raggedleft\hintfont{#3}\end{minipage}\hspace*{\separatorcolumnwidth}\begin{minipage}[t]{\doubleitemmaincolumnwidth}#4\end{minipage}}} +\newcommand*{\cvlistitem}[2][\listitemsymbol{}]{% + \cvline[0pt]{}{#1~\begin{minipage}[t]{\listitemmaincolumnwidth}#2\end{minipage}}} +\newcommand*{\cvlistdoubleitem}[3][\listitemsymbol{}]{% + \cvline[0pt]{}{#1~\begin{minipage}[t]{\listdoubleitemmaincolumnwidth}#2\end{minipage}% + \hfill% + \ifthenelse{\equal{#3}{}}% + {}% + {#1~\begin{minipage}[t]{\listdoubleitemmaincolumnwidth}#3\end{minipage}}}} +\newcommand*{\cventry}[6]{% + \cvline{#1}{% + {\bfseries#2}% + \ifx#3\else{, {\slshape#3}}\fi% + \ifx#4\else{, #4}\fi% + \ifx#5\else{, #5}\fi% + .% + \ifx#6\else{\newline{}\begin{minipage}[t]{\linewidth}\small#6\end{minipage}}\fi + }}% +\newcommand*{\cvlanguage}[3]{% + \cvline{#1}{\begin{minipage}[t]{.225\maincolumnwidth}\textbf{#2}\end{minipage}\hfill\begin{minipage}[t]{0.725\maincolumnwidth}\raggedleft\footnotesize\itshape #3\end{minipage}}} +\newcommand*{\cvcomputer}[4]{% + \cvdoubleitem{#1}{\small#2}{#3}{\small#4}} +\newcommand*{\link}[2][]{% + \ifthenelse{\equal{#1}{}}% + {\href{#2}{#2}}% + {\href{#2}{#1}}} +\newcommand*{\httplink}[2][]{% + \ifthenelse{\equal{#1}{}}% + {\href{http://#2}{#2}}% + {\href{http://#2}{#1}}} +\newcommand*{\emaillink}[2][]{% + \ifthenelse{\equal{#1}{}}% + {\href{mailto:#2}{#2}}% + {\href{mailto:#2}{#1}}} +\newif\if@displaypagenumbers\@displaypagenumberstrue +\newcommand*{\nopagenumbers}{\@displaypagenumbersfalse} +\AtBeginDocument{% + \if@displaypagenumbers% + \@ifundefined{r@lastpage}{}{% + \ifthenelse{\pageref{lastpage} > 1}{% + \fancypagestyle{plain}{% + \fancyfoot[r]{\beginL\addressfont\@quotecolour\footnotesize\thepage\beginL/\endL\pageref{lastpage}\endL}}% + \pagestyle{plain}}{}}% + \AtEndDocument{\label{lastpage}}% + \fi} +\newlength{\bibindent} +\setlength{\bibindent}{1.5em} +\newcommand*{\bibliographyitemlabel}{\includegraphics{bibitem.pdf}} +\newenvironment{thebibliography}[1]% + {% + \section{\refname}% + \small% + \begin{list}{\bibliographyitemlabel}% + {% + \setlength{\topsep}{0pt}% + \setlength{\labelwidth}{\hintscolumnwidth}% + \setlength{\labelsep}{\separatorcolumnwidth}% + \leftmargin\labelwidth% + \advance\leftmargin\labelsep% + \@openbib@code% + \usecounter{enumiv}% + \let\p@enumiv\@empty% + \renewcommand\theenumiv{\@arabic\c@enumiv}}% + \sloppy\clubpenalty4000\widowpenalty4000% + }% + {% + \def\@noitemerr{\@latex@warning{Empty `thebibliography' environment}}% + \end{list}% + } +\newcommand\newblock{\hskip .11em\@plus.33em\@minus.07em} +\let\@openbib@code\@empty + +%% +%% Copyright © 2009-2010 by Vafa Khalighi +%% +%% Distributable 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 "maintained" (as per LPPL maintenance status) +%% by Vafa Khalighi. +%% +%% +%% +%% +%% +%% End of file `bidimoderncv.cls'. diff --git a/Master/texmf-dist/tex/xelatex/bidi/bidipoem.sty b/Master/texmf-dist/tex/xelatex/bidi/bidipoem.sty index 06f83b9c3f4..e4ff25a26cd 100644 --- a/Master/texmf-dist/tex/xelatex/bidi/bidipoem.sty +++ b/Master/texmf-dist/tex/xelatex/bidi/bidipoem.sty @@ -10,7 +10,7 @@ %% \NeedsTeXFormat{LaTeX2e} \ProvidesPackage{bidipoem}% -[2010/03/01 Environments for typesetting Persian traditional and modern poems] +[2010/07/25 Environments for typesetting Persian traditional and modern poems] \def\poemcolsepskip{.1\versewidth plus .1\versewidth minus .05\versewidth} \def\poemmarginskip{1em plus 1fil minus 1em} \def\poemextrabaselineskip{0\baselineskip} diff --git a/Master/texmf-dist/tex/xelatex/bidi/book-bidi.def b/Master/texmf-dist/tex/xelatex/bidi/book-bidi.def deleted file mode 100644 index 7adaa49516b..00000000000 --- a/Master/texmf-dist/tex/xelatex/bidi/book-bidi.def +++ /dev/null @@ -1,240 +0,0 @@ -%% -%% This is file `book-bidi.def', - -%% -%% __________________________________ -%% Copyright © 2009-2010 Vafa Khalighi -%% -%% License information appended. -%% -%% -\ProvidesFile{book-bidi.def}[2010/03/01 v0.2 adaptations for standard book class] - \if@titlepage - \renewcommand\maketitle{\begin{titlepage}% - \let\footnotesize\small - \let\footnoterule\relax - \let \footnote \thanks - \let \LTRfootnote \LTRthanks - \let \RTLfootnote \RTLthanks - \null\vfil - \vskip 60\p@ - \begin{center}% - {\LARGE \@title \par}% - \vskip 3em% - {\large - \lineskip .75em% - \begin{tabular}[t]{c}% - \@author - \end{tabular}\par}% - \vskip 1.5em% - {\large \@date \par}% % Set date in \large size. - \end{center}\par - \@thanks - \vfil\null - \end{titlepage}% - \setcounter{footnote}{0}% - \global\let\thanks\relax - \global\let\LTRthanks\relax - \global\let\RTLthanks\relax - \global\let\maketitle\relax - \global\let\@thanks\@empty - \global\let\@author\@empty - \global\let\@date\@empty - \global\let\@title\@empty - \global\let\title\relax - \global\let\author\relax - \global\let\date\relax - \global\let\and\relax -} -\else -\renewcommand\maketitle{\par - \begingroup - \renewcommand\thefootnote{\@fnsymbol\c@footnote}% - \def\@makefnmark{\rlap{\@textsuperscript{\normalfont\@thefnmark}}}% - \long\def\@makefntext##1{\parindent 1em\noindent - \hb@xt@1.8em{% - \hss\@textsuperscript{\normalfont\@thefnmark}}##1}% - \if@twocolumn - \ifnum \col@number=\@ne - \@maketitle - \else - \twocolumn[\@maketitle]% - \fi - \else - \newpage - \global\@topnum\z@ % Prevents figures from going at top of page. - \@maketitle - \fi - \thispagestyle{plain}\@thanks - \endgroup - \setcounter{footnote}{0}% - \global\let\thanks\relax - \global\let\LTRthanks\relax - \global\let\RTLthanks\relax - \global\let\maketitle\relax - \global\let\@maketitle\relax - \global\let\@thanks\@empty - \global\let\@author\@empty - \global\let\@date\@empty - \global\let\@title\@empty - \global\let\title\relax - \global\let\author\relax - \global\let\date\relax - \global\let\and\relax -} -\def\@maketitle{% - \newpage - \null - \vskip 2em% - \begin{center}% - \let \footnote \thanks - \let \LTRfootnote \LTRthanks - \let \RTLfootnote \RTLthanks - {\LARGE \@title \par}% - \vskip 1.5em% - {\large - \lineskip .5em% - \begin{tabular}[t]{c}% - \@author - \end{tabular}\par}% - \vskip 1em% - {\large \@date}% - \end{center}% - \par - \vskip 1.5em} -\fi -\renewcommand*\l@part[2]{% - \ifnum \c@tocdepth >-2\relax - \addpenalty{-\@highpenalty}% - \addvspace{2.25em \@plus\p@}% - \setlength\@tempdima{3em}% - \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\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 \thechapter {\@arabic\c@chapter} -\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} -\def\@makechapterhead#1{% - \vspace*{50\p@}% - {\parindent \z@ \if@RTL\raggedleft\else\raggedright\fi \normalfont - \ifnum \c@secnumdepth >\m@ne - \if@mainmatter - \huge\bfseries \@chapapp\space \thechapter - \par\nobreak - \vskip 20\p@ - \fi - \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@ - }} -\renewenvironment{thebibliography}[1] - {\chapter*{\bibname}% - \@mkboth{\MakeUppercase\bibname}{\MakeUppercase\bibname}% - \list{\@biblabel{\@arabic\c@enumiv}}% - {\settowidth\labelwidth{\@biblabel{#1}}% - \rightmargin\labelwidth - \advance\rightmargin\labelsep - \@openbib@code - \usecounter{enumiv}% - \let\p@enumiv\@empty - \renewcommand\theenumiv{\@arabic\c@enumiv}}% - \sloppy - \clubpenalty4000 - \@clubpenalty \clubpenalty - \widowpenalty4000% - \sfcode`\.\@m} - {\def\@noitemerr - {\@latex@warning{Empty `thebibliography' environment}}% - \endlist} -\renewcommand\backmatter{% - \if@openright - \cleardoublepage - \else - \clearpage - \fi - \@mainmatterfalse} - -\if@twoside - \def\ps@headings{% - \let\@oddfoot\@empty\let\@evenfoot\@empty - \def\@evenhead{\sl\if@RTLmain\beginR\fi\rightmark\if@RTLmain\endR\fi\hfil\thepage}% - \def\@oddhead{\sl\thepage\hfil\if@RTLmain\beginR\fi\leftmark\if@RTLmain\endR\fi}% - \let\@mkboth\markboth - \def\chaptermark##1{% - \markboth {\MakeUppercase{% - \if@RTLmain\beginR\fi\@chapapp\ \thechapter.\,\,\if@RTLmain\endR\fi% - \ifnum \c@secnumdepth >\m@ne - \if@mainmatter - \if@RTLmain\beginR\fi##1\if@RTLmain\endR\fi - \fi - \fi - }}{}}% - \def\ps@plain{\ps@empty -\def\@oddfoot{\hfil\thepage\hfil}% -\let\@evenfoot\@oddfoot -} - \def\sectionmark##1{% - \markright {\MakeUppercase{% -\if@RTLmain\beginR\fi\thesection\if@RTLmain\endR\fi\, - \ifnum \c@secnumdepth >\z@ - \if@RTLmain\beginR\fi##1\if@RTLmain\endR\fi \ % - \fi - }}}} -\else - \def\ps@headings{% - \let\@oddfoot\@empty - \def\@oddhead{\sl\thepage\hfil\if@RTLmain\beginR\fi\rightmark\if@RTLmain\endR\fi}% - \let\@mkboth\markboth - \def\chaptermark##1{% - \markright {\MakeUppercase{% - \if@RTLmain\beginR\fi\@chapapp\ \thechapter. \if@RTLmain\endR\fi % - \ifnum \c@secnumdepth >\m@ne - \if@mainmatter - \if@RTLmain\beginR\fi##1\if@RTLmain\endR\fi - \fi - \fi - }}}} - -\fi -\pagestyle{headings} -\def\@idxitem{\par\hangindent -40\p@} -%% -%% Copyright © 2009-2010 by Vafa Khalighi -%% -%% Distributable 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 "maintained" (as per LPPL maintenance status) -%% by Vafa Khalighi. -%% -%% -%% -%% -%% -%% End of file `book-bidi.def'. diff --git a/Master/texmf-dist/tex/xelatex/bidi/book-xetex-bidi.def b/Master/texmf-dist/tex/xelatex/bidi/book-xetex-bidi.def new file mode 100644 index 00000000000..5113e120d38 --- /dev/null +++ b/Master/texmf-dist/tex/xelatex/bidi/book-xetex-bidi.def @@ -0,0 +1,177 @@ +%% +%% This is file `book-xetex-bidi.def', + +%% +%% __________________________________ +%% Copyright © 2009-2010 Vafa Khalighi +%% +%% License information appended. +%% +%% +\ProvidesFile{book-xetex-bidi.def}[2010/07/25 v0.5 bidi adaptations for standard book class for XeTeX engine] +\@ifclassloaded{bookest}{}{% + \if@titlepage + \renewcommand\maketitle{\begin{titlepage}% + \let\footnotesize\small + \let\footnoterule\relax + \let \footnote \thanks + \let \LTRfootnote \LTRthanks + \let \RTLfootnote \RTLthanks + \null\vfil + \vskip 60\p@ + \begin{center}% + {\LARGE \@title \par}% + \vskip 3em% + {\large + \lineskip .75em% + \begin{tabular}[t]{c}% + \@author + \end{tabular}\par}% + \vskip 1.5em% + {\large \@date \par}% % Set date in \large size. + \end{center}\par + \@thanks + \vfil\null + \end{titlepage}% + \setcounter{footnote}{0}% + \global\let\thanks\relax + \global\let\LTRthanks\relax + \global\let\RTLthanks\relax + \global\let\maketitle\relax + \global\let\@thanks\@empty + \global\let\@author\@empty + \global\let\@date\@empty + \global\let\@title\@empty + \global\let\title\relax + \global\let\author\relax + \global\let\date\relax + \global\let\and\relax +} +\else +\renewcommand\maketitle{\par + \begingroup + \renewcommand\thefootnote{\@fnsymbol\c@footnote}% + \def\@makefnmark{\rlap{\@textsuperscript{\normalfont\@thefnmark}}}% + \long\def\@makefntext##1{\parindent 1em\noindent + \hb@xt@1.8em{% + \hss\@textsuperscript{\normalfont\@thefnmark}}##1}% + \if@twocolumn + \ifnum \col@number=\@ne + \@maketitle + \else + \twocolumn[\@maketitle]% + \fi + \else + \newpage + \global\@topnum\z@ % Prevents figures from going at top of page. + \@maketitle + \fi + \thispagestyle{plain}\@thanks + \endgroup + \setcounter{footnote}{0}% + \global\let\thanks\relax + \global\let\LTRthanks\relax + \global\let\RTLthanks\relax + \global\let\maketitle\relax + \global\let\@maketitle\relax + \global\let\@thanks\@empty + \global\let\@author\@empty + \global\let\@date\@empty + \global\let\@title\@empty + \global\let\title\relax + \global\let\author\relax + \global\let\date\relax + \global\let\and\relax +} +\def\@maketitle{% + \newpage + \null + \vskip 2em% + \begin{center}% + \let \footnote \thanks + \let \LTRfootnote \LTRthanks + \let \RTLfootnote \RTLthanks + {\LARGE \@title \par}% + \vskip 1.5em% + {\large + \lineskip .5em% + \begin{tabular}[t]{c}% + \@author + \end{tabular}\par}% + \vskip 1em% + {\large \@date}% + \end{center}% + \par + \vskip 1.5em} +\fi} +\renewcommand*\l@part[2]{% + \ifnum \c@tocdepth >-2\relax + \addpenalty{-\@highpenalty}% + \addvspace{2.25em \@plus\p@}% + \setlength\@tempdima{3em}% + \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\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 \thechapter {\@arabic\c@chapter} +\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} +\def\@makechapterhead#1{% + \vspace*{50\p@}% + {\parindent \z@ \if@RTL\raggedleft\else\raggedright\fi \normalfont + \ifnum \c@secnumdepth >\m@ne + \if@mainmatter + \huge\bfseries \@chapapp\space \thechapter + \par\nobreak + \vskip 20\p@ + \fi + \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@ + }} +\renewcommand\backmatter{% + \if@openright + \cleardoublepage + \else + \clearpage + \fi + \@mainmatterfalse} +%% +%% Copyright © 2009-2010 by Vafa Khalighi +%% +%% Distributable 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 "maintained" (as per LPPL maintenance status) +%% by Vafa Khalighi. +%% +%% +%% +%% +%% +%% End of file `book-xetex-bidi.def'. diff --git a/Master/texmf-dist/tex/xelatex/bidi/bookest-bidi.def b/Master/texmf-dist/tex/xelatex/bidi/bookest-bidi.def deleted file mode 100644 index 9969102163e..00000000000 --- a/Master/texmf-dist/tex/xelatex/bidi/bookest-bidi.def +++ /dev/null @@ -1,90 +0,0 @@ -%% -%% This is file `bookest-bidi.def', - -%% -%% __________________________________ -%% Copyright © 2009-2010 Vafa Khalighi -%% -%% License information appended. -%% -%% -\ProvidesFile{bookest-bidi.def}[2010/03/01 v0.2 adaptations for bookest class] -\AtBeginDocument{ -\def\@makechapterhead#1{% - \vspace*{20\p@} - {\parindent \z@ \if@RTL\raggedleft\else\raggedright\fi \normalfont - \ifnum \c@secnumdepth >\m@ne - \if@mainmatter - {\colorA\huge\scshape \@chapapp\space \thechapter} - \par\nobreak - \vskip 10\p@ - \fi - \fi - \interlinepenalty\@M - {\colorB\hrule} - \vskip 15\p@ - \begin{flushleft} - {\colorA\Huge \bfseries #1}\par\nobreak - \end{flushleft} - \vskip 5\p@ - {\colorB\hrule} - \vskip 30\p@ - }} -\def\@makeschapterhead#1{% - \vspace*{20\p@} - {\parindent \z@ \raggedright \normalfont - {\colorB\hrule} - \vskip 15\p@ - \begin{center} - {\colorA\Huge \bfseries #1}\par\nobreak - \end{center} - \vskip 5\p@ - {\colorB\hrule} - \vskip 30\p@ - }} -\renewcommand{\setevenhead}[1]{\def\@evenhead{#1}} -\renewcommand{\setoddhead}[1]{\def\@oddhead{#1}} -\renewcommand{\setevenfoot}[1]{\def\@evenfoot{#1}} -\renewcommand{\setoddfoot}[1]{\def\@oddfoot{#1}} -\renewcommand{\oddheadtext}{{\colorA{\slshape\rightmark}\hfill\thepage}} -\renewcommand{\setoddheadtext}[1]{\renewcommand{\oddheadtext}{#1}} -\renewcommand{\evenheadtext}{\oddheadtext} -\renewcommand{\setevenheadtext}[1]{\renewcommand{\evenheadtext}{#1}} -\renewcommand{\evenfoottext}{} -\renewcommand{\setevenfoottext}[1]{\renewcommand{\evenfoottext}{#1}} -\renewcommand{\oddfoottext}{} -\renewcommand{\setoddfoottext}[1]{\renewcommand{\oddfoottext}{#1}} -\renewcommand{\setleftmark}[1]{\renewcommand{\leftmark}{#1}} -\renewcommand{\setrightmark}[1]{\renewcommand{\rightmark}{#1}} -\renewcommand{\makeheadrule}{{\colorB\hrule\@width\textwidth \@height 0.4pt \vskip-0.4pt}} -\renewcommand{\makefootrule}{\makeheadrule} -\if@twoside - \setevenheadtext{{\colorA\thepage\hfill\slshape\leftmark}} -\fi -\setevenhead{\vbox{\evenheadtext \vskip 5\p@ \makeheadrule}} -\setoddhead{\vbox{\oddheadtext \vskip 5\p@ \makeheadrule}} -\let\UCase\MakeUppercase -\renewcommand{\MakeUppercase}{} -\def\ps@plain{% - \def\@oddfoot{{\hfil\colorA\thepage\hfil}} - \def\@evenfoot{{\hfil\colorA\thepage\hfil}} - \let\@oddhead\@empty - \let\@evenhead\@empty -} -} -\NoHyper -%% -%% Copyright © 2009-2010 by Vafa Khalighi -%% -%% Distributable 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 "maintained" (as per LPPL maintenance status) -%% by Vafa Khalighi. -%% -%% -%% -%% -%% -%% End of file `bookest-bidi.def'. diff --git a/Master/texmf-dist/tex/xelatex/bidi/bookest-xetex-bidi.def b/Master/texmf-dist/tex/xelatex/bidi/bookest-xetex-bidi.def new file mode 100644 index 00000000000..382d639cf0f --- /dev/null +++ b/Master/texmf-dist/tex/xelatex/bidi/bookest-xetex-bidi.def @@ -0,0 +1,58 @@ +%% +%% This is file `bookest-xetex-bidi.def', + +%% +%% __________________________________ +%% Copyright © 2009-2010 Vafa Khalighi +%% +%% License information appended. +%% +%% +\ProvidesFile{bookest-xetex-bidi.def}[2010/07/25 v0.4 bidi adaptations for bookest class for XeTeX engine] +\def\@makechapterhead#1{% + \vspace*{20\p@} + {\parindent \z@ \if@RTL\raggedleft\else\raggedright\fi \normalfont + \ifnum \c@secnumdepth >\m@ne + \if@mainmatter + {\colorA\huge\scshape \@chapapp\space \thechapter} + \par\nobreak + \vskip 10\p@ + \fi + \fi + \interlinepenalty\@M + {\colorB\hrule} + \vskip 15\p@ + \if@RTL\begin{flushleft}\else\begin{flushright}\fi + {\colorA\Huge \bfseries #1}\par\nobreak + \if@RTL\end{flushleft}\else\end{flushright}\fi + \vskip 5\p@ + {\colorB\hrule} + \vskip 30\p@ + }} +\def\@makeschapterhead#1{% + \vspace*{20\p@} + {\parindent \z@ \raggedright \normalfont + {\colorB\hrule} + \vskip 15\p@ + \begin{center} + {\colorA\Huge \bfseries #1}\par\nobreak + \end{center} + \vskip 5\p@ + {\colorB\hrule} + \vskip 30\p@ + }} +%% +%% Copyright © 2009-2010 by Vafa Khalighi +%% +%% Distributable 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 "maintained" (as per LPPL maintenance status) +%% by Vafa Khalighi. +%% +%% +%% +%% +%% +%% End of file `bookest-xetex-bidi.def'. diff --git a/Master/texmf-dist/tex/xelatex/bidi/breqn-bidi.def b/Master/texmf-dist/tex/xelatex/bidi/breqn-bidi.def deleted file mode 100644 index d5fd237e0c5..00000000000 --- a/Master/texmf-dist/tex/xelatex/bidi/breqn-bidi.def +++ /dev/null @@ -1,80 +0,0 @@ -%% -%% This is file `breqn-bidi.def', - -%% -%% __________________________________ -%% Copyright © 2009-2010 Vafa Khalighi -%% -%% License information appended. -%% -%% -\ProvidesFile{breqn-bidi.def}[2010/03/01 v0.1 adaptations for breqn package] -\def\@dmath[#1]{\if@RTL\@RTLfalse\fi% - \everydisplay\expandafter{\the\everydisplay \display@setup}% - \if@noskipsec \leavevmode \fi - \if@inlabel \leavevmode \global\@inlabelfalse \fi - \if\eq@group\else\eq@prelim\fi - \setkeys{breqn}{#1}% - \the\eqstyle - \eq@setnumber - \begingroup - \eq@setup@a - \eq@startup -} -\def\@dgroup[#1]{\if@RTL\@RTLfalse\fi% - \let\eq@group\@True \global\let\eq@GRP@first@dmath\@True - \global\GRP@queue\@emptytoks \global\setbox\GRP@box\box\voidb@x - \global\let\GRP@label\@empty - \global\grp@wdL\z@\global\grp@wdR\z@\global\grp@wdT\z@ - \global\grp@linewidth\z@\global\grp@wdNum\z@ - \global\let\grp@eqs@numbered\@False - \global\let\grp@aligned\@True - \global\let\grp@shiftnumber\@False - \eq@prelim - \setkeys{breqn}{#1}% - \if\grp@hasNumber \grp@setnumber \fi -} -\def\@dseries[#1]{\if@RTL\@RTLfalse\fi% - \let\display@setup\dseries@display@setup - % Question: should this be the default for dseries??? - \global\eq@wdCond\z@ - \@dmath[layout={M},#1]% - \mathsurround\z@\@@math \penalty\@Mi - \let\endmath\ends@math - \def\premath{% - \ifdim\lastskip<.3em \unskip - \else\ifnum\lastpenalty<\@M \dquad\fi\fi -}% - \def\postmath{\unpenalty\eq@addpunct \penalty\intermath@penalty \dquad \@ignoretrue}% -\ignorespaces -} -\def\eqnumform#1{\if@Latin\else\beginR\@RTLtrue\fi(#1\@@italiccorr)\if@Latin\else\endR\fi} -\renewenvironment{dsuspend}{% - \global\setbox\EQ@box\vbox\bgroup\if@Latin\else\@RTLtrue\fi \@parboxrestore - \parshape 1 \displayindent \displaywidth\relax - \hsize=\columnwidth \noindent\ignorespaces -}{% - \par\egroup - \global\setbox\GRP@box\vbox{% - \hbox{\copy\EQ@box\vtop{\unvbox\EQ@box}}% - \unvbox\GRP@box - }% - \global\GRP@queue\@xp{\the\GRP@queue - \@elt{\let\eq@isIntertext\@True}% - }% -} -%% -%% Copyright © 2009-2010 by Vafa Khalighi -%% -%% Distributable 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 "maintained" (as per LPPL maintenance status) -%% by Vafa Khalighi. -%% -%% -%% -%% -%% -%% End of file `breqn-bidi.def'. diff --git a/Master/texmf-dist/tex/xelatex/bidi/breqn-xetex-bidi.def b/Master/texmf-dist/tex/xelatex/bidi/breqn-xetex-bidi.def new file mode 100644 index 00000000000..6854f373be3 --- /dev/null +++ b/Master/texmf-dist/tex/xelatex/bidi/breqn-xetex-bidi.def @@ -0,0 +1,80 @@ +%% +%% This is file `breqn-xetex-bidi.def', + +%% +%% __________________________________ +%% Copyright © 2009-2010 Vafa Khalighi +%% +%% License information appended. +%% +%% +\ProvidesFile{breqn-xetex-bidi.def}[2010/07/25 v0.1 bidi adaptations for breqn package for XeTeX engine] +\def\@dmath[#1]{\if@RTL\@RTLfalse\fi% + \everydisplay\expandafter{\the\everydisplay \display@setup}% + \if@noskipsec \leavevmode \fi + \if@inlabel \leavevmode \global\@inlabelfalse \fi + \if\eq@group\else\eq@prelim\fi + \setkeys{breqn}{#1}% + \the\eqstyle + \eq@setnumber + \begingroup + \eq@setup@a + \eq@startup +} +\def\@dgroup[#1]{\if@RTL\@RTLfalse\fi% + \let\eq@group\@True \global\let\eq@GRP@first@dmath\@True + \global\GRP@queue\@emptytoks \global\setbox\GRP@box\box\voidb@x + \global\let\GRP@label\@empty + \global\grp@wdL\z@\global\grp@wdR\z@\global\grp@wdT\z@ + \global\grp@linewidth\z@\global\grp@wdNum\z@ + \global\let\grp@eqs@numbered\@False + \global\let\grp@aligned\@True + \global\let\grp@shiftnumber\@False + \eq@prelim + \setkeys{breqn}{#1}% + \if\grp@hasNumber \grp@setnumber \fi +} +\def\@dseries[#1]{\if@RTL\@RTLfalse\fi% + \let\display@setup\dseries@display@setup + % Question: should this be the default for dseries??? + \global\eq@wdCond\z@ + \@dmath[layout={M},#1]% + \mathsurround\z@\@@math \penalty\@Mi + \let\endmath\ends@math + \def\premath{% + \ifdim\lastskip<.3em \unskip + \else\ifnum\lastpenalty<\@M \dquad\fi\fi +}% + \def\postmath{\unpenalty\eq@addpunct \penalty\intermath@penalty \dquad \@ignoretrue}% +\ignorespaces +} +\def\eqnumform#1{\if@Latin\else\beginR\@RTLtrue\fi(#1\@@italiccorr)\if@Latin\else\endR\fi} +\renewenvironment{dsuspend}{% + \global\setbox\EQ@box\vbox\bgroup\if@Latin\else\@RTLtrue\fi \@parboxrestore + \parshape 1 \displayindent \displaywidth\relax + \hsize=\columnwidth \noindent\ignorespaces +}{% + \par\egroup + \global\setbox\GRP@box\vbox{% + \hbox{\copy\EQ@box\vtop{\unvbox\EQ@box}}% + \unvbox\GRP@box + }% + \global\GRP@queue\@xp{\the\GRP@queue + \@elt{\let\eq@isIntertext\@True}% + }% +} +%% +%% Copyright © 2009-2010 by Vafa Khalighi +%% +%% Distributable 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 "maintained" (as per LPPL maintenance status) +%% by Vafa Khalighi. +%% +%% +%% +%% +%% +%% End of file `breqn-xetex-bidi.def'. diff --git a/Master/texmf-dist/tex/xelatex/bidi/caption-xetex-bidi.def b/Master/texmf-dist/tex/xelatex/bidi/caption-xetex-bidi.def new file mode 100644 index 00000000000..4c9c7ba410a --- /dev/null +++ b/Master/texmf-dist/tex/xelatex/bidi/caption-xetex-bidi.def @@ -0,0 +1,27 @@ +%% +%% This is file `caption-xetex-bidi.def', + +%% +%% __________________________________ +%% Copyright © 2009-2010 Vafa Khalighi +%% +%% License information appended. +%% +%% +\ProvidesFile{caption-xetex-bidi.def}[2010/07/25 v0.1 bidi adaptations for caption package for XeTeX engine] +\let\@makecaption\caption@makecaption +%% +%% Copyright © 2009-2010 by Vafa Khalighi +%% +%% Distributable 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 "maintained" (as per LPPL maintenance status) +%% by Vafa Khalighi. +%% +%% +%% +%% +%% +%% End of file `caption-xetex-bidi.def'. diff --git a/Master/texmf-dist/tex/xelatex/bidi/color-bidi.def b/Master/texmf-dist/tex/xelatex/bidi/color-bidi.def deleted file mode 100644 index bf1612373c0..00000000000 --- a/Master/texmf-dist/tex/xelatex/bidi/color-bidi.def +++ /dev/null @@ -1,66 +0,0 @@ -%% -%% This is file `color-bidi.def', - -%% -%% __________________________________ -%% Copyright © 2009-2010 Vafa Khalighi -%% -%% License information appended. -%% -%% -\ProvidesFile{color-bidi.def}[2010/03/01 v0.1 adaptations for color package] -\long\def\color@b@x#1#2#3{% - \leavevmode\if@RTL\beginL\fi - \setbox\z@\hbox{\kern\fboxsep{\set@color\if@RTL\beginR\fi#3\if@RTL\endR\fi}\kern\fboxsep}% - \dimen@\ht\z@\advance\dimen@\fboxsep\ht\z@\dimen@ - \dimen@\dp\z@\advance\dimen@\fboxsep\dp\z@\dimen@ - {#1{#2\color@block{\wd\z@}{\ht\z@}{\dp\z@}% - \box\z@}}\if@RTL\endL\fi} -\DeclareRobustCommand\color{% - \ifhmode\if@RTL\beginL\aftergroup\endR\fi\fi\@ifnextchar[\@undeclaredcolor\@declaredcolor} -\def\@declaredcolor#1{% - \@ifundefined{\string\color @#1}% - {\c@lor@error{`#1'}}% - {\expandafter\let\expandafter\current@color - \csname\string\color @#1\endcsname - \set@color}% - \ignorespaces\ifhmode\if@RTL\beginR\aftergroup\endL\fi\fi} -\def\@undeclaredcolor[#1]#2{% - \@ifundefined{color@#1}% - {\c@lor@error{model `#1'}}% - {\csname color@#1\endcsname\current@color{#2}% - \set@color}% - \ignorespaces\ifhmode\if@RTL\beginR\aftergroup\endL\fi\fi} -\DeclareRobustCommand\bidicolor{% - \@ifnextchar[\@bidiundeclaredcolor\@bidideclaredcolor} -\def\@bidiundeclaredcolor[#1]#2{% - \@ifundefined{color@#1}% - {\c@lor@error{model `#1'}}% - {\csname color@#1\endcsname\current@color{#2}% - \set@color}% - \ignorespaces} -\def\@bidideclaredcolor#1{% - \@ifundefined{\string\color @#1}% - {\c@lor@error{`#1'}}% - {\expandafter\let\expandafter\current@color - \csname\string\color @#1\endcsname - \set@color}% - \ignorespaces} -\def\color@box#1#2{\color@b@x\relax{\bidicolor#1{#2}}} -\def\color@fbox#1#2#3{% - \color@b@x{\fboxsep\z@\bidicolor#1{#2}\fbox}{\bidicolor#1{#3}}} -%% -%% Copyright © 2009-2010 by Vafa Khalighi -%% -%% Distributable 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 "maintained" (as per LPPL maintenance status) -%% by Vafa Khalighi. -%% -%% -%% -%% -%% -%% End of file `color-bidi.def'. diff --git a/Master/texmf-dist/tex/xelatex/bidi/color-xetex-bidi.def b/Master/texmf-dist/tex/xelatex/bidi/color-xetex-bidi.def new file mode 100644 index 00000000000..0f108ac0f87 --- /dev/null +++ b/Master/texmf-dist/tex/xelatex/bidi/color-xetex-bidi.def @@ -0,0 +1,66 @@ +%% +%% This is file `color-xetex-bidi.def', + +%% +%% __________________________________ +%% Copyright © 2009-2010 Vafa Khalighi +%% +%% License information appended. +%% +%% +\ProvidesFile{color-xetex-bidi.def}[2010/07/25 v0.1 bidi adaptations for color package for XeTeX engine] +\long\def\color@b@x#1#2#3{% + \leavevmode\if@RTL\beginL\fi + \setbox\z@\hbox{\kern\fboxsep{\set@color\if@RTL\beginR\fi#3\if@RTL\endR\fi}\kern\fboxsep}% + \dimen@\ht\z@\advance\dimen@\fboxsep\ht\z@\dimen@ + \dimen@\dp\z@\advance\dimen@\fboxsep\dp\z@\dimen@ + {#1{#2\color@block{\wd\z@}{\ht\z@}{\dp\z@}% + \box\z@}}\if@RTL\endL\fi} +\DeclareRobustCommand\color{% + \ifhmode\if@RTL\beginL\aftergroup\endR\fi\fi\@ifnextchar[\@undeclaredcolor\@declaredcolor} +\def\@declaredcolor#1{% + \@ifundefined{\string\color @#1}% + {\c@lor@error{`#1'}}% + {\expandafter\let\expandafter\current@color + \csname\string\color @#1\endcsname + \set@color}% + \ignorespaces\ifhmode\if@RTL\beginR\aftergroup\endL\fi\fi} +\def\@undeclaredcolor[#1]#2{% + \@ifundefined{color@#1}% + {\c@lor@error{model `#1'}}% + {\csname color@#1\endcsname\current@color{#2}% + \set@color}% + \ignorespaces\ifhmode\if@RTL\beginR\aftergroup\endL\fi\fi} +\DeclareRobustCommand\bidicolor{% + \@ifnextchar[\@bidiundeclaredcolor\@bidideclaredcolor} +\def\@bidiundeclaredcolor[#1]#2{% + \@ifundefined{color@#1}% + {\c@lor@error{model `#1'}}% + {\csname color@#1\endcsname\current@color{#2}% + \set@color}% + \ignorespaces} +\def\@bidideclaredcolor#1{% + \@ifundefined{\string\color @#1}% + {\c@lor@error{`#1'}}% + {\expandafter\let\expandafter\current@color + \csname\string\color @#1\endcsname + \set@color}% + \ignorespaces} +\def\color@box#1#2{\color@b@x\relax{\bidicolor#1{#2}}} +\def\color@fbox#1#2#3{% + \color@b@x{\fboxsep\z@\bidicolor#1{#2}\fbox}{\bidicolor#1{#3}}} +%% +%% Copyright © 2009-2010 by Vafa Khalighi +%% +%% Distributable 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 "maintained" (as per LPPL maintenance status) +%% by Vafa Khalighi. +%% +%% +%% +%% +%% +%% End of file `color-xetex-bidi.def'. diff --git a/Master/texmf-dist/tex/xelatex/bidi/colortbl-bidi.def b/Master/texmf-dist/tex/xelatex/bidi/colortbl-bidi.def deleted file mode 100644 index 1c60f587434..00000000000 --- a/Master/texmf-dist/tex/xelatex/bidi/colortbl-bidi.def +++ /dev/null @@ -1,63 +0,0 @@ -%% -%% This is file `colortbl-bidi.def', - -%% -%% __________________________________ -%% Copyright © 2009-2010 Vafa Khalighi -%% -%% License information appended. -%% -%% -\ProvidesFile{colortbl-bidi.def}[2010/03/01 v0.1 adaptations for colortbl package] -\def\CT@setup{% - \@tempdimb\col@sep - \@tempdimc\col@sep - \def\CT@color{% - \global\let\CT@do@color\CT@@do@color - \bidicolor}} -\def\@classz{\@classx - \@tempcnta \count@ - \prepnext@tok -\expandafter\CT@extract\the\toks\@tempcnta\columncolor!\@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} -%% -%% Copyright © 2009-2010 by Vafa Khalighi -%% -%% Distributable 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 "maintained" (as per LPPL maintenance status) -%% by Vafa Khalighi. -%% -%% -%% -%% -%% -%% End of file `colortbl-bidi.def'. diff --git a/Master/texmf-dist/tex/xelatex/bidi/colortbl-xetex-bidi.def b/Master/texmf-dist/tex/xelatex/bidi/colortbl-xetex-bidi.def new file mode 100644 index 00000000000..0b41e0c1520 --- /dev/null +++ b/Master/texmf-dist/tex/xelatex/bidi/colortbl-xetex-bidi.def @@ -0,0 +1,63 @@ +%% +%% This is file `colortbl-xetex-bidi.def', + +%% +%% __________________________________ +%% Copyright © 2009-2010 Vafa Khalighi +%% +%% License information appended. +%% +%% +\ProvidesFile{colortbl-xetex-bidi.def}[2010/07/25 v0.1 bidi adaptations for colortbl package for XeTeX engine] +\def\CT@setup{% + \@tempdimb\col@sep + \@tempdimc\col@sep + \def\CT@color{% + \global\let\CT@do@color\CT@@do@color + \bidicolor}} +\def\@classz{\@classx + \@tempcnta \count@ + \prepnext@tok +\expandafter\CT@extract\the\toks\@tempcnta\columncolor!\@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} +%% +%% Copyright © 2009-2010 by Vafa Khalighi +%% +%% Distributable 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 "maintained" (as per LPPL maintenance status) +%% by Vafa Khalighi. +%% +%% +%% +%% +%% +%% End of file `colortbl-xetex-bidi.def'. diff --git a/Master/texmf-dist/tex/xelatex/bidi/cvthemebidicasual.sty b/Master/texmf-dist/tex/xelatex/bidi/cvthemebidicasual.sty new file mode 100644 index 00000000000..7cf3de727d5 --- /dev/null +++ b/Master/texmf-dist/tex/xelatex/bidi/cvthemebidicasual.sty @@ -0,0 +1,124 @@ +%% +%% This is file `cvthemebidicasual.sty', + +%% +%% __________________________________ +%% Copyright © 2009-2010 Vafa Khalighi +%% +%% License information appended. +%% +%% +\NeedsTeXFormat{LaTeX2e} +\ProvidesPackage{cvthemebidicasual} +\DeclareOption{blue}{} +\newif\if@colourorange\@colourorangefalse +\DeclareOption{orange}{\@colourorangetrue} +\newif\if@colourgreen\@colourgreenfalse +\DeclareOption{green}{\@colourgreentrue} +\newif\if@colourred\@colourredfalse +\DeclareOption{red}{\@colourredtrue} +\newif\if@colourgrey\@colourgreyfalse +\DeclareOption{grey}{\@colourgreytrue} +\DeclareOption*{ + \PackageWarning{cvthemebidicasual}{Unknown option ‘\CurrentOption’}} +\ExecuteOptions{colour} +\ProcessOptions\relax +\renewcommand*{\listitemsymbol}{\textbullet} +\definecolor{firstnamecolor}{rgb}{0.65,0.65,0.65} +\familynamecolour{808080} +\firstnamecolour{A9A9A9} +\quotecolour{696969} +\addresscolour{696969} +\definecolor{sectionrectanglecolor}{rgb}{0.25,0.50,0.75} +\sectiontitlecolour{1E90FF} +\subsectioncolour{4682B4} +\definecolor{rulecolour}{gray}{0.6} +\definecolor{footersymbolcolour}{rgb}{0.25,0.50,0.75} +\definecolor{footersymbolcolor}{rgb}{0.25,0.50,0.75} +\if@colourorange + \definecolor{sectionrectanglecolor}{rgb}{1.00,0.65,0.20} + \definecolor{sectionrectanglecolor}{rgb}{1.00,0.65,0.20} + \sectiontitlecolour{FF8C00} + \subsectioncolour{FF8C00} + \definecolor{footersymbolcolour}{rgb}{0.95,0.55,0.15} + \definecolor{footersymbolcolor}{rgb}{0.95,0.55,0.15}\fi +\if@colourgreen + \definecolor{sectionrectanglecolor}{rgb}{0.55,0.85,0.35} + \definecolor{sectionrectanglecolour}{rgb}{0.55,0.85,0.35} + \sectiontitlecolour{008000} + \subsectioncolour{008000} + \definecolor{footersymbolcolour}{rgb}{0.30,0.65,0.15} + \definecolor{footersymbolcolor}{rgb}{0.30,0.65,0.15}\fi +\if@colourred + \definecolor{sectionrectanglecolor}{rgb}{1.00,0.30,0.30} + \definecolor{sectionrectanglecolour}{rgb}{1.00,0.30,0.30} + \sectiontitlecolour{FF0000} + \subsectioncolour{FF0000} + \definecolor{footersymbolcolour}{rgb}{0.95,0.20,0.20} + \definecolor{footersymbolcolor}{rgb}{0.95,0.20,0.20}\fi +\if@colourgrey + \definecolor{sectionrectanglecolor}{rgb}{0.75,0.75,0.75} + \definecolor{sectionrectanglecolour}{rgb}{0.75,0.75,0.75} + \sectiontitlecolour{808080} + \subsectioncolour{808080} + \definecolor{footersymbolcolour}{rgb}{0.35,0.35,0.35} + \definecolor{footersymbolcolor}{rgb}{0.35,0.35,0.35}\fi +\renewcommand*{\ttdefault}{pcr} +\renewcommand*{\firstnamefont}{\fontsize{38}{40}\mdseries\upshape} +\renewcommand*{\familynamefont}{\firstnamefont} +\renewcommand*{\addressfont}{\normalsize\mdseries\slshape} +\renewcommand*{\quotefont}{\large\slshape} +\renewcommand*{\sectionfont}{\Large\mdseries\upshape} +\renewcommand*{\subsectionfont}{\large\mdseries\upshape} +\renewcommand*{\maketitle}{% + {\beginL% + \ifthenelse{\isundefined{\@photo}}% + {}% + {{\color{firstnamecolor}\framebox{\includegraphics[width=\@photowidth]{\@photo}}}}% + \hfill% + \raggedleft{\if@RTL\beginR\fi\firstnamestyle{\@firstname}~\familynamestyle{\@familyname}\if@RTL\endR\fi}\endL\\[-.35em]}% + {\color{firstnamecolor}\rule{\textwidth}{.25ex}\\[2.5em]}% + \ifthenelse{\isundefined{\@quote}}% + {}% + {\centering{\begin{minipage}{\quotewidth}\centering\quotestyle{\@quote}\end{minipage}}\\[2.5em]}% + }% +\newif\if@firstfooterelement\@firstfooterelementtrue +\providecommand*{\footersymbol}{} +\renewcommand*{\footersymbol}{% + \if@firstfooterelement% + \else% + { ~~\color{footersymbolcolor}\textbullet~~~}\fi} +\providecommand*{\makefooter}{} +\renewcommand*{\makefooter}{% + \fancypagestyle{plain}{% + \fancyfoot[c]{% + \parbox{0.8\textwidth}{% + \centering% + \addressfont\@addresscolour% + \ifthenelse{\isundefined{\@address}}{}{% + \if@RTLmain\beginR\fi\addresssymbol~\@address\if@RTLmain\endR\fi\\% + \@firstfooterelementfalse}% + \if@RTLmain\beginR\fi\ifthenelse{\isundefined{\@mobile}}{}{\if@RTLmain\beginR\fi\mobilesymbol~\@mobile\if@RTLmain\endR\fi\@firstfooterelementfalse}% + \ifthenelse{\isundefined{\@phone}}{}{\footersymbol\if@RTLmain\beginR\fi\phonesymbol~\@phone\if@RTLmain\endR\fi\@firstfooterelementfalse}% + \ifthenelse{\isundefined{\@fax}}{}{\footersymbol\if@RTLmain\beginR\fi\faxsymbol~\@fax\if@RTLmain\endR\fi\@firstfooterelementfalse}% + \ifthenelse{\isundefined{\@email}}{}{\footersymbol\if@RTLmain\beginR\fi\emailsymbol~\emaillink{\@email}\if@RTLmain\endR\fi\@firstfooterelementfalse}% + \ifthenelse{\isundefined{\@extrainfo}}{}{\if@RTLmain\beginR\fi\footersymbol\@extrainfo\if@RTLmain\endR\fi\@firstfooterelementfalse}\if@RTLmain\endR\fi}}% + }% + \pagestyle{plain}} +\AtBeginDocument{\makefooter} + +%% +%% Copyright © 2009-2010 by Vafa Khalighi +%% +%% Distributable 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 "maintained" (as per LPPL maintenance status) +%% by Vafa Khalighi. +%% +%% +%% +%% +%% +%% End of file `cvthemebidicasual.sty'. diff --git a/Master/texmf-dist/tex/xelatex/bidi/cvthemebidiclassic.sty b/Master/texmf-dist/tex/xelatex/bidi/cvthemebidiclassic.sty new file mode 100644 index 00000000000..d2ff4eed4d5 --- /dev/null +++ b/Master/texmf-dist/tex/xelatex/bidi/cvthemebidiclassic.sty @@ -0,0 +1,131 @@ +%% +%% This is file `cvthemebidiclassic.sty', + +%% +%% __________________________________ +%% Copyright © 2009-2010 Vafa Khalighi +%% +%% License information appended. +%% +%% +\NeedsTeXFormat{LaTeX2e} +\ProvidesPackage{cvthemebidiclassic} +\DeclareOption{blue}{} +\newif\if@colourorange\@colourorangefalse +\DeclareOption{orange}{\@colourorangetrue} +\newif\if@colourgreen\@colourgreenfalse +\DeclareOption{green}{\@colourgreentrue} +\newif\if@colourred\@colourredfalse +\DeclareOption{red}{\@colourredtrue} +\newif\if@colourgrey\@colourgreyfalse +\DeclareOption{grey}{\@colourgreytrue} +\DeclareOption*{ + \PackageWarning{cvthemebidiclassic}{Unknown option ‘\CurrentOption’}} +\ExecuteOptions{colour} +\ProcessOptions\relax +\renewcommand*{\listitemsymbol}{\textbullet} +\firstnamecolour{} +\familynamecolour{} +\titlecolour{808080} +\quotecolour{696969} +\addresscolour{696969} +\definecolor{sectionrectanglecolour}{rgb}{0.25,0.50,0.75} +\definecolor{sectionrectanglecolor}{rgb}{0.25,0.5,0.75} +\sectiontitlecolour{1E90FF} +\subsectioncolour{4682B4} +\if@colourorange + \addresscolour{FF8C00} + \definecolor{sectionrectanglecolour}{rgb}{1.00,0.65,0.20} + \definecolor{sectionrectanglecolor}{rgb}{1,0.65,0.20} + \sectiontitlecolour{FF8C00} + \subsectioncolour{FF8C00}\fi +\if@colourgreen + \addresscolour{008000} + \definecolor{sectionrectanglecolour}{rgb}{0.55,0.85,0.35} + \definecolor{sectionrectanglecolor}{rgb}{0.55,0.85,0.35} + \sectiontitlecolour{008000} + \subsectioncolour{008000}\fi +\if@colourred + \addresscolour{FF0000} + \definecolor{sectionrectanglecolour}{rgb}{1.00,0.30,0.30} + \definecolor{sectionrectanglecolor}{rgb}{1.00,0.30,0.30} + \sectiontitlecolour{FF0000} + \subsectioncolour{FF0000}\fi +\if@colourgrey + \addresscolour{808080} + \definecolor{sectionrectanglecolour}{rgb}{0.75,0.75,0.75} + \definecolor{sectionrectanglecolor}{rgb}{0.75,0.75,0.75} + \sectiontitlecolour{808080} + \subsectioncolour{808080}\fi +\renewcommand*{\ttdefault}{pcr} +\renewcommand*{\firstnamefont}{\fontsize{34}{36}\mdseries\upshape} +\renewcommand*{\titlefont}{\LARGE\mdseries\slshape} +\renewcommand*{\addressfont}{\normalsize\mdseries\slshape} +\renewcommand*{\familynamefont}{\firstnamefont} +\renewcommand*{\quotefont}{\large\slshape} +\renewcommand*{\sectionfont}{\Large\mdseries\upshape} +\renewcommand*{\subsectionfont}{\large\mdseries\upshape} +\newlength{\maketitlenamemaxwidth} +\setlength{\maketitlenamemaxwidth}{.525\textwidth} +\newlength{\maketitlenamefullwidth} +\settowidth{\maketitlenamefullwidth}{\firstnamestyle{\@firstname~}\familynamestyle{\@familyname}} +\newlength{\maketitlenamewidth} +\ifnum\maketitlenamemaxwidth<\maketitlenamefullwidth\setlength{\maketitlenamewidth}{\maketitlenamemaxwidth}\else\setlength{\maketitlenamewidth}{\maketitlenamefullwidth}\fi +\newlength{\maketitlepicturewidth} +\setlength{\maketitlepicturewidth}{\@photowidth} +\newlength{\maketitledetailswidth} +\renewcommand*{\recomputethemelengths}{% + \setlength{\maketitledetailswidth}{\textwidth}% + \addtolength{\maketitledetailswidth}{-\maketitlenamewidth}% + \addtolength{\maketitledetailswidth}{-\separatorcolumnwidth}% + \addtolength{\maketitledetailswidth}{-\maketitlepicturewidth}} +\recomputethemelengths +\newif\if@firstdetailselement\@firstdetailselementtrue +\newcommand*{\maketitledetailsnewline}{ + \if@firstdetailselement% + \@firstdetailselementfalse% + \else% + \\[.2em]\fi} +\renewcommand*{\maketitle}{% + % name and title + \begin{minipage}[b]{\maketitlenamewidth}% + \firstnamestyle{\@firstname~}\familynamestyle{\@familyname}% + \ifthenelse{\equal{\@title}{}}{}{\\[1.25em]\titlestyle{\@title}}% + \end{minipage}% + % optional data + \begin{minipage}[b]{\maketitledetailswidth}% + \raggedleft\addressfont\@addresscolour% + \ifthenelse{\isundefined{\@address}}{}{% + \maketitledetailsnewline% + \addresssymbol~\\\@address}% + \ifthenelse{\isundefined{\@mobile}}{}{\maketitledetailsnewline\mobilesymbol~\@mobile}% + \ifthenelse{\isundefined{\@phone}}{}{\maketitledetailsnewline\phonesymbol~\@phone}% + \ifthenelse{\isundefined{\@fax}}{}{\maketitledetailsnewline\faxsymbol~\@fax}% + \ifthenelse{\isundefined{\@email}}{}{\maketitledetailsnewline\emailsymbol~\emaillink{\@email}}% + \ifthenelse{\isundefined{\@extrainfo}}{}{\maketitledetailsnewline\@extrainfo}% + \end{minipage}% + % optional photo + \ifthenelse{\isundefined{\@photo}}% + {}% + {\hspace*{\separatorcolumnwidth}\color{firstnamecolor}\framebox{\includegraphics[width=\maketitlepicturewidth]{\@photo}}}\\[3em]% + % optional quote + \ifthenelse{\isundefined{\@quote}}% + {}% + {\centering{\begin{minipage}{\quotewidth}\centering\quotestyle{\@quote}\end{minipage}}\\[2.5em]}% + } + +%% +%% Copyright © 2009-2010 by Vafa Khalighi +%% +%% Distributable 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 "maintained" (as per LPPL maintenance status) +%% by Vafa Khalighi. +%% +%% +%% +%% +%% +%% End of file `cvthemebidiclassic.sty'. diff --git a/Master/texmf-dist/tex/xelatex/bidi/draftwatermark-bidi.def b/Master/texmf-dist/tex/xelatex/bidi/draftwatermark-bidi.def deleted file mode 100644 index 51ec5a6fb31..00000000000 --- a/Master/texmf-dist/tex/xelatex/bidi/draftwatermark-bidi.def +++ /dev/null @@ -1,28 +0,0 @@ -%% -%% This is file `draftwatermark-bidi.def', - -%% -%% __________________________________ -%% Copyright © 2009-2010 Vafa Khalighi -%% -%% License information appended. -%% -%% -\ProvidesFile{draftwatermark-bidi.def}[2010/03/01 v0.2 adaptations for draftwatermark package] -\renewcommand\SetWatermarkText[1]{% - \def\sc@wm@text{\if@RTLmain\beginR\fi#1\if@RTLmain\endR\fi}} -%% -%% Copyright © 2009-2010 by Vafa Khalighi -%% -%% Distributable 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 "maintained" (as per LPPL maintenance status) -%% by Vafa Khalighi. -%% -%% -%% -%% -%% -%% End of file `draftwatermark-bidi.def'. diff --git a/Master/texmf-dist/tex/xelatex/bidi/draftwatermark-xetex-bidi.def b/Master/texmf-dist/tex/xelatex/bidi/draftwatermark-xetex-bidi.def new file mode 100644 index 00000000000..4cd997a2ec4 --- /dev/null +++ b/Master/texmf-dist/tex/xelatex/bidi/draftwatermark-xetex-bidi.def @@ -0,0 +1,28 @@ +%% +%% This is file `draftwatermark-xetex-bidi.def', + +%% +%% __________________________________ +%% Copyright © 2009-2010 Vafa Khalighi +%% +%% License information appended. +%% +%% +\ProvidesFile{draftwatermark-xetex-bidi.def}[2010/07/25 v0.2 bidi adaptations for draftwatermark package for XeTeX engine] +\renewcommand\SetWatermarkText[1]{% + \def\sc@wm@text{\if@RTLmain\beginR\fi#1\if@RTLmain\endR\fi}} +%% +%% Copyright © 2009-2010 by Vafa Khalighi +%% +%% Distributable 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 "maintained" (as per LPPL maintenance status) +%% by Vafa Khalighi. +%% +%% +%% +%% +%% +%% End of file `draftwatermark-xetex-bidi.def'. diff --git a/Master/texmf-dist/tex/xelatex/bidi/extbook-bidi.def b/Master/texmf-dist/tex/xelatex/bidi/extbook-bidi.def deleted file mode 100644 index 9f25e652eb1..00000000000 --- a/Master/texmf-dist/tex/xelatex/bidi/extbook-bidi.def +++ /dev/null @@ -1,239 +0,0 @@ -%% -%% This is file `extbook-bidi.def', - -%% -%% __________________________________ -%% Copyright © 2009-2010 Vafa Khalighi -%% -%% License information appended. -%% -%% -\ProvidesFile{extbook-bidi.def}[2010/03/01 v0.1 adaptations for extbook class] - \if@titlepage - \renewcommand\maketitle{\begin{titlepage}% - \let\footnotesize\small - \let\footnoterule\relax - \let \footnote \thanks - \let \LTRfootnote \LTRthanks - \let \RTLfootnote \RTLthanks - \null\vfil - \vskip 60\p@ - \begin{center}% - {\LARGE \@title \par}% - \vskip 3em% - {\large - \lineskip .75em% - \begin{tabular}[t]{c}% - \@author - \end{tabular}\par}% - \vskip 1.5em% - {\large \@date \par}% % Set date in \large size. - \end{center}\par - \@thanks - \vfil\null - \end{titlepage}% - \setcounter{footnote}{0}% - \global\let\thanks\relax - \global\let\LTRthanks\relax - \global\let\RTLthanks\relax - \global\let\maketitle\relax - \global\let\@thanks\@empty - \global\let\@author\@empty - \global\let\@date\@empty - \global\let\@title\@empty - \global\let\title\relax - \global\let\author\relax - \global\let\date\relax - \global\let\and\relax -} -\else -\renewcommand\maketitle{\par - \begingroup - \renewcommand\thefootnote{\@fnsymbol\c@footnote}% - \def\@makefnmark{\rlap{\@textsuperscript{\normalfont\@thefnmark}}}% - \long\def\@makefntext##1{\parindent 1em\noindent - \hb@xt@1.8em{% - \hss\@textsuperscript{\normalfont\@thefnmark}}##1}% - \if@twocolumn - \ifnum \col@number=\@ne - \@maketitle - \else - \twocolumn[\@maketitle]% - \fi - \else - \newpage - \global\@topnum\z@ % Prevents figures from going at top of page. - \@maketitle - \fi - \thispagestyle{plain}\@thanks - \endgroup - \setcounter{footnote}{0}% - \global\let\thanks\relax - \global\let\LTRthanks\relax - \global\let\RTLthanks\relax - \global\let\maketitle\relax - \global\let\@maketitle\relax - \global\let\@thanks\@empty - \global\let\@author\@empty - \global\let\@date\@empty - \global\let\@title\@empty - \global\let\title\relax - \global\let\author\relax - \global\let\date\relax - \global\let\and\relax -} -\def\@maketitle{% - \newpage - \null - \vskip 2em% - \begin{center}% - \let \footnote \thanks - \let \LTRfootnote \LTRthanks - \let \RTLfootnote \RTLthanks - {\LARGE \@title \par}% - \vskip 1.5em% - {\large - \lineskip .5em% - \begin{tabular}[t]{c}% - \@author - \end{tabular}\par}% - \vskip 1em% - {\large \@date}% - \end{center}% - \par - \vskip 1.5em} -\fi -\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\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 \thechapter {\@arabic\c@chapter} -\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} -\def\@makechapterhead#1{% - \vspace*{50\p@}% - {\parindent \z@ \if@RTL\raggedleft\else\raggedright\fi \normalfont - \ifnum \c@secnumdepth >\m@ne - \if@mainmatter - \huge\bfseries \@chapapp\space \thechapter - \par\nobreak - \vskip 20\p@ - \fi - \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@ - }} -\renewenvironment{thebibliography}[1] - {\chapter*{\bibname}% - \@mkboth{\MakeUppercase\bibname}{\MakeUppercase\bibname}% - \list{\@biblabel{\@arabic\c@enumiv}}% - {\settowidth\labelwidth{\@biblabel{#1}}% - \rightmargin\labelwidth - \advance\rightmargin\labelsep - \@openbib@code - \usecounter{enumiv}% - \let\p@enumiv\@empty - \renewcommand\theenumiv{\@arabic\c@enumiv}}% - \sloppy - \clubpenalty4000 - \@clubpenalty \clubpenalty - \widowpenalty4000% - \sfcode`\.\@m} - {\def\@noitemerr - {\@latex@warning{Empty `thebibliography' environment}}% - \endlist} -\renewcommand\backmatter{% - \if@openright - \cleardoublepage - \else - \clearpage - \fi - \@mainmatterfalse} -\if@twoside - \def\ps@headings{% - \let\@oddfoot\@empty\let\@evenfoot\@empty - \def\@evenhead{\sl\if@RTLmain\beginR\fi\rightmark\if@RTLmain\endR\fi\hfil\thepage}% - \def\@oddhead{\sl\thepage\hfil\if@RTLmain\beginR\fi\leftmark\if@RTLmain\endR\fi}% - \let\@mkboth\markboth - \def\chaptermark##1{% - \markboth {\MakeUppercase{% - \if@RTLmain\beginR\fi\@chapapp\ \thechapter.\,\,\if@RTLmain\endR\fi% - \ifnum \c@secnumdepth >\m@ne - \if@mainmatter - \if@RTLmain\beginR\fi##1\if@RTLmain\endR\fi - \fi - \fi - }}{}}% - \def\ps@plain{\ps@empty -\def\@oddfoot{\hfil\thepage\hfil}% -\let\@evenfoot\@oddfoot -} - \def\sectionmark##1{% - \markright {\MakeUppercase{% -\if@RTLmain\beginR\fi\thesection\if@RTLmain\endR\fi\, - \ifnum \c@secnumdepth >\z@ - \if@RTLmain\beginR\fi##1\if@RTLmain\endR\fi \ % - \fi - }}}} -\else - \def\ps@headings{% - \let\@oddfoot\@empty - \def\@oddhead{\sl\thepage\hfil\if@RTLmain\beginR\fi\rightmark\if@RTLmain\endR\fi}% - \let\@mkboth\markboth - \def\chaptermark##1{% - \markright {\MakeUppercase{% - \if@RTLmain\beginR\fi\@chapapp\ \thechapter. \if@RTLmain\endR\fi % - \ifnum \c@secnumdepth >\m@ne - \if@mainmatter - \if@RTLmain\beginR\fi##1\if@RTLmain\endR\fi - \fi - \fi - }}}} - -\fi -\pagestyle{headings} -\def\@idxitem{\par\hangindent -40\p@} -%% -%% Copyright © 2009-2010 by Vafa Khalighi -%% -%% Distributable 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 "maintained" (as per LPPL maintenance status) -%% by Vafa Khalighi. -%% -%% -%% -%% -%% -%% End of file `extbook-bidi.def'. diff --git a/Master/texmf-dist/tex/xelatex/bidi/extbook-xetex-bidi.def b/Master/texmf-dist/tex/xelatex/bidi/extbook-xetex-bidi.def new file mode 100644 index 00000000000..c56e0893c8c --- /dev/null +++ b/Master/texmf-dist/tex/xelatex/bidi/extbook-xetex-bidi.def @@ -0,0 +1,176 @@ +%% +%% This is file `extbook-xetex-bidi.def', + +%% +%% __________________________________ +%% Copyright © 2009-2010 Vafa Khalighi +%% +%% License information appended. +%% +%% +\ProvidesFile{extbook-xetex-bidi.def}[2010/07/25 v0.2 bidi adaptations for extbook class for XeTeX engine] + \if@titlepage + \renewcommand\maketitle{\begin{titlepage}% + \let\footnotesize\small + \let\footnoterule\relax + \let \footnote \thanks + \let \LTRfootnote \LTRthanks + \let \RTLfootnote \RTLthanks + \null\vfil + \vskip 60\p@ + \begin{center}% + {\LARGE \@title \par}% + \vskip 3em% + {\large + \lineskip .75em% + \begin{tabular}[t]{c}% + \@author + \end{tabular}\par}% + \vskip 1.5em% + {\large \@date \par}% % Set date in \large size. + \end{center}\par + \@thanks + \vfil\null + \end{titlepage}% + \setcounter{footnote}{0}% + \global\let\thanks\relax + \global\let\LTRthanks\relax + \global\let\RTLthanks\relax + \global\let\maketitle\relax + \global\let\@thanks\@empty + \global\let\@author\@empty + \global\let\@date\@empty + \global\let\@title\@empty + \global\let\title\relax + \global\let\author\relax + \global\let\date\relax + \global\let\and\relax +} +\else +\renewcommand\maketitle{\par + \begingroup + \renewcommand\thefootnote{\@fnsymbol\c@footnote}% + \def\@makefnmark{\rlap{\@textsuperscript{\normalfont\@thefnmark}}}% + \long\def\@makefntext##1{\parindent 1em\noindent + \hb@xt@1.8em{% + \hss\@textsuperscript{\normalfont\@thefnmark}}##1}% + \if@twocolumn + \ifnum \col@number=\@ne + \@maketitle + \else + \twocolumn[\@maketitle]% + \fi + \else + \newpage + \global\@topnum\z@ % Prevents figures from going at top of page. + \@maketitle + \fi + \thispagestyle{plain}\@thanks + \endgroup + \setcounter{footnote}{0}% + \global\let\thanks\relax + \global\let\LTRthanks\relax + \global\let\RTLthanks\relax + \global\let\maketitle\relax + \global\let\@maketitle\relax + \global\let\@thanks\@empty + \global\let\@author\@empty + \global\let\@date\@empty + \global\let\@title\@empty + \global\let\title\relax + \global\let\author\relax + \global\let\date\relax + \global\let\and\relax +} +\def\@maketitle{% + \newpage + \null + \vskip 2em% + \begin{center}% + \let \footnote \thanks + \let \LTRfootnote \LTRthanks + \let \RTLfootnote \RTLthanks + {\LARGE \@title \par}% + \vskip 1.5em% + {\large + \lineskip .5em% + \begin{tabular}[t]{c}% + \@author + \end{tabular}\par}% + \vskip 1em% + {\large \@date}% + \end{center}% + \par + \vskip 1.5em} +\fi +\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\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 \thechapter {\@arabic\c@chapter} +\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} +\def\@makechapterhead#1{% + \vspace*{50\p@}% + {\parindent \z@ \if@RTL\raggedleft\else\raggedright\fi \normalfont + \ifnum \c@secnumdepth >\m@ne + \if@mainmatter + \huge\bfseries \@chapapp\space \thechapter + \par\nobreak + \vskip 20\p@ + \fi + \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@ + }} +\renewcommand\backmatter{% + \if@openright + \cleardoublepage + \else + \clearpage + \fi + \@mainmatterfalse} +%% +%% Copyright © 2009-2010 by Vafa Khalighi +%% +%% Distributable 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 "maintained" (as per LPPL maintenance status) +%% by Vafa Khalighi. +%% +%% +%% +%% +%% +%% End of file `extbook-xetex-bidi.def'. diff --git a/Master/texmf-dist/tex/xelatex/bidi/fancyhdr-bidi.def b/Master/texmf-dist/tex/xelatex/bidi/fancyhdr-bidi.def deleted file mode 100644 index a8c0fb77c44..00000000000 --- a/Master/texmf-dist/tex/xelatex/bidi/fancyhdr-bidi.def +++ /dev/null @@ -1,36 +0,0 @@ -%% -%% This is file `fancyhdr-bidi.def', - -%% -%% __________________________________ -%% Copyright © 2009-2010 Vafa Khalighi -%% -%% License information appended. -%% -%% -\ProvidesFile{fancyhdr-bidi.def}[2010/03/01 v0.2 adaptations for fancyhdr package] -\def\@fancyhead#1#2#3#4#5{\if@RTLmain\beginR\fi#1\if@RTLmain\endR\fi\hbox to\headwidth{\fancy@reset - \@fancyvbox\headheight{\hbox - {\rlap{\parbox[b]{\headwidth}{\if@RTLmain\raggedleft\else\raggedright\fi\if@RTLmain\beginR\fi#2\if@RTLmain\endR\fi}}\hfill - \parbox[b]{\headwidth}{\centering\if@RTLmain\beginR\fi#3\if@RTLmain\endR\fi}\hfill - \llap{\parbox[b]{\headwidth}{\if@RTLmain\raggedright\else\raggedleft\fi\if@RTLmain\beginR\fi#4\if@RTLmain\endR\fi}}}\headrule}}\if@RTLmain\beginR\fi#5\if@RTLmain\endR\fi} -\def\@fancyfoot#1#2#3#4#5{\if@RTLmain\beginR\fi#1\if@RTLmain\endR\fi\hbox to\headwidth{\fancy@reset - \@fancyvbox\footskip{\footrule - \hbox{\rlap{\parbox[t]{\headwidth}{\if@RTLmain\raggedleft\else\raggedright\fi\if@RTLmain\beginR\fi#2\if@RTLmain\endR\fi}}\hfill - \parbox[t]{\headwidth}{\centering\if@RTLmain\beginR\fi#3\if@RTLmain\endR\fi}\hfill - \llap{\parbox[t]{\headwidth}{\if@RTLmain\raggedright\else\raggedleft\fi\if@RTLmain\beginR\fi#4\if@RTLmain\endR\fi}}}}}\if@RTLmain\beginR\fi#5\if@RTLmain\endR\fi} -%% -%% Copyright © 2009-2010 by Vafa Khalighi -%% -%% Distributable 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 "maintained" (as per LPPL maintenance status) -%% by Vafa Khalighi. -%% -%% -%% -%% -%% -%% End of file `fancyhdr-bidi.def'. diff --git a/Master/texmf-dist/tex/xelatex/bidi/fancyhdr-xetex-bidi.def b/Master/texmf-dist/tex/xelatex/bidi/fancyhdr-xetex-bidi.def new file mode 100644 index 00000000000..24be58e219e --- /dev/null +++ b/Master/texmf-dist/tex/xelatex/bidi/fancyhdr-xetex-bidi.def @@ -0,0 +1,36 @@ +%% +%% This is file `fancyhdr-xetex-bidi.def', + +%% +%% __________________________________ +%% Copyright © 2009-2010 Vafa Khalighi +%% +%% License information appended. +%% +%% +\ProvidesFile{fancyhdr-xetex-bidi.def}[2010/07/25 v0.2 bidi adaptations for fancyhdr package for XeTeX engine] +\def\@fancyhead#1#2#3#4#5{\if@RTLmain\beginR\fi#1\if@RTLmain\endR\fi\hbox to\headwidth{\fancy@reset + \@fancyvbox\headheight{\hbox + {\rlap{\parbox[b]{\headwidth}{\if@RTLmain\raggedleft\else\raggedright\fi\if@RTLmain\beginR\fi#2\if@RTLmain\endR\fi}}\hfill + \parbox[b]{\headwidth}{\centering\if@RTLmain\beginR\fi#3\if@RTLmain\endR\fi}\hfill + \llap{\parbox[b]{\headwidth}{\if@RTLmain\raggedright\else\raggedleft\fi\if@RTLmain\beginR\fi#4\if@RTLmain\endR\fi}}}\headrule}}\if@RTLmain\beginR\fi#5\if@RTLmain\endR\fi} +\def\@fancyfoot#1#2#3#4#5{\if@RTLmain\beginR\fi#1\if@RTLmain\endR\fi\hbox to\headwidth{\fancy@reset + \@fancyvbox\footskip{\footrule + \hbox{\rlap{\parbox[t]{\headwidth}{\if@RTLmain\raggedleft\else\raggedright\fi\if@RTLmain\beginR\fi#2\if@RTLmain\endR\fi}}\hfill + \parbox[t]{\headwidth}{\centering\if@RTLmain\beginR\fi#3\if@RTLmain\endR\fi}\hfill + \llap{\parbox[t]{\headwidth}{\if@RTLmain\raggedright\else\raggedleft\fi\if@RTLmain\beginR\fi#4\if@RTLmain\endR\fi}}}}}\if@RTLmain\beginR\fi#5\if@RTLmain\endR\fi} +%% +%% Copyright © 2009-2010 by Vafa Khalighi +%% +%% Distributable 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 "maintained" (as per LPPL maintenance status) +%% by Vafa Khalighi. +%% +%% +%% +%% +%% +%% End of file `fancyhdr-xetex-bidi.def'. diff --git a/Master/texmf-dist/tex/xelatex/bidi/fleqn-bidi.def b/Master/texmf-dist/tex/xelatex/bidi/fleqn-bidi.def deleted file mode 100644 index cb0fb2e1765..00000000000 --- a/Master/texmf-dist/tex/xelatex/bidi/fleqn-bidi.def +++ /dev/null @@ -1,55 +0,0 @@ -%% -%% This is file `fleqn-bidi.def', - -%% -%% __________________________________ -%% Copyright © 2009-2010 Vafa Khalighi -%% -%% License information appended. -%% -%% -\ProvidesFile{fleqn-bidi.def}[2010/03/01 v0.1 adaptations for fleqn tag] -\renewcommand\[{\relax - \ifmmode\@badmath - \else - \begin{trivlist}% - \@beginparpenalty\predisplaypenalty - \@endparpenalty\postdisplaypenalty - \item[]\leavevmode - \hb@xt@\linewidth\bgroup \beginL$\m@th\displaystyle %$ - \hskip\mathindent\bgroup - \fi} -\renewcommand\]{\relax - \ifmmode - \egroup $\hfil% $ - \endL\egroup - \end{trivlist}% - \else \@badmath - \fi} -\renewenvironment{equation}% - {\@beginparpenalty\predisplaypenalty - \@endparpenalty\postdisplaypenalty - \refstepcounter{equation}% - \trivlist \item[]\leavevmode - \hb@xt@\linewidth\bgroup\beginL $\m@th% $ - \displaystyle - \hskip\mathindent}% - {$\hfil % $ - \displaywidth\linewidth\hbox{\@eqnnum}% - \endL\egroup - \endtrivlist} -%% -%% Copyright © 2009-2010 by Vafa Khalighi -%% -%% Distributable 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 "maintained" (as per LPPL maintenance status) -%% by Vafa Khalighi. -%% -%% -%% -%% -%% -%% End of file `fleqn-bidi.def'. diff --git a/Master/texmf-dist/tex/xelatex/bidi/fleqn-xetex-bidi.def b/Master/texmf-dist/tex/xelatex/bidi/fleqn-xetex-bidi.def new file mode 100644 index 00000000000..42988d14205 --- /dev/null +++ b/Master/texmf-dist/tex/xelatex/bidi/fleqn-xetex-bidi.def @@ -0,0 +1,55 @@ +%% +%% This is file `fleqn-xetex-bidi.def', + +%% +%% __________________________________ +%% Copyright © 2009-2010 Vafa Khalighi +%% +%% License information appended. +%% +%% +\ProvidesFile{fleqn-xetex-bidi.def}[2010/07/25 v0.1 bidi adaptations for fleqn tag for XeTeX engine] +\renewcommand\[{\relax + \ifmmode\@badmath + \else + \begin{trivlist}% + \@beginparpenalty\predisplaypenalty + \@endparpenalty\postdisplaypenalty + \item[]\leavevmode + \hb@xt@\linewidth\bgroup \beginL$\m@th\displaystyle %$ + \hskip\mathindent\bgroup + \fi} +\renewcommand\]{\relax + \ifmmode + \egroup $\hfil% $ + \endL\egroup + \end{trivlist}% + \else \@badmath + \fi} +\renewenvironment{equation}% + {\@beginparpenalty\predisplaypenalty + \@endparpenalty\postdisplaypenalty + \refstepcounter{equation}% + \trivlist \item[]\leavevmode + \hb@xt@\linewidth\bgroup\beginL $\m@th% $ + \displaystyle + \hskip\mathindent}% + {$\hfil % $ + \displaywidth\linewidth\hbox{\@eqnnum}% + \endL\egroup + \endtrivlist} +%% +%% Copyright © 2009-2010 by Vafa Khalighi +%% +%% Distributable 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 "maintained" (as per LPPL maintenance status) +%% by Vafa Khalighi. +%% +%% +%% +%% +%% +%% End of file `fleqn-xetex-bidi.def'. diff --git a/Master/texmf-dist/tex/xelatex/bidi/flowfram-bidi.def b/Master/texmf-dist/tex/xelatex/bidi/flowfram-bidi.def deleted file mode 100644 index ba1aca3f617..00000000000 --- a/Master/texmf-dist/tex/xelatex/bidi/flowfram-bidi.def +++ /dev/null @@ -1,155 +0,0 @@ -%% -%% This is file `flowfram-bidi.def', - -%% -%% __________________________________ -%% Copyright © 2009-2010 Vafa Khalighi -%% -%% License information appended. -%% -%% -\ProvidesFile{flowfram-bidi.def}[2010/03/01 v0.1 adaptations for flowfram package] -\def\@outputdblcol{% -\@nxtcol=\c@thisframe -\c@curpg=\c@page -\@g@tnextcol{\@nxtcol}% -\if@ff@nwpg % next flow frame starts on new page - \global\@firstcolumntrue - \@setcolbox\c@thisframe - \if@specialpage - \global\@specialpagefalse - \@nameuse{ps@\@specialstyle}\relax - \fi - \if@twoside - \ifodd\count\z@ - \let\@thehead\@oddhead - \let\@thefoot\@oddfoot - \else - \let\@thehead\@evenhead - \let\@thefoot\@evenfoot - \fi - \else - \let\@thehead\@oddhead - \let\@thefoot\@oddfoot - \fi - \@begindvi - \@dodynamicthehead\@dodynamicthefoot - \vbadness=\@M - \setbox\@outputbox\vbox{\hbox to \textwidth{\@ff@do@allframes}}% - \@combinedblfloats - \@outputpage -\advance\c@curpg by -\c@page\relax - \whiledo{\c@curpg>0}{\advance\c@curpg by -1\relax - \setbox\@outputbox\vbox{\hbox to \textwidth{\@ff@do@allframes}}% -\@outputpage} - \begingroup - \@dblfloatplacement - \@startdblcolumn - \@whilesw \if@fcolmade \fi - {\@outputpage \@startdblcolumn }\endgroup - \@resetst@tics - \@resetdyn@mics -\else % still on same page, save contents of box255 - \global\@firstcolumnfalse - \@setcolbox\c@thisframe -\fi -\global\c@thisframe=\@nxtcol -\@setcol{\c@thisframe}\relax -\global\@colht\vsize -} -\def\@outputpage{% -\begingroup - \let\protect\noexpand - \@resetactivechars - \global\let\@@if@newlist\if@newlist - \global\@newlistfalse\@parboxrestore - \shipout\vbox{\set@typeset@protect - \aftergroup - \endgroup - \aftergroup - \set@typeset@protect - \reset@font\normalsize\normalsfcodes - \let\label\@gobble - \let\index\@gobble - \let\glossary\@gobble - \baselineskip\z@skip - \lineskip\z@skip - \lineskiplimit\z@ - \vskip\topmargin\moveright\@themargin - \vbox{% - \vskip\headheight - \vskip\headsep - \box\@outputbox - }}% - \global\let\if@newlist\@@if@newlist - \stepcounter{page}% - \setcounter{displayedframe}{0}% - \let\firstmark\botmark} - - -\newcommand*\bidi@s@tfftextcol{\ifthenelse{\equal{\ff@txtcol}{}}{}{% -\expandafter\bidicolor\ff@txtcol}} - -\newcommand{\bidi@ff@box}[3]{{\@ffbackground{\vbox to#2 -{\hb@xt@ #1{\hss{\bidi@s@tfftextcol #3}\hss}\vss\kern\z@}}}} - - -\renewcommand*{\@docolbox}[1]{% -\edef\ff@frametype{% -\csname @ff@frametype@\romannumeral#1\endcsname}% -\edef\ff@col{\csname @ff@col@\romannumeral#1\endcsname}% -\edef\ff@txtcol{\csname @ff@txtcol@\romannumeral#1\endcsname}% -\edef\ff@backcol{\csname @ff@backcol@\romannumeral#1\endcsname}% -\@ff@setoffset{#1}% -\rotateframe{\csname @ff@angle@\romannumeral#1\endcsname}{% -\ifthenelse{\boolean{columnframe\romannumeral#1}}{% -\@ff@fbox{\csname colwidth\romannumeral#1\endcsname}% -{\csname colheight\romannumeral#1\endcsname}{% -\expandafter\box\csname column\romannumeral#1\endcsname}{% -\csname\ff@frametype\endcsname}% -}{% -\bidi@ff@box{\csname colwidth\romannumeral#1\endcsname}% -{\csname colheight\romannumeral#1\endcsname}{% -\expandafter\box\csname column\romannumeral#1\endcsname}% -}}} -\@ifclassloaded{book}{% -\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 \thechapter {\@arabic\c@chapter} -\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}}{} -\@ifclassloaded{report}{% -\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 \thechapter {\@arabic\c@chapter} -\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}}{} -%% -%% Copyright © 2009-2010 by Vafa Khalighi -%% -%% Distributable 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 "maintained" (as per LPPL maintenance status) -%% by Vafa Khalighi. -%% -%% -%% -%% -%% -%% End of file `flowfram-bidi.def'. diff --git a/Master/texmf-dist/tex/xelatex/bidi/flowfram-xetex-bidi.def b/Master/texmf-dist/tex/xelatex/bidi/flowfram-xetex-bidi.def new file mode 100644 index 00000000000..c466ca32872 --- /dev/null +++ b/Master/texmf-dist/tex/xelatex/bidi/flowfram-xetex-bidi.def @@ -0,0 +1,155 @@ +%% +%% This is file `flowfram-xetex-bidi.def', + +%% +%% __________________________________ +%% Copyright © 2009-2010 Vafa Khalighi +%% +%% License information appended. +%% +%% +\ProvidesFile{flowfram-xetex-bidi.def}[2010/07/25 v0.1 bidi adaptations for flowfram package for XeTeX engine] +\def\@outputdblcol{% +\@nxtcol=\c@thisframe +\c@curpg=\c@page +\@g@tnextcol{\@nxtcol}% +\if@ff@nwpg % next flow frame starts on new page + \global\@firstcolumntrue + \@setcolbox\c@thisframe + \if@specialpage + \global\@specialpagefalse + \@nameuse{ps@\@specialstyle}\relax + \fi + \if@twoside + \ifodd\count\z@ + \let\@thehead\@oddhead + \let\@thefoot\@oddfoot + \else + \let\@thehead\@evenhead + \let\@thefoot\@evenfoot + \fi + \else + \let\@thehead\@oddhead + \let\@thefoot\@oddfoot + \fi + \@begindvi + \@dodynamicthehead\@dodynamicthefoot + \vbadness=\@M + \setbox\@outputbox\vbox{\hbox to \textwidth{\@ff@do@allframes}}% + \@combinedblfloats + \@outputpage +\advance\c@curpg by -\c@page\relax + \whiledo{\c@curpg>0}{\advance\c@curpg by -1\relax + \setbox\@outputbox\vbox{\hbox to \textwidth{\@ff@do@allframes}}% +\@outputpage} + \begingroup + \@dblfloatplacement + \@startdblcolumn + \@whilesw \if@fcolmade \fi + {\@outputpage \@startdblcolumn }\endgroup + \@resetst@tics + \@resetdyn@mics +\else % still on same page, save contents of box255 + \global\@firstcolumnfalse + \@setcolbox\c@thisframe +\fi +\global\c@thisframe=\@nxtcol +\@setcol{\c@thisframe}\relax +\global\@colht\vsize +} +\def\@outputpage{% +\begingroup + \let\protect\noexpand + \@resetactivechars + \global\let\@@if@newlist\if@newlist + \global\@newlistfalse\@parboxrestore + \shipout\vbox{\set@typeset@protect + \aftergroup + \endgroup + \aftergroup + \set@typeset@protect + \reset@font\normalsize\normalsfcodes + \let\label\@gobble + \let\index\@gobble + \let\glossary\@gobble + \baselineskip\z@skip + \lineskip\z@skip + \lineskiplimit\z@ + \vskip\topmargin\moveright\@themargin + \vbox{% + \vskip\headheight + \vskip\headsep + \box\@outputbox + }}% + \global\let\if@newlist\@@if@newlist + \stepcounter{page}% + \setcounter{displayedframe}{0}% + \let\firstmark\botmark} + + +\newcommand*\bidi@s@tfftextcol{\ifthenelse{\equal{\ff@txtcol}{}}{}{% +\expandafter\bidicolor\ff@txtcol}} + +\newcommand{\bidi@ff@box}[3]{{\@ffbackground{\vbox to#2 +{\hb@xt@ #1{\hss{\bidi@s@tfftextcol #3}\hss}\vss\kern\z@}}}} + + +\renewcommand*{\@docolbox}[1]{% +\edef\ff@frametype{% +\csname @ff@frametype@\romannumeral#1\endcsname}% +\edef\ff@col{\csname @ff@col@\romannumeral#1\endcsname}% +\edef\ff@txtcol{\csname @ff@txtcol@\romannumeral#1\endcsname}% +\edef\ff@backcol{\csname @ff@backcol@\romannumeral#1\endcsname}% +\@ff@setoffset{#1}% +\rotateframe{\csname @ff@angle@\romannumeral#1\endcsname}{% +\ifthenelse{\boolean{columnframe\romannumeral#1}}{% +\@ff@fbox{\csname colwidth\romannumeral#1\endcsname}% +{\csname colheight\romannumeral#1\endcsname}{% +\expandafter\box\csname column\romannumeral#1\endcsname}{% +\csname\ff@frametype\endcsname}% +}{% +\bidi@ff@box{\csname colwidth\romannumeral#1\endcsname}% +{\csname colheight\romannumeral#1\endcsname}{% +\expandafter\box\csname column\romannumeral#1\endcsname}% +}}} +\@ifclassloaded{book}{% +\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 \thechapter {\@arabic\c@chapter} +\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}}{} +\@ifclassloaded{report}{% +\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 \thechapter {\@arabic\c@chapter} +\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}}{} +%% +%% Copyright © 2009-2010 by Vafa Khalighi +%% +%% Distributable 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 "maintained" (as per LPPL maintenance status) +%% by Vafa Khalighi. +%% +%% +%% +%% +%% +%% End of file `flowfram-xetex-bidi.def'. diff --git a/Master/texmf-dist/tex/xelatex/bidi/footnote-bidi.def b/Master/texmf-dist/tex/xelatex/bidi/footnote-bidi.def deleted file mode 100644 index 9ce5054aeeb..00000000000 --- a/Master/texmf-dist/tex/xelatex/bidi/footnote-bidi.def +++ /dev/null @@ -1,256 +0,0 @@ -%% -%% This is file `footnote-bidi.def', - -%% -%% __________________________________ -%% Copyright © 2009-2010 Vafa Khalighi -%% -%% License information appended. -%% -%% -\ProvidesFile{footnote-bidi.def}[2010/03/01 v0.4 footnote macros for bidi package] -\if@RTLmain\@RTL@footnotetrue\else\@RTL@footnotefalse\fi -\def\bidi@footnote@output{{% - \dimen0=\ht\footins - \advance\dimen0 by\dp\footins - \def\@elt##1##2{% - \ifx\bidi@footnoterule\relax\global\let\bidi@footnoterule##2\fi - \advance\dimen0 by -##1\relax - \ifdim\dimen0<\z@ - {% - \let\@elt\relax\let\right@footnote\relax\let\left@footnote\relax - \dimen0=-\dimen0% - \xdef\new@bidi@footnote@list{\new@bidi@footnote@list\noexpand\@elt{\the\dimen0}{##2}}% -}% - \fi - \ifdim\dimen0>\z@\else -\let\right@footnote\relax\let\left@footnote\relax -\def\@elt####1####2{% - {\let\@elt\relax - \xdef\new@bidi@footnote@list{\new@bidi@footnote@list\noexpand\@elt{####1}{####2}}}% -}% - \fi - }% - \def\new@bidi@footnote@list{}% - \bidi@footnote@list - \global\let\bidi@footnote@list\new@bidi@footnote@list - }} -\def\right@footnote{% - \hbox to \columnwidth - {\beginR \vbox{\kern -3\p@ - \hrule width .4\columnwidth \kern2.6\p@}\hfil\endR}} -\def\left@footnote{% - \hrule width .4\columnwidth\kern 2.6\p@} -\def\textwidth@footnote{\kern-3\p@ - \hrule \@width \textwidth \kern 2.6\p@} -\def\right@footnoterule{\bidi@footnote@output\right@footnote\global\let\bidi@footnoterule\relax} -\def\left@footnoterule{\bidi@footnote@output\left@footnote\global\let\bidi@footnoterule\relax} -\def\textwidth@footnoterule{\bidi@footnote@output\textwidth@footnote\global\let\bidi@footnoterule\relax} -\def\auto@footnoterule{\bidi@footnote@output - \ifx\bidi@footnoterule\relax\if@RTL\right@footnote\else\left@footnote\fi\else\bidi@footnoterule\fi - \global\let\bidi@footnoterule\relax} -\def\leftfootnoterule{\def\footnoterule{\left@footnoterule}} -\let\LRfootnoterule=\leftfootnoterule -\def\rightfootnoterule{\def\footnoterule{\right@footnoterule}} -\def\textwidthfootnoterule{\def\footnoterule{\textwidth@footnoterule}} -\def\autofootnoterule{\def\footnoterule{\auto@footnoterule}} -\def\@makefnmark{\hbox{\@textsuperscript{\normalfont\@thefnmark}}} -\def\bidi@footnote@list{} -\let\bidi@footnoterule\relax -\def\RTLfootnote{\@ifnextchar[\@xRTLfootnote{\stepcounter\@mpfn - \protected@xdef\@thefnmark{\thempfn}% - \@footnotemark\@RTLfootnotetext}} -\def\@xRTLfootnote[#1]{% - \begingroup - \csname c@\@mpfn\endcsname #1\relax - \unrestored@protected@xdef\@thefnmark{\thempfn}% - \endgroup - \@footnotemark\@RTLfootnotetext} -\def\LTRfootnote{\@ifnextchar[\@xLTRfootnote{\stepcounter\@mpfn - \protected@xdef\@thefnmark{\thempfn}% - \@footnotemark\@LTRfootnotetext}} -\def\@xLTRfootnote[#1]{% - \begingroup - \csname c@\@mpfn\endcsname #1\relax - \unrestored@protected@xdef\@thefnmark{\thempfn}% - \endgroup - \@footnotemark\@LTRfootnotetext} -\def\insertRTL{\bgroup\beginR\@RTLtrue} -\def\endinsertRTL{\endR\egroup} -\def\insertLTR{\bgroup\beginL\@RTLfalse} -\def\endinsertLTR{\endL\egroup} -\DeclareRobustCommand\InLTR{\insertLTR} -\DeclareRobustCommand\EInLTR{\endinsertLTR} -\DeclareRobustCommand\InRTL{\insertRTL} -\DeclareRobustCommand\EInRTL{\endinsertRTL} -\long\def\parse@lsent#1#2\EInLTR#3#4#5\parse@end{\@sentdirfalse -\def\@tempa{\InLTR}\def\@tempb{\EInLTR}\def\@tempc{#1}\def\@tempd{#4}% -\ifx\@tempa\@tempc\ifx\@tempb\@tempd\@sentdirtrue\fi\fi} -\long\def\parse@rsent#1#2\EInRTL#3#4#5\parse@end{\@sentdirfalse -\def\@tempa{\InRTL}\def\@tempb{\EInRTL}\def\@tempc{#1}\def\@tempd{#4}% -\ifx\@tempa\@tempc\ifx\@tempb\@tempd\@sentdirtrue\fi\fi} -\long\def\iflsentence#1{\parse@lsent#1\EInLTR123\parse@end\if@sentdir} -\long\def\ifrsentence#1{\parse@rsent#1\EInRTL123\parse@end\if@sentdir} -\long\def\bidi@footnotetext@dir#1{% - \@tempswatrue - \ifrsentence{#1}\rtl\@tempswafalse\fi - \iflsentence{#1}\ltr\@tempswafalse\fi - \if@tempswa\if@RTL\rtl\else\ltr\fi\fi - \xdef\bidi@this@footnote{\if@RTL\noexpand\right@footnote\else\noexpand\left@footnote\fi}% -} -\def\bidi@footnotetext@after{% - {% - \let\@elt\relax\let\right@footnote\relax\let\left@footnote\relax - \dimen0=\ht\footins - \advance\dimen0 by\dp\footins - \xdef\bidi@footnote@list{\bidi@footnote@list\@elt{\the\dimen0}{\bidi@this@footnote}}% - }% -} -\def\setfootnoteRL{\@RTL@footnotetrue} -\def\unsetfootnoteRL{\@RTL@footnotefalse} -\def\setfootnoteLR{\unsetfootnoteRL} -\long\def\@footnotetext#1{% - \begingroup - \setbox\footins - \vbox{\if@RTL@footnote\@RTLtrue\else\@RTLfalse\fi\reset@font\footnotesize - \interlinepenalty\interfootnotelinepenalty - \splittopskip\footnotesep - \splitmaxdepth \dp\strutbox \floatingpenalty \@MM - \hsize\columnwidth \@parboxrestore - \bidi@footnotetext@dir{#1}% - \protected@edef\@currentlabel{\csname p@footnote\endcsname\@thefnmark}\@makefntext - {\rule{\z@}{\footnotesep}\ignorespaces#1\strut}}% - \bidi@footnotetext@after - \insert\footins{\unvbox\footins}% - \endgroup} -\long\def\@RTLfootnotetext#1{% - \begingroup - \setbox\footins - \vbox{\@RTLtrue\reset@font\footnotesize - \interlinepenalty\interfootnotelinepenalty - \splittopskip\footnotesep - \splitmaxdepth \dp\strutbox \floatingpenalty \@MM - \hsize\columnwidth \@parboxrestore - \bidi@footnotetext@dir{#1}% - \protected@edef\@currentlabel{\csname p@footnote\endcsname\@thefnmark}\@makefntext - {\rule{\z@}{\footnotesep}\ignorespaces #1\strut}}% - \bidi@footnotetext@after - \insert\footins{\unvbox\footins}% - \endgroup} -\long\def\@LTRfootnotetext#1{% - \begingroup - \setbox\footins - \vbox{\@RTLfalse\reset@font\footnotesize - \interlinepenalty\interfootnotelinepenalty - \splittopskip\footnotesep - \splitmaxdepth \dp\strutbox \floatingpenalty \@MM - \hsize\columnwidth \@parboxrestore - \bidi@footnotetext@dir{#1}% - \protected@edef\@currentlabel{\csname p@footnote\endcsname\@thefnmark}\@makefntext - {\rule{\z@}{\footnotesep}\ignorespaces#1\strut}}% - \bidi@footnotetext@after - \insert\footins{\unvbox\footins}% - \endgroup} -\long\def\@mpRTLfootnotetext#1{% - \global\setbox\@mpfootins\vbox{\@RTLtrue% - \unvbox\@mpfootins - \reset@font\footnotesize - \hsize\columnwidth - \@parboxrestore - \protected@edef\@currentlabel - {\csname p@mpfootnote\endcsname\@thefnmark}% - \color@begingroup - \bidi@footnotetext@dir{#1} - \ifnum\c@mpfootnote=1\if@RTL\global\let\bidi@footnoterule\right@footnote\else\global\let\bidi@footnoterule\left@footnote\fi\fi - \@makefntext{% - \rule\z@\footnotesep\ignorespaces#1\@finalstrut\strutbox}% - \color@endgroup}} -\long\def\@mpLTRfootnotetext#1{% - \global\setbox\@mpfootins\vbox{\@RTLfalse% - \unvbox\@mpfootins - \reset@font\footnotesize - \hsize\columnwidth - \@parboxrestore - \protected@edef\@currentlabel - {\csname p@mpfootnote\endcsname\@thefnmark}% - \color@begingroup - \bidi@footnotetext@dir{#1} - \ifnum\c@mpfootnote=1\if@RTL\global\let\bidi@footnoterule\right@footnote\else\global\let\bidi@footnoterule\left@footnote\fi\fi - \@makefntext{% - \rule\z@\footnotesep\ignorespaces#1\@finalstrut\strutbox}% - \color@endgroup}} -\long\def\@mpfootnotetext#1{% - \global\setbox\@mpfootins\vbox{\if@RTL@footnote\@RTLtrue\else\@RTLfalse\fi% - \unvbox\@mpfootins - \reset@font\footnotesize - \hsize\columnwidth - \@parboxrestore - \protected@edef\@currentlabel - {\csname p@mpfootnote\endcsname\@thefnmark}% - \color@begingroup - \bidi@footnotetext@dir{#1} - \ifnum\c@mpfootnote=1\if@RTL\global\let\bidi@footnoterule\right@footnote\else\global\let\bidi@footnoterule\left@footnote\fi\fi - \@makefntext{% - \rule\z@\footnotesep\ignorespaces#1\@finalstrut\strutbox}% - \color@endgroup}} -\def\@iiiminipage#1#2[#3]#4{% - \leavevmode - \@pboxswfalse - \setlength\@tempdima{#4}% - \def\@mpargs{{#1}{#2}[#3]{#4}}% - \setbox\@tempboxa\vbox\bgroup - \color@begingroup - \hsize\@tempdima - \textwidth\hsize \columnwidth\hsize - \@parboxrestore - \def\@mpfn{mpfootnote}\def\thempfn{\thempfootnote}\c@mpfootnote\z@ - \let\@footnotetext\@mpfootnotetext - \let\@LTRfootnotetext\@mpLTRfootnotetext - \let\@RTLfootnotetext\@mpRTLfootnotetext - \let\@listdepth\@mplistdepth \@mplistdepth\z@ - \@minipagerestore - \@setminipage} -\def\LTRthanks#1{\footnotemark - \protected@xdef\@thanks{\@thanks - \protect\LTRfootnotetext[\the\c@footnote]{#1}}% -} -\def\LTRfootnotetext{% - \@ifnextchar [\@xLTRfootnotenext - {\protected@xdef\@thefnmark{\thempfn}% - \@LTRfootnotetext}} -\def\@xLTRfootnotenext[#1]{% - \begingroup - \csname c@\@mpfn\endcsname #1\relax - \unrestored@protected@xdef\@thefnmark{\thempfn}% - \endgroup - \@LTRfootnotetext} -\def\RTLthanks#1{\footnotemark - \protected@xdef\@thanks{\@thanks - \protect\RTLfootnotetext[\the\c@footnote]{#1}}% -} -\let\@thanks\@empty -\def\RTLfootnotetext{% - \@ifnextchar [\@xRTLfootnotenext - {\protected@xdef\@thefnmark{\thempfn}% - \@RTLfootnotetext}} -\def\@xRTLfootnotenext[#1]{% - \begingroup - \csname c@\@mpfn\endcsname #1\relax - \unrestored@protected@xdef\@thefnmark{\thempfn}% - \endgroup - \@RTLfootnotetext} -%% -%% Copyright © 2009-2010 by Vafa Khalighi -%% -%% Distributable 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 "maintained" (as per LPPL maintenance status) -%% by Vafa Khalighi. -%% -%% -%% -%% -%% -%% End of file `footnote-bidi.def'. diff --git a/Master/texmf-dist/tex/xelatex/bidi/footnote-luatex-bidi.def b/Master/texmf-dist/tex/xelatex/bidi/footnote-luatex-bidi.def new file mode 100644 index 00000000000..f07784e623d --- /dev/null +++ b/Master/texmf-dist/tex/xelatex/bidi/footnote-luatex-bidi.def @@ -0,0 +1,26 @@ +%% +%% This is file `footnote-luatex-bidi.def', + +%% +%% __________________________________ +%% Copyright © 2009-2010 Vafa Khalighi +%% +%% License information appended. +%% +%% +\ProvidesFile{footnote-luatex-bidi.def}[2010/07/25 v0.1 bidi footnote macros for LuaTeX engine] +%% +%% Copyright © 2009-2010 by Vafa Khalighi +%% +%% Distributable 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 "maintained" (as per LPPL maintenance status) +%% by Vafa Khalighi. +%% +%% +%% +%% +%% +%% End of file `footnote-luatex-bidi.def'. diff --git a/Master/texmf-dist/tex/xelatex/bidi/footnote-xetex-bidi.def b/Master/texmf-dist/tex/xelatex/bidi/footnote-xetex-bidi.def new file mode 100644 index 00000000000..855a34bf08e --- /dev/null +++ b/Master/texmf-dist/tex/xelatex/bidi/footnote-xetex-bidi.def @@ -0,0 +1,256 @@ +%% +%% This is file `footnote-xetex-bidi.def', + +%% +%% __________________________________ +%% Copyright © 2009-2010 Vafa Khalighi +%% +%% License information appended. +%% +%% +\ProvidesFile{footnote-xetex-bidi.def}[2010/07/25 v0.4 bidi footnote macros for XeTeX engine] +\if@RTLmain\@RTL@footnotetrue\else\@RTL@footnotefalse\fi +\def\bidi@footnote@output{{% + \dimen0=\ht\footins + \advance\dimen0 by\dp\footins + \def\@elt##1##2{% + \ifx\bidi@footnoterule\relax\global\let\bidi@footnoterule##2\fi + \advance\dimen0 by -##1\relax + \ifdim\dimen0<\z@ + {% + \let\@elt\relax\let\right@footnote\relax\let\left@footnote\relax + \dimen0=-\dimen0% + \xdef\new@bidi@footnote@list{\new@bidi@footnote@list\noexpand\@elt{\the\dimen0}{##2}}% +}% + \fi + \ifdim\dimen0>\z@\else +\let\right@footnote\relax\let\left@footnote\relax +\def\@elt####1####2{% + {\let\@elt\relax + \xdef\new@bidi@footnote@list{\new@bidi@footnote@list\noexpand\@elt{####1}{####2}}}% +}% + \fi + }% + \def\new@bidi@footnote@list{}% + \bidi@footnote@list + \global\let\bidi@footnote@list\new@bidi@footnote@list + }} +\def\right@footnote{% + \hbox to \columnwidth + {\beginR \vbox{\kern -3\p@ + \hrule width .4\columnwidth \kern2.6\p@}\hfil\endR}} +\def\left@footnote{% + \hrule width .4\columnwidth\kern 2.6\p@} +\def\textwidth@footnote{\kern-3\p@ + \hrule \@width \textwidth \kern 2.6\p@} +\def\right@footnoterule{\bidi@footnote@output\right@footnote\global\let\bidi@footnoterule\relax} +\def\left@footnoterule{\bidi@footnote@output\left@footnote\global\let\bidi@footnoterule\relax} +\def\textwidth@footnoterule{\bidi@footnote@output\textwidth@footnote\global\let\bidi@footnoterule\relax} +\def\auto@footnoterule{\bidi@footnote@output + \ifx\bidi@footnoterule\relax\if@RTL\right@footnote\else\left@footnote\fi\else\bidi@footnoterule\fi + \global\let\bidi@footnoterule\relax} +\def\leftfootnoterule{\def\footnoterule{\left@footnoterule}} +\let\LRfootnoterule=\leftfootnoterule +\def\rightfootnoterule{\def\footnoterule{\right@footnoterule}} +\def\textwidthfootnoterule{\def\footnoterule{\textwidth@footnoterule}} +\def\autofootnoterule{\def\footnoterule{\auto@footnoterule}} +\def\@makefnmark{\hbox{\@textsuperscript{\normalfont\@thefnmark}}} +\def\bidi@footnote@list{} +\let\bidi@footnoterule\relax +\def\RTLfootnote{\@ifnextchar[\@xRTLfootnote{\stepcounter\@mpfn + \protected@xdef\@thefnmark{\thempfn}% + \@footnotemark\@RTLfootnotetext}} +\def\@xRTLfootnote[#1]{% + \begingroup + \csname c@\@mpfn\endcsname #1\relax + \unrestored@protected@xdef\@thefnmark{\thempfn}% + \endgroup + \@footnotemark\@RTLfootnotetext} +\def\LTRfootnote{\@ifnextchar[\@xLTRfootnote{\stepcounter\@mpfn + \protected@xdef\@thefnmark{\thempfn}% + \@footnotemark\@LTRfootnotetext}} +\def\@xLTRfootnote[#1]{% + \begingroup + \csname c@\@mpfn\endcsname #1\relax + \unrestored@protected@xdef\@thefnmark{\thempfn}% + \endgroup + \@footnotemark\@LTRfootnotetext} +\def\insertRTL{\bgroup\beginR\@RTLtrue} +\def\endinsertRTL{\endR\egroup} +\def\insertLTR{\bgroup\beginL\@RTLfalse} +\def\endinsertLTR{\endL\egroup} +\DeclareRobustCommand\InLTR{\insertLTR} +\DeclareRobustCommand\EInLTR{\endinsertLTR} +\DeclareRobustCommand\InRTL{\insertRTL} +\DeclareRobustCommand\EInRTL{\endinsertRTL} +\long\def\parse@lsent#1#2\EInLTR#3#4#5\parse@end{\@sentdirfalse +\def\@tempa{\InLTR}\def\@tempb{\EInLTR}\def\@tempc{#1}\def\@tempd{#4}% +\ifx\@tempa\@tempc\ifx\@tempb\@tempd\@sentdirtrue\fi\fi} +\long\def\parse@rsent#1#2\EInRTL#3#4#5\parse@end{\@sentdirfalse +\def\@tempa{\InRTL}\def\@tempb{\EInRTL}\def\@tempc{#1}\def\@tempd{#4}% +\ifx\@tempa\@tempc\ifx\@tempb\@tempd\@sentdirtrue\fi\fi} +\long\def\iflsentence#1{\parse@lsent#1\EInLTR123\parse@end\if@sentdir} +\long\def\ifrsentence#1{\parse@rsent#1\EInRTL123\parse@end\if@sentdir} +\long\def\bidi@footnotetext@dir#1{% + \@tempswatrue + \ifrsentence{#1}\rtl\@tempswafalse\fi + \iflsentence{#1}\ltr\@tempswafalse\fi + \if@tempswa\if@RTL\rtl\else\ltr\fi\fi + \xdef\bidi@this@footnote{\if@RTL\noexpand\right@footnote\else\noexpand\left@footnote\fi}% +} +\def\bidi@footnotetext@after{% + {% + \let\@elt\relax\let\right@footnote\relax\let\left@footnote\relax + \dimen0=\ht\footins + \advance\dimen0 by\dp\footins + \xdef\bidi@footnote@list{\bidi@footnote@list\@elt{\the\dimen0}{\bidi@this@footnote}}% + }% +} +\def\setfootnoteRL{\@RTL@footnotetrue} +\def\unsetfootnoteRL{\@RTL@footnotefalse} +\def\setfootnoteLR{\unsetfootnoteRL} +\long\def\@footnotetext#1{% + \begingroup + \setbox\footins + \vbox{\if@RTL@footnote\@RTLtrue\else\@RTLfalse\fi\reset@font\footnotesize + \interlinepenalty\interfootnotelinepenalty + \splittopskip\footnotesep + \splitmaxdepth \dp\strutbox \floatingpenalty \@MM + \hsize\columnwidth \@parboxrestore + \bidi@footnotetext@dir{#1}% + \protected@edef\@currentlabel{\csname p@footnote\endcsname\@thefnmark}\@makefntext + {\rule{\z@}{\footnotesep}\ignorespaces#1\strut}}% + \bidi@footnotetext@after + \insert\footins{\unvbox\footins}% + \endgroup} +\long\def\@RTLfootnotetext#1{% + \begingroup + \setbox\footins + \vbox{\@RTLtrue\reset@font\footnotesize + \interlinepenalty\interfootnotelinepenalty + \splittopskip\footnotesep + \splitmaxdepth \dp\strutbox \floatingpenalty \@MM + \hsize\columnwidth \@parboxrestore + \bidi@footnotetext@dir{#1}% + \protected@edef\@currentlabel{\csname p@footnote\endcsname\@thefnmark}\@makefntext + {\rule{\z@}{\footnotesep}\ignorespaces #1\strut}}% + \bidi@footnotetext@after + \insert\footins{\unvbox\footins}% + \endgroup} +\long\def\@LTRfootnotetext#1{% + \begingroup + \setbox\footins + \vbox{\@RTLfalse\reset@font\footnotesize + \interlinepenalty\interfootnotelinepenalty + \splittopskip\footnotesep + \splitmaxdepth \dp\strutbox \floatingpenalty \@MM + \hsize\columnwidth \@parboxrestore + \bidi@footnotetext@dir{#1}% + \protected@edef\@currentlabel{\csname p@footnote\endcsname\@thefnmark}\@makefntext + {\rule{\z@}{\footnotesep}\ignorespaces#1\strut}}% + \bidi@footnotetext@after + \insert\footins{\unvbox\footins}% + \endgroup} +\long\def\@mpRTLfootnotetext#1{% + \global\setbox\@mpfootins\vbox{\@RTLtrue% + \unvbox\@mpfootins + \reset@font\footnotesize + \hsize\columnwidth + \@parboxrestore + \protected@edef\@currentlabel + {\csname p@mpfootnote\endcsname\@thefnmark}% + \color@begingroup + \bidi@footnotetext@dir{#1} + \ifnum\c@mpfootnote=1\if@RTL\global\let\bidi@footnoterule\right@footnote\else\global\let\bidi@footnoterule\left@footnote\fi\fi + \@makefntext{% + \rule\z@\footnotesep\ignorespaces#1\@finalstrut\strutbox}% + \color@endgroup}} +\long\def\@mpLTRfootnotetext#1{% + \global\setbox\@mpfootins\vbox{\@RTLfalse% + \unvbox\@mpfootins + \reset@font\footnotesize + \hsize\columnwidth + \@parboxrestore + \protected@edef\@currentlabel + {\csname p@mpfootnote\endcsname\@thefnmark}% + \color@begingroup + \bidi@footnotetext@dir{#1} + \ifnum\c@mpfootnote=1\if@RTL\global\let\bidi@footnoterule\right@footnote\else\global\let\bidi@footnoterule\left@footnote\fi\fi + \@makefntext{% + \rule\z@\footnotesep\ignorespaces#1\@finalstrut\strutbox}% + \color@endgroup}} +\long\def\@mpfootnotetext#1{% + \global\setbox\@mpfootins\vbox{\if@RTL@footnote\@RTLtrue\else\@RTLfalse\fi% + \unvbox\@mpfootins + \reset@font\footnotesize + \hsize\columnwidth + \@parboxrestore + \protected@edef\@currentlabel + {\csname p@mpfootnote\endcsname\@thefnmark}% + \color@begingroup + \bidi@footnotetext@dir{#1} + \ifnum\c@mpfootnote=1\if@RTL\global\let\bidi@footnoterule\right@footnote\else\global\let\bidi@footnoterule\left@footnote\fi\fi + \@makefntext{% + \rule\z@\footnotesep\ignorespaces#1\@finalstrut\strutbox}% + \color@endgroup}} +\def\@iiiminipage#1#2[#3]#4{% + \leavevmode + \@pboxswfalse + \setlength\@tempdima{#4}% + \def\@mpargs{{#1}{#2}[#3]{#4}}% + \setbox\@tempboxa\vbox\bgroup + \color@begingroup + \hsize\@tempdima + \textwidth\hsize \columnwidth\hsize + \@parboxrestore + \def\@mpfn{mpfootnote}\def\thempfn{\thempfootnote}\c@mpfootnote\z@ + \let\@footnotetext\@mpfootnotetext + \let\@LTRfootnotetext\@mpLTRfootnotetext + \let\@RTLfootnotetext\@mpRTLfootnotetext + \let\@listdepth\@mplistdepth \@mplistdepth\z@ + \@minipagerestore + \@setminipage} +\def\LTRthanks#1{\footnotemark + \protected@xdef\@thanks{\@thanks + \protect\LTRfootnotetext[\the\c@footnote]{#1}}% +} +\def\LTRfootnotetext{% + \@ifnextchar [\@xLTRfootnotenext + {\protected@xdef\@thefnmark{\thempfn}% + \@LTRfootnotetext}} +\def\@xLTRfootnotenext[#1]{% + \begingroup + \csname c@\@mpfn\endcsname #1\relax + \unrestored@protected@xdef\@thefnmark{\thempfn}% + \endgroup + \@LTRfootnotetext} +\def\RTLthanks#1{\footnotemark + \protected@xdef\@thanks{\@thanks + \protect\RTLfootnotetext[\the\c@footnote]{#1}}% +} +\let\@thanks\@empty +\def\RTLfootnotetext{% + \@ifnextchar [\@xRTLfootnotenext + {\protected@xdef\@thefnmark{\thempfn}% + \@RTLfootnotetext}} +\def\@xRTLfootnotenext[#1]{% + \begingroup + \csname c@\@mpfn\endcsname #1\relax + \unrestored@protected@xdef\@thefnmark{\thempfn}% + \endgroup + \@RTLfootnotetext} +%% +%% Copyright © 2009-2010 by Vafa Khalighi +%% +%% Distributable 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 "maintained" (as per LPPL maintenance status) +%% by Vafa Khalighi. +%% +%% +%% +%% +%% +%% End of file `footnote-xetex-bidi.def'. diff --git a/Master/texmf-dist/tex/xelatex/bidi/graphicx-bidi.def b/Master/texmf-dist/tex/xelatex/bidi/graphicx-bidi.def deleted file mode 100644 index 71b4c27904e..00000000000 --- a/Master/texmf-dist/tex/xelatex/bidi/graphicx-bidi.def +++ /dev/null @@ -1,130 +0,0 @@ -%% -%% This is file `graphicx-bidi.def', - -%% -%% __________________________________ -%% Copyright © 2009-2010 Vafa Khalighi -%% -%% License information appended. -%% -%% -\ProvidesFile{graphicx-bidi.def}[2010/03/01 v0.3 adaptations for graphicx package] -\def\Grot@box@std#1#2{\ifmmode\else\if@RTL\beginL\fi\fi% - \Grot@setangle{#1}% - \setbox\z@\hbox{{\ifmmode\if@RTL\beginR\fi#2\if@RTL\endR\fi\else\if@RTL\beginR\fi#2\if@RTL\endR\fi\fi}}% - \Grot@x\z@ - \Grot@y\z@ - \Grot@box\ifmmode\else\if@RTL\endL\fi\fi} -\long\def\Gscale@box#1[#2]#3{\ifmmode\else\if@RTL\beginL\fi\fi% - \leavevmode - \def\Gscale@x{#1}\def\Gscale@y{#2}% - \setbox\z@\hbox{{#3}}% - \setbox\tw@\hbox{\Gscale@start\rlap{\copy\z@}\Gscale@end}% - \ifdim#2\p@<\z@ - \ht\tw@-#2\dp\z@ - \dp\tw@-#2\ht\z@ - \else - \ht\tw@#2\ht\z@ - \dp\tw@#2\dp\z@ - \fi - \ifdim#1\p@<\z@ - \hb@xt@-#1\wd\z@{\kern-#1\wd\z@\box\tw@\hss}% - \else - \wd\tw@#1\wd\z@ - \box\tw@ - \fi\ifmmode\else\if@RTL\endL\fi\fi} -\def\Gin@ii[#1]#2{\ifmmode\else\if@RTL\beginL\fi\fi% - \def\@tempa{[}\def\@tempb{#2}% - \ifx\@tempa\@tempb - \def\@tempa{\Gin@iii[#1][}% - \expandafter\@tempa - \else - \begingroup - \@tempswafalse - \toks@{\Ginclude@graphics{#2}}% - \setkeys{Gin}{#1}% - \Gin@esetsize - \the\toks@ - \endgroup - \fi\ifmmode\else\if@RTL\endL\fi\fi} -\def\reflectbox{\bidiGscale@box-1[1]} -\long\def\bidiGscale@box#1[#2]#3{\ifmmode\else\if@RTL\beginL\fi\fi% - \leavevmode - \def\Gscale@x{#1}\def\Gscale@y{#2}% - \setbox\z@\hbox{{\ifmmode\if@RTL\beginR\fi#3\if@RTL\endR\fi\else\if@RTL\beginR\fi#3\if@RTL\endR\fi\fi}}% - \setbox\tw@\hbox{\Gscale@start\rlap{\copy\z@}\Gscale@end}% - \ifdim#2\p@<\z@ - \ht\tw@-#2\dp\z@ - \dp\tw@-#2\ht\z@ - \else - \ht\tw@#2\ht\z@ - \dp\tw@#2\dp\z@ - \fi - \ifdim#1\p@<\z@ - \hb@xt@-#1\wd\z@{\kern-#1\wd\z@\box\tw@\hss}% - \else - \wd\tw@#1\wd\z@ - \box\tw@ - \fi\ifmmode\else\if@RTL\endL\fi\fi} -\def\scalebox#1{% - \@ifnextchar[{\bidiGscale@box{#1}}{\bidiGscale@box{#1}[#1]}} -\def\resizebox{% - \leavevmode - \@ifstar{\bidiGscale@@box\totalheight}{\bidiGscale@@box\height}} -\def\bidiGscale@@box#1#2#3{% - \let\@tempa\Gin@exclamation - \expandafter\def\expandafter\@tempb\expandafter{\string#2}% - \expandafter\def\expandafter\@tempc\expandafter{\string#3}% - \ifx\@tempb\@tempa - \ifx\@tempc\@tempa - \toks@{\mbox}% - \else - \toks@{\bidiGscale@box@dd{#3}#1}% - \fi - \else - \ifx\@tempc\@tempa - \toks@{\bidiGscale@box@dd{#2}\width}% - \else - \toks@{\bidiGscale@box@dddd{#2}\width{#3}#1}% - \fi - \fi - \the\toks@} -\long\def\bidiGscale@box@dd#1#2#3{% - \@begin@tempboxa\hbox{\ifmmode\if@RTL\beginR\fi#3\if@RTL\endR\fi\else\if@RTL\beginR\fi#3\if@RTL\endR\fi\fi}% - \setlength\@tempdima{#1}% - \setlength\@tempdimb{#2}% - \Gscale@div\@tempa\@tempdima\@tempdimb - \Gscale@box\@tempa[\@tempa]{\box\@tempboxa}% - \@end@tempboxa} -\long\def\bidiGscale@box@dddd#1#2#3#4#5{% - \@begin@tempboxa\hbox{\ifmmode\if@RTL\beginR\fi#5\if@RTL\endR\fi\else\if@RTL\beginR\fi#5\if@RTL\endR\fi\fi}% - \setlength\@tempdima{#1}% - \setlength\@tempdimb{#2}% - \Gscale@div\@tempa\@tempdima\@tempdimb - \setlength\@tempdima{#3}% - \setlength\@tempdimb{#4}% - \Gscale@div\@tempb\@tempdima\@tempdimb - \ifGin@iso - \ifdim\@tempa\p@>\@tempb\p@ - \let\@tempa\@tempb - \else - \let\@tempb\@tempa - \fi - \fi - \Gscale@box\@tempa[\@tempb]{\box\@tempboxa}% - \@end@tempboxa} -%% -%% Copyright © 2009-2010 by Vafa Khalighi -%% -%% Distributable 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 "maintained" (as per LPPL maintenance status) -%% by Vafa Khalighi. -%% -%% -%% -%% -%% -%% End of file `graphicx-bidi.def'. diff --git a/Master/texmf-dist/tex/xelatex/bidi/graphicx-xetex-bidi.def b/Master/texmf-dist/tex/xelatex/bidi/graphicx-xetex-bidi.def new file mode 100644 index 00000000000..961aef11f4b --- /dev/null +++ b/Master/texmf-dist/tex/xelatex/bidi/graphicx-xetex-bidi.def @@ -0,0 +1,130 @@ +%% +%% This is file `graphicx-xetex-bidi.def', + +%% +%% __________________________________ +%% Copyright © 2009-2010 Vafa Khalighi +%% +%% License information appended. +%% +%% +\ProvidesFile{graphicx-xetex-bidi.def}[2010/07/25 v0.3 bidi adaptations for graphicx package for XeTeX engine] +\def\Grot@box@std#1#2{\ifmmode\else\if@RTL\beginL\fi\fi% + \Grot@setangle{#1}% + \setbox\z@\hbox{{\ifmmode\if@RTL\beginR\fi#2\if@RTL\endR\fi\else\if@RTL\beginR\fi#2\if@RTL\endR\fi\fi}}% + \Grot@x\z@ + \Grot@y\z@ + \Grot@box\ifmmode\else\if@RTL\endL\fi\fi} +\long\def\Gscale@box#1[#2]#3{\ifmmode\else\if@RTL\beginL\fi\fi% + \leavevmode + \def\Gscale@x{#1}\def\Gscale@y{#2}% + \setbox\z@\hbox{{#3}}% + \setbox\tw@\hbox{\Gscale@start\rlap{\copy\z@}\Gscale@end}% + \ifdim#2\p@<\z@ + \ht\tw@-#2\dp\z@ + \dp\tw@-#2\ht\z@ + \else + \ht\tw@#2\ht\z@ + \dp\tw@#2\dp\z@ + \fi + \ifdim#1\p@<\z@ + \hb@xt@-#1\wd\z@{\kern-#1\wd\z@\box\tw@\hss}% + \else + \wd\tw@#1\wd\z@ + \box\tw@ + \fi\ifmmode\else\if@RTL\endL\fi\fi} +\def\Gin@ii[#1]#2{\ifmmode\else\if@RTL\beginL\fi\fi% + \def\@tempa{[}\def\@tempb{#2}% + \ifx\@tempa\@tempb + \def\@tempa{\Gin@iii[#1][}% + \expandafter\@tempa + \else + \begingroup + \@tempswafalse + \toks@{\Ginclude@graphics{#2}}% + \setkeys{Gin}{#1}% + \Gin@esetsize + \the\toks@ + \endgroup + \fi\ifmmode\else\if@RTL\endL\fi\fi} +\def\reflectbox{\bidiGscale@box-1[1]} +\long\def\bidiGscale@box#1[#2]#3{\ifmmode\else\if@RTL\beginL\fi\fi% + \leavevmode + \def\Gscale@x{#1}\def\Gscale@y{#2}% + \setbox\z@\hbox{{\ifmmode\if@RTL\beginR\fi#3\if@RTL\endR\fi\else\if@RTL\beginR\fi#3\if@RTL\endR\fi\fi}}% + \setbox\tw@\hbox{\Gscale@start\rlap{\copy\z@}\Gscale@end}% + \ifdim#2\p@<\z@ + \ht\tw@-#2\dp\z@ + \dp\tw@-#2\ht\z@ + \else + \ht\tw@#2\ht\z@ + \dp\tw@#2\dp\z@ + \fi + \ifdim#1\p@<\z@ + \hb@xt@-#1\wd\z@{\kern-#1\wd\z@\box\tw@\hss}% + \else + \wd\tw@#1\wd\z@ + \box\tw@ + \fi\ifmmode\else\if@RTL\endL\fi\fi} +\def\scalebox#1{% + \@ifnextchar[{\bidiGscale@box{#1}}{\bidiGscale@box{#1}[#1]}} +\def\resizebox{% + \leavevmode + \@ifstar{\bidiGscale@@box\totalheight}{\bidiGscale@@box\height}} +\def\bidiGscale@@box#1#2#3{% + \let\@tempa\Gin@exclamation + \expandafter\def\expandafter\@tempb\expandafter{\string#2}% + \expandafter\def\expandafter\@tempc\expandafter{\string#3}% + \ifx\@tempb\@tempa + \ifx\@tempc\@tempa + \toks@{\mbox}% + \else + \toks@{\bidiGscale@box@dd{#3}#1}% + \fi + \else + \ifx\@tempc\@tempa + \toks@{\bidiGscale@box@dd{#2}\width}% + \else + \toks@{\bidiGscale@box@dddd{#2}\width{#3}#1}% + \fi + \fi + \the\toks@} +\long\def\bidiGscale@box@dd#1#2#3{% + \@begin@tempboxa\hbox{\ifmmode\if@RTL\beginR\fi#3\if@RTL\endR\fi\else\if@RTL\beginR\fi#3\if@RTL\endR\fi\fi}% + \setlength\@tempdima{#1}% + \setlength\@tempdimb{#2}% + \Gscale@div\@tempa\@tempdima\@tempdimb + \Gscale@box\@tempa[\@tempa]{\box\@tempboxa}% + \@end@tempboxa} +\long\def\bidiGscale@box@dddd#1#2#3#4#5{% + \@begin@tempboxa\hbox{\ifmmode\if@RTL\beginR\fi#5\if@RTL\endR\fi\else\if@RTL\beginR\fi#5\if@RTL\endR\fi\fi}% + \setlength\@tempdima{#1}% + \setlength\@tempdimb{#2}% + \Gscale@div\@tempa\@tempdima\@tempdimb + \setlength\@tempdima{#3}% + \setlength\@tempdimb{#4}% + \Gscale@div\@tempb\@tempdima\@tempdimb + \ifGin@iso + \ifdim\@tempa\p@>\@tempb\p@ + \let\@tempa\@tempb + \else + \let\@tempb\@tempa + \fi + \fi + \Gscale@box\@tempa[\@tempb]{\box\@tempboxa}% + \@end@tempboxa} +%% +%% Copyright © 2009-2010 by Vafa Khalighi +%% +%% Distributable 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 "maintained" (as per LPPL maintenance status) +%% by Vafa Khalighi. +%% +%% +%% +%% +%% +%% End of file `graphicx-xetex-bidi.def'. diff --git a/Master/texmf-dist/tex/xelatex/bidi/hyperref-bidi.def b/Master/texmf-dist/tex/xelatex/bidi/hyperref-bidi.def deleted file mode 100644 index a5e3d744ced..00000000000 --- a/Master/texmf-dist/tex/xelatex/bidi/hyperref-bidi.def +++ /dev/null @@ -1,252 +0,0 @@ -%% -%% This is file `hyperref-bidi.def', - -%% -%% __________________________________ -%% Copyright © 2009-2010 Vafa Khalighi -%% -%% License information appended. -%% -%% -\ProvidesFile{hyperref-bidi.def}[2010/03/01 v0.2 adaptations for hyperref package] -\AtBeginDocument{% -\def\contentsline#1#2#3#4{% - \ifx\\#4\\% - \csname l@#1\endcsname{#2}{#3}% - \else - \ifcase\Hy@linktoc % none - \csname l@#1\endcsname{#2}{#3}% - \or % section - \csname l@#1\endcsname{% - \beginL\hyper@linkstart{link}{#4}{\if@RTL\beginR\fi#2\if@RTL\endR\fi}\hyper@linkend\endL - }{#3}% - \or % page - \csname l@#1\endcsname{{#2}}{% - \beginL\hyper@linkstart{link}{#4}{#3}\hyper@linkend\endL - }% - \else % all - \csname l@#1\endcsname{% - \beginL\hyper@linkstart{link}{#4}{\if@RTL\beginR\fi#2\if@RTL\endR\fi}\hyper@linkend\endL - }{% - \beginL\hyper@linkstart{link}{#4}{#3}\hyper@linkend\endL - }% - \fi - \fi -} -\ifHy@hyperfootnotes - \let\H@@footnotetext\@footnotetext - \let\HRTL@@RTLfootnotetext\@RTLfootnotetext - \let\HLTR@@LTRfootnotetext\@LTRfootnotetext - \def\@xfootnotenext[#1]{% - \begingroup - \csname c@\@mpfn\endcsname #1\relax - \unrestored@protected@xdef\@thefnmark{\thempfn}% - \endgroup - \ifx\@footnotetext\@mpfootnotetext - \expandafter\H@@mpfootnotetext - \else - \expandafter\H@@footnotetext - \fi - }% - \def\@xRTLfootnotenext[#1]{% - \begingroup - \csname c@\@mpfn\endcsname #1\relax - \unrestored@protected@xdef\@thefnmark{\thempfn}% - \endgroup - \ifx\@RTLfootnotetext\@mpRTLfootnotetext - \expandafter\HRTL@@mpRTLfootnotetext - \else - \expandafter\HRTL@@RTLfootnotetext - \fi - }% - \def\@xLTRfootnotenext[#1]{% - \begingroup - \csname c@\@mpfn\endcsname #1\relax - \unrestored@protected@xdef\@thefnmark{\thempfn}% - \endgroup - \ifx\@LTRfootnotetext\@mpLTRfootnotetext - \expandafter\HLTR@@mpLTRfootnotetext - \else - \expandafter\HLTR@@LTRfootnotetext - \fi - }% - \def\@xfootnotemark[#1]{% - \begingroup - \c@footnote #1\relax - \unrestored@protected@xdef\@thefnmark{\thefootnote}% - \endgroup - \H@@footnotemark - }% - \let\H@@mpfootnotetext\@mpfootnotetext - \let\HRTL@@mpRTLfootnotetext\@mpRTLfootnotetext - \let\HLTR@@mpLTRfootnotetext\@mpLTRfootnotetext - \long\def\@mpfootnotetext#1{% - \H@@mpfootnotetext{% - \ifHy@nesting - \hyper@@anchor{\Hy@footnote@currentHref}{#1}% - \else - \Hy@raisedlink{% - \hyper@@anchor{\Hy@footnote@currentHref}{\relax}% - }#1% - \fi - }% - }% - \long\def\@mpRTLfootnotetext#1{% - \HRTL@@mpRTLfootnotetext{% - \ifHy@nesting - \hyper@@anchor{\Hy@footnote@currentHref}{#1}% - \else - \Hy@raisedlink{% - \hyper@@anchor{\Hy@footnote@currentHref}{\relax}% - }#1% - \fi - }% - }% - \long\def\@mpLTRfootnotetext#1{% - \HLTR@@mpLTRfootnotetext{% - \ifHy@nesting - \hyper@@anchor{\Hy@footnote@currentHref}{#1}% - \else - \Hy@raisedlink{% - \hyper@@anchor{\Hy@footnote@currentHref}{\relax}% - }#1% - \fi - }% - }% - \long\def\@footnotetext#1{% - \H@@footnotetext{% - \ifHy@nesting - \hyper@@anchor{\Hy@footnote@currentHref}{#1}% - \else - \Hy@raisedlink{% - \hyper@@anchor{\Hy@footnote@currentHref}{\relax}% - }% - \let\@currentHlabel\Hy@footnote@currentHlabel - \let\@currentHref\Hy@footnote@currentHref - \let\@currentlabelname\@empty - #1% - \fi - }% - }% - \long\def\@RTLfootnotetext#1{% - \HRTL@@RTLfootnotetext{% - \ifHy@nesting - \hyper@@anchor{\Hy@footnote@currentHref}{#1}% - \else - \Hy@raisedlink{% - \hyper@@anchor{\Hy@footnote@currentHref}{\relax}% - }% - \let\@currentHlabel\Hy@footnote@currentHlabel - \let\@currentHref\Hy@footnote@currentHref - \let\@currentlabelname\@empty - #1% - \fi - }% - }% - \long\def\@LTRfootnotetext#1{% - \HLTR@@LTRfootnotetext{% - \ifHy@nesting - \hyper@@anchor{\Hy@footnote@currentHref}{#1}% - \else - \Hy@raisedlink{% - \hyper@@anchor{\Hy@footnote@currentHref}{\relax}% - }% - \let\@currentHlabel\Hy@footnote@currentHlabel - \let\@currentHref\Hy@footnote@currentHref - \let\@currentlabelname\@empty - #1% - \fi - }% - }% - \def\@footnotemark{% - \leavevmode - \ifhmode\edef\@x@sf{\the\spacefactor}\nobreak\fi - \stepcounter{Hfootnote}% - \global\let\Hy@saved@currentHlabel\@currentHlabel - \global\let\Hy@saved@currentHref\@currentHref - \hyper@makecurrent{Hfootnote}% - \global\let\Hy@footnote@currentHlabel\@currentHlabel - \global\let\Hy@footnote@currentHref\@currentHref - \global\let\@currentHlabel\Hy@saved@currentHlabel - \global\let\@currentHref\Hy@saved@currentHref - \beginL\hyper@linkstart{link}{\Hy@footnote@currentHref}% - \@makefnmark - \hyper@linkend\endL - \ifhmode\spacefactor\@x@sf\fi - \relax - }% - \let\maketitle\HyOrg@maketitle - \def\maketitle{% - \let\Hy@saved@footnotemark\@footnotemark - \let\Hy@saved@footnotetext\@footnotetext - \let\HyRTL@saved@RTLfootnotetext\@RTLfootnotetext - \let\HyLTR@saved@LTRfootnotetext\@LTRfootnotetext - \let\@footnotemark\H@@footnotemark - \let\@footnotetext\H@@footnotetext - \let\@RTLfootnotetext\HRTL@@RTLfootnotetext - \let\@LTRfootnotetext\HLTR@@LTRfootnotetext - \@ifnextchar[\Hy@maketitle@optarg{% ] - \HyOrg@maketitle - \Hy@maketitle@end - }% - }% - \def\Hy@maketitle@optarg[#1]{% - \HyOrg@maketitle[{#1}]% - \Hy@maketitle@end - }% - \def\Hy@maketitle@end{% - \ifx\@footnotemark\H@@footnotemark - \let\@footnotemark\Hy@saved@footnotemark - \fi - \ifx\@footnotetext\H@@footnotetext - \let\@footnotetext\Hy@saved@footnotetext - \fi - \ifx\@RTLfootnotetext\HRTL@@RTLfootnotetext - \let\@RTLfootnotetext\HyRTL@saved@RTLfootnotetext - \fi - \ifx\@LTRfootnotetext\HLTR@@LTRfootnotetext - \let\@LTRfootnotetext\HyLTR@saved@LTRfootnotetext - \fi - }% - \def\realfootnote{% - \@ifnextchar[\@xfootnote{% - \stepcounter{\@mpfn}% - \protected@xdef\@thefnmark{\thempfn}% - \H@@footnotemark\H@@footnotetext - }% - }% -\fi -\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\hyper@natlinkstart#1{% - \Hy@backout{#1}% - \beginL\hyper@linkstart{cite}{cite.#1}\if@RTL\beginR\fi% - \def\hyper@nat@current{#1}% -} -\def\hyper@natlinkend{% - \if@RTL\endR\fi\hyper@linkend\endL -} -\def\hyper@natlinkbreak#1#2{% - \if@RTL\endR\fi\hyper@linkend\endL#1\beginL\hyper@linkstart{cite}{cite.#2}\if@RTL\beginR\fi% -}% -} -%% -%% Copyright © 2009-2010 by Vafa Khalighi -%% -%% Distributable 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 "maintained" (as per LPPL maintenance status) -%% by Vafa Khalighi. -%% -%% -%% -%% -%% -%% End of file `hyperref-bidi.def'. diff --git a/Master/texmf-dist/tex/xelatex/bidi/hyperref-xetex-bidi.def b/Master/texmf-dist/tex/xelatex/bidi/hyperref-xetex-bidi.def new file mode 100644 index 00000000000..9abd39f87bb --- /dev/null +++ b/Master/texmf-dist/tex/xelatex/bidi/hyperref-xetex-bidi.def @@ -0,0 +1,252 @@ +%% +%% This is file `hyperref-xetex-bidi.def', + +%% +%% __________________________________ +%% Copyright © 2009-2010 Vafa Khalighi +%% +%% License information appended. +%% +%% +\ProvidesFile{hyperref-xetex-bidi.def}[2010/07/25 v0.4 bidi adaptations for hyperref package for XeTeX engine] +\AtBeginDocument{% +\def\contentsline#1#2#3#4{% + \ifx\\#4\\% + \csname l@#1\endcsname{#2}{#3}% + \else + \ifcase\Hy@linktoc % none + \csname l@#1\endcsname{#2}{#3}% + \or % section + \csname l@#1\endcsname{% + \beginL\hyper@linkstart{link}{#4}{\if@RTL\beginR\fi#2\if@RTL\endR\fi}\hyper@linkend\endL + }{#3}% + \or % page + \csname l@#1\endcsname{{#2}}{% + \beginL\hyper@linkstart{link}{#4}{#3}\hyper@linkend\endL + }% + \else % all + \csname l@#1\endcsname{% + \beginL\hyper@linkstart{link}{#4}{\if@RTL\beginR\fi#2\if@RTL\endR\fi}\hyper@linkend\endL + }{% + \beginL\hyper@linkstart{link}{#4}{#3}\hyper@linkend\endL + }% + \fi + \fi +} +\ifHy@hyperfootnotes + \let\H@@footnotetext\@footnotetext + \let\HRTL@@RTLfootnotetext\@RTLfootnotetext + \let\HLTR@@LTRfootnotetext\@LTRfootnotetext + \def\@xfootnotenext[#1]{% + \begingroup + \csname c@\@mpfn\endcsname #1\relax + \unrestored@protected@xdef\@thefnmark{\thempfn}% + \endgroup + \ifx\@footnotetext\@mpfootnotetext + \expandafter\H@@mpfootnotetext + \else + \expandafter\H@@footnotetext + \fi + }% + \def\@xRTLfootnotenext[#1]{% + \begingroup + \csname c@\@mpfn\endcsname #1\relax + \unrestored@protected@xdef\@thefnmark{\thempfn}% + \endgroup + \ifx\@RTLfootnotetext\@mpRTLfootnotetext + \expandafter\HRTL@@mpRTLfootnotetext + \else + \expandafter\HRTL@@RTLfootnotetext + \fi + }% + \def\@xLTRfootnotenext[#1]{% + \begingroup + \csname c@\@mpfn\endcsname #1\relax + \unrestored@protected@xdef\@thefnmark{\thempfn}% + \endgroup + \ifx\@LTRfootnotetext\@mpLTRfootnotetext + \expandafter\HLTR@@mpLTRfootnotetext + \else + \expandafter\HLTR@@LTRfootnotetext + \fi + }% + \def\@xfootnotemark[#1]{% + \begingroup + \c@footnote #1\relax + \unrestored@protected@xdef\@thefnmark{\thefootnote}% + \endgroup + \H@@footnotemark + }% + \let\H@@mpfootnotetext\@mpfootnotetext + \let\HRTL@@mpRTLfootnotetext\@mpRTLfootnotetext + \let\HLTR@@mpLTRfootnotetext\@mpLTRfootnotetext + \long\def\@mpfootnotetext#1{% + \H@@mpfootnotetext{% + \ifHy@nesting + \hyper@@anchor{\Hy@footnote@currentHref}{#1}% + \else + \Hy@raisedlink{% + \hyper@@anchor{\Hy@footnote@currentHref}{\relax}% + }#1% + \fi + }% + }% + \long\def\@mpRTLfootnotetext#1{% + \HRTL@@mpRTLfootnotetext{% + \ifHy@nesting + \hyper@@anchor{\Hy@footnote@currentHref}{#1}% + \else + \Hy@raisedlink{% + \hyper@@anchor{\Hy@footnote@currentHref}{\relax}% + }#1% + \fi + }% + }% + \long\def\@mpLTRfootnotetext#1{% + \HLTR@@mpLTRfootnotetext{% + \ifHy@nesting + \hyper@@anchor{\Hy@footnote@currentHref}{#1}% + \else + \Hy@raisedlink{% + \hyper@@anchor{\Hy@footnote@currentHref}{\relax}% + }#1% + \fi + }% + }% + \long\def\@footnotetext#1{% + \H@@footnotetext{% + \ifHy@nesting + \hyper@@anchor{\Hy@footnote@currentHref}{#1}% + \else + \Hy@raisedlink{% + \hyper@@anchor{\Hy@footnote@currentHref}{\relax}% + }% + \let\@currentHlabel\Hy@footnote@currentHlabel + \let\@currentHref\Hy@footnote@currentHref + \let\@currentlabelname\@empty + #1% + \fi + }% + }% + \long\def\@RTLfootnotetext#1{% + \HRTL@@RTLfootnotetext{% + \ifHy@nesting + \hyper@@anchor{\Hy@footnote@currentHref}{#1}% + \else + \Hy@raisedlink{% + \hyper@@anchor{\Hy@footnote@currentHref}{\relax}% + }% + \let\@currentHlabel\Hy@footnote@currentHlabel + \let\@currentHref\Hy@footnote@currentHref + \let\@currentlabelname\@empty + #1% + \fi + }% + }% + \long\def\@LTRfootnotetext#1{% + \HLTR@@LTRfootnotetext{% + \ifHy@nesting + \hyper@@anchor{\Hy@footnote@currentHref}{#1}% + \else + \Hy@raisedlink{% + \hyper@@anchor{\Hy@footnote@currentHref}{\relax}% + }% + \let\@currentHlabel\Hy@footnote@currentHlabel + \let\@currentHref\Hy@footnote@currentHref + \let\@currentlabelname\@empty + #1% + \fi + }% + }% + \def\@footnotemark{% + \leavevmode + \ifhmode\edef\@x@sf{\the\spacefactor}\nobreak\fi + \stepcounter{Hfootnote}% + \global\let\Hy@saved@currentHlabel\@currentHlabel + \global\let\Hy@saved@currentHref\@currentHref + \hyper@makecurrent{Hfootnote}% + \global\let\Hy@footnote@currentHlabel\@currentHlabel + \global\let\Hy@footnote@currentHref\@currentHref + \global\let\@currentHlabel\Hy@saved@currentHlabel + \global\let\@currentHref\Hy@saved@currentHref + \beginL\hyper@linkstart{link}{\Hy@footnote@currentHref}% + \@makefnmark + \hyper@linkend\endL + \ifhmode\spacefactor\@x@sf\fi + \relax + }% + \let\HyOrg@maketitle\maketitle + \def\maketitle{% + \let\Hy@saved@footnotemark\@footnotemark + \let\Hy@saved@footnotetext\@footnotetext + \let\HyRTL@saved@RTLfootnotetext\@RTLfootnotetext + \let\HyLTR@saved@LTRfootnotetext\@LTRfootnotetext + \let\@footnotemark\H@@footnotemark + \let\@footnotetext\H@@footnotetext + \let\@RTLfootnotetext\HRTL@@RTLfootnotetext + \let\@LTRfootnotetext\HLTR@@LTRfootnotetext + \@ifnextchar[\Hy@maketitle@optarg{% ] + \HyOrg@maketitle + \Hy@maketitle@end + }% + }% + \def\Hy@maketitle@optarg[#1]{% + \HyOrg@maketitle[{#1}]% + \Hy@maketitle@end + }% + \def\Hy@maketitle@end{% + \ifx\@footnotemark\H@@footnotemark + \let\@footnotemark\Hy@saved@footnotemark + \fi + \ifx\@footnotetext\H@@footnotetext + \let\@footnotetext\Hy@saved@footnotetext + \fi + \ifx\@RTLfootnotetext\HRTL@@RTLfootnotetext + \let\@RTLfootnotetext\HyRTL@saved@RTLfootnotetext + \fi + \ifx\@LTRfootnotetext\HLTR@@LTRfootnotetext + \let\@LTRfootnotetext\HyLTR@saved@LTRfootnotetext + \fi + }% + \def\realfootnote{% + \@ifnextchar[\@xfootnote{% + \stepcounter{\@mpfn}% + \protected@xdef\@thefnmark{\thempfn}% + \H@@footnotemark\H@@footnotetext + }% + }% +\fi +\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\hyper@natlinkstart#1{% + \Hy@backout{#1}% + \beginL\hyper@linkstart{cite}{cite.#1}\if@RTL\beginR\fi% + \def\hyper@nat@current{#1}% +} +\def\hyper@natlinkend{% + \if@RTL\endR\fi\hyper@linkend\endL +} +\def\hyper@natlinkbreak#1#2{% + \if@RTL\endR\fi\hyper@linkend\endL#1\beginL\hyper@linkstart{cite}{cite.#2}\if@RTL\beginR\fi% +}% +} +%% +%% Copyright © 2009-2010 by Vafa Khalighi +%% +%% Distributable 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 "maintained" (as per LPPL maintenance status) +%% by Vafa Khalighi. +%% +%% +%% +%% +%% +%% End of file `hyperref-xetex-bidi.def'. diff --git a/Master/texmf-dist/tex/xelatex/bidi/leqno-bidi.def b/Master/texmf-dist/tex/xelatex/bidi/leqno-bidi.def deleted file mode 100644 index c7beb947669..00000000000 --- a/Master/texmf-dist/tex/xelatex/bidi/leqno-bidi.def +++ /dev/null @@ -1,29 +0,0 @@ -%% -%% This is file `leqno-bidi.def', - -%% -%% __________________________________ -%% Copyright © 2009-2010 Vafa Khalighi -%% -%% License information appended. -%% -%% -\ProvidesFile{leqno-bidi.def}[2010/03/01 v0.1 adaptations for leqno tag] -\renewcommand\@eqnnum{\hb@xt@.01\p@{}% - \rlap{\normalfont\normalcolor - \hskip -\displaywidth\if@RTL\beginR\fi(\theequation)\if@RTL\endR\fi}} -%% -%% Copyright © 2009-2010 by Vafa Khalighi -%% -%% Distributable 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 "maintained" (as per LPPL maintenance status) -%% by Vafa Khalighi. -%% -%% -%% -%% -%% -%% End of file `leqno-bidi.def'. diff --git a/Master/texmf-dist/tex/xelatex/bidi/leqno-xetex-bidi.def b/Master/texmf-dist/tex/xelatex/bidi/leqno-xetex-bidi.def new file mode 100644 index 00000000000..eb576128696 --- /dev/null +++ b/Master/texmf-dist/tex/xelatex/bidi/leqno-xetex-bidi.def @@ -0,0 +1,29 @@ +%% +%% This is file `leqno-xetex-bidi.def', + +%% +%% __________________________________ +%% Copyright © 2009-2010 Vafa Khalighi +%% +%% License information appended. +%% +%% +\ProvidesFile{leqno-xetex-bidi.def}[2010/07/25 v0.1 bidi adaptations for leqno tag for XeTeX engine] +\renewcommand\@eqnnum{\hb@xt@.01\p@{}% + \rlap{\normalfont\normalcolor + \hskip -\displaywidth\if@RTL\beginR\fi(\theequation)\if@RTL\endR\fi}} +%% +%% Copyright © 2009-2010 by Vafa Khalighi +%% +%% Distributable 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 "maintained" (as per LPPL maintenance status) +%% by Vafa Khalighi. +%% +%% +%% +%% +%% +%% End of file `leqno-xetex-bidi.def'. diff --git a/Master/texmf-dist/tex/xelatex/bidi/letter-bidi.def b/Master/texmf-dist/tex/xelatex/bidi/letter-bidi.def deleted file mode 100644 index 8d1a312e2f8..00000000000 --- a/Master/texmf-dist/tex/xelatex/bidi/letter-bidi.def +++ /dev/null @@ -1,39 +0,0 @@ -%% -%% This is file `letter-bidi.def', - -%% -%% __________________________________ -%% Copyright © 2009-2010 Vafa Khalighi -%% -%% License information appended. -%% -%% -\ProvidesFile{letter-bidi.def}[2010/03/01 v0.1 adaptations for standard letter class] -\renewcommand*{\opening}[1]{\ifx\@empty\fromaddress - \thispagestyle{firstpage}% - {\if@RTL\raggedright\else\raggedleft\fi\@date\par}% - \else % home address - \thispagestyle{empty}% - {\if@RTL\raggedright\else\raggedleft\fi\if@RTL\begin{tabular}{r@{}}\else\begin{tabular}{l@{}}\fi\ignorespaces - \fromaddress \\*[2\parskip]% - \@date \end{tabular}\par}% - \fi - \vspace{2\parskip}% - {\if@RTL\raggedleft\else\raggedright\fi \toname \\ \toaddress \par}% - \vspace{2\parskip}% - #1\par\nobreak} -%% -%% Copyright © 2009-2010 by Vafa Khalighi -%% -%% Distributable 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 "maintained" (as per LPPL maintenance status) -%% by Vafa Khalighi. -%% -%% -%% -%% -%% -%% End of file `letter-bidi.def'. diff --git a/Master/texmf-dist/tex/xelatex/bidi/letter-xetex-bidi.def b/Master/texmf-dist/tex/xelatex/bidi/letter-xetex-bidi.def new file mode 100644 index 00000000000..0c0dce9fee8 --- /dev/null +++ b/Master/texmf-dist/tex/xelatex/bidi/letter-xetex-bidi.def @@ -0,0 +1,39 @@ +%% +%% This is file `letter-xetex-bidi.def', + +%% +%% __________________________________ +%% Copyright © 2009-2010 Vafa Khalighi +%% +%% License information appended. +%% +%% +\ProvidesFile{letter-xetex-bidi.def}[2010/07/25 v0.1 bidi adaptations for standard letter class for XeTeX engine] +\renewcommand*{\opening}[1]{\ifx\@empty\fromaddress + \thispagestyle{firstpage}% + {\if@RTL\raggedright\else\raggedleft\fi\@date\par}% + \else % home address + \thispagestyle{empty}% + {\if@RTL\raggedright\else\raggedleft\fi\if@RTL\begin{tabular}{r@{}}\else\begin{tabular}{l@{}}\fi\ignorespaces + \fromaddress \\*[2\parskip]% + \@date \end{tabular}\par}% + \fi + \vspace{2\parskip}% + {\if@RTL\raggedleft\else\raggedright\fi \toname \\ \toaddress \par}% + \vspace{2\parskip}% + #1\par\nobreak} +%% +%% Copyright © 2009-2010 by Vafa Khalighi +%% +%% Distributable 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 "maintained" (as per LPPL maintenance status) +%% by Vafa Khalighi. +%% +%% +%% +%% +%% +%% End of file `letter-xetex-bidi.def'. diff --git a/Master/texmf-dist/tex/xelatex/bidi/listings-bidi.def b/Master/texmf-dist/tex/xelatex/bidi/listings-bidi.def deleted file mode 100644 index 1d15dce14b0..00000000000 --- a/Master/texmf-dist/tex/xelatex/bidi/listings-bidi.def +++ /dev/null @@ -1,34 +0,0 @@ -%% -%% This is file `listings-bidi.def', - -%% -%% __________________________________ -%% Copyright © 2009-2010 Vafa Khalighi -%% -%% License information appended. -%% -%% -\ProvidesFile{listings-bidi.def}[2010/03/01 v0.2 adaptations for listings package] -\long\def\@makecaption#1#2{% - \vskip 10pt% - \setbox\@tempboxa\hbox{#1: #2}% - \ifdim \wd\@tempboxa >\hsize \if@RTLmain\beginR\fi#1: #2\par% - \else \hbox -to\hsize{\if@RTLmain\beginR\fi\hfil\box\@tempboxa\hfil% -\if@RTLmain\endR\fi}% - \fi} -%% -%% Copyright © 2009-2010 by Vafa Khalighi -%% -%% Distributable 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 "maintained" (as per LPPL maintenance status) -%% by Vafa Khalighi. -%% -%% -%% -%% -%% -%% End of file `listings-bidi.def'. diff --git a/Master/texmf-dist/tex/xelatex/bidi/listings-xetex-bidi.def b/Master/texmf-dist/tex/xelatex/bidi/listings-xetex-bidi.def new file mode 100644 index 00000000000..9a2eee4a73a --- /dev/null +++ b/Master/texmf-dist/tex/xelatex/bidi/listings-xetex-bidi.def @@ -0,0 +1,44 @@ +%% +%% This is file `listings-xetex-bidi.def', + +%% +%% __________________________________ +%% Copyright © 2009-2010 Vafa Khalighi +%% +%% License information appended. +%% +%% +\ProvidesFile{listings-xetex-bidi.def}[2010/07/25 v0.3 bidi adaptations for listings package for XeTeX engine] +\long\def\@makecaption#1#2{% + \vskip 10pt% + \setbox\@tempboxa\hbox{#1: #2}% + \ifdim \wd\@tempboxa >\hsize \if@RTLmain\beginR\fi#1: #2\par% + \else \hbox +to\hsize{\if@RTLmain\beginR\fi\hfil\box\@tempboxa\hfil% +\if@RTLmain\endR\fi}% + \fi} +\AtBeginDocument{ +\def\SepMark#1{\gdef\@SepMark{\if@RTLmain\beginR\fi#1\if@RTLmain\endR\fi}} +\SepMark{.} + \@ifundefined{thechapter}{\let\lst@ifnumberbychapter\iffalse}{} + \lst@ifnumberbychapter + \gdef\thelstlisting% + {\ifnum \c@chapter>\z@ \thechapter\@SepMark\fi \@arabic\c@lstlisting} + \else + \gdef\thelstlisting{\@arabic\c@lstlisting} + \fi} +%% +%% Copyright © 2009-2010 by Vafa Khalighi +%% +%% Distributable 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 "maintained" (as per LPPL maintenance status) +%% by Vafa Khalighi. +%% +%% +%% +%% +%% +%% End of file `listings-xetex-bidi.def'. diff --git a/Master/texmf-dist/tex/xelatex/bidi/loadingorder-bidi.def b/Master/texmf-dist/tex/xelatex/bidi/loadingorder-bidi.def index dcfde485603..4ee1e07497a 100644 --- a/Master/texmf-dist/tex/xelatex/bidi/loadingorder-bidi.def +++ b/Master/texmf-dist/tex/xelatex/bidi/loadingorder-bidi.def @@ -8,7 +8,7 @@ %% License information appended. %% %% -\ProvidesFile{loadingorder-bidi.def}[2010/03/01 v0.1 making sure that bidi is the last package loaded] +\ProvidesFile{loadingorder-bidi.def}[2010/07/25 v0.4 making sure that bidi is the last package loaded] \newcommand\bidi@isloaded[2][]{ \expandafter\ifx\csname if@bidi@#2loaded@\endcsname\relax \expandafter\newif\csname if@bidi@#2loaded@\endcsname @@ -19,6 +19,7 @@ \bidi@isloaded{amsmath} \bidi@isloaded{amsthm} \bidi@isloaded{breqn} +\bidi@isloaded{caption} \bidi@isloaded{color} \bidi@isloaded{xcolor} \bidi@isloaded{colortbl} @@ -33,9 +34,11 @@ \bidi@isloaded{pdfpages} \bidi@isloaded{listings} \bidi@isloaded{pstricks} +\bidi@isloaded{pgf} \bidi@isloaded{tikz} \bidi@isloaded{array} \bidi@isloaded{stabular} +\bidi@isloaded{subfigure} \bidi@isloaded{supertabular} \bidi@isloaded{xtab} \bidi@isloaded{longtable} @@ -60,6 +63,9 @@ \if@bidi@breqnloaded@\else \bidi@isloaded[\PackageError{bidi}{Oops! you have loaded package breqn after bidi package. Please load package breqn before bidi package, and then try to run xelatex on your document again}{}]{breqn} \fi% + \if@bidi@captionloaded@\else + \bidi@isloaded[\PackageError{bidi}{Oops! you have loaded package caption after bidi package. Please load package caption before bidi package, and then try to run xelatex on your document again}{}]{caption} + \fi% \if@bidi@colorloaded@\else \@ifpackageloaded{hyperref}{}{% \bidi@isloaded[\PackageError{bidi}{Oops! you have loaded package color after bidi package. Please load package color before bidi package, and then try to run xelatex on your document again}{}]{color}} @@ -103,6 +109,9 @@ \if@bidi@pstricksloaded@\else \bidi@isloaded[\PackageError{bidi}{Oops! you have loaded package pstricks after bidi package. Please load package pstricks before bidi package, and then try to run xelatex on your document again}{}]{pstricks} \fi% + \if@bidi@pgfloaded@\else + \bidi@isloaded[\PackageError{bidi}{Oops! you have loaded package pgf after bidi package. Please load package pgf before bidi package, and then try to run xelatex on your document again}{}]{pgf} + \fi% \if@bidi@tikzloaded@\else \bidi@isloaded[\PackageError{bidi}{Oops! you have loaded package tikz after bidi package. Please load package tikz before bidi package, and then try to run xelatex on your document again}{}]{tikz} \fi% @@ -112,6 +121,9 @@ \if@bidi@stabularloaded@\else \bidi@isloaded[\PackageError{bidi}{Oops! you have loaded package stabular after bidi package. Please load package stabular before bidi package, and then try to run xelatex on your document again}{}]{stabular} \fi% + \if@bidi@subfigureloaded@\else + \bidi@isloaded[\PackageError{bidi}{Oops! you have loaded package subfigure after bidi package. Please load package subfigure before bidi package, and then try to run xelatex on your document again}{}]{subfigure} + \fi% \if@bidi@supertabularloaded@\else \bidi@isloaded[\PackageError{bidi}{Oops! you have loaded package supertabular after bidi package. Please load package supertabular before bidi package, and then try to run xelatex on your document again}{}]{supertabular} \fi% diff --git a/Master/texmf-dist/tex/xelatex/bidi/longtable-bidi.def b/Master/texmf-dist/tex/xelatex/bidi/longtable-bidi.def deleted file mode 100644 index 53d583ecda0..00000000000 --- a/Master/texmf-dist/tex/xelatex/bidi/longtable-bidi.def +++ /dev/null @@ -1,36 +0,0 @@ -%% -%% This is file `longtable-bidi.def', - -%% -%% __________________________________ -%% Copyright © 2009-2010 Vafa Khalighi -%% -%% License information appended. -%% -%% -\ProvidesFile{longtable-bidi.def}[2010/03/01 v0.2 adaptations for longtable package] -\def\LT@makecaption#1#2#3{% - \LT@mcol\LT@cols c{\hbox to\z@{\hss\parbox[t]\LTcapwidth{% - \sbox\@tempboxa{\if@RTL\beginR\fi#1{#2: }#3\if@RTL\endR\fi}% - \ifdim\wd\@tempboxa>\hsize - #1{#2: }#3% - \else - \hbox to\hsize{\hfil\box\@tempboxa\hfil}% - \fi - \endgraf\vskip\baselineskip}% - \hss}}} -%% -%% Copyright © 2009-2010 by Vafa Khalighi -%% -%% Distributable 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 "maintained" (as per LPPL maintenance status) -%% by Vafa Khalighi. -%% -%% -%% -%% -%% -%% End of file `longtable-bidi.def'. diff --git a/Master/texmf-dist/tex/xelatex/bidi/longtable-xetex-bidi.def b/Master/texmf-dist/tex/xelatex/bidi/longtable-xetex-bidi.def new file mode 100644 index 00000000000..fbadba5032e --- /dev/null +++ b/Master/texmf-dist/tex/xelatex/bidi/longtable-xetex-bidi.def @@ -0,0 +1,36 @@ +%% +%% This is file `longtable-xetex-bidi.def', + +%% +%% __________________________________ +%% Copyright © 2009-2010 Vafa Khalighi +%% +%% License information appended. +%% +%% +\ProvidesFile{longtable-xetex-bidi.def}[2010/07/25 v0.1 bidi adaptations for longtable package for XeTeX engine] +\def\LT@makecaption#1#2#3{% + \LT@mcol\LT@cols c{\hbox to\z@{\hss\parbox[t]\LTcapwidth{% + \sbox\@tempboxa{\if@RTL\beginR\fi#1{#2: }#3\if@RTL\endR\fi}% + \ifdim\wd\@tempboxa>\hsize + #1{#2: }#3% + \else + \hbox to\hsize{\hfil\box\@tempboxa\hfil}% + \fi + \endgraf\vskip\baselineskip}% + \hss}}} +%% +%% Copyright © 2009-2010 by Vafa Khalighi +%% +%% Distributable 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 "maintained" (as per LPPL maintenance status) +%% by Vafa Khalighi. +%% +%% +%% +%% +%% +%% End of file `longtable-xetex-bidi.def'. diff --git a/Master/texmf-dist/tex/xelatex/bidi/luatex-bidi.def b/Master/texmf-dist/tex/xelatex/bidi/luatex-bidi.def new file mode 100644 index 00000000000..933132ac794 --- /dev/null +++ b/Master/texmf-dist/tex/xelatex/bidi/luatex-bidi.def @@ -0,0 +1,30 @@ +%% +%% This is file `luatex-bidi.def', + +%% +%% __________________________________ +%% Copyright © 2009-2010 Vafa Khalighi +%% +%% License information appended. +%% +%% +\ProvidesFile{luatex-bidi.def}[2010/07/25 v0.1 bidi adaptations for LuaTeX engine] +\directlua { tex.enableprimitives('',tex.extraprimitives()) } + +\input{footnote-luatex-bidi.def} + +%% +%% Copyright © 2009-2010 by Vafa Khalighi +%% +%% Distributable 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 "maintained" (as per LPPL maintenance status) +%% by Vafa Khalighi. +%% +%% +%% +%% +%% +%% End of file `luatex-bidi.def'. diff --git a/Master/texmf-dist/tex/xelatex/bidi/memoir-bidi.def b/Master/texmf-dist/tex/xelatex/bidi/memoir-bidi.def deleted file mode 100644 index 0f92a04494d..00000000000 --- a/Master/texmf-dist/tex/xelatex/bidi/memoir-bidi.def +++ /dev/null @@ -1,80 +0,0 @@ -%% -%% This is file `memoir-bidi.def', - -%% -%% __________________________________ -%% Copyright © 2009-2010 Vafa Khalighi -%% -%% License information appended. -%% -%% -\ProvidesFile{memoir-bidi.def}[2010/03/01 v0.2 adaptations for memoir class] -\renewcommand{\keepthetitle}{% - \@bsmtitlempty - \global\let\thanks\relax - \global\let\LTRthanks\relax - \global\let\RTLthanks\relax - \global\let\and\relax - \global\let\andnext\relax - \global\let\@thanks\@empty - \global\let\@title\@empty - \global\let\@author\@empty - \global\let\@date\@empty} -\renewcommand{\maketitle}{\par - \begingroup - \@bsmarkseries - \def\@makefnmark{\@textsuperscript{% - \normalfont\@bsthanksheadpre \tamark \@bsthanksheadpost}}% - \long\def\@makefntext##1{\makethanksmark ##1} - \if@twocolumn - \ifnum \col@number=\@ne - \@maketitle - \else - \twocolumn[\@maketitle]% - \fi - \else - \ifdim\pagetotal>\z@ - \newpage - \fi - \global\@topnum\z@ - \@maketitle - \fi - \thispagestyle{title}\@thanks - \endgroup - \@bscontmark % \setcounter{footnote}{0}% - } -\renewcommand*{\memRTLleftskip}{\if@RTL\rightskip\else\leftskip\fi} -\renewcommand*{\memRTLrightskip}{\if@RTL\leftskip\else\rightskip\fi} -\renewcommand*{\memRTLvleftskip}{\if@RTL\vrightskip\else\vleftskip\fi} -\renewcommand*{\memRTLvrightskip}{\if@RTL\vleftskip\else\vrightskip\fi} -\renewcommand*{\memRTLraggedright}{\if@RTL\raggedleft\else\raggedright\fi} -\renewcommand*{\memRTLraggedleft}{\if@RTL\raggedright\else\raggedleft\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{\setthesection}{\thechapter\@SepMark\Alph{section}} -\renewcommand{\theequation}{% - \ifnum \c@chapter>\z@ \thechapter\@SepMark\fi \@arabic\c@equation} -\renewcommand{\thefigure}{\thechapter\@SepMark\@arabic\c@figure} -\renewcommand{\thetable}{\thechapter\@SepMark\@arabic\c@table} -%% -%% Copyright © 2009-2010 by Vafa Khalighi -%% -%% Distributable 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 "maintained" (as per LPPL maintenance status) -%% by Vafa Khalighi. -%% -%% -%% -%% -%% -%% End of file `memoir-bidi.def'. diff --git a/Master/texmf-dist/tex/xelatex/bidi/memoir-xetex-bidi.def b/Master/texmf-dist/tex/xelatex/bidi/memoir-xetex-bidi.def new file mode 100644 index 00000000000..2286747db37 --- /dev/null +++ b/Master/texmf-dist/tex/xelatex/bidi/memoir-xetex-bidi.def @@ -0,0 +1,177 @@ +%% +%% This is file `memoir-xetex-bidi.def', + +%% +%% __________________________________ +%% Copyright © 2009-2010 Vafa Khalighi +%% +%% License information appended. +%% +%% +\ProvidesFile{memoir-xetex-bidi.def}[2010/07/25 v0.4 bidi adaptations for memoir class for XeTeX engine] +\renewcommand{\keepthetitle}{% + \@bsmtitlempty + \global\let\thanks\relax + \global\let\LTRthanks\relax + \global\let\RTLthanks\relax + \global\let\and\relax + \global\let\andnext\relax + \global\let\@thanks\@empty + \global\let\@title\@empty + \global\let\@author\@empty + \global\let\@date\@empty} +\renewcommand{\maketitle}{\par + \begingroup + \@bsmarkseries + \def\@makefnmark{\@textsuperscript{% + \normalfont\@bsthanksheadpre \tamark \@bsthanksheadpost}}% + \long\def\@makefntext##1{\makethanksmark ##1} + \if@twocolumn + \ifnum \col@number=\@ne + \@maketitle + \else + \twocolumn[\@maketitle]% + \fi + \else + \ifdim\pagetotal>\z@ + \newpage + \fi + \global\@topnum\z@ + \@maketitle + \fi + \thispagestyle{title}\@thanks + \endgroup + \@bscontmark % \setcounter{footnote}{0}% + } +\renewcommand*{\memRTLleftskip}{\if@RTL\rightskip\else\leftskip\fi} +\renewcommand*{\memRTLrightskip}{\if@RTL\leftskip\else\rightskip\fi} +\renewcommand*{\memRTLvleftskip}{\if@RTL\vrightskip\else\vleftskip\fi} +\renewcommand*{\memRTLvrightskip}{\if@RTL\vleftskip\else\vrightskip\fi} +\renewcommand*{\memRTLraggedright}{\if@RTL\raggedleft\else\raggedright\fi} +\renewcommand*{\memRTLraggedleft}{\if@RTL\raggedright\else\raggedleft\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{\setthesection}{\thechapter\@SepMark\Alph{section}} +\renewcommand{\theequation}{% + \ifnum \c@chapter>\z@ \thechapter\@SepMark\fi \@arabic\c@equation} +\renewcommand{\thefigure}{\thechapter\@SepMark\@arabic\c@figure} +\renewcommand{\thetable}{\thechapter\@SepMark\@arabic\c@table} +\ifartopt + \chapterstyle{article} + \counterwithout{figure}{chapter} + \counterwithout{table}{chapter} + \counterwithout{footnote}{chapter} + \counterwithout{equation}{chapter} + \renewcommand{\chaptername}{} + \renewcommand{\maketitlehookb}{% + \vskip -1.5\topsep\vskip -1.5\partopsep} + \renewcommand{\maketitlehookc}{% + \vskip -1.5\topsep\vskip -1.5\partopsep} +\fi +\long\def\@makecaption#1#2{\let\@memtempa\relax + \ifdim\prevdepth>-99\p@ \vskip\abovecaptionskip + \else \def\@memtempa{\vbox to\topskip{}}\fi + \let\@contfnote\footnote \renewcommand{\footnote}[2][]{} + \let\@contfmark\footnotemark \renewcommand{\footnotemark}[1][]{} + \sbox\@tempboxa{\@contnfont #1\@contdelim \@conttfont #2\@contfinal} + \let\footnote\@contfnote + \let\footnotemark\@contfmark + \ifdim\wd\@tempboxa<\linewidth \centering \fi + \if@contcw + \centering + \parbox{\@contcwidth}{% + \ifdim\wd\@tempboxa<\@contcwidth \centering \fi + \fi + \ifdim\wd\@tempboxa<\linewidth + \@contpre + {\@contnfont #1\@contdelim}\@memtempa + {\@contcshortstyle \@conttfont #2\@contfinal\par} + \else + \if@conthang + \sbox\@tempboxa{\@contnfont #1\@contdelim} + \@contpre% + {\@contcstyle\hangindent=\wd\@tempboxa + \noindent\box\@tempboxa\@memtempa \@conttfont #2\@contfinal\par} + \else + \if@contindent + \@contpre% + {\@contnfont #1\@contdelim}\@memtempa + {\@contcstyle\hangindent=\@contindw + \hangafter=\@ne\@conttfont #2\@contfinal\par}% <- v1.4 + \else + \@contpre% + {\@contnfont #1\@contdelim}\@memtempa + {\@contcstyle \@conttfont #2\@contfinal\par} + \fi + \fi + \fi + \@contpost + \if@contcw + \par + } % end of the \parbox + \fi + \vskip\belowcaptionskip} +\@ifpackageloaded{caption}{% +\AtBeginPackage{caption}{ +\ClassWarningNoLine{memoir}{% + You are using the caption package with the memoir \MessageBreak + class. This may cause unexpected or inconsistent \MessageBreak + results if you use any of memoir's captioning facilities} + +\long\def\@makecaption##1##2{% + \vskip\abovecaptionskip + \sbox\@tempboxa{\if@RTL\beginR\fi##1: ##2\if@RTL\endR\fi}% + \ifdim \wd\@tempboxa >\hsize + \if@RTL\beginR\fi##1: ##2\if@RTL\endR\fi\par + \else + \global \@minipagefalse + \hb@xt@\hsize{\hfil\box\@tempboxa\hfil}% + \fi + \vskip\belowcaptionskip} + +\def\caption{% + \ifx\@captype\@undefined + \@latex@error{\noexpand\caption outside float}\@ehd + \expandafter\@gobble + \else + \refstepcounter\@captype + \expandafter\@firstofone + \fi + {\@dblarg{\@caption\@captype}}% +} + +\long\def\@caption##1[##2]##3{% + \par + \addcontentsline{\csname ext@##1\endcsname}{##1}% + {\protect\numberline{\csname the##1\endcsname}{\ignorespaces ##2}}% + \begingroup + \@parboxrestore + \if@minipage + \@setminipage + \fi + \normalsize + \@makecaption{\csname fnum@##1\endcsname}{\ignorespaces ##3}\par + \endgroup} +}}{} +%% +%% Copyright © 2009-2010 by Vafa Khalighi +%% +%% Distributable 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 "maintained" (as per LPPL maintenance status) +%% by Vafa Khalighi. +%% +%% +%% +%% +%% +%% End of file `memoir-xetex-bidi.def'. diff --git a/Master/texmf-dist/tex/xelatex/bidi/minitoc-bidi.def b/Master/texmf-dist/tex/xelatex/bidi/minitoc-bidi.def deleted file mode 100644 index 4713bc7d33f..00000000000 --- a/Master/texmf-dist/tex/xelatex/bidi/minitoc-bidi.def +++ /dev/null @@ -1,63 +0,0 @@ -%% -%% This is file `minitoc-bidi.def', - -%% -%% __________________________________ -%% Copyright © 2009-2010 Vafa Khalighi -%% -%% License information appended. -%% -%% -\ProvidesFile{minitoc-bidi.def}[2010/03/01 v0.1 adaptations for minitoc package] -\def\@undottedtocline#1#2#3#4#5{% - \ifnum #1>\c@tocdepth\relax \else - \vskip \z@ plus.2\p@ - {\if@RTL\rightskip\else\leftskip\fi #2\relax \if@RTL\leftskip\else\rightskip\fi \@tocrmarg \parfillskip -\if@RTL\leftskip\else\rightskip\fi - \parindent #2\relax\@afterindenttrue - \interlinepenalty\@M - \leavevmode - \@tempdima #3\relax \advance\if@RTL\rightskip\else\leftskip\fi \@tempdima \hbox{}% - \hskip -\if@RTL\rightskip\else\leftskip\fi - #4\nobreak\hfill \nobreak - \null\par}% - \fi} -\def\@Undottedtocline#1#2#3#4#5{% - \ifnum #1>\c@tocdepth\relax \else - \vskip \z@ \@plus.2\p@ - {\if@RTL\rightskip\else\leftskip\fi #2\relax \if@RTL\leftskip\else\rightskip\fi \@tocrmarg \parfillskip -\if@RTL\leftskip\else\rightskip\fi - \parindent #2\relax\@afterindenttrue - \interlinepenalty\@M - \leavevmode - \@tempdima #3\relax - \advance\if@RTL\rightskip\else\leftskip\fi \@tempdima \null\nobreak\hskip -\if@RTL\rightskip\else\leftskip\fi - {\coffeefont #4}\nobreak \nobreak\null - \par}% - \fi} -\def\@Undottedtoclinep#1#2#3#4#5{% - \ifnum #1>\c@tocdepth\relax \else - \vskip \z@ \@plus.2\p@ - {\if@RTL\rightskip\else\leftskip\fi #2\relax \if@RTL\leftskip\else\rightskip\fi \@tocrmarg \parfillskip -\if@RTL\leftskip\else\rightskip\fi - \parindent #2\relax\@afterindenttrue - \interlinepenalty\@M - \leavevmode - \@tempdima #3\relax - \advance\if@RTL\rightskip\else\leftskip\fi \@tempdima \null\nobreak\hskip -\if@RTL\rightskip\else\leftskip\fi - {#4}\nobreak \hfill \nobreak\null - \hb@xt@\@pnumwidth{\hfil\normalfont \normalcolor #5}% - \par}% - \fi} -%% -%% Copyright © 2009-2010 by Vafa Khalighi -%% -%% Distributable 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 "maintained" (as per LPPL maintenance status) -%% by Vafa Khalighi. -%% -%% -%% -%% -%% -%% End of file `minitoc-bidi.def'. diff --git a/Master/texmf-dist/tex/xelatex/bidi/minitoc-xetex-bidi.def b/Master/texmf-dist/tex/xelatex/bidi/minitoc-xetex-bidi.def new file mode 100644 index 00000000000..2940b4355f2 --- /dev/null +++ b/Master/texmf-dist/tex/xelatex/bidi/minitoc-xetex-bidi.def @@ -0,0 +1,63 @@ +%% +%% This is file `minitoc-xetex-bidi.def', + +%% +%% __________________________________ +%% Copyright © 2009-2010 Vafa Khalighi +%% +%% License information appended. +%% +%% +\ProvidesFile{minitoc-xetex-bidi.def}[2010/07/25 v0.1 bidi adaptations for minitoc package for XeTeX engine] +\def\@undottedtocline#1#2#3#4#5{% + \ifnum #1>\c@tocdepth\relax \else + \vskip \z@ plus.2\p@ + {\if@RTL\rightskip\else\leftskip\fi #2\relax \if@RTL\leftskip\else\rightskip\fi \@tocrmarg \parfillskip -\if@RTL\leftskip\else\rightskip\fi + \parindent #2\relax\@afterindenttrue + \interlinepenalty\@M + \leavevmode + \@tempdima #3\relax \advance\if@RTL\rightskip\else\leftskip\fi \@tempdima \hbox{}% + \hskip -\if@RTL\rightskip\else\leftskip\fi + #4\nobreak\hfill \nobreak + \null\par}% + \fi} +\def\@Undottedtocline#1#2#3#4#5{% + \ifnum #1>\c@tocdepth\relax \else + \vskip \z@ \@plus.2\p@ + {\if@RTL\rightskip\else\leftskip\fi #2\relax \if@RTL\leftskip\else\rightskip\fi \@tocrmarg \parfillskip -\if@RTL\leftskip\else\rightskip\fi + \parindent #2\relax\@afterindenttrue + \interlinepenalty\@M + \leavevmode + \@tempdima #3\relax + \advance\if@RTL\rightskip\else\leftskip\fi \@tempdima \null\nobreak\hskip -\if@RTL\rightskip\else\leftskip\fi + {\coffeefont #4}\nobreak \nobreak\null + \par}% + \fi} +\def\@Undottedtoclinep#1#2#3#4#5{% + \ifnum #1>\c@tocdepth\relax \else + \vskip \z@ \@plus.2\p@ + {\if@RTL\rightskip\else\leftskip\fi #2\relax \if@RTL\leftskip\else\rightskip\fi \@tocrmarg \parfillskip -\if@RTL\leftskip\else\rightskip\fi + \parindent #2\relax\@afterindenttrue + \interlinepenalty\@M + \leavevmode + \@tempdima #3\relax + \advance\if@RTL\rightskip\else\leftskip\fi \@tempdima \null\nobreak\hskip -\if@RTL\rightskip\else\leftskip\fi + {#4}\nobreak \hfill \nobreak\null + \hb@xt@\@pnumwidth{\hfil\normalfont \normalcolor #5}% + \par}% + \fi} +%% +%% Copyright © 2009-2010 by Vafa Khalighi +%% +%% Distributable 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 "maintained" (as per LPPL maintenance status) +%% by Vafa Khalighi. +%% +%% +%% +%% +%% +%% End of file `minitoc-xetex-bidi.def'. diff --git a/Master/texmf-dist/tex/xelatex/bidi/multicol-bidi.def b/Master/texmf-dist/tex/xelatex/bidi/multicol-bidi.def deleted file mode 100644 index 2d0545b0b53..00000000000 --- a/Master/texmf-dist/tex/xelatex/bidi/multicol-bidi.def +++ /dev/null @@ -1,171 +0,0 @@ -%% -%% This is file `multicol-bidi.def', - -%% -%% __________________________________ -%% Copyright © 2009-2010 Vafa Khalighi -%% -%% License information appended. -%% -%% -\ProvidesFile{multicol-bidi.def}[2010/03/01 v0.1 adaptations for multicol package] -\def\revprocess@cols#1#2{\count@\doublecol@number\relax -\advance\count@ by -2 - \loop #2% - \ifnum\count@>#1\relax - \advance\count@-\tw@ - \repeat} -\def\page@sofar{% - \process@cols\mult@rightbox - {\ifvoid\count@ - \setbox\count@\hbox to\hsize{}% - \else - \wd\count@\hsize - \fi}% - \count@\col@number \advance\count@\m@ne - \mult@info\z@ - {Column spec: \the\full@width\space = indent - + columns + sep =\MessageBreak - \the\multicol@leftmargin\space - + \the\col@number\space - x \the\hsize\space - + \the\count@\space - x \the\columnsep - }% -\ifvmode\else\errmessage{Multicol Error}\fi - \nointerlineskip - \setbox\z@\hbox{p}\global\dimen\tw@\dp\z@ - \moveright\multicol@leftmargin - \if@RTL\hbox to\full@width{% - \ifdim\dp\mult@rightbox>\dimen\tw@ - \global\dimen\tw@\dp\mult@rightbox \fi - \box\mult@rightbox - \llap{\phantom p}% - \revprocess@cols\mult@gfirstbox{% - \ifdim\dp\count@>\dimen\tw@ - \global\dimen\tw@\dp\count@ \fi - \hss{\columnseprulecolor\vrule - \@width\columnseprule}\hss\box\count@}% -}\else% - \hbox to\full@width{% - \process@cols\mult@gfirstbox{% - \ifdim\dp\count@>\dimen\tw@ - \global\dimen\tw@\dp\count@ \fi - \box\count@ - \hss{\columnseprulecolor\vrule - \@width\columnseprule}\hss}% - \ifdim\dp\mult@rightbox>\dimen\tw@ - \global\dimen\tw@\dp\mult@rightbox \fi - \box\mult@rightbox - \rlap{\phantom p}% - }\fi% - \kern-\dimen\tw@ - \ifdim\dimen\tw@ = \mc@gridwarn - \PackageWarning{multicol}% - {Very deep columns!\MessageBreak - Grid alignment might be broken}% - \fi -} -\def\right@footnote{% - \hbox to \textwidth - {\beginR \vbox{\kern -3\p@ - \hrule width .4\columnwidth \kern2.6\p@}\hfil\endR}} -\long\def\@footnotetext#1{% - \begingroup - \setbox\footins - \vbox{\if@RTL@footnote\@RTLtrue\else\@RTLfalse\fi\reset@font\footnotesize - \interlinepenalty\interfootnotelinepenalty - \splittopskip\footnotesep - \splitmaxdepth \dp\strutbox \floatingpenalty \@MM - \hsize\textwidth \@parboxrestore - \bidi@footnotetext@dir{#1}% - \protected@edef\@currentlabel{\csname p@footnote\endcsname\@thefnmark}\@makefntext - {\rule{\z@}{\footnotesep}\ignorespaces\if@RTL@footnote#1\else\rmfamily#1\fi\strut}}% - \bidi@footnotetext@after - \insert\footins{\unvbox\footins}% - \endgroup} -\long\def\@RTLfootnotetext#1{% - \begingroup - \setbox\footins - \vbox{\@RTLtrue\reset@font\footnotesize - \interlinepenalty\interfootnotelinepenalty - \splittopskip\footnotesep - \splitmaxdepth \dp\strutbox \floatingpenalty \@MM - \hsize\textwidth \@parboxrestore - \bidi@footnotetext@dir{#1}% - \protected@edef\@currentlabel{\csname p@footnote\endcsname\@thefnmark}\@makefntext - {\rule{\z@}{\footnotesep}\ignorespaces #1\strut}}% - \bidi@footnotetext@after - \insert\footins{\unvbox\footins}% - \endgroup} -\long\def\@LTRfootnotetext#1{% - \begingroup - \setbox\footins - \vbox{\@RTLfalse\reset@font\footnotesize - \interlinepenalty\interfootnotelinepenalty - \splittopskip\footnotesep - \splitmaxdepth \dp\strutbox \floatingpenalty \@MM - \hsize\textwidth \@parboxrestore - \bidi@footnotetext@dir{#1}% - \protected@edef\@currentlabel{\csname p@footnote\endcsname\@thefnmark}\@makefntext - {\rule{\z@}{\footnotesep}\ignorespaces\rmfamily #1\strut}}% - \bidi@footnotetext@after - \insert\footins{\unvbox\footins}% - \endgroup} -\long\def\@mpRTLfootnotetext#1{% - \global\setbox\@mpfootins\vbox{\@RTLtrue% - \unvbox\@mpfootins - \reset@font\footnotesize - \hsize\textwidth - \@parboxrestore - \protected@edef\@currentlabel - {\csname p@mpfootnote\endcsname\@thefnmark}% - \color@begingroup - \bidi@footnotetext@dir{#1} - \ifnum\c@mpfootnote=1\if@RTL\global\let\bidi@footnoterule\right@footnote\else\global\let\bidi@footnoterule\left@footnote\fi\fi - \@makefntext{% - \rule\z@\footnotesep\ignorespaces#1\@finalstrut\strutbox}% - \color@endgroup}} -\long\def\@mpLTRfootnotetext#1{% - \global\setbox\@mpfootins\vbox{\@RTLfalse% - \unvbox\@mpfootins - \reset@font\footnotesize - \hsize\textwidth - \@parboxrestore - \protected@edef\@currentlabel - {\csname p@mpfootnote\endcsname\@thefnmark}% - \color@begingroup - \bidi@footnotetext@dir{#1} - \ifnum\c@mpfootnote=1\if@RTL\global\let\bidi@footnoterule\right@footnote\else\global\let\bidi@footnoterule\left@footnote\fi\fi - \@makefntext{% - \rule\z@\footnotesep\ignorespaces\rmfamily#1\@finalstrut\strutbox}% - \color@endgroup}} -\long\def\@mpfootnotetext#1{% - \global\setbox\@mpfootins\vbox{\if@RTL@footnote\@RTLtrue\else\@RTLfalse\fi% - \unvbox\@mpfootins - \reset@font\footnotesize - \hsize\textwidth - \@parboxrestore - \protected@edef\@currentlabel - {\csname p@mpfootnote\endcsname\@thefnmark}% - \color@begingroup - \bidi@footnotetext@dir{#1} - \ifnum\c@mpfootnote=1\if@RTL\global\let\bidi@footnoterule\right@footnote\else\global\let\bidi@footnoterule\left@footnote\fi\fi - \@makefntext{% - \rule\z@\footnotesep\ignorespaces\if@RTL@footnote#1\else\rmfamily#1\fi\@finalstrut\strutbox}% - \color@endgroup}} -%% -%% Copyright © 2009-2010 by Vafa Khalighi -%% -%% Distributable 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 "maintained" (as per LPPL maintenance status) -%% by Vafa Khalighi. -%% -%% -%% -%% -%% -%% End of file `multicol-bidi.def'. diff --git a/Master/texmf-dist/tex/xelatex/bidi/multicol-xetex-bidi.def b/Master/texmf-dist/tex/xelatex/bidi/multicol-xetex-bidi.def new file mode 100644 index 00000000000..b8bd151746f --- /dev/null +++ b/Master/texmf-dist/tex/xelatex/bidi/multicol-xetex-bidi.def @@ -0,0 +1,171 @@ +%% +%% This is file `multicol-xetex-bidi.def', + +%% +%% __________________________________ +%% Copyright © 2009-2010 Vafa Khalighi +%% +%% License information appended. +%% +%% +\ProvidesFile{multicol-xetex-bidi.def}[2010/07/25 v0.1 bidi adaptations for multicol package for XeTeX engine] +\def\revprocess@cols#1#2{\count@\doublecol@number\relax +\advance\count@ by -2 + \loop #2% + \ifnum\count@>#1\relax + \advance\count@-\tw@ + \repeat} +\def\page@sofar{% + \process@cols\mult@rightbox + {\ifvoid\count@ + \setbox\count@\hbox to\hsize{}% + \else + \wd\count@\hsize + \fi}% + \count@\col@number \advance\count@\m@ne + \mult@info\z@ + {Column spec: \the\full@width\space = indent + + columns + sep =\MessageBreak + \the\multicol@leftmargin\space + + \the\col@number\space + x \the\hsize\space + + \the\count@\space + x \the\columnsep + }% +\ifvmode\else\errmessage{Multicol Error}\fi + \nointerlineskip + \setbox\z@\hbox{p}\global\dimen\tw@\dp\z@ + \moveright\multicol@leftmargin + \if@RTL\hbox to\full@width{% + \ifdim\dp\mult@rightbox>\dimen\tw@ + \global\dimen\tw@\dp\mult@rightbox \fi + \box\mult@rightbox + \llap{\phantom p}% + \revprocess@cols\mult@gfirstbox{% + \ifdim\dp\count@>\dimen\tw@ + \global\dimen\tw@\dp\count@ \fi + \hss{\columnseprulecolor\vrule + \@width\columnseprule}\hss\box\count@}% +}\else% + \hbox to\full@width{% + \process@cols\mult@gfirstbox{% + \ifdim\dp\count@>\dimen\tw@ + \global\dimen\tw@\dp\count@ \fi + \box\count@ + \hss{\columnseprulecolor\vrule + \@width\columnseprule}\hss}% + \ifdim\dp\mult@rightbox>\dimen\tw@ + \global\dimen\tw@\dp\mult@rightbox \fi + \box\mult@rightbox + \rlap{\phantom p}% + }\fi% + \kern-\dimen\tw@ + \ifdim\dimen\tw@ = \mc@gridwarn + \PackageWarning{multicol}% + {Very deep columns!\MessageBreak + Grid alignment might be broken}% + \fi +} +\def\right@footnote{% + \hbox to \textwidth + {\beginR \vbox{\kern -3\p@ + \hrule width .4\columnwidth \kern2.6\p@}\hfil\endR}} +\long\def\@footnotetext#1{% + \begingroup + \setbox\footins + \vbox{\if@RTL@footnote\@RTLtrue\else\@RTLfalse\fi\reset@font\footnotesize + \interlinepenalty\interfootnotelinepenalty + \splittopskip\footnotesep + \splitmaxdepth \dp\strutbox \floatingpenalty \@MM + \hsize\textwidth \@parboxrestore + \bidi@footnotetext@dir{#1}% + \protected@edef\@currentlabel{\csname p@footnote\endcsname\@thefnmark}\@makefntext + {\rule{\z@}{\footnotesep}\ignorespaces\if@RTL@footnote#1\else\rmfamily#1\fi\strut}}% + \bidi@footnotetext@after + \insert\footins{\unvbox\footins}% + \endgroup} +\long\def\@RTLfootnotetext#1{% + \begingroup + \setbox\footins + \vbox{\@RTLtrue\reset@font\footnotesize + \interlinepenalty\interfootnotelinepenalty + \splittopskip\footnotesep + \splitmaxdepth \dp\strutbox \floatingpenalty \@MM + \hsize\textwidth \@parboxrestore + \bidi@footnotetext@dir{#1}% + \protected@edef\@currentlabel{\csname p@footnote\endcsname\@thefnmark}\@makefntext + {\rule{\z@}{\footnotesep}\ignorespaces #1\strut}}% + \bidi@footnotetext@after + \insert\footins{\unvbox\footins}% + \endgroup} +\long\def\@LTRfootnotetext#1{% + \begingroup + \setbox\footins + \vbox{\@RTLfalse\reset@font\footnotesize + \interlinepenalty\interfootnotelinepenalty + \splittopskip\footnotesep + \splitmaxdepth \dp\strutbox \floatingpenalty \@MM + \hsize\textwidth \@parboxrestore + \bidi@footnotetext@dir{#1}% + \protected@edef\@currentlabel{\csname p@footnote\endcsname\@thefnmark}\@makefntext + {\rule{\z@}{\footnotesep}\ignorespaces\rmfamily #1\strut}}% + \bidi@footnotetext@after + \insert\footins{\unvbox\footins}% + \endgroup} +\long\def\@mpRTLfootnotetext#1{% + \global\setbox\@mpfootins\vbox{\@RTLtrue% + \unvbox\@mpfootins + \reset@font\footnotesize + \hsize\textwidth + \@parboxrestore + \protected@edef\@currentlabel + {\csname p@mpfootnote\endcsname\@thefnmark}% + \color@begingroup + \bidi@footnotetext@dir{#1} + \ifnum\c@mpfootnote=1\if@RTL\global\let\bidi@footnoterule\right@footnote\else\global\let\bidi@footnoterule\left@footnote\fi\fi + \@makefntext{% + \rule\z@\footnotesep\ignorespaces#1\@finalstrut\strutbox}% + \color@endgroup}} +\long\def\@mpLTRfootnotetext#1{% + \global\setbox\@mpfootins\vbox{\@RTLfalse% + \unvbox\@mpfootins + \reset@font\footnotesize + \hsize\textwidth + \@parboxrestore + \protected@edef\@currentlabel + {\csname p@mpfootnote\endcsname\@thefnmark}% + \color@begingroup + \bidi@footnotetext@dir{#1} + \ifnum\c@mpfootnote=1\if@RTL\global\let\bidi@footnoterule\right@footnote\else\global\let\bidi@footnoterule\left@footnote\fi\fi + \@makefntext{% + \rule\z@\footnotesep\ignorespaces\rmfamily#1\@finalstrut\strutbox}% + \color@endgroup}} +\long\def\@mpfootnotetext#1{% + \global\setbox\@mpfootins\vbox{\if@RTL@footnote\@RTLtrue\else\@RTLfalse\fi% + \unvbox\@mpfootins + \reset@font\footnotesize + \hsize\textwidth + \@parboxrestore + \protected@edef\@currentlabel + {\csname p@mpfootnote\endcsname\@thefnmark}% + \color@begingroup + \bidi@footnotetext@dir{#1} + \ifnum\c@mpfootnote=1\if@RTL\global\let\bidi@footnoterule\right@footnote\else\global\let\bidi@footnoterule\left@footnote\fi\fi + \@makefntext{% + \rule\z@\footnotesep\ignorespaces\if@RTL@footnote#1\else\rmfamily#1\fi\@finalstrut\strutbox}% + \color@endgroup}} +%% +%% Copyright © 2009-2010 by Vafa Khalighi +%% +%% Distributable 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 "maintained" (as per LPPL maintenance status) +%% by Vafa Khalighi. +%% +%% +%% +%% +%% +%% End of file `multicol-xetex-bidi.def'. diff --git a/Master/texmf-dist/tex/xelatex/bidi/pdfpages-bidi.def b/Master/texmf-dist/tex/xelatex/bidi/pdfpages-bidi.def deleted file mode 100644 index ed17f193b6a..00000000000 --- a/Master/texmf-dist/tex/xelatex/bidi/pdfpages-bidi.def +++ /dev/null @@ -1,73 +0,0 @@ -%% -%% This is file `pdfpages-bidi.def', - -%% -%% __________________________________ -%% Copyright © 2009-2010 Vafa Khalighi -%% -%% License information appended. -%% -%% -\ProvidesFile{pdfpages-bidi.def}[2010/03/01 v0.1 adaptations for pdfpages package] -\renewcommand*{\includepdf}[2][]{% - \begingroup - \@RTLfalse - \let\AM@threadname\relax - \AM@split@options{pdfpages}{#1}% - \edef\AM@temp{{pdfpages}{\the\@temptokena}}% - \expandafter\setkeys\AM@temp - \ifthenelse{\boolean{AM@pkg@draft} \and \boolean{AM@survey}}{% - \let\AM@currentdocname\relax - \renewcommand\includegraphics[2][]{Survey in draft-mode}% - \def\AM@pagecount{0}% - }{% - \AM@findfile{#2}% - \if\AM@threadname\relax - \def\AM@threadname{\AM@currentdocname}% - \fi - }% - \ifAM@survey - \def\AM@pagestemp{}% - \@tempcnta=0 - \def\foo{% - \@ifundefined{r@\AM@xrprefix pdfpages@page\the\@tempcnta}% - {\let\foo\relax} - {\expandafter\ifx\expandafter\\\AM@pagestemp\\ - \edef\AM@pagestemp{% - \AM@pageref{\AM@xrprefix pdfpages@page\the\@tempcnta}}% - \else - \edef\AM@pagestemp{\AM@pagestemp,% - \AM@pageref{\AM@xrprefix pdfpages@page\the\@tempcnta}}% - \fi - \advance\@tempcnta 1\relax - }% - \foo - }% - \foo - \expandafter\ifx\expandafter\\\AM@pagestemp\\ - \def\AM@pagestemp{1}% - \fi - \fi - \ifAM@output - \expandafter\AM@readlist\expandafter{\AM@pagestemp}% - \AM@output{#1}% - \fi - \AM@CheckAtEnd - \endgroup - \AM@ClearShipoutPicture -} -%% -%% Copyright © 2009-2010 by Vafa Khalighi -%% -%% Distributable 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 "maintained" (as per LPPL maintenance status) -%% by Vafa Khalighi. -%% -%% -%% -%% -%% -%% End of file `pdfpages-bidi.def'. diff --git a/Master/texmf-dist/tex/xelatex/bidi/pdfpages-xetex-bidi.def b/Master/texmf-dist/tex/xelatex/bidi/pdfpages-xetex-bidi.def new file mode 100644 index 00000000000..14f2c086a1c --- /dev/null +++ b/Master/texmf-dist/tex/xelatex/bidi/pdfpages-xetex-bidi.def @@ -0,0 +1,73 @@ +%% +%% This is file `pdfpages-xetex-bidi.def', + +%% +%% __________________________________ +%% Copyright © 2009-2010 Vafa Khalighi +%% +%% License information appended. +%% +%% +\ProvidesFile{pdfpages-xetex-bidi.def}[2010/07/25 v0.1 bidi adaptations for pdfpages package for XeTeX engine] +\renewcommand*{\includepdf}[2][]{% + \begingroup + \@RTLfalse + \let\AM@threadname\relax + \AM@split@options{pdfpages}{#1}% + \edef\AM@temp{{pdfpages}{\the\@temptokena}}% + \expandafter\setkeys\AM@temp + \ifthenelse{\boolean{AM@pkg@draft} \and \boolean{AM@survey}}{% + \let\AM@currentdocname\relax + \renewcommand\includegraphics[2][]{Survey in draft-mode}% + \def\AM@pagecount{0}% + }{% + \AM@findfile{#2}% + \if\AM@threadname\relax + \def\AM@threadname{\AM@currentdocname}% + \fi + }% + \ifAM@survey + \def\AM@pagestemp{}% + \@tempcnta=0 + \def\foo{% + \@ifundefined{r@\AM@xrprefix pdfpages@page\the\@tempcnta}% + {\let\foo\relax} + {\expandafter\ifx\expandafter\\\AM@pagestemp\\ + \edef\AM@pagestemp{% + \AM@pageref{\AM@xrprefix pdfpages@page\the\@tempcnta}}% + \else + \edef\AM@pagestemp{\AM@pagestemp,% + \AM@pageref{\AM@xrprefix pdfpages@page\the\@tempcnta}}% + \fi + \advance\@tempcnta 1\relax + }% + \foo + }% + \foo + \expandafter\ifx\expandafter\\\AM@pagestemp\\ + \def\AM@pagestemp{1}% + \fi + \fi + \ifAM@output + \expandafter\AM@readlist\expandafter{\AM@pagestemp}% + \AM@output{#1}% + \fi + \AM@CheckAtEnd + \endgroup + \AM@ClearShipoutPicture +} +%% +%% Copyright © 2009-2010 by Vafa Khalighi +%% +%% Distributable 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 "maintained" (as per LPPL maintenance status) +%% by Vafa Khalighi. +%% +%% +%% +%% +%% +%% End of file `pdfpages-xetex-bidi.def'. diff --git a/Master/texmf-dist/tex/xelatex/bidi/pgf-xetex-bidi.def b/Master/texmf-dist/tex/xelatex/bidi/pgf-xetex-bidi.def new file mode 100644 index 00000000000..1ec69559b88 --- /dev/null +++ b/Master/texmf-dist/tex/xelatex/bidi/pgf-xetex-bidi.def @@ -0,0 +1,30 @@ +%% +%% This is file `pgf-xetex-bidi.def', + +%% +%% __________________________________ +%% Copyright © 2009-2010 Vafa Khalighi +%% +%% License information appended. +%% +%% +\ProvidesFile{pgf-xetex-bidi.def}[2010/07/25 v0.1 bidi adaptations for pgf package for XeTeX engine] +\let\origin@pgfpicture=\pgfpicture +\let\origin@endpgfpicture=\endpgfpicture +\def\pgfpicture{\ifmmode\else\LTR\fi\origin@pgfpicture} +\def\endpgfpicture{\origin@endpgfpicture\ifmmode\else\endLTR\fi} +%% +%% Copyright © 2009-2010 by Vafa Khalighi +%% +%% Distributable 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 "maintained" (as per LPPL maintenance status) +%% by Vafa Khalighi. +%% +%% +%% +%% +%% +%% End of file `pgf-xetex-bidi.def'. diff --git a/Master/texmf-dist/tex/xelatex/bidi/pstricks-bidi.def b/Master/texmf-dist/tex/xelatex/bidi/pstricks-bidi.def deleted file mode 100644 index 96e9fce73dd..00000000000 --- a/Master/texmf-dist/tex/xelatex/bidi/pstricks-bidi.def +++ /dev/null @@ -1,27 +0,0 @@ -%% -%% This is file `pstricks-bidi.def', - -%% -%% __________________________________ -%% Copyright © 2009-2010 Vafa Khalighi -%% -%% License information appended. -%% -%% -\ProvidesFile{pstricks-bidi.def}[2010/03/01 v0.1 adaptations for pstricks package] -\def\pspicture{\begingroup\@RTLfalse\pst@ifstar\pst@picture}% -%% -%% Copyright © 2009-2010 by Vafa Khalighi -%% -%% Distributable 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 "maintained" (as per LPPL maintenance status) -%% by Vafa Khalighi. -%% -%% -%% -%% -%% -%% End of file `pstricks-bidi.def'. diff --git a/Master/texmf-dist/tex/xelatex/bidi/pstricks-xetex-bidi.def b/Master/texmf-dist/tex/xelatex/bidi/pstricks-xetex-bidi.def new file mode 100644 index 00000000000..b32ba381de0 --- /dev/null +++ b/Master/texmf-dist/tex/xelatex/bidi/pstricks-xetex-bidi.def @@ -0,0 +1,27 @@ +%% +%% This is file `pstricks-xetex-bidi.def', + +%% +%% __________________________________ +%% Copyright © 2009-2010 Vafa Khalighi +%% +%% License information appended. +%% +%% +\ProvidesFile{pstricks-xetex-bidi.def}[2010/07/25 v0.2 bidi adaptations for pstricks package for XeTeX engine] +\def\pspicture{\begingroup\ifmmode\else\@RTLfalse\fi\pst@ifstar\pst@picture}% +%% +%% Copyright © 2009-2010 by Vafa Khalighi +%% +%% Distributable 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 "maintained" (as per LPPL maintenance status) +%% by Vafa Khalighi. +%% +%% +%% +%% +%% +%% End of file `pstricks-xetex-bidi.def'. diff --git a/Master/texmf-dist/tex/xelatex/bidi/ragged2e-bidi.def b/Master/texmf-dist/tex/xelatex/bidi/ragged2e-bidi.def deleted file mode 100644 index 5784b0222d1..00000000000 --- a/Master/texmf-dist/tex/xelatex/bidi/ragged2e-bidi.def +++ /dev/null @@ -1,111 +0,0 @@ -%% -%% This is file `ragged2e-bidi.def', - -%% -%% __________________________________ -%% Copyright © 2009-2010 Vafa Khalighi -%% -%% License information appended. -%% -%% -\ProvidesFile{ragged2e-bidi.def}[2010/03/01 v0.2 adaptations for ragged2e package] -\renewcommand{\Centering}{% - \ifx\\\@raggedtwoe@savedcr - \let\\\@centercr - \fi - \let\@gnewline\@raggedtwoe@gnewline - \if@RTL\rightskip\else\leftskip\fi\CenteringLeftskip - \@rightskip\CenteringRightskip - \if@RTL\leftskip\else\rightskip\fi\@rightskip - \parfillskip\CenteringParfillskip - \parindent\CenteringParindent - \@raggedtwoe@spaceskiptrue - \@raggedtwoe@everyselectfont - } -\renewcommand{\RaggedLeft}{% - \ifx\\\@raggedtwoe@savedcr - \let\\\@centercr - \fi - \let\@gnewline\@raggedtwoe@gnewline - \if@RTL\rightskip\else\leftskip\fi\RaggedLeftLeftskip - \@rightskip\RaggedLeftRightskip - \if@RTL\leftskip\else\rightskip\fi\@rightskip - \parfillskip\RaggedLeftParfillskip - \parindent\RaggedLeftParindent - \@raggedtwoe@spaceskiptrue - \@raggedtwoe@everyselectfont - } -\renewcommand{\RaggedRight}{% - \ifx\\\@raggedtwoe@savedcr - \let\\\@centercr - \fi - \let\@gnewline\@raggedtwoe@gnewline - \if@RTL\rightskip\else\leftskip\fi\RaggedRightLeftskip - \@rightskip\RaggedRightRightskip - \if@RTL\leftskip\else\rightskip\fi\@rightskip - \parfillskip\RaggedRightParfillskip - \parindent\RaggedRightParindent - \@raggedtwoe@spaceskiptrue - \@raggedtwoe@everyselectfont - } -\renewcommand{\justifying}{% - \let\\\@raggedtwoe@savedcr - \let\@gnewline\@raggedtwoe@saved@gnewline - \if@RTL\rightskip\else\leftskip\fi\z@ - \@rightskip\z@ - \if@RTL\leftskip\else\rightskip\fi\@rightskip - \parfillskip\JustifyingParfillskip - \parindent\JustifyingParindent - \@raggedtwoe@spaceskipfalse - \@raggedtwoe@everyselectfont - } -\renewcommand*{\@raggedtwoe@raggedrightboxes@opt}{ - \CheckCommand*{\@arrayparboxrestore}{% - \let\if@nobreak\iffalse - \let\if@noskipsec\iffalse - \let\par\@@par - \let\-\@dischyph - \let\'\@acci\let\`\@accii\let\=\@acciii - \parindent\z@ \parskip\z@skip - \everypar{}% - \linewidth\hsize - \@totalleftmargin\z@ - \if@RTL\rightskip\else\leftskip\fi\z@skip \if@RTL\leftskip\else\rightskip\fi\z@skip \@rightskip\z@skip - \parfillskip\@flushglue \lineskip\normallineskip - \baselineskip\normalbaselineskip - \sloppy}% - \renewcommand{\@arrayparboxrestore}{% - \let\if@nobreak\iffalse - \let\if@noskipsec\iffalse - \let\par\@@par - \let\-\@dischyph - \let\'\@acci\let\`\@accii\let\=\@acciii - \parskip\z@skip - \everypar{}% - \linewidth\hsize - \@totalleftmargin\z@ - \RaggedRight - \lineskip\normallineskip - \baselineskip\normalbaselineskip - \sloppy}% - \let\@raggedtwoe@raggedrightboxes@opt\relax - } -\let\origin@RaggedLeft=\RaggedLeft -\let\origin@RaggedRight=\RaggedRight -\def\RaggedLeft{\if@RTL\origin@RaggedRight\else\origin@RaggedLeft\fi} -\def\RaggedRight{\if@RTL\origin@RaggedLeft\else\origin@RaggedRight\fi} -%% -%% Copyright © 2009-2010 by Vafa Khalighi -%% -%% Distributable 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 "maintained" (as per LPPL maintenance status) -%% by Vafa Khalighi. -%% -%% -%% -%% -%% -%% End of file `ragged2e-bidi.def'. diff --git a/Master/texmf-dist/tex/xelatex/bidi/ragged2e-xetex-bidi.def b/Master/texmf-dist/tex/xelatex/bidi/ragged2e-xetex-bidi.def new file mode 100644 index 00000000000..f24799afeb7 --- /dev/null +++ b/Master/texmf-dist/tex/xelatex/bidi/ragged2e-xetex-bidi.def @@ -0,0 +1,111 @@ +%% +%% This is file `ragged2e-xetex-bidi.def', + +%% +%% __________________________________ +%% Copyright © 2009-2010 Vafa Khalighi +%% +%% License information appended. +%% +%% +\ProvidesFile{ragged2e-xetex-bidi.def}[2010/07/25 v0.2 bidi adaptations for ragged2e package for XeTeX engine] +\renewcommand{\Centering}{% + \ifx\\\@raggedtwoe@savedcr + \let\\\@centercr + \fi + \let\@gnewline\@raggedtwoe@gnewline + \if@RTL\rightskip\else\leftskip\fi\CenteringLeftskip + \@rightskip\CenteringRightskip + \if@RTL\leftskip\else\rightskip\fi\@rightskip + \parfillskip\CenteringParfillskip + \parindent\CenteringParindent + \@raggedtwoe@spaceskiptrue + \@raggedtwoe@everyselectfont + } +\renewcommand{\RaggedLeft}{% + \ifx\\\@raggedtwoe@savedcr + \let\\\@centercr + \fi + \let\@gnewline\@raggedtwoe@gnewline + \if@RTL\rightskip\else\leftskip\fi\RaggedLeftLeftskip + \@rightskip\RaggedLeftRightskip + \if@RTL\leftskip\else\rightskip\fi\@rightskip + \parfillskip\RaggedLeftParfillskip + \parindent\RaggedLeftParindent + \@raggedtwoe@spaceskiptrue + \@raggedtwoe@everyselectfont + } +\renewcommand{\RaggedRight}{% + \ifx\\\@raggedtwoe@savedcr + \let\\\@centercr + \fi + \let\@gnewline\@raggedtwoe@gnewline + \if@RTL\rightskip\else\leftskip\fi\RaggedRightLeftskip + \@rightskip\RaggedRightRightskip + \if@RTL\leftskip\else\rightskip\fi\@rightskip + \parfillskip\RaggedRightParfillskip + \parindent\RaggedRightParindent + \@raggedtwoe@spaceskiptrue + \@raggedtwoe@everyselectfont + } +\renewcommand{\justifying}{% + \let\\\@raggedtwoe@savedcr + \let\@gnewline\@raggedtwoe@saved@gnewline + \if@RTL\rightskip\else\leftskip\fi\z@ + \@rightskip\z@ + \if@RTL\leftskip\else\rightskip\fi\@rightskip + \parfillskip\JustifyingParfillskip + \parindent\JustifyingParindent + \@raggedtwoe@spaceskipfalse + \@raggedtwoe@everyselectfont + } +\renewcommand*{\@raggedtwoe@raggedrightboxes@opt}{ + \CheckCommand*{\@arrayparboxrestore}{% + \let\if@nobreak\iffalse + \let\if@noskipsec\iffalse + \let\par\@@par + \let\-\@dischyph + \let\'\@acci\let\`\@accii\let\=\@acciii + \parindent\z@ \parskip\z@skip + \everypar{}% + \linewidth\hsize + \@totalleftmargin\z@ + \if@RTL\rightskip\else\leftskip\fi\z@skip \if@RTL\leftskip\else\rightskip\fi\z@skip \@rightskip\z@skip + \parfillskip\@flushglue \lineskip\normallineskip + \baselineskip\normalbaselineskip + \sloppy}% + \renewcommand{\@arrayparboxrestore}{% + \let\if@nobreak\iffalse + \let\if@noskipsec\iffalse + \let\par\@@par + \let\-\@dischyph + \let\'\@acci\let\`\@accii\let\=\@acciii + \parskip\z@skip + \everypar{}% + \linewidth\hsize + \@totalleftmargin\z@ + \RaggedRight + \lineskip\normallineskip + \baselineskip\normalbaselineskip + \sloppy}% + \let\@raggedtwoe@raggedrightboxes@opt\relax + } +\let\origin@RaggedLeft=\RaggedLeft +\let\origin@RaggedRight=\RaggedRight +\def\RaggedLeft{\if@RTL\origin@RaggedRight\else\origin@RaggedLeft\fi} +\def\RaggedRight{\if@RTL\origin@RaggedLeft\else\origin@RaggedRight\fi} +%% +%% Copyright © 2009-2010 by Vafa Khalighi +%% +%% Distributable 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 "maintained" (as per LPPL maintenance status) +%% by Vafa Khalighi. +%% +%% +%% +%% +%% +%% End of file `ragged2e-xetex-bidi.def'. diff --git a/Master/texmf-dist/tex/xelatex/bidi/rapport3-bidi.def b/Master/texmf-dist/tex/xelatex/bidi/rapport3-bidi.def deleted file mode 100644 index 24281980dfc..00000000000 --- a/Master/texmf-dist/tex/xelatex/bidi/rapport3-bidi.def +++ /dev/null @@ -1,253 +0,0 @@ -%% -%% This is file `rapport3-bidi.def', - -%% -%% __________________________________ -%% Copyright © 2009-2010 Vafa Khalighi -%% -%% License information appended. -%% -%% -\ProvidesFile{rapport3-bidi.def}[2010/03/01 v0.1 adaptations for rapport3 class] -\if@titlepage -\renewcommand*\TitleFont{\rmfamily} -\renewcommand*\maketitle{% - \begin{titlepage}% - \let\footnotesize\small - \let\footnoterule\relax - \let \footnote \thanks - \let \LTRfootnote \LTRthanks - \let \RTLfootnote \RTLthanks - \long\def\@makefntext##1{\parindent\z@ - \def\labelitemi{\textendash}\@revlabeltrue - \leavevmode\@textsuperscript{\@thefnmark}\kern1em\relax ##1} - \renewcommand*\thefootnote{\@fnsymbol\c@footnote}% - \if@compatibility\setcounter{page}{0}\fi - \null\vfil - \vskip 60\p@ - \begin{center}% - \TitleFont - {\LARGE \def\\{\penalty -\@M} - \if@allcaps - \expandafter\uc@nothanks\@title\thanks\relax - \else - \@title - \fi\par}% - \vskip 3em% - {\large - \lineskip .75em \parindent\z@ - \begin{tabular}[t]{c}% - \if@allcaps - \expandafter\uc@authornothanks\@author\and\relax - \else - \@author - \fi - \end{tabular}\par}% - \vskip 1.5em% - {\large - \if@allcaps - \uppercase\expandafter{\@date}% - \else - \@date - \fi\par}% - \end{center}\par - \@thanks - \vfil\null - \end{titlepage}% - \setcounter{footnote}{0}% - \global\let\thanks\relax - \global\let\LTRthanks\relax - \global\let\RTLthanks\relax - \global\let\maketitle\relax - \global\let\@thanks\@empty - \global\let\@author\@empty - \global\let\@title\@empty - \global\let\@date\@empty - \global\let\title\relax - \global\let\author\relax - \global\let\date\relax - \global\let\and\relax -} -\def\uc@nothanks#1\thanks{\uppercase{#1}\futurelet\@tempa\uc@tx} -\def\uc@authornothanks#1\and{\uc@nothanks#1\thanks\relax - \futurelet\@tempa\uc@ax} -\def\uc@ax{% - \ifx\@tempa\relax - \else - \\ \andname \\ \expandafter\uc@authornothanks - \fi} -\def\uc@tx{\ifx\@tempa\relax - \else \expandafter\uc@ty \fi} -\def\uc@ty#1{\thanks{#1}\uc@nothanks} -\else -\renewcommand*\maketitle{\par - \begingroup - \renewcommand*\thefootnote{\@fnsymbol\c@footnote}% - \def\@makefnmark{\rlap{% - \@textsuperscript{\normalfont\@thefnmark}}}% - \long\def\@makefntext{\@xmakefntext{% - \@textsuperscript{\normalfont\@thefnmark}}}% - \if@twocolumn - \ifnum \col@number=\@ne - \@maketitle - \else - \twocolumn[\@maketitle]% - \fi - \else - \newpage - \global\@topnum\z@ - \@maketitle - \fi - \thispagestyle{plain}\@thanks - \endgroup - \setcounter{footnote}{0}% - \global\let\thanks\relax - \global\let\LTRthanks\relax - \global\let\RTLthanks\relax - \global\let\maketitle\relax - \global\let\@maketitle\relax - \global\let\@thanks\@empty - \global\let\@author\@empty - \global\let\@title\@empty - \global\let\@date\@empty - \global\let\title\relax - \global\let\author\relax - \global\let\date\relax - \global\let\and\relax - } -\def\@maketitle{% - \newpage - \null - \vskip 2em% -\if@titlecentered - \begin{center}% - \let \footnote \thanks - \let \LTRfootnote \LTRthanks - \let \RTLfootnote \RTLthanks - {\LARGE \TitleFont \@title \par}% - \vskip 1.5em% - {\large \TitleFont - \lineskip .5em% - \begin{tabular}[t]{c}% - \@author - \end{tabular}\par}% - \vskip 1em% - {\large \TitleFont \@date}% - \end{center}% - \else - {\LARGE \TitleFont \head@style \@title \par} \vskip 1.5em - {\large \TitleFont \lineskip .5em \tabcolsep\z@ - \def\and{%%% \begin{tabular} has already started - \end{tabular}\hskip 1em plus .17fil - \begin{tabular}[t]{l}}%% \end{tabular} will come - \begin{tabular}[t]{l}\@author\end{tabular}\par} - \vskip 1em {\large \TitleFont \@date} - \fi - \par - \vskip 1.5em} -\fi -\renewcommand*\@regtocline[3]{% - \ifnum #1>\c@tocdepth - \else - \vskip\z@\@plus.2\p@ - {\hangindent\z@ \@afterindenttrue \interlinepenalty\@M - \if@RTL\rightskip\else\leftskip\fi\unitindent - \if@RTL\leftskip\else\rightskip\fi\unitindent\@plus 1fil - \parfillskip\z@ - \@tempdima\unitindent - \parindent\z@ - \leavevmode - \hbox{}\hskip -\if@RTL\rightskip\else\leftskip\fi\relax#2\nobreak - \hskip 1em \nobreak{\slshape #3}\par - }% - \fi} -\if@oldtoc -\renewcommand*\l@part[2]{% - \ifnum \c@tocdepth >-2\relax - \addpenalty{-\@highpenalty}% - \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 - \global\@nobreaktrue - \everypar{\global\@nobreakfalse\everypar{}}% - \endgroup - \fi} -\else - \renewcommand*\l@part{% - \ifnum \c@tocdepth >-2\relax - \addpenalty{-\@highpenalty}% - \addvspace{2.25em \@plus \p@}% - \@regtocline{0}% - \fi} -\fi -\if@oldtoc -\renewcommand*\l@chapter[2]{% - \addpenalty{-\@highpenalty}% - \vskip 1.0em \@plus\p@ - \setlength\@tempdima{1.5em}% - \begingroup - \parindent \z@ \if@RTL\leftskip\else\rightskip\fi \@pnumwidth - \parfillskip -\@pnumwidth - \leavevmode \bfseries - \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} -\else - \renewcommand*\l@chapter{\@regtocline{0}} -\fi -\renewcommand*\head@style{% - \interlinepenalty \@M - \hyphenpenalty=\@M \exhyphenpenalty=\@M - \if@RTL\leftskip\else\rightskip\fi=0cm plus .7\hsize\relax} -\if@titlepage - \renewenvironment{abstract}{% - \titlepage - \null\vfil - \hbox{\SectFont \abstractname} - \noindent\ignorespaces} - {\par\vfil\null\endtitlepage} -\else - \renewenvironment{abstract}{% - \if@twocolumn - \section*{\abstractname}% - \else - \small - \bgroup\if@RTL\leftskip\else\rightskip\fi=\unitindent - \hbox{\SectFont \abstractname}% - \noindent\ignorespaces - \fi} - {\if@twocolumn\else\par\egroup\fi} -\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*\thefigure{% - \ifnum\c@chapter>\z@\thechapter\@SepMark\fi\@arabic\c@figure} -\renewcommand*\thetable{% - \ifnum\c@chapter>\z@\thechapter\@SepMark\fi\@arabic\c@table} -\renewcommand*\theequation{% - \ifnum \c@chapter>\z@ \thechapter\@SepMark\fi\@arabic\c@equation} -%% -%% Copyright © 2009-2010 by Vafa Khalighi -%% -%% Distributable 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 "maintained" (as per LPPL maintenance status) -%% by Vafa Khalighi. -%% -%% -%% -%% -%% -%% End of file `rapport3-bidi.def'. diff --git a/Master/texmf-dist/tex/xelatex/bidi/rapport3-xetex-bidi.def b/Master/texmf-dist/tex/xelatex/bidi/rapport3-xetex-bidi.def new file mode 100644 index 00000000000..8d921bfcb4b --- /dev/null +++ b/Master/texmf-dist/tex/xelatex/bidi/rapport3-xetex-bidi.def @@ -0,0 +1,253 @@ +%% +%% This is file `rapport3-xetex-bidi.def', + +%% +%% __________________________________ +%% Copyright © 2009-2010 Vafa Khalighi +%% +%% License information appended. +%% +%% +\ProvidesFile{rapport3-xetex-bidi.def}[2010/07/25 v0.1 bidi adaptations for rapport3 class for XeTeX engine] +\if@titlepage +\renewcommand*\TitleFont{\rmfamily} +\renewcommand*\maketitle{% + \begin{titlepage}% + \let\footnotesize\small + \let\footnoterule\relax + \let \footnote \thanks + \let \LTRfootnote \LTRthanks + \let \RTLfootnote \RTLthanks + \long\def\@makefntext##1{\parindent\z@ + \def\labelitemi{\textendash}\@revlabeltrue + \leavevmode\@textsuperscript{\@thefnmark}\kern1em\relax ##1} + \renewcommand*\thefootnote{\@fnsymbol\c@footnote}% + \if@compatibility\setcounter{page}{0}\fi + \null\vfil + \vskip 60\p@ + \begin{center}% + \TitleFont + {\LARGE \def\\{\penalty -\@M} + \if@allcaps + \expandafter\uc@nothanks\@title\thanks\relax + \else + \@title + \fi\par}% + \vskip 3em% + {\large + \lineskip .75em \parindent\z@ + \begin{tabular}[t]{c}% + \if@allcaps + \expandafter\uc@authornothanks\@author\and\relax + \else + \@author + \fi + \end{tabular}\par}% + \vskip 1.5em% + {\large + \if@allcaps + \uppercase\expandafter{\@date}% + \else + \@date + \fi\par}% + \end{center}\par + \@thanks + \vfil\null + \end{titlepage}% + \setcounter{footnote}{0}% + \global\let\thanks\relax + \global\let\LTRthanks\relax + \global\let\RTLthanks\relax + \global\let\maketitle\relax + \global\let\@thanks\@empty + \global\let\@author\@empty + \global\let\@title\@empty + \global\let\@date\@empty + \global\let\title\relax + \global\let\author\relax + \global\let\date\relax + \global\let\and\relax +} +\def\uc@nothanks#1\thanks{\uppercase{#1}\futurelet\@tempa\uc@tx} +\def\uc@authornothanks#1\and{\uc@nothanks#1\thanks\relax + \futurelet\@tempa\uc@ax} +\def\uc@ax{% + \ifx\@tempa\relax + \else + \\ \andname \\ \expandafter\uc@authornothanks + \fi} +\def\uc@tx{\ifx\@tempa\relax + \else \expandafter\uc@ty \fi} +\def\uc@ty#1{\thanks{#1}\uc@nothanks} +\else +\renewcommand*\maketitle{\par + \begingroup + \renewcommand*\thefootnote{\@fnsymbol\c@footnote}% + \def\@makefnmark{\rlap{% + \@textsuperscript{\normalfont\@thefnmark}}}% + \long\def\@makefntext{\@xmakefntext{% + \@textsuperscript{\normalfont\@thefnmark}}}% + \if@twocolumn + \ifnum \col@number=\@ne + \@maketitle + \else + \twocolumn[\@maketitle]% + \fi + \else + \newpage + \global\@topnum\z@ + \@maketitle + \fi + \thispagestyle{plain}\@thanks + \endgroup + \setcounter{footnote}{0}% + \global\let\thanks\relax + \global\let\LTRthanks\relax + \global\let\RTLthanks\relax + \global\let\maketitle\relax + \global\let\@maketitle\relax + \global\let\@thanks\@empty + \global\let\@author\@empty + \global\let\@title\@empty + \global\let\@date\@empty + \global\let\title\relax + \global\let\author\relax + \global\let\date\relax + \global\let\and\relax + } +\def\@maketitle{% + \newpage + \null + \vskip 2em% +\if@titlecentered + \begin{center}% + \let \footnote \thanks + \let \LTRfootnote \LTRthanks + \let \RTLfootnote \RTLthanks + {\LARGE \TitleFont \@title \par}% + \vskip 1.5em% + {\large \TitleFont + \lineskip .5em% + \begin{tabular}[t]{c}% + \@author + \end{tabular}\par}% + \vskip 1em% + {\large \TitleFont \@date}% + \end{center}% + \else + {\LARGE \TitleFont \head@style \@title \par} \vskip 1.5em + {\large \TitleFont \lineskip .5em \tabcolsep\z@ + \def\and{%%% \begin{tabular} has already started + \end{tabular}\hskip 1em plus .17fil + \begin{tabular}[t]{l}}%% \end{tabular} will come + \begin{tabular}[t]{l}\@author\end{tabular}\par} + \vskip 1em {\large \TitleFont \@date} + \fi + \par + \vskip 1.5em} +\fi +\renewcommand*\@regtocline[3]{% + \ifnum #1>\c@tocdepth + \else + \vskip\z@\@plus.2\p@ + {\hangindent\z@ \@afterindenttrue \interlinepenalty\@M + \if@RTL\rightskip\else\leftskip\fi\unitindent + \if@RTL\leftskip\else\rightskip\fi\unitindent\@plus 1fil + \parfillskip\z@ + \@tempdima\unitindent + \parindent\z@ + \leavevmode + \hbox{}\hskip -\if@RTL\rightskip\else\leftskip\fi\relax#2\nobreak + \hskip 1em \nobreak{\slshape #3}\par + }% + \fi} +\if@oldtoc +\renewcommand*\l@part[2]{% + \ifnum \c@tocdepth >-2\relax + \addpenalty{-\@highpenalty}% + \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 + \global\@nobreaktrue + \everypar{\global\@nobreakfalse\everypar{}}% + \endgroup + \fi} +\else + \renewcommand*\l@part{% + \ifnum \c@tocdepth >-2\relax + \addpenalty{-\@highpenalty}% + \addvspace{2.25em \@plus \p@}% + \@regtocline{0}% + \fi} +\fi +\if@oldtoc +\renewcommand*\l@chapter[2]{% + \addpenalty{-\@highpenalty}% + \vskip 1.0em \@plus\p@ + \setlength\@tempdima{1.5em}% + \begingroup + \parindent \z@ \if@RTL\leftskip\else\rightskip\fi \@pnumwidth + \parfillskip -\@pnumwidth + \leavevmode \bfseries + \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} +\else + \renewcommand*\l@chapter{\@regtocline{0}} +\fi +\renewcommand*\head@style{% + \interlinepenalty \@M + \hyphenpenalty=\@M \exhyphenpenalty=\@M + \if@RTL\leftskip\else\rightskip\fi=0cm plus .7\hsize\relax} +\if@titlepage + \renewenvironment{abstract}{% + \titlepage + \null\vfil + \hbox{\SectFont \abstractname} + \noindent\ignorespaces} + {\par\vfil\null\endtitlepage} +\else + \renewenvironment{abstract}{% + \if@twocolumn + \section*{\abstractname}% + \else + \small + \bgroup\if@RTL\leftskip\else\rightskip\fi=\unitindent + \hbox{\SectFont \abstractname}% + \noindent\ignorespaces + \fi} + {\if@twocolumn\else\par\egroup\fi} +\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*\thefigure{% + \ifnum\c@chapter>\z@\thechapter\@SepMark\fi\@arabic\c@figure} +\renewcommand*\thetable{% + \ifnum\c@chapter>\z@\thechapter\@SepMark\fi\@arabic\c@table} +\renewcommand*\theequation{% + \ifnum \c@chapter>\z@ \thechapter\@SepMark\fi\@arabic\c@equation} +%% +%% Copyright © 2009-2010 by Vafa Khalighi +%% +%% Distributable 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 "maintained" (as per LPPL maintenance status) +%% by Vafa Khalighi. +%% +%% +%% +%% +%% +%% End of file `rapport3-xetex-bidi.def'. diff --git a/Master/texmf-dist/tex/xelatex/bidi/refrep-bidi.def b/Master/texmf-dist/tex/xelatex/bidi/refrep-bidi.def deleted file mode 100644 index 8446921e028..00000000000 --- a/Master/texmf-dist/tex/xelatex/bidi/refrep-bidi.def +++ /dev/null @@ -1,158 +0,0 @@ -%% -%% This is file `refrep-bidi.def', - -%% -%% __________________________________ -%% Copyright © 2009-2010 Vafa Khalighi -%% -%% License information appended. -%% -%% -\ProvidesFile{refrep-bidi.def}[2010/03/01 v0.1 adaptations for refrep class] -\if@titlepage - \renewcommand\maketitle{\begin{titlepage}% - \let\footnotesize\small - \let\footnoterule\relax - \let\footnote\thanks - \let\LTRfootnote\LTRthanks - \let\RTLfootnote\RTLthanks - \renewcommand\thefootnote{\@fnsymbol\c@footnote}% - \def\@makefnmark% - {\rlap{\@textsuperscript{\normalfont\@thefnmark}}}% - \long\def\@makefntext##1{% - \@setpar{\@@par - \@tempdima = \hsize - \advance\@tempdima -1em - \parshape \@ne 1em \@tempdima}% - \par\parindent 1em \noindent - \hb@xt@\z@{\hss\@textsuperscript{\normalfont\@thefnmark}\,}##1} - \null\vfil - \vskip 60\p@ - \begin{center}% - {\LARGE \@title \par}% - \vskip 3em% - {\large - \lineskip .75em% - \begin{tabular}[t]{c}% - \@author - \end{tabular}\par}% - \vskip 1.5em% - {\large \@date \par}% % Set date in \large size. - \end{center}\par - \@thanks - \vfil\null - \end{titlepage}% - \setcounter{footnote}{0}% - \global\let\thanks\relax - \global\let\LTRthanks\relax - \global\let\RTLthanks\relax - \global\let\maketitle\relax - \global\let\@thanks\@empty - \global\let\@author\@empty - \global\let\@date\@empty - \global\let\@title\@empty - \global\let\title\relax - \global\let\author\relax - \global\let\date\relax - \global\let\and\relax - } -\else - \renewcommand\maketitle{\par - \begingroup - \renewcommand\thefootnote{\@fnsymbol\c@footnote}% - \def\@makefnmark% - {\rlap{\@textsuperscript{\normalfont\@thefnmark}}}% - \long\def\@makefntext##1{% - \@setpar{\@@par - \@tempdima = \hsize - \advance\@tempdima -1em - \parshape \@ne 1em \@tempdima}% - \par\parindent 1em \noindent - \hb@xt@\z@{\hss\@textsuperscript{\normalfont\@thefnmark}\,}##1} - \if@twocolumn - \ifnum \col@number=\@ne - \@maketitle - \else - \twocolumn[\@maketitle]% - \fi - \else - \newpage - \global\@topnum\z@ % Prevents figures from going at top of page. - \@maketitle - \fi - \thispagestyle{empty}\@thanks - \endgroup - \setcounter{footnote}{0}% - \global\let\thanks\relax - \global\let\LTRthanks\relax - \global\let\RTLthanks\relax - \global\let\maketitle\relax - \global\let\@maketitle\relax - \global\let\@thanks\@empty - \global\let\@author\@empty - \global\let\@date\@empty - \global\let\@title\@empty - \global\let\title\relax - \global\let\author\relax - \global\let\date\relax - \global\let\and\relax -} - \def\@maketitle{% - \newpage - \null - \longthickrule\vskip1.5em% - \let \footnote \thanks - \let \LTRfootnote \LTRthanks - \let \RTLfootnote \RTLthanks - {\secshape \parskip\z@ \parindent\z@ - \Large\bfseries \@title \par}% - \vskip1.5em\longthickrule\vskip1.5em% - {\normalsize - \lineskip .5em% - \begin{flushright}% - {\slshape\@author\par} - \vskip 1em% - {\@date}% - \end{flushright}\par}% - \vskip 1.5em} -\fi -\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 \hbox to\@pnumwidth{\hss #2}}\par - \nobreak - \global\@nobreaktrue - \everypar{\global\@nobreakfalse\everypar{}}% - \endgroup - \fi} -\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\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} -%% -%% Copyright © 2009-2010 by Vafa Khalighi -%% -%% Distributable 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 "maintained" (as per LPPL maintenance status) -%% by Vafa Khalighi. -%% -%% -%% -%% -%% -%% End of file `refrep-bidi.def'. diff --git a/Master/texmf-dist/tex/xelatex/bidi/refrep-xetex-bidi.def b/Master/texmf-dist/tex/xelatex/bidi/refrep-xetex-bidi.def new file mode 100644 index 00000000000..4bc24e8486c --- /dev/null +++ b/Master/texmf-dist/tex/xelatex/bidi/refrep-xetex-bidi.def @@ -0,0 +1,158 @@ +%% +%% This is file `refrep-xetex-bidi.def', + +%% +%% __________________________________ +%% Copyright © 2009-2010 Vafa Khalighi +%% +%% License information appended. +%% +%% +\ProvidesFile{refrep-xetex-bidi.def}[2010/07/25 v0.1 bidi adaptations for refrep class for XeTeX engine] +\if@titlepage + \renewcommand\maketitle{\begin{titlepage}% + \let\footnotesize\small + \let\footnoterule\relax + \let\footnote\thanks + \let\LTRfootnote\LTRthanks + \let\RTLfootnote\RTLthanks + \renewcommand\thefootnote{\@fnsymbol\c@footnote}% + \def\@makefnmark% + {\rlap{\@textsuperscript{\normalfont\@thefnmark}}}% + \long\def\@makefntext##1{% + \@setpar{\@@par + \@tempdima = \hsize + \advance\@tempdima -1em + \parshape \@ne 1em \@tempdima}% + \par\parindent 1em \noindent + \hb@xt@\z@{\hss\@textsuperscript{\normalfont\@thefnmark}\,}##1} + \null\vfil + \vskip 60\p@ + \begin{center}% + {\LARGE \@title \par}% + \vskip 3em% + {\large + \lineskip .75em% + \begin{tabular}[t]{c}% + \@author + \end{tabular}\par}% + \vskip 1.5em% + {\large \@date \par}% % Set date in \large size. + \end{center}\par + \@thanks + \vfil\null + \end{titlepage}% + \setcounter{footnote}{0}% + \global\let\thanks\relax + \global\let\LTRthanks\relax + \global\let\RTLthanks\relax + \global\let\maketitle\relax + \global\let\@thanks\@empty + \global\let\@author\@empty + \global\let\@date\@empty + \global\let\@title\@empty + \global\let\title\relax + \global\let\author\relax + \global\let\date\relax + \global\let\and\relax + } +\else + \renewcommand\maketitle{\par + \begingroup + \renewcommand\thefootnote{\@fnsymbol\c@footnote}% + \def\@makefnmark% + {\rlap{\@textsuperscript{\normalfont\@thefnmark}}}% + \long\def\@makefntext##1{% + \@setpar{\@@par + \@tempdima = \hsize + \advance\@tempdima -1em + \parshape \@ne 1em \@tempdima}% + \par\parindent 1em \noindent + \hb@xt@\z@{\hss\@textsuperscript{\normalfont\@thefnmark}\,}##1} + \if@twocolumn + \ifnum \col@number=\@ne + \@maketitle + \else + \twocolumn[\@maketitle]% + \fi + \else + \newpage + \global\@topnum\z@ % Prevents figures from going at top of page. + \@maketitle + \fi + \thispagestyle{empty}\@thanks + \endgroup + \setcounter{footnote}{0}% + \global\let\thanks\relax + \global\let\LTRthanks\relax + \global\let\RTLthanks\relax + \global\let\maketitle\relax + \global\let\@maketitle\relax + \global\let\@thanks\@empty + \global\let\@author\@empty + \global\let\@date\@empty + \global\let\@title\@empty + \global\let\title\relax + \global\let\author\relax + \global\let\date\relax + \global\let\and\relax +} + \def\@maketitle{% + \newpage + \null + \longthickrule\vskip1.5em% + \let \footnote \thanks + \let \LTRfootnote \LTRthanks + \let \RTLfootnote \RTLthanks + {\secshape \parskip\z@ \parindent\z@ + \Large\bfseries \@title \par}% + \vskip1.5em\longthickrule\vskip1.5em% + {\normalsize + \lineskip .5em% + \begin{flushright}% + {\slshape\@author\par} + \vskip 1em% + {\@date}% + \end{flushright}\par}% + \vskip 1.5em} +\fi +\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 \hbox to\@pnumwidth{\hss #2}}\par + \nobreak + \global\@nobreaktrue + \everypar{\global\@nobreakfalse\everypar{}}% + \endgroup + \fi} +\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\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} +%% +%% Copyright © 2009-2010 by Vafa Khalighi +%% +%% Distributable 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 "maintained" (as per LPPL maintenance status) +%% by Vafa Khalighi. +%% +%% +%% +%% +%% +%% End of file `refrep-xetex-bidi.def'. diff --git a/Master/texmf-dist/tex/xelatex/bidi/report-bidi.def b/Master/texmf-dist/tex/xelatex/bidi/report-bidi.def deleted file mode 100644 index 9f02d7c0b05..00000000000 --- a/Master/texmf-dist/tex/xelatex/bidi/report-bidi.def +++ /dev/null @@ -1,225 +0,0 @@ -%% -%% This is file `report-bidi.def', - -%% -%% __________________________________ -%% Copyright © 2009-2010 Vafa Khalighi -%% -%% License information appended. -%% -%% -\ProvidesFile{report-bidi.def}[2010/03/01 v0.2 adaptations for standard report class] - \if@titlepage - \renewcommand\maketitle{\begin{titlepage}% - \let\footnotesize\small - \let\footnoterule\relax - \let \footnote \thanks - \let \LTRfootnote \LTRthanks - \let \RTLfootnote \RTLthanks - \null\vfil - \vskip 60\p@ - \begin{center}% - {\LARGE \@title \par}% - \vskip 3em% - {\large - \lineskip .75em% - \begin{tabular}[t]{c}% - \@author - \end{tabular}\par}% - \vskip 1.5em% - {\large \@date \par}% % Set date in \large size. - \end{center}\par - \@thanks - \vfil\null - \end{titlepage}% - \setcounter{footnote}{0}% - \global\let\thanks\relax - \global\let\LTRthanks\relax - \global\let\RTLthanks\relax - \global\let\maketitle\relax - \global\let\@thanks\@empty - \global\let\@author\@empty - \global\let\@date\@empty - \global\let\@title\@empty - \global\let\title\relax - \global\let\author\relax - \global\let\date\relax - \global\let\and\relax -} -\else -\renewcommand\maketitle{\par - \begingroup - \renewcommand\thefootnote{\@fnsymbol\c@footnote}% - \def\@makefnmark{\rlap{\@textsuperscript{\normalfont\@thefnmark}}}% - \long\def\@makefntext##1{\parindent 1em\noindent - \hb@xt@1.8em{% - \hss\@textsuperscript{\normalfont\@thefnmark}}##1}% - \if@twocolumn - \ifnum \col@number=\@ne - \@maketitle - \else - \twocolumn[\@maketitle]% - \fi - \else - \newpage - \global\@topnum\z@ % Prevents figures from going at top of page. - \@maketitle - \fi - \thispagestyle{plain}\@thanks - \endgroup - \setcounter{footnote}{0}% - \global\let\thanks\relax - \global\let\LTRthanks\relax - \global\let\RTLthanks\relax - \global\let\maketitle\relax - \global\let\@maketitle\relax - \global\let\@thanks\@empty - \global\let\@author\@empty - \global\let\@date\@empty - \global\let\@title\@empty - \global\let\title\relax - \global\let\author\relax - \global\let\date\relax - \global\let\and\relax -} -\def\@maketitle{% - \newpage - \null - \vskip 2em% - \begin{center}% - \let \footnote \thanks - \let \LTRfootnote \LTRthanks - \let \RTLfootnote \RTLthanks - {\LARGE \@title \par}% - \vskip 1.5em% - {\large - \lineskip .5em% - \begin{tabular}[t]{c}% - \@author - \end{tabular}\par}% - \vskip 1em% - {\large \@date}% - \end{center}% - \par - \vskip 1.5em} -\fi -\renewcommand*\l@part[2]{% - \ifnum \c@tocdepth >-2\relax - \addpenalty{-\@highpenalty}% - \addvspace{2.25em \@plus\p@}% - \setlength\@tempdima{3em}% - \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\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 \thechapter {\@arabic\c@chapter} -\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} -\def\@makechapterhead#1{% - \vspace*{50\p@}% - {\parindent \z@ \if@RTL\raggedleft\else\raggedright\fi \normalfont - \ifnum \c@secnumdepth >\m@ne - \huge\bfseries \@chapapp\space \thechapter - \par\nobreak - \vskip 20\p@ - \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@ - }} -\renewenvironment{thebibliography}[1] - {\chapter*{\bibname}% - \@mkboth{\MakeUppercase\bibname}{\MakeUppercase\bibname}% - \list{\@biblabel{\@arabic\c@enumiv}}% - {\settowidth\labelwidth{\@biblabel{#1}}% - \rightmargin\labelwidth - \advance\rightmargin\labelsep - \@openbib@code - \usecounter{enumiv}% - \let\p@enumiv\@empty - \renewcommand\theenumiv{\@arabic\c@enumiv}}% - \sloppy - \clubpenalty4000 - \@clubpenalty \clubpenalty - \widowpenalty4000% - \sfcode`\.\@m} - {\def\@noitemerr - {\@latex@warning{Empty `thebibliography' environment}}% - \endlist} -\if@twoside - \def\ps@headings{% - \let\@oddfoot\@empty\let\@evenfoot\@empty - \def\@evenhead{\sl\thepage\hfil\if@RTLmain\beginR\fi\leftmark\if@RTLmain\endR\fi}% - \def\@oddhead{\sl\if@RTLmain\beginR\fi\rightmark\if@RTLmain\endR\fi\hfil\thepage}% - \let\@mkboth\markboth - \def\chaptermark##1{% - \markboth {\MakeUppercase{% - \ifnum \c@secnumdepth >\m@ne - \if@RTLmain\beginR\fi\@chapapp\ \thechapter. \ \if@RTLmain\endR\fi% - \fi - \if@RTLmain\beginR\fi##1\if@RTLmain\endR\fi}}{}}% - \def\sectionmark##1{% - \markright {\MakeUppercase{% - \ifnum \c@secnumdepth >\z@ - \if@RTLmain\beginR\fi\thesection. \ \if@RTLmain\endR\fi% - \fi - \if@RTLmain\beginR\fi##1\if@RTLmain\endR\fi}}}} -\else - \def\ps@headings{% - \let\@oddfoot\@empty - \def\@oddhead{\sl\if@RTLmain\beginR\fi\rightmark\if@RTLmain\endR\fi\hfil\thepage}% - \let\@mkboth\markboth - \def\chaptermark##1{% - \markright {\MakeUppercase{% - \ifnum \c@secnumdepth >\m@ne - \if@RTLmain\beginR\fi\@chapapp\ \thechapter. \ \if@RTLmain\endR\fi% - \fi - \if@RTLmain\beginR\fi##1\if@RTLmain\endR\fi}}}} -\fi -\def\ps@myheadings{% - \let\@oddfoot\@empty\let\@evenfoot\@empty - \def\@evenhead{\sl\thepage\hfil\if@RTLmain\beginR\fi\leftmark\if@RTLmain\endR\fi}% - \def\@oddhead{\sl\if@RTLmain\beginR\fi\rightmark\if@RTLmain\endR\fi\hfil\thepage}% - \let\@mkboth\@gobbletwo - \let\chaptermark\@gobble - \let\sectionmark\@gobble - } -\pagestyle{plain} -%% -%% Copyright © 2009-2010 by Vafa Khalighi -%% -%% Distributable 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 "maintained" (as per LPPL maintenance status) -%% by Vafa Khalighi. -%% -%% -%% -%% -%% -%% End of file `report-bidi.def'. diff --git a/Master/texmf-dist/tex/xelatex/bidi/report-xetex-bidi.def b/Master/texmf-dist/tex/xelatex/bidi/report-xetex-bidi.def new file mode 100644 index 00000000000..fd61108ff92 --- /dev/null +++ b/Master/texmf-dist/tex/xelatex/bidi/report-xetex-bidi.def @@ -0,0 +1,167 @@ +%% +%% This is file `report-xetex-bidi.def', + +%% +%% __________________________________ +%% Copyright © 2009-2010 Vafa Khalighi +%% +%% License information appended. +%% +%% +\ProvidesFile{report-xetex-bidi.def}[2010/07/25 v0.3 bidi adaptations for standard report class for XeTeX engine] + \if@titlepage + \renewcommand\maketitle{\begin{titlepage}% + \let\footnotesize\small + \let\footnoterule\relax + \let \footnote \thanks + \let \LTRfootnote \LTRthanks + \let \RTLfootnote \RTLthanks + \null\vfil + \vskip 60\p@ + \begin{center}% + {\LARGE \@title \par}% + \vskip 3em% + {\large + \lineskip .75em% + \begin{tabular}[t]{c}% + \@author + \end{tabular}\par}% + \vskip 1.5em% + {\large \@date \par}% % Set date in \large size. + \end{center}\par + \@thanks + \vfil\null + \end{titlepage}% + \setcounter{footnote}{0}% + \global\let\thanks\relax + \global\let\LTRthanks\relax + \global\let\RTLthanks\relax + \global\let\maketitle\relax + \global\let\@thanks\@empty + \global\let\@author\@empty + \global\let\@date\@empty + \global\let\@title\@empty + \global\let\title\relax + \global\let\author\relax + \global\let\date\relax + \global\let\and\relax +} +\else +\renewcommand\maketitle{\par + \begingroup + \renewcommand\thefootnote{\@fnsymbol\c@footnote}% + \def\@makefnmark{\rlap{\@textsuperscript{\normalfont\@thefnmark}}}% + \long\def\@makefntext##1{\parindent 1em\noindent + \hb@xt@1.8em{% + \hss\@textsuperscript{\normalfont\@thefnmark}}##1}% + \if@twocolumn + \ifnum \col@number=\@ne + \@maketitle + \else + \twocolumn[\@maketitle]% + \fi + \else + \newpage + \global\@topnum\z@ % Prevents figures from going at top of page. + \@maketitle + \fi + \thispagestyle{plain}\@thanks + \endgroup + \setcounter{footnote}{0}% + \global\let\thanks\relax + \global\let\LTRthanks\relax + \global\let\RTLthanks\relax + \global\let\maketitle\relax + \global\let\@maketitle\relax + \global\let\@thanks\@empty + \global\let\@author\@empty + \global\let\@date\@empty + \global\let\@title\@empty + \global\let\title\relax + \global\let\author\relax + \global\let\date\relax + \global\let\and\relax +} +\def\@maketitle{% + \newpage + \null + \vskip 2em% + \begin{center}% + \let \footnote \thanks + \let \LTRfootnote \LTRthanks + \let \RTLfootnote \RTLthanks + {\LARGE \@title \par}% + \vskip 1.5em% + {\large + \lineskip .5em% + \begin{tabular}[t]{c}% + \@author + \end{tabular}\par}% + \vskip 1em% + {\large \@date}% + \end{center}% + \par + \vskip 1.5em} +\fi +\renewcommand*\l@part[2]{% + \ifnum \c@tocdepth >-2\relax + \addpenalty{-\@highpenalty}% + \addvspace{2.25em \@plus\p@}% + \setlength\@tempdima{3em}% + \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\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 \thechapter {\@arabic\c@chapter} +\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} +\def\@makechapterhead#1{% + \vspace*{50\p@}% + {\parindent \z@ \if@RTL\raggedleft\else\raggedright\fi \normalfont + \ifnum \c@secnumdepth >\m@ne + \huge\bfseries \@chapapp\space \thechapter + \par\nobreak + \vskip 20\p@ + \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@ + }} +%% +%% Copyright © 2009-2010 by Vafa Khalighi +%% +%% Distributable 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 "maintained" (as per LPPL maintenance status) +%% by Vafa Khalighi. +%% +%% +%% +%% +%% +%% End of file `report-xetex-bidi.def'. diff --git a/Master/texmf-dist/tex/xelatex/bidi/scrartcl-bidi.def b/Master/texmf-dist/tex/xelatex/bidi/scrartcl-bidi.def deleted file mode 100644 index 63091c1a5ce..00000000000 --- a/Master/texmf-dist/tex/xelatex/bidi/scrartcl-bidi.def +++ /dev/null @@ -1,264 +0,0 @@ -%% -%% This is file `scrartcl-bidi.def', - -%% -%% __________________________________ -%% Copyright © 2009-2010 Vafa Khalighi -%% -%% License information appended. -%% -%% -\ProvidesFile{scrartcl-bidi.def}[2010/03/01 v0.1 adaptations for scrartcl class] -\renewcommand*\maketitle[1][1]{% - \if@titlepage - \begin{titlepage} - \setcounter{page}{% - #1% - }% - \let\footnotesize\small - \let\footnoterule\relax - \let\footnote\thanks - \let\LTRfootnote\LTRthanks - \let\RTLfootnote\RTLthanks - \renewcommand*\thefootnote{\@fnsymbol\c@footnote}% - \let\@oldmakefnmark\@makefnmark - \renewcommand*{\@makefnmark}{\rlap\@oldmakefnmark}% - \ifx\@extratitle\@empty \else - \noindent\@extratitle\next@tpage\cleardoubleemptypage - \thispagestyle{empty}% - \fi - \setparsizes{\z@}{\z@}{\z@\@plus 1fil}\par@updaterelative - \ifx\@titlehead\@empty \else - \begin{minipage}[t]{\textwidth}% - \@titlehead - \end{minipage}\par - \fi - \null\vfill - \begin{center} - \ifx\@subject\@empty \else - {\subject@font \@subject \par}% - \vskip 3em - \fi - {\titlefont\huge \@title\par}% - \vskip 1em - {\ifx\@subtitle\@empty\else\usekomafont{subtitle}\@subtitle\par\fi}% - \vskip 2em - {\Large \lineskip 0.75em - \begin{tabular}[t]{c} - \@author - \end{tabular}\par - }% - \vskip 1.5em - {\Large \@date \par}% - \vskip \z@ \@plus3fill - {\Large \@publishers \par}% - \vskip 3em - \end{center}\par - \@thanks - \vfill\null - \if@twoside\next@tpage - \begin{minipage}[t]{\textwidth} - \@uppertitleback - \end{minipage}\par - \vfill - \begin{minipage}[b]{\textwidth} - \@lowertitleback - \end{minipage} - \fi - \ifx\@dedication\@empty \else - \next@tpage\null\vfill - {\centering \Large \@dedication \par}% - \vskip \z@ \@plus3fill - \if@twoside \next@tpage\cleardoubleemptypage \fi - \fi - \end{titlepage} - \else - \par - \@tempcnta=% - #1% - \relax\ifnum\@tempcnta=1\else - \ClassWarning{\KOMAClassName}{% - Optional argument of \string\maketitle\space ignored - at\MessageBreak - notitlepage-mode% - }% - \fi - \begingroup - \renewcommand*\thefootnote{\@fnsymbol\c@footnote}% - \let\@oldmakefnmark\@makefnmark - \renewcommand*{\@makefnmark}{\rlap\@oldmakefnmark} - \if@twocolumn - \ifnum \col@number=\@ne - \@maketitle - \else - \twocolumn[\@maketitle]% - \fi - \else - \newpage - \global\@topnum\z@ - \@maketitle - \fi - \thispagestyle{\titlepagestyle}\@thanks - \endgroup - \fi - \setcounter{footnote}{0}% - \let\thanks\relax - \let\LTRthanks\relax - \let\RTLthanks\relax - \let\maketitle\relax - \let\@maketitle\relax - \global\let\@thanks\@empty - \global\let\@author\@empty - \global\let\@date\@empty - \global\let\@title\@empty - \global\let\@subtitle\@empty - \global\let\@extratitle\@empty - \global\let\@titlehead\@empty - \global\let\@subject\@empty - \global\let\@publishers\@empty - \global\let\@uppertitleback\@empty - \global\let\@lowertitleback\@empty - \global\let\@dedication\@empty - \global\let\author\relax - \global\let\title\relax - \global\let\extratitle\relax - \global\let\titlehead\relax - \global\let\subject\relax - \global\let\publishers\relax - \global\let\uppertitleback\relax - \global\let\lowertitleback\relax - \global\let\dedication\relax - \global\let\date\relax - \global\let\and\relax -}% -\renewcommand*{\@maketitle}{% - \clearpage - \let\footnote\thanks - \let\LTRfootnote\LTRthanks - \let\RTLfootnote\RTLthanks - \ifx\@extratitle\@empty \else - \noindent\@extratitle \next@tpage \if@twoside \null\next@tpage \fi - \fi - \setparsizes{\z@}{\z@}{\z@\@plus 1fil}\par@updaterelative - \ifx\@titlehead\@empty \else - \begin{minipage}[t]{\textwidth} - \@titlehead - \end{minipage}\par - \fi - \null - \vskip 2em% - \begin{center}% - \ifx\@subject\@empty \else - {\subject@font \@subject \par} - \vskip 1.5em - \fi - {\titlefont\huge \@title \par}% - \vskip .5em - {\ifx\@subtitle\@empty\else\usekomafont{subtitle}\@subtitle\par\fi}% - \vskip 1em - {\Large - \lineskip .5em% - \begin{tabular}[t]{c} - \@author - \end{tabular}\par - }% - \vskip 1em% - {\Large \@date \par}% - \vskip \z@ \@plus 1em - {\Large \@publishers \par} - \ifx\@dedication\@empty \else - \vskip 2em - {\Large \@dedication \par} - \fi - \end{center}% - \par - \vskip 2em -}% -\renewcommand*\l@part[2]{% - \ifnum \c@tocdepth >\m@ne\relax - \addpenalty{\@secpenalty}% - \addvspace{2.25em \@plus\p@}% - \setlength{\@tempdima}{2em}% - \if@tocleft - \ifx\toc@l@number\@empty\else - \setlength\@tempdima{0\toc@l@number}% - \fi - \fi - \begingroup - \parindent \z@ \if@RTL\leftskip\else\rightskip\fi \@pnumwidth - \parfillskip -\@pnumwidth - \leavevmode - \advance\if@RTL\rightskip\else\leftskip\fi\@tempdima - \hskip -\if@RTL\rightskip\else\leftskip\fi - \usekomafont{partentry}{#1\nobreak - \usekomafont{partentrypagenumber}{\hfil\nobreak - \hb@xt@\@pnumwidth{\hss#2}}}\par - \ifnum \scr@compatibility>\@nameuse{scr@v@2.96}\relax - \endgroup - \penalty20010 - \else - \if@compatibility - \global\@nobreaktrue - \everypar{\global\@nobreakfalse\everypar{}}% - \else - \penalty\@highpenalty - \fi - \endgroup - \fi - \fi -} -\renewcommand*\l@section[2]{% - \ifnum \c@tocdepth >\z@ - \ifnum \lastpenalty<20009 - \addpenalty{\@secpenalty}% - \fi - \addvspace{1.0em \@plus\p@}% - \setlength\@tempdima{1.5em}% - \if@tocleft - \ifx\toc@l@number\@empty\else - \setlength\@tempdima{0\toc@l@number}% - \fi - \fi - \begingroup - \raggedsectionentry - \parindent \z@ \advance\if@RTL\leftskip\else\rightskip\fi \@pnumwidth - \parfillskip -\@pnumwidth - \interlinepenalty\@M - \leavevmode - \advance\if@RTL\rightskip\else\leftskip\fi \@tempdima \null\nobreak\hskip -\if@RTL\rightskip\else\leftskip\fi - \usekomafont{sectionentry}{#1\nobreak - \usekomafont{sectionentrypagenumber}{% - \hfill\nobreak - \hb@xt@\@pnumwidth{\hss#2}}}\par - \endgroup - \ifnum \scr@compatibility>\@nameuse{scr@v@2.96}\relax - \penalty20008 - \fi - \fi -} -\def\raggedsection{\if@RTL\raggedleft\else\raggedright\fi} -\def\raggedpart{\if@RTL\raggedleft\else\raggedright\fi} -\renewcommand*\autodot{\if@altsecnumformat\@SepMark\fi} -\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 -} -%% -%% Copyright © 2009-2010 by Vafa Khalighi -%% -%% Distributable 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 "maintained" (as per LPPL maintenance status) -%% by Vafa Khalighi. -%% -%% -%% -%% -%% -%% End of file `scrartcl-bidi.def'. diff --git a/Master/texmf-dist/tex/xelatex/bidi/scrartcl-xetex-bidi.def b/Master/texmf-dist/tex/xelatex/bidi/scrartcl-xetex-bidi.def new file mode 100644 index 00000000000..951f7541b56 --- /dev/null +++ b/Master/texmf-dist/tex/xelatex/bidi/scrartcl-xetex-bidi.def @@ -0,0 +1,264 @@ +%% +%% This is file `scrartcl-xetex-bidi.def', + +%% +%% __________________________________ +%% Copyright © 2009-2010 Vafa Khalighi +%% +%% License information appended. +%% +%% +\ProvidesFile{scrartcl-xetex-bidi.def}[2010/07/25 v0.1 bidi adaptations for scrartcl class for XeTeX engine] +\renewcommand*\maketitle[1][1]{% + \if@titlepage + \begin{titlepage} + \setcounter{page}{% + #1% + }% + \let\footnotesize\small + \let\footnoterule\relax + \let\footnote\thanks + \let\LTRfootnote\LTRthanks + \let\RTLfootnote\RTLthanks + \renewcommand*\thefootnote{\@fnsymbol\c@footnote}% + \let\@oldmakefnmark\@makefnmark + \renewcommand*{\@makefnmark}{\rlap\@oldmakefnmark}% + \ifx\@extratitle\@empty \else + \noindent\@extratitle\next@tpage\cleardoubleemptypage + \thispagestyle{empty}% + \fi + \setparsizes{\z@}{\z@}{\z@\@plus 1fil}\par@updaterelative + \ifx\@titlehead\@empty \else + \begin{minipage}[t]{\textwidth}% + \@titlehead + \end{minipage}\par + \fi + \null\vfill + \begin{center} + \ifx\@subject\@empty \else + {\subject@font \@subject \par}% + \vskip 3em + \fi + {\titlefont\huge \@title\par}% + \vskip 1em + {\ifx\@subtitle\@empty\else\usekomafont{subtitle}\@subtitle\par\fi}% + \vskip 2em + {\Large \lineskip 0.75em + \begin{tabular}[t]{c} + \@author + \end{tabular}\par + }% + \vskip 1.5em + {\Large \@date \par}% + \vskip \z@ \@plus3fill + {\Large \@publishers \par}% + \vskip 3em + \end{center}\par + \@thanks + \vfill\null + \if@twoside\next@tpage + \begin{minipage}[t]{\textwidth} + \@uppertitleback + \end{minipage}\par + \vfill + \begin{minipage}[b]{\textwidth} + \@lowertitleback + \end{minipage} + \fi + \ifx\@dedication\@empty \else + \next@tpage\null\vfill + {\centering \Large \@dedication \par}% + \vskip \z@ \@plus3fill + \if@twoside \next@tpage\cleardoubleemptypage \fi + \fi + \end{titlepage} + \else + \par + \@tempcnta=% + #1% + \relax\ifnum\@tempcnta=1\else + \ClassWarning{\KOMAClassName}{% + Optional argument of \string\maketitle\space ignored + at\MessageBreak + notitlepage-mode% + }% + \fi + \begingroup + \renewcommand*\thefootnote{\@fnsymbol\c@footnote}% + \let\@oldmakefnmark\@makefnmark + \renewcommand*{\@makefnmark}{\rlap\@oldmakefnmark} + \if@twocolumn + \ifnum \col@number=\@ne + \@maketitle + \else + \twocolumn[\@maketitle]% + \fi + \else + \newpage + \global\@topnum\z@ + \@maketitle + \fi + \thispagestyle{\titlepagestyle}\@thanks + \endgroup + \fi + \setcounter{footnote}{0}% + \let\thanks\relax + \let\LTRthanks\relax + \let\RTLthanks\relax + \let\maketitle\relax + \let\@maketitle\relax + \global\let\@thanks\@empty + \global\let\@author\@empty + \global\let\@date\@empty + \global\let\@title\@empty + \global\let\@subtitle\@empty + \global\let\@extratitle\@empty + \global\let\@titlehead\@empty + \global\let\@subject\@empty + \global\let\@publishers\@empty + \global\let\@uppertitleback\@empty + \global\let\@lowertitleback\@empty + \global\let\@dedication\@empty + \global\let\author\relax + \global\let\title\relax + \global\let\extratitle\relax + \global\let\titlehead\relax + \global\let\subject\relax + \global\let\publishers\relax + \global\let\uppertitleback\relax + \global\let\lowertitleback\relax + \global\let\dedication\relax + \global\let\date\relax + \global\let\and\relax +}% +\renewcommand*{\@maketitle}{% + \clearpage + \let\footnote\thanks + \let\LTRfootnote\LTRthanks + \let\RTLfootnote\RTLthanks + \ifx\@extratitle\@empty \else + \noindent\@extratitle \next@tpage \if@twoside \null\next@tpage \fi + \fi + \setparsizes{\z@}{\z@}{\z@\@plus 1fil}\par@updaterelative + \ifx\@titlehead\@empty \else + \begin{minipage}[t]{\textwidth} + \@titlehead + \end{minipage}\par + \fi + \null + \vskip 2em% + \begin{center}% + \ifx\@subject\@empty \else + {\subject@font \@subject \par} + \vskip 1.5em + \fi + {\titlefont\huge \@title \par}% + \vskip .5em + {\ifx\@subtitle\@empty\else\usekomafont{subtitle}\@subtitle\par\fi}% + \vskip 1em + {\Large + \lineskip .5em% + \begin{tabular}[t]{c} + \@author + \end{tabular}\par + }% + \vskip 1em% + {\Large \@date \par}% + \vskip \z@ \@plus 1em + {\Large \@publishers \par} + \ifx\@dedication\@empty \else + \vskip 2em + {\Large \@dedication \par} + \fi + \end{center}% + \par + \vskip 2em +}% +\renewcommand*\l@part[2]{% + \ifnum \c@tocdepth >\m@ne\relax + \addpenalty{\@secpenalty}% + \addvspace{2.25em \@plus\p@}% + \setlength{\@tempdima}{2em}% + \if@tocleft + \ifx\toc@l@number\@empty\else + \setlength\@tempdima{0\toc@l@number}% + \fi + \fi + \begingroup + \parindent \z@ \if@RTL\leftskip\else\rightskip\fi \@pnumwidth + \parfillskip -\@pnumwidth + \leavevmode + \advance\if@RTL\rightskip\else\leftskip\fi\@tempdima + \hskip -\if@RTL\rightskip\else\leftskip\fi + \usekomafont{partentry}{#1\nobreak + \usekomafont{partentrypagenumber}{\hfil\nobreak + \hb@xt@\@pnumwidth{\hss#2}}}\par + \ifnum \scr@compatibility>\@nameuse{scr@v@2.96}\relax + \endgroup + \penalty20010 + \else + \if@compatibility + \global\@nobreaktrue + \everypar{\global\@nobreakfalse\everypar{}}% + \else + \penalty\@highpenalty + \fi + \endgroup + \fi + \fi +} +\renewcommand*\l@section[2]{% + \ifnum \c@tocdepth >\z@ + \ifnum \lastpenalty<20009 + \addpenalty{\@secpenalty}% + \fi + \addvspace{1.0em \@plus\p@}% + \setlength\@tempdima{1.5em}% + \if@tocleft + \ifx\toc@l@number\@empty\else + \setlength\@tempdima{0\toc@l@number}% + \fi + \fi + \begingroup + \raggedsectionentry + \parindent \z@ \advance\if@RTL\leftskip\else\rightskip\fi \@pnumwidth + \parfillskip -\@pnumwidth + \interlinepenalty\@M + \leavevmode + \advance\if@RTL\rightskip\else\leftskip\fi \@tempdima \null\nobreak\hskip -\if@RTL\rightskip\else\leftskip\fi + \usekomafont{sectionentry}{#1\nobreak + \usekomafont{sectionentrypagenumber}{% + \hfill\nobreak + \hb@xt@\@pnumwidth{\hss#2}}}\par + \endgroup + \ifnum \scr@compatibility>\@nameuse{scr@v@2.96}\relax + \penalty20008 + \fi + \fi +} +\def\raggedsection{\if@RTL\raggedleft\else\raggedright\fi} +\def\raggedpart{\if@RTL\raggedleft\else\raggedright\fi} +\renewcommand*\autodot{\if@altsecnumformat\@SepMark\fi} +\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 +} +%% +%% Copyright © 2009-2010 by Vafa Khalighi +%% +%% Distributable 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 "maintained" (as per LPPL maintenance status) +%% by Vafa Khalighi. +%% +%% +%% +%% +%% +%% End of file `scrartcl-xetex-bidi.def'. diff --git a/Master/texmf-dist/tex/xelatex/bidi/scrbook-bidi.def b/Master/texmf-dist/tex/xelatex/bidi/scrbook-bidi.def deleted file mode 100644 index 037d59efc81..00000000000 --- a/Master/texmf-dist/tex/xelatex/bidi/scrbook-bidi.def +++ /dev/null @@ -1,320 +0,0 @@ -%% -%% This is file `scrbook-bidi.def', - -%% -%% __________________________________ -%% Copyright © 2009-2010 Vafa Khalighi -%% -%% License information appended. -%% -%% -\ProvidesFile{scrbook-bidi.def}[2010/03/01 v0.1 adaptations for scrbook class] -\renewcommand*\maketitle[1][1]{% - \if@titlepage - \begin{titlepage} - \setcounter{page}{% - #1% - }% - \let\footnotesize\small - \let\footnoterule\relax - \let\footnote\thanks - \let\LTRfootnote\LTRthanks - \let\RTLfootnote\RTLthanks - \renewcommand*\thefootnote{\@fnsymbol\c@footnote}% - \let\@oldmakefnmark\@makefnmark - \renewcommand*{\@makefnmark}{\rlap\@oldmakefnmark}% - \ifx\@extratitle\@empty \else - \noindent\@extratitle\next@tpage\cleardoubleemptypage - \thispagestyle{empty}% - \fi - \setparsizes{\z@}{\z@}{\z@\@plus 1fil}\par@updaterelative - \ifx\@titlehead\@empty \else - \begin{minipage}[t]{\textwidth}% - \@titlehead - \end{minipage}\par - \fi - \null\vfill - \begin{center} - \ifx\@subject\@empty \else - {\subject@font \@subject \par}% - \vskip 3em - \fi - {\titlefont\huge \@title\par}% - \vskip 1em - {\ifx\@subtitle\@empty\else\usekomafont{subtitle}\@subtitle\par\fi}% - \vskip 2em - {\Large \lineskip 0.75em - \begin{tabular}[t]{c} - \@author - \end{tabular}\par - }% - \vskip 1.5em - {\Large \@date \par}% - \vskip \z@ \@plus3fill - {\Large \@publishers \par}% - \vskip 3em - \end{center}\par - \@thanks - \vfill\null - \if@twoside\next@tpage - \begin{minipage}[t]{\textwidth} - \@uppertitleback - \end{minipage}\par - \vfill - \begin{minipage}[b]{\textwidth} - \@lowertitleback - \end{minipage} - \fi - \ifx\@dedication\@empty \else - \next@tpage\null\vfill - {\centering \Large \@dedication \par}% - \vskip \z@ \@plus3fill - \if@twoside \next@tpage\cleardoubleemptypage \fi - \fi - \end{titlepage} - \else - \par - \@tempcnta=% - #1% - \relax\ifnum\@tempcnta=1\else - \ClassWarning{\KOMAClassName}{% - Optional argument of \string\maketitle\space ignored - at\MessageBreak - notitlepage-mode% - }% - \fi - \begingroup - \renewcommand*\thefootnote{\@fnsymbol\c@footnote}% - \let\@oldmakefnmark\@makefnmark - \renewcommand*{\@makefnmark}{\rlap\@oldmakefnmark} - \if@twocolumn - \ifnum \col@number=\@ne - \@maketitle - \else - \twocolumn[\@maketitle]% - \fi - \else - \newpage - \global\@topnum\z@ - \@maketitle - \fi - \thispagestyle{\titlepagestyle}\@thanks - \endgroup - \fi - \setcounter{footnote}{0}% - \let\thanks\relax - \let\LTRthanks\relax - \let\RTLthanks\relax - \let\maketitle\relax - \let\@maketitle\relax - \global\let\@thanks\@empty - \global\let\@author\@empty - \global\let\@date\@empty - \global\let\@title\@empty - \global\let\@subtitle\@empty - \global\let\@extratitle\@empty - \global\let\@titlehead\@empty - \global\let\@subject\@empty - \global\let\@publishers\@empty - \global\let\@uppertitleback\@empty - \global\let\@lowertitleback\@empty - \global\let\@dedication\@empty - \global\let\author\relax - \global\let\title\relax - \global\let\extratitle\relax - \global\let\titlehead\relax - \global\let\subject\relax - \global\let\publishers\relax - \global\let\uppertitleback\relax - \global\let\lowertitleback\relax - \global\let\dedication\relax - \global\let\date\relax - \global\let\and\relax -}% -\renewcommand*{\@maketitle}{% - \clearpage - \let\footnote\thanks - \let\LTRfootnote\LTRthanks - \let\RTLfootnote\RTLthanks - \ifx\@extratitle\@empty \else - \noindent\@extratitle \next@tpage \if@twoside \null\next@tpage \fi - \fi - \setparsizes{\z@}{\z@}{\z@\@plus 1fil}\par@updaterelative - \ifx\@titlehead\@empty \else - \begin{minipage}[t]{\textwidth} - \@titlehead - \end{minipage}\par - \fi - \null - \vskip 2em% - \begin{center}% - \ifx\@subject\@empty \else - {\subject@font \@subject \par} - \vskip 1.5em - \fi - {\titlefont\huge \@title \par}% - \vskip .5em - {\ifx\@subtitle\@empty\else\usekomafont{subtitle}\@subtitle\par\fi}% - \vskip 1em - {\Large - \lineskip .5em% - \begin{tabular}[t]{c} - \@author - \end{tabular}\par - }% - \vskip 1em% - {\Large \@date \par}% - \vskip \z@ \@plus 1em - {\Large \@publishers \par} - \ifx\@dedication\@empty \else - \vskip 2em - {\Large \@dedication \par} - \fi - \end{center}% - \par - \vskip 2em -}% -\renewcommand*\l@part[2]{% - \ifnum \c@tocdepth >-2\relax - \addpenalty{-\@highpenalty}% - \addvspace{2.25em \@plus\p@}% - \setlength{\@tempdima}{2em}% - \if@tocleft - \ifx\toc@l@number\@empty\else - \setlength\@tempdima{0\toc@l@number}% - \fi - \fi - \begingroup - \parindent \z@ \if@RTL\leftskip\else\rightskip\fi \@pnumwidth - \parfillskip -\@pnumwidth - \leavevmode - \advance\if@RTL\rightskip\else\leftskip\fi\@tempdima - \hskip -\if@RTL\rightskip\else\leftskip\fi - \usekomafont{partentry}{#1\nobreak - \usekomafont{partentrypagenumber}{\hfil\nobreak - \hb@xt@\@pnumwidth{\hss#2}}}\par - \ifnum \scr@compatibility>\@nameuse{scr@v@2.96}\relax - \endgroup - \penalty20010 - \else - \penalty\@highpenalty - \endgroup - \fi - \fi -}\renewcommand*\l@part[2]{% - \ifnum \c@tocdepth >-2\relax - \addpenalty{-\@highpenalty}% - \addvspace{2.25em \@plus\p@}% - \setlength{\@tempdima}{2em}% - \if@tocleft - \ifx\toc@l@number\@empty\else - \setlength\@tempdima{0\toc@l@number}% - \fi - \fi - \begingroup - \parindent \z@ \if@RTL\leftskip\else\rightskip\fi \@pnumwidth - \parfillskip -\@pnumwidth - \leavevmode - \advance\if@RTL\rightskip\else\leftskip\fi\@tempdima - \hskip -\if@RTL\rightskip\else\leftskip\fi - \usekomafont{partentry}{#1\nobreak - \usekomafont{partentrypagenumber}{\hfil\nobreak - \hb@xt@\@pnumwidth{\hss#2}}}\par - \ifnum \scr@compatibility>\@nameuse{scr@v@2.96}\relax - \endgroup - \penalty20010 - \else - \penalty\@highpenalty - \endgroup - \fi - \fi -} -\renewcommand*\l@chapter[2]{% - \ifnum \c@tocdepth >\m@ne - \ifnum \lastpenalty<20010 - \addpenalty{-\@highpenalty}% - \fi - \vskip 1.0em \@plus\p@ - \setlength\@tempdima{1.5em}% - \if@tocleft - \ifx\toc@l@number\@empty\else - \setlength\@tempdima{0\toc@l@number}% - \fi - \fi - \begingroup - \raggedchapterentry - \parindent \z@ \advance\if@RTL\leftskip\else\rightskip\fi \@pnumwidth - \parfillskip -\@pnumwidth - \interlinepenalty\@M - \leavevmode - \advance\if@RTL\rightskip\else\leftskip\fi \@tempdima \null\nobreak\hskip -\if@RTL\rightskip\else\leftskip\fi - \usekomafont{chapterentry}{#1\nobreak - \usekomafont{chapterentrypagenumber}{% - \hfill\nobreak - \hb@xt@\@pnumwidth{\hss#2}}}\par - \ifnum \scr@compatibility>\@nameuse{scr@v@2.96}\relax - \endgroup - \penalty20009 - \else - \penalty\@highpenalty - \endgroup - \fi - \fi -} -\def\raggedsection{\if@RTL\raggedleft\else\raggedright\fi} -\renewcommand*\autodot{\if@altsecnumformat\@SepMark\fi} -\renewcommand*\thesection{% - \ifnum \scr@compatibility>\@nameuse{scr@v@2.97d}\relax - \if@mainmatter\thechapter\@SepMark\fi - \else - \thechapter\@SepMark% - \fi - \@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*\thefigure{% - \ifnum \scr@compatibility>\@nameuse{scr@v@2.97d}\relax - \if@mainmatter\thechapter\@SepMark\fi - \else - \thechapter\@SepMark% - \fi - \@arabic\c@figure -} -\renewcommand*\thetable{% - \ifnum \scr@compatibility>\@nameuse{scr@v@2.97d}\relax - \if@mainmatter\thechapter\@SepMark\fi - \else - \thechapter\@SepMark% - \fi - \@arabic\c@table -} -\renewcommand*\theequation{% - \ifnum \scr@compatibility>\@nameuse{scr@v@2.97d}\relax - \if@mainmatter\thechapter\@SepMark\fi - \else - \thechapter\@SepMark% - \fi - \@arabic\c@equation -} -%% -%% Copyright © 2009-2010 by Vafa Khalighi -%% -%% Distributable 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 "maintained" (as per LPPL maintenance status) -%% by Vafa Khalighi. -%% -%% -%% -%% -%% -%% End of file `scrbook-bidi.def'. diff --git a/Master/texmf-dist/tex/xelatex/bidi/scrbook-xetex-bidi.def b/Master/texmf-dist/tex/xelatex/bidi/scrbook-xetex-bidi.def new file mode 100644 index 00000000000..8b5a7f83f4d --- /dev/null +++ b/Master/texmf-dist/tex/xelatex/bidi/scrbook-xetex-bidi.def @@ -0,0 +1,320 @@ +%% +%% This is file `scrbook-xetex-bidi.def', + +%% +%% __________________________________ +%% Copyright © 2009-2010 Vafa Khalighi +%% +%% License information appended. +%% +%% +\ProvidesFile{scrbook-xetex-bidi.def}[2010/07/25 v0.1 bidi adaptations for scrbook class for XeTeX engine] +\renewcommand*\maketitle[1][1]{% + \if@titlepage + \begin{titlepage} + \setcounter{page}{% + #1% + }% + \let\footnotesize\small + \let\footnoterule\relax + \let\footnote\thanks + \let\LTRfootnote\LTRthanks + \let\RTLfootnote\RTLthanks + \renewcommand*\thefootnote{\@fnsymbol\c@footnote}% + \let\@oldmakefnmark\@makefnmark + \renewcommand*{\@makefnmark}{\rlap\@oldmakefnmark}% + \ifx\@extratitle\@empty \else + \noindent\@extratitle\next@tpage\cleardoubleemptypage + \thispagestyle{empty}% + \fi + \setparsizes{\z@}{\z@}{\z@\@plus 1fil}\par@updaterelative + \ifx\@titlehead\@empty \else + \begin{minipage}[t]{\textwidth}% + \@titlehead + \end{minipage}\par + \fi + \null\vfill + \begin{center} + \ifx\@subject\@empty \else + {\subject@font \@subject \par}% + \vskip 3em + \fi + {\titlefont\huge \@title\par}% + \vskip 1em + {\ifx\@subtitle\@empty\else\usekomafont{subtitle}\@subtitle\par\fi}% + \vskip 2em + {\Large \lineskip 0.75em + \begin{tabular}[t]{c} + \@author + \end{tabular}\par + }% + \vskip 1.5em + {\Large \@date \par}% + \vskip \z@ \@plus3fill + {\Large \@publishers \par}% + \vskip 3em + \end{center}\par + \@thanks + \vfill\null + \if@twoside\next@tpage + \begin{minipage}[t]{\textwidth} + \@uppertitleback + \end{minipage}\par + \vfill + \begin{minipage}[b]{\textwidth} + \@lowertitleback + \end{minipage} + \fi + \ifx\@dedication\@empty \else + \next@tpage\null\vfill + {\centering \Large \@dedication \par}% + \vskip \z@ \@plus3fill + \if@twoside \next@tpage\cleardoubleemptypage \fi + \fi + \end{titlepage} + \else + \par + \@tempcnta=% + #1% + \relax\ifnum\@tempcnta=1\else + \ClassWarning{\KOMAClassName}{% + Optional argument of \string\maketitle\space ignored + at\MessageBreak + notitlepage-mode% + }% + \fi + \begingroup + \renewcommand*\thefootnote{\@fnsymbol\c@footnote}% + \let\@oldmakefnmark\@makefnmark + \renewcommand*{\@makefnmark}{\rlap\@oldmakefnmark} + \if@twocolumn + \ifnum \col@number=\@ne + \@maketitle + \else + \twocolumn[\@maketitle]% + \fi + \else + \newpage + \global\@topnum\z@ + \@maketitle + \fi + \thispagestyle{\titlepagestyle}\@thanks + \endgroup + \fi + \setcounter{footnote}{0}% + \let\thanks\relax + \let\LTRthanks\relax + \let\RTLthanks\relax + \let\maketitle\relax + \let\@maketitle\relax + \global\let\@thanks\@empty + \global\let\@author\@empty + \global\let\@date\@empty + \global\let\@title\@empty + \global\let\@subtitle\@empty + \global\let\@extratitle\@empty + \global\let\@titlehead\@empty + \global\let\@subject\@empty + \global\let\@publishers\@empty + \global\let\@uppertitleback\@empty + \global\let\@lowertitleback\@empty + \global\let\@dedication\@empty + \global\let\author\relax + \global\let\title\relax + \global\let\extratitle\relax + \global\let\titlehead\relax + \global\let\subject\relax + \global\let\publishers\relax + \global\let\uppertitleback\relax + \global\let\lowertitleback\relax + \global\let\dedication\relax + \global\let\date\relax + \global\let\and\relax +}% +\renewcommand*{\@maketitle}{% + \clearpage + \let\footnote\thanks + \let\LTRfootnote\LTRthanks + \let\RTLfootnote\RTLthanks + \ifx\@extratitle\@empty \else + \noindent\@extratitle \next@tpage \if@twoside \null\next@tpage \fi + \fi + \setparsizes{\z@}{\z@}{\z@\@plus 1fil}\par@updaterelative + \ifx\@titlehead\@empty \else + \begin{minipage}[t]{\textwidth} + \@titlehead + \end{minipage}\par + \fi + \null + \vskip 2em% + \begin{center}% + \ifx\@subject\@empty \else + {\subject@font \@subject \par} + \vskip 1.5em + \fi + {\titlefont\huge \@title \par}% + \vskip .5em + {\ifx\@subtitle\@empty\else\usekomafont{subtitle}\@subtitle\par\fi}% + \vskip 1em + {\Large + \lineskip .5em% + \begin{tabular}[t]{c} + \@author + \end{tabular}\par + }% + \vskip 1em% + {\Large \@date \par}% + \vskip \z@ \@plus 1em + {\Large \@publishers \par} + \ifx\@dedication\@empty \else + \vskip 2em + {\Large \@dedication \par} + \fi + \end{center}% + \par + \vskip 2em +}% +\renewcommand*\l@part[2]{% + \ifnum \c@tocdepth >-2\relax + \addpenalty{-\@highpenalty}% + \addvspace{2.25em \@plus\p@}% + \setlength{\@tempdima}{2em}% + \if@tocleft + \ifx\toc@l@number\@empty\else + \setlength\@tempdima{0\toc@l@number}% + \fi + \fi + \begingroup + \parindent \z@ \if@RTL\leftskip\else\rightskip\fi \@pnumwidth + \parfillskip -\@pnumwidth + \leavevmode + \advance\if@RTL\rightskip\else\leftskip\fi\@tempdima + \hskip -\if@RTL\rightskip\else\leftskip\fi + \usekomafont{partentry}{#1\nobreak + \usekomafont{partentrypagenumber}{\hfil\nobreak + \hb@xt@\@pnumwidth{\hss#2}}}\par + \ifnum \scr@compatibility>\@nameuse{scr@v@2.96}\relax + \endgroup + \penalty20010 + \else + \penalty\@highpenalty + \endgroup + \fi + \fi +}\renewcommand*\l@part[2]{% + \ifnum \c@tocdepth >-2\relax + \addpenalty{-\@highpenalty}% + \addvspace{2.25em \@plus\p@}% + \setlength{\@tempdima}{2em}% + \if@tocleft + \ifx\toc@l@number\@empty\else + \setlength\@tempdima{0\toc@l@number}% + \fi + \fi + \begingroup + \parindent \z@ \if@RTL\leftskip\else\rightskip\fi \@pnumwidth + \parfillskip -\@pnumwidth + \leavevmode + \advance\if@RTL\rightskip\else\leftskip\fi\@tempdima + \hskip -\if@RTL\rightskip\else\leftskip\fi + \usekomafont{partentry}{#1\nobreak + \usekomafont{partentrypagenumber}{\hfil\nobreak + \hb@xt@\@pnumwidth{\hss#2}}}\par + \ifnum \scr@compatibility>\@nameuse{scr@v@2.96}\relax + \endgroup + \penalty20010 + \else + \penalty\@highpenalty + \endgroup + \fi + \fi +} +\renewcommand*\l@chapter[2]{% + \ifnum \c@tocdepth >\m@ne + \ifnum \lastpenalty<20010 + \addpenalty{-\@highpenalty}% + \fi + \vskip 1.0em \@plus\p@ + \setlength\@tempdima{1.5em}% + \if@tocleft + \ifx\toc@l@number\@empty\else + \setlength\@tempdima{0\toc@l@number}% + \fi + \fi + \begingroup + \raggedchapterentry + \parindent \z@ \advance\if@RTL\leftskip\else\rightskip\fi \@pnumwidth + \parfillskip -\@pnumwidth + \interlinepenalty\@M + \leavevmode + \advance\if@RTL\rightskip\else\leftskip\fi \@tempdima \null\nobreak\hskip -\if@RTL\rightskip\else\leftskip\fi + \usekomafont{chapterentry}{#1\nobreak + \usekomafont{chapterentrypagenumber}{% + \hfill\nobreak + \hb@xt@\@pnumwidth{\hss#2}}}\par + \ifnum \scr@compatibility>\@nameuse{scr@v@2.96}\relax + \endgroup + \penalty20009 + \else + \penalty\@highpenalty + \endgroup + \fi + \fi +} +\def\raggedsection{\if@RTL\raggedleft\else\raggedright\fi} +\renewcommand*\autodot{\if@altsecnumformat\@SepMark\fi} +\renewcommand*\thesection{% + \ifnum \scr@compatibility>\@nameuse{scr@v@2.97d}\relax + \if@mainmatter\thechapter\@SepMark\fi + \else + \thechapter\@SepMark% + \fi + \@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*\thefigure{% + \ifnum \scr@compatibility>\@nameuse{scr@v@2.97d}\relax + \if@mainmatter\thechapter\@SepMark\fi + \else + \thechapter\@SepMark% + \fi + \@arabic\c@figure +} +\renewcommand*\thetable{% + \ifnum \scr@compatibility>\@nameuse{scr@v@2.97d}\relax + \if@mainmatter\thechapter\@SepMark\fi + \else + \thechapter\@SepMark% + \fi + \@arabic\c@table +} +\renewcommand*\theequation{% + \ifnum \scr@compatibility>\@nameuse{scr@v@2.97d}\relax + \if@mainmatter\thechapter\@SepMark\fi + \else + \thechapter\@SepMark% + \fi + \@arabic\c@equation +} +%% +%% Copyright © 2009-2010 by Vafa Khalighi +%% +%% Distributable 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 "maintained" (as per LPPL maintenance status) +%% by Vafa Khalighi. +%% +%% +%% +%% +%% +%% End of file `scrbook-xetex-bidi.def'. diff --git a/Master/texmf-dist/tex/xelatex/bidi/scrreprt-bidi.def b/Master/texmf-dist/tex/xelatex/bidi/scrreprt-bidi.def deleted file mode 100644 index 8893e6eee9a..00000000000 --- a/Master/texmf-dist/tex/xelatex/bidi/scrreprt-bidi.def +++ /dev/null @@ -1,277 +0,0 @@ -%% -%% This is file `scrreprt-bidi.def', - -%% -%% __________________________________ -%% Copyright © 2009-2010 Vafa Khalighi -%% -%% License information appended. -%% -%% -\ProvidesFile{scrreprt-bidi.def}[2010/03/01 v0.1 adaptations for scrreprt class] -\renewcommand*\maketitle[1][1]{% - \if@titlepage - \begin{titlepage} - \setcounter{page}{% - #1% - }% - \let\footnotesize\small - \let\footnoterule\relax - \let\footnote\thanks - \let\LTRfootnote\LTRthanks - \let\RTLfootnote\RTLthanks - \renewcommand*\thefootnote{\@fnsymbol\c@footnote}% - \let\@oldmakefnmark\@makefnmark - \renewcommand*{\@makefnmark}{\rlap\@oldmakefnmark}% - \ifx\@extratitle\@empty \else - \noindent\@extratitle\next@tpage\cleardoubleemptypage - \thispagestyle{empty}% - \fi - \setparsizes{\z@}{\z@}{\z@\@plus 1fil}\par@updaterelative - \ifx\@titlehead\@empty \else - \begin{minipage}[t]{\textwidth}% - \@titlehead - \end{minipage}\par - \fi - \null\vfill - \begin{center} - \ifx\@subject\@empty \else - {\subject@font \@subject \par}% - \vskip 3em - \fi - {\titlefont\huge \@title\par}% - \vskip 1em - {\ifx\@subtitle\@empty\else\usekomafont{subtitle}\@subtitle\par\fi}% - \vskip 2em - {\Large \lineskip 0.75em - \begin{tabular}[t]{c} - \@author - \end{tabular}\par - }% - \vskip 1.5em - {\Large \@date \par}% - \vskip \z@ \@plus3fill - {\Large \@publishers \par}% - \vskip 3em - \end{center}\par - \@thanks - \vfill\null - \if@twoside\next@tpage - \begin{minipage}[t]{\textwidth} - \@uppertitleback - \end{minipage}\par - \vfill - \begin{minipage}[b]{\textwidth} - \@lowertitleback - \end{minipage} - \fi - \ifx\@dedication\@empty \else - \next@tpage\null\vfill - {\centering \Large \@dedication \par}% - \vskip \z@ \@plus3fill - \if@twoside \next@tpage\cleardoubleemptypage \fi - \fi - \end{titlepage} - \else - \par - \@tempcnta=% - #1% - \relax\ifnum\@tempcnta=1\else - \ClassWarning{\KOMAClassName}{% - Optional argument of \string\maketitle\space ignored - at\MessageBreak - notitlepage-mode% - }% - \fi - \begingroup - \renewcommand*\thefootnote{\@fnsymbol\c@footnote}% - \let\@oldmakefnmark\@makefnmark - \renewcommand*{\@makefnmark}{\rlap\@oldmakefnmark} - \if@twocolumn - \ifnum \col@number=\@ne - \@maketitle - \else - \twocolumn[\@maketitle]% - \fi - \else - \newpage - \global\@topnum\z@ - \@maketitle - \fi - \thispagestyle{\titlepagestyle}\@thanks - \endgroup - \fi - \setcounter{footnote}{0}% - \let\thanks\relax - \let\LTRthanks\relax - \let\RTLthanks\relax - \let\maketitle\relax - \let\@maketitle\relax - \global\let\@thanks\@empty - \global\let\@author\@empty - \global\let\@date\@empty - \global\let\@title\@empty - \global\let\@subtitle\@empty - \global\let\@extratitle\@empty - \global\let\@titlehead\@empty - \global\let\@subject\@empty - \global\let\@publishers\@empty - \global\let\@uppertitleback\@empty - \global\let\@lowertitleback\@empty - \global\let\@dedication\@empty - \global\let\author\relax - \global\let\title\relax - \global\let\extratitle\relax - \global\let\titlehead\relax - \global\let\subject\relax - \global\let\publishers\relax - \global\let\uppertitleback\relax - \global\let\lowertitleback\relax - \global\let\dedication\relax - \global\let\date\relax - \global\let\and\relax -}% -\renewcommand*{\@maketitle}{% - \clearpage - \let\footnote\thanks - \let\LTRfootnote\LTRthanks - \let\RTLfootnote\RTLthanks - \ifx\@extratitle\@empty \else - \noindent\@extratitle \next@tpage \if@twoside \null\next@tpage \fi - \fi - \setparsizes{\z@}{\z@}{\z@\@plus 1fil}\par@updaterelative - \ifx\@titlehead\@empty \else - \begin{minipage}[t]{\textwidth} - \@titlehead - \end{minipage}\par - \fi - \null - \vskip 2em% - \begin{center}% - \ifx\@subject\@empty \else - {\subject@font \@subject \par} - \vskip 1.5em - \fi - {\titlefont\huge \@title \par}% - \vskip .5em - {\ifx\@subtitle\@empty\else\usekomafont{subtitle}\@subtitle\par\fi}% - \vskip 1em - {\Large - \lineskip .5em% - \begin{tabular}[t]{c} - \@author - \end{tabular}\par - }% - \vskip 1em% - {\Large \@date \par}% - \vskip \z@ \@plus 1em - {\Large \@publishers \par} - \ifx\@dedication\@empty \else - \vskip 2em - {\Large \@dedication \par} - \fi - \end{center}% - \par - \vskip 2em -}% -\renewcommand*\l@part[2]{% - \ifnum \c@tocdepth >-2\relax - \addpenalty{-\@highpenalty}% - \addvspace{2.25em \@plus\p@}% - \setlength{\@tempdima}{2em}% - \if@tocleft - \ifx\toc@l@number\@empty\else - \setlength\@tempdima{0\toc@l@number}% - \fi - \fi - \begingroup - \parindent \z@ \if@RTL\leftskip\else\rightskip\fi \@pnumwidth - \parfillskip -\@pnumwidth - \leavevmode - \advance\if@RTL\rightskip\else\leftskip\fi\@tempdima - \hskip -\if@RTL\rightskip\else\leftskip\fi - \usekomafont{partentry}{#1\nobreak - \usekomafont{partentrypagenumber}{\hfil\nobreak - \hb@xt@\@pnumwidth{\hss#2}}}\par - \ifnum \scr@compatibility>\@nameuse{scr@v@2.96}\relax - \endgroup - \penalty20010 - \else - \penalty\@highpenalty - \endgroup - \fi - \fi -} -\renewcommand*\l@chapter[2]{% - \ifnum \c@tocdepth >\m@ne - \ifnum \lastpenalty<20010 - \addpenalty{-\@highpenalty}% - \fi - \vskip 1.0em \@plus\p@ - \setlength\@tempdima{1.5em}% - \if@tocleft - \ifx\toc@l@number\@empty\else - \setlength\@tempdima{0\toc@l@number}% - \fi - \fi - \begingroup - \raggedchapterentry - \parindent \z@ \advance\if@RTL\leftskip\else\rightskip\fi \@pnumwidth - \parfillskip -\@pnumwidth - \interlinepenalty\@M - \leavevmode - \advance\if@RTL\rightskip\else\leftskip\fi \@tempdima \null\nobreak\hskip -\if@RTL\rightskip\else\leftskip\fi - \usekomafont{chapterentry}{#1\nobreak - \usekomafont{chapterentrypagenumber}{% - \hfill\nobreak - \hb@xt@\@pnumwidth{\hss#2}}}\par - \ifnum \scr@compatibility>\@nameuse{scr@v@2.96}\relax - \endgroup - \penalty20009 - \else - \penalty\@highpenalty - \endgroup - \fi - \fi -} -\def\raggedsection{\if@RTL\raggedleft\else\raggedright\fi} -\renewcommand*\autodot{\if@altsecnumformat\@SepMark\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*\thefigure{% - \thechapter\@SepMark% - \@arabic\c@figure -} -\renewcommand*\thetable{% - \thechapter\@SepMark% - \@arabic\c@table -} -\renewcommand*\theequation{% - \thechapter\@SepMark% - \@arabic\c@equation -} -%% -%% Copyright © 2009-2010 by Vafa Khalighi -%% -%% Distributable 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 "maintained" (as per LPPL maintenance status) -%% by Vafa Khalighi. -%% -%% -%% -%% -%% -%% End of file `scrreprt-bidi.def'. diff --git a/Master/texmf-dist/tex/xelatex/bidi/scrreprt-xetex-bidi.def b/Master/texmf-dist/tex/xelatex/bidi/scrreprt-xetex-bidi.def new file mode 100644 index 00000000000..efe0fa29c24 --- /dev/null +++ b/Master/texmf-dist/tex/xelatex/bidi/scrreprt-xetex-bidi.def @@ -0,0 +1,277 @@ +%% +%% This is file `scrreprt-xetex-bidi.def', + +%% +%% __________________________________ +%% Copyright © 2009-2010 Vafa Khalighi +%% +%% License information appended. +%% +%% +\ProvidesFile{scrreprt-xetex-bidi.def}[2010/07/25 v0.1 bidi adaptations for scrreprt class for XeTeX engine] +\renewcommand*\maketitle[1][1]{% + \if@titlepage + \begin{titlepage} + \setcounter{page}{% + #1% + }% + \let\footnotesize\small + \let\footnoterule\relax + \let\footnote\thanks + \let\LTRfootnote\LTRthanks + \let\RTLfootnote\RTLthanks + \renewcommand*\thefootnote{\@fnsymbol\c@footnote}% + \let\@oldmakefnmark\@makefnmark + \renewcommand*{\@makefnmark}{\rlap\@oldmakefnmark}% + \ifx\@extratitle\@empty \else + \noindent\@extratitle\next@tpage\cleardoubleemptypage + \thispagestyle{empty}% + \fi + \setparsizes{\z@}{\z@}{\z@\@plus 1fil}\par@updaterelative + \ifx\@titlehead\@empty \else + \begin{minipage}[t]{\textwidth}% + \@titlehead + \end{minipage}\par + \fi + \null\vfill + \begin{center} + \ifx\@subject\@empty \else + {\subject@font \@subject \par}% + \vskip 3em + \fi + {\titlefont\huge \@title\par}% + \vskip 1em + {\ifx\@subtitle\@empty\else\usekomafont{subtitle}\@subtitle\par\fi}% + \vskip 2em + {\Large \lineskip 0.75em + \begin{tabular}[t]{c} + \@author + \end{tabular}\par + }% + \vskip 1.5em + {\Large \@date \par}% + \vskip \z@ \@plus3fill + {\Large \@publishers \par}% + \vskip 3em + \end{center}\par + \@thanks + \vfill\null + \if@twoside\next@tpage + \begin{minipage}[t]{\textwidth} + \@uppertitleback + \end{minipage}\par + \vfill + \begin{minipage}[b]{\textwidth} + \@lowertitleback + \end{minipage} + \fi + \ifx\@dedication\@empty \else + \next@tpage\null\vfill + {\centering \Large \@dedication \par}% + \vskip \z@ \@plus3fill + \if@twoside \next@tpage\cleardoubleemptypage \fi + \fi + \end{titlepage} + \else + \par + \@tempcnta=% + #1% + \relax\ifnum\@tempcnta=1\else + \ClassWarning{\KOMAClassName}{% + Optional argument of \string\maketitle\space ignored + at\MessageBreak + notitlepage-mode% + }% + \fi + \begingroup + \renewcommand*\thefootnote{\@fnsymbol\c@footnote}% + \let\@oldmakefnmark\@makefnmark + \renewcommand*{\@makefnmark}{\rlap\@oldmakefnmark} + \if@twocolumn + \ifnum \col@number=\@ne + \@maketitle + \else + \twocolumn[\@maketitle]% + \fi + \else + \newpage + \global\@topnum\z@ + \@maketitle + \fi + \thispagestyle{\titlepagestyle}\@thanks + \endgroup + \fi + \setcounter{footnote}{0}% + \let\thanks\relax + \let\LTRthanks\relax + \let\RTLthanks\relax + \let\maketitle\relax + \let\@maketitle\relax + \global\let\@thanks\@empty + \global\let\@author\@empty + \global\let\@date\@empty + \global\let\@title\@empty + \global\let\@subtitle\@empty + \global\let\@extratitle\@empty + \global\let\@titlehead\@empty + \global\let\@subject\@empty + \global\let\@publishers\@empty + \global\let\@uppertitleback\@empty + \global\let\@lowertitleback\@empty + \global\let\@dedication\@empty + \global\let\author\relax + \global\let\title\relax + \global\let\extratitle\relax + \global\let\titlehead\relax + \global\let\subject\relax + \global\let\publishers\relax + \global\let\uppertitleback\relax + \global\let\lowertitleback\relax + \global\let\dedication\relax + \global\let\date\relax + \global\let\and\relax +}% +\renewcommand*{\@maketitle}{% + \clearpage + \let\footnote\thanks + \let\LTRfootnote\LTRthanks + \let\RTLfootnote\RTLthanks + \ifx\@extratitle\@empty \else + \noindent\@extratitle \next@tpage \if@twoside \null\next@tpage \fi + \fi + \setparsizes{\z@}{\z@}{\z@\@plus 1fil}\par@updaterelative + \ifx\@titlehead\@empty \else + \begin{minipage}[t]{\textwidth} + \@titlehead + \end{minipage}\par + \fi + \null + \vskip 2em% + \begin{center}% + \ifx\@subject\@empty \else + {\subject@font \@subject \par} + \vskip 1.5em + \fi + {\titlefont\huge \@title \par}% + \vskip .5em + {\ifx\@subtitle\@empty\else\usekomafont{subtitle}\@subtitle\par\fi}% + \vskip 1em + {\Large + \lineskip .5em% + \begin{tabular}[t]{c} + \@author + \end{tabular}\par + }% + \vskip 1em% + {\Large \@date \par}% + \vskip \z@ \@plus 1em + {\Large \@publishers \par} + \ifx\@dedication\@empty \else + \vskip 2em + {\Large \@dedication \par} + \fi + \end{center}% + \par + \vskip 2em +}% +\renewcommand*\l@part[2]{% + \ifnum \c@tocdepth >-2\relax + \addpenalty{-\@highpenalty}% + \addvspace{2.25em \@plus\p@}% + \setlength{\@tempdima}{2em}% + \if@tocleft + \ifx\toc@l@number\@empty\else + \setlength\@tempdima{0\toc@l@number}% + \fi + \fi + \begingroup + \parindent \z@ \if@RTL\leftskip\else\rightskip\fi \@pnumwidth + \parfillskip -\@pnumwidth + \leavevmode + \advance\if@RTL\rightskip\else\leftskip\fi\@tempdima + \hskip -\if@RTL\rightskip\else\leftskip\fi + \usekomafont{partentry}{#1\nobreak + \usekomafont{partentrypagenumber}{\hfil\nobreak + \hb@xt@\@pnumwidth{\hss#2}}}\par + \ifnum \scr@compatibility>\@nameuse{scr@v@2.96}\relax + \endgroup + \penalty20010 + \else + \penalty\@highpenalty + \endgroup + \fi + \fi +} +\renewcommand*\l@chapter[2]{% + \ifnum \c@tocdepth >\m@ne + \ifnum \lastpenalty<20010 + \addpenalty{-\@highpenalty}% + \fi + \vskip 1.0em \@plus\p@ + \setlength\@tempdima{1.5em}% + \if@tocleft + \ifx\toc@l@number\@empty\else + \setlength\@tempdima{0\toc@l@number}% + \fi + \fi + \begingroup + \raggedchapterentry + \parindent \z@ \advance\if@RTL\leftskip\else\rightskip\fi \@pnumwidth + \parfillskip -\@pnumwidth + \interlinepenalty\@M + \leavevmode + \advance\if@RTL\rightskip\else\leftskip\fi \@tempdima \null\nobreak\hskip -\if@RTL\rightskip\else\leftskip\fi + \usekomafont{chapterentry}{#1\nobreak + \usekomafont{chapterentrypagenumber}{% + \hfill\nobreak + \hb@xt@\@pnumwidth{\hss#2}}}\par + \ifnum \scr@compatibility>\@nameuse{scr@v@2.96}\relax + \endgroup + \penalty20009 + \else + \penalty\@highpenalty + \endgroup + \fi + \fi +} +\def\raggedsection{\if@RTL\raggedleft\else\raggedright\fi} +\renewcommand*\autodot{\if@altsecnumformat\@SepMark\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*\thefigure{% + \thechapter\@SepMark% + \@arabic\c@figure +} +\renewcommand*\thetable{% + \thechapter\@SepMark% + \@arabic\c@table +} +\renewcommand*\theequation{% + \thechapter\@SepMark% + \@arabic\c@equation +} +%% +%% Copyright © 2009-2010 by Vafa Khalighi +%% +%% Distributable 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 "maintained" (as per LPPL maintenance status) +%% by Vafa Khalighi. +%% +%% +%% +%% +%% +%% End of file `scrreprt-xetex-bidi.def'. diff --git a/Master/texmf-dist/tex/xelatex/bidi/stabular-bidi.def b/Master/texmf-dist/tex/xelatex/bidi/stabular-bidi.def deleted file mode 100644 index 58b3c837a9a..00000000000 --- a/Master/texmf-dist/tex/xelatex/bidi/stabular-bidi.def +++ /dev/null @@ -1,52 +0,0 @@ -%% -%% This is file `stabular-bidi.def', - -%% -%% __________________________________ -%% Copyright © 2009-2010 Vafa Khalighi -%% -%% License information appended. -%% -%% -\ProvidesFile{stabular-bidi.def}[2010/03/01 v0.1 adaptations for stabular package] -\def\@stabular{\if@RTL\global\@RTLtabtrue\fi - \leavevmode \bgroup \if@RTLtab\beginR \fi - \let\@acol\@tabacol - \let\@classz\@tabclassz - \let\@classiv\@tabclassiv \let\\\@tabularcr\@stabarray} -\def\endstabular{\crcr\egroup\if@RTLtab\egroup\endR\egroup\fi - \egroup \if@RTLtab\endR\fi\egroup - \global\@RTLtabfalse} -\expandafter \let \csname endstabular*\endcsname = \endstabular -\def\@sarray[#1]#2{% - \bgroup - \setbox\@arstrutbox\hbox{% - \vrule \@height\arraystretch\ht\strutbox - \@depth\arraystretch \dp\strutbox - \@width\z@}% - \@mkpream{#2}% - \edef\@preamble{% - \ialign \noexpand\@halignto - \bgroup \@arstrut \@preamble \tabskip\z@skip \cr}% - \let\@startpbox\@@startpbox \let\@endpbox\@@endpbox - \let\tabularnewline\\% - \let\@sharp##% - \set@typeset@protect - \lineskip\z@skip\baselineskip\z@skip - \if@RTLtab\hbox\bgroup\beginR\vbox\bgroup\fi - \@preamble} -%% -%% Copyright © 2009-2010 by Vafa Khalighi -%% -%% Distributable 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 "maintained" (as per LPPL maintenance status) -%% by Vafa Khalighi. -%% -%% -%% -%% -%% -%% End of file `stabular-bidi.def'. diff --git a/Master/texmf-dist/tex/xelatex/bidi/stabular-xetex-bidi.def b/Master/texmf-dist/tex/xelatex/bidi/stabular-xetex-bidi.def new file mode 100644 index 00000000000..d64969296fe --- /dev/null +++ b/Master/texmf-dist/tex/xelatex/bidi/stabular-xetex-bidi.def @@ -0,0 +1,52 @@ +%% +%% This is file `stabular-xetex-bidi.def', + +%% +%% __________________________________ +%% Copyright © 2009-2010 Vafa Khalighi +%% +%% License information appended. +%% +%% +\ProvidesFile{stabular-xetex-bidi.def}[2010/07/25 v0.1 bidi adaptations for stabular package for XeTeX engine] +\def\@stabular{\if@RTL\global\@RTLtabtrue\fi + \leavevmode \bgroup \if@RTLtab\beginR \fi + \let\@acol\@tabacol + \let\@classz\@tabclassz + \let\@classiv\@tabclassiv \let\\\@tabularcr\@stabarray} +\def\endstabular{\crcr\egroup\if@RTLtab\egroup\endR\egroup\fi + \egroup \if@RTLtab\endR\fi\egroup + \global\@RTLtabfalse} +\expandafter \let \csname endstabular*\endcsname = \endstabular +\def\@sarray[#1]#2{% + \bgroup + \setbox\@arstrutbox\hbox{% + \vrule \@height\arraystretch\ht\strutbox + \@depth\arraystretch \dp\strutbox + \@width\z@}% + \@mkpream{#2}% + \edef\@preamble{% + \ialign \noexpand\@halignto + \bgroup \@arstrut \@preamble \tabskip\z@skip \cr}% + \let\@startpbox\@@startpbox \let\@endpbox\@@endpbox + \let\tabularnewline\\% + \let\@sharp##% + \set@typeset@protect + \lineskip\z@skip\baselineskip\z@skip + \if@RTLtab\hbox\bgroup\beginR\vbox\bgroup\fi + \@preamble} +%% +%% Copyright © 2009-2010 by Vafa Khalighi +%% +%% Distributable 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 "maintained" (as per LPPL maintenance status) +%% by Vafa Khalighi. +%% +%% +%% +%% +%% +%% End of file `stabular-xetex-bidi.def'. diff --git a/Master/texmf-dist/tex/xelatex/bidi/subfigure-xetex-bidi.def b/Master/texmf-dist/tex/xelatex/bidi/subfigure-xetex-bidi.def new file mode 100644 index 00000000000..24dda09a62a --- /dev/null +++ b/Master/texmf-dist/tex/xelatex/bidi/subfigure-xetex-bidi.def @@ -0,0 +1,30 @@ +%% +%% This is file `subfigure-xetex-bidi.def', + +%% +%% __________________________________ +%% Copyright © 2009-2010 Vafa Khalighi +%% +%% License information appended. +%% +%% +\ProvidesFile{subfigure-xetex-bidi.def}[2010/03/01 v0.1 bidi adaptations for subfigure package for XeTeX engine] +\AtBeginDocument{% +\let\p@subfigure=\thefigure +\let\p@subtable=\thetable% +} +%% +%% Copyright © 2009-2010 by Vafa Khalighi +%% +%% Distributable 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 "maintained" (as per LPPL maintenance status) +%% by Vafa Khalighi. +%% +%% +%% +%% +%% +%% End of file `subfigure-xetex-bidi.def'. diff --git a/Master/texmf-dist/tex/xelatex/bidi/tabls-bidi.def b/Master/texmf-dist/tex/xelatex/bidi/tabls-bidi.def deleted file mode 100644 index caa17c1eed9..00000000000 --- a/Master/texmf-dist/tex/xelatex/bidi/tabls-bidi.def +++ /dev/null @@ -1,60 +0,0 @@ -%% -%% This is file `tabls-bidi.def', - -%% -%% __________________________________ -%% Copyright © 2009-2010 Vafa Khalighi -%% -%% License information appended. -%% -%% -\ProvidesFile{tabls-bidi.def}[2010/03/01 v0.1 adaptations for tabls package] -\def\endtabular{\endarray $\if@RTLtab\endR\fi\egroup - \global\@RTLtabfalse} - -\expandafter\let\csname endtabular*\endcsname=\endtabular - -\def\endarray{\ifvmode\csname crcr\endcsname % just do \crcr if \\ given - \else \\[\z@ \global\advance\@arstdepth-\@otarlinesep]% - \fi\egroup\if@RTLtab\egroup\endR\egroup\fi\@unrecurse\egroup} - -\def\@array[#1]#2{% remember global variables to allow recursion: - \edef\@unrecurse{\global\@skip@bove\the\@skip@bove - \global\@arstheight\the\@arstheight\global\@arstdepth\the\@arstdepth}% - \let\@otarlinesep\@tarlinesep \global\@skip@bove-\@otarlinesep - \ifx\@classz\@arrayclassz \let\@tarlinesep\arraylinesep - \else \let\@tarlinesep\tablinesep \fi - \divide\@tarlinesep\tw@ % half sep is applied to height & depth - \let\@seesize\relax \let\@rememsize\relax \@mkpream{#2}% - \@tempdima\arraystretch\ht\strutbox \@tempdimb\arraystretch\dp\strutbox - \ifdim\@tarlinesep>\z@ % (need \protect for \multicolumn) - \def\@rememsize{\protect\@r@m@msize}\let\@seesize\@s@@size - \advance\@tempdima-\@tarlinesep \advance\@tempdimb-\@tarlinesep - \fi \setbox\@arstrutbox\hbox{% set up smaller strut - \vrule \@height\@tempdima \@depth\@tempdimb \@width\z@}% - \let\protect\noexpand - \edef\@preamble{\ialign \noexpand\@halignto \bgroup - \unhcopy\@arstrutbox \@preamble \tabskip\z@skip &\@sharp \cr}% - \let\@startpbox\@@startpbox \let\@endpbox\@@endpbox - \if#1t\vtop \else \if#1b\vbox \else \vcenter \fi\fi - \bgroup \let\par\@empty - \global\@arstheight\ht\@arstrutbox \global\@arstdepth\dp\@arstrutbox - \advance\extrarulesep.5\arrayrulewidth - \let\@sharp##\let\protect\relax \lineskip\z@skip \baselineskip\z@skip - \if@RTLtab\hbox\bgroup\beginR\vbox\bgroup\fi - \@preamble} -%% -%% Copyright © 2009-2010 by Vafa Khalighi -%% -%% Distributable 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 "maintained" (as per LPPL maintenance status) -%% by Vafa Khalighi. -%% -%% -%% -%% -%% -%% End of file `tabls-bidi.def'. diff --git a/Master/texmf-dist/tex/xelatex/bidi/tabls-xetex-bidi.def b/Master/texmf-dist/tex/xelatex/bidi/tabls-xetex-bidi.def new file mode 100644 index 00000000000..c0913650d74 --- /dev/null +++ b/Master/texmf-dist/tex/xelatex/bidi/tabls-xetex-bidi.def @@ -0,0 +1,60 @@ +%% +%% This is file `tabls-xetex-bidi.def', + +%% +%% __________________________________ +%% Copyright © 2009-2010 Vafa Khalighi +%% +%% License information appended. +%% +%% +\ProvidesFile{tabls-xetex-bidi.def}[2010/07/25 v0.1 bidi adaptations for tabls package for XeTeX engine] +\def\endtabular{\endarray $\if@RTLtab\endR\fi\egroup + \global\@RTLtabfalse} + +\expandafter\let\csname endtabular*\endcsname=\endtabular + +\def\endarray{\ifvmode\csname crcr\endcsname % just do \crcr if \\ given + \else \\[\z@ \global\advance\@arstdepth-\@otarlinesep]% + \fi\egroup\if@RTLtab\egroup\endR\egroup\fi\@unrecurse\egroup} + +\def\@array[#1]#2{% remember global variables to allow recursion: + \edef\@unrecurse{\global\@skip@bove\the\@skip@bove + \global\@arstheight\the\@arstheight\global\@arstdepth\the\@arstdepth}% + \let\@otarlinesep\@tarlinesep \global\@skip@bove-\@otarlinesep + \ifx\@classz\@arrayclassz \let\@tarlinesep\arraylinesep + \else \let\@tarlinesep\tablinesep \fi + \divide\@tarlinesep\tw@ % half sep is applied to height & depth + \let\@seesize\relax \let\@rememsize\relax \@mkpream{#2}% + \@tempdima\arraystretch\ht\strutbox \@tempdimb\arraystretch\dp\strutbox + \ifdim\@tarlinesep>\z@ % (need \protect for \multicolumn) + \def\@rememsize{\protect\@r@m@msize}\let\@seesize\@s@@size + \advance\@tempdima-\@tarlinesep \advance\@tempdimb-\@tarlinesep + \fi \setbox\@arstrutbox\hbox{% set up smaller strut + \vrule \@height\@tempdima \@depth\@tempdimb \@width\z@}% + \let\protect\noexpand + \edef\@preamble{\ialign \noexpand\@halignto \bgroup + \unhcopy\@arstrutbox \@preamble \tabskip\z@skip &\@sharp \cr}% + \let\@startpbox\@@startpbox \let\@endpbox\@@endpbox + \if#1t\vtop \else \if#1b\vbox \else \vcenter \fi\fi + \bgroup \let\par\@empty + \global\@arstheight\ht\@arstrutbox \global\@arstdepth\dp\@arstrutbox + \advance\extrarulesep.5\arrayrulewidth + \let\@sharp##\let\protect\relax \lineskip\z@skip \baselineskip\z@skip + \if@RTLtab\hbox\bgroup\beginR\vbox\bgroup\fi + \@preamble} +%% +%% Copyright © 2009-2010 by Vafa Khalighi +%% +%% Distributable 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 "maintained" (as per LPPL maintenance status) +%% by Vafa Khalighi. +%% +%% +%% +%% +%% +%% End of file `tabls-xetex-bidi.def'. diff --git a/Master/texmf-dist/tex/xelatex/bidi/tabulary-bidi.def b/Master/texmf-dist/tex/xelatex/bidi/tabulary-bidi.def deleted file mode 100644 index 266127839e9..00000000000 --- a/Master/texmf-dist/tex/xelatex/bidi/tabulary-bidi.def +++ /dev/null @@ -1,55 +0,0 @@ -%% -%% This is file `tabulary-bidi.def', - -%% -%% __________________________________ -%% Copyright © 2009-2010 Vafa Khalighi -%% -%% License information appended. -%% -%% -\ProvidesFile{tabulary-bidi.def}[2010/03/01 v0.1 adaptations for tabulary package] -\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 - \if \@nextchar C7 \else - \if \@nextchar L8 \else - \if \@nextchar R9 \else - \if \@nextchar J10 \else - \z@ \@chclass - \if\@nextchar |\@ne \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 \fi \fi} -%% -%% Copyright © 2009-2010 by Vafa Khalighi -%% -%% Distributable 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 "maintained" (as per LPPL maintenance status) -%% by Vafa Khalighi. -%% -%% -%% -%% -%% -%% End of file `tabulary-bidi.def'. diff --git a/Master/texmf-dist/tex/xelatex/bidi/tabulary-xetex-bidi.def b/Master/texmf-dist/tex/xelatex/bidi/tabulary-xetex-bidi.def new file mode 100644 index 00000000000..83a57ae8eb1 --- /dev/null +++ b/Master/texmf-dist/tex/xelatex/bidi/tabulary-xetex-bidi.def @@ -0,0 +1,55 @@ +%% +%% This is file `tabulary-xetex-bidi.def', + +%% +%% __________________________________ +%% Copyright © 2009-2010 Vafa Khalighi +%% +%% License information appended. +%% +%% +\ProvidesFile{tabulary-xetex-bidi.def}[2010/07/25 v0.1 bidi adaptations for tabulary package for XeTeX engine] +\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 + \if \@nextchar C7 \else + \if \@nextchar L8 \else + \if \@nextchar R9 \else + \if \@nextchar J10 \else + \z@ \@chclass + \if\@nextchar |\@ne \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 \fi \fi} +%% +%% Copyright © 2009-2010 by Vafa Khalighi +%% +%% Distributable 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 "maintained" (as per LPPL maintenance status) +%% by Vafa Khalighi. +%% +%% +%% +%% +%% +%% End of file `tabulary-xetex-bidi.def'. diff --git a/Master/texmf-dist/tex/xelatex/bidi/tikz-bidi.def b/Master/texmf-dist/tex/xelatex/bidi/tikz-bidi.def deleted file mode 100644 index b384fdc082f..00000000000 --- a/Master/texmf-dist/tex/xelatex/bidi/tikz-bidi.def +++ /dev/null @@ -1,30 +0,0 @@ -%% -%% This is file `tikz-bidi.def', - -%% -%% __________________________________ -%% Copyright © 2009-2010 Vafa Khalighi -%% -%% License information appended. -%% -%% -\ProvidesFile{tikz-bidi.def}[2010/03/01 v0.1 adaptations for tikz package] -\let\origin@tikzpicture=\tikzpicture -\let\origin@endtikzpicture=\endtikzpicture -\def\tikzpicture{\LTR\origin@tikzpicture} -\def\endtikzpicture{\origin@endtikzpicture\endLTR} -%% -%% Copyright © 2009-2010 by Vafa Khalighi -%% -%% Distributable 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 "maintained" (as per LPPL maintenance status) -%% by Vafa Khalighi. -%% -%% -%% -%% -%% -%% End of file `tikz-bidi.def'. diff --git a/Master/texmf-dist/tex/xelatex/bidi/tikz-xetex-bidi.def b/Master/texmf-dist/tex/xelatex/bidi/tikz-xetex-bidi.def new file mode 100644 index 00000000000..dce434239c2 --- /dev/null +++ b/Master/texmf-dist/tex/xelatex/bidi/tikz-xetex-bidi.def @@ -0,0 +1,30 @@ +%% +%% This is file `tikz-xetex-bidi.def', + +%% +%% __________________________________ +%% Copyright © 2009-2010 Vafa Khalighi +%% +%% License information appended. +%% +%% +\ProvidesFile{tikz-xetex-bidi.def}[2010/07/25 v0.2 bidi adaptations for tikz package for XeTeX engine] +\let\origin@tikzpicture=\tikzpicture +\let\origin@endtikzpicture=\endtikzpicture +\def\tikzpicture{\ifmmode\else\LTR\fi\origin@tikzpicture} +\def\endtikzpicture{\origin@endtikzpicture\ifmmode\else\endLTR\fi} +%% +%% Copyright © 2009-2010 by Vafa Khalighi +%% +%% Distributable 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 "maintained" (as per LPPL maintenance status) +%% by Vafa Khalighi. +%% +%% +%% +%% +%% +%% End of file `tikz-xetex-bidi.def'. diff --git a/Master/texmf-dist/tex/xelatex/bidi/tocbibind-bidi.def b/Master/texmf-dist/tex/xelatex/bidi/tocbibind-bidi.def deleted file mode 100644 index 81826afc359..00000000000 --- a/Master/texmf-dist/tex/xelatex/bidi/tocbibind-bidi.def +++ /dev/null @@ -1,55 +0,0 @@ -%% -%% This is file `tocbibind-bidi.def', - -%% -%% __________________________________ -%% Copyright © 2009-2010 Vafa Khalighi -%% -%% License information appended. -%% -%% -\ProvidesFile{tocbibind-bidi.def}[2010/03/01 v0.1 adaptations for tocbibind package] -\if@dotocbib - \@ifpackageloaded{natbib}{}{% natbib not loaded - \renewcommand{\bibsection}{\t@cb@bchapsec} - \renewenvironment{thebibliography}[1]{% - \bibsection - \begin{thebibitemlist}{#1}}{\end{thebibitemlist}}} - \renewenvironment{thebibitemlist}[1]{ - \list{\@biblabel{\@arabic\c@enumiv}}% - {\settowidth\labelwidth{\@biblabel{#1}}% - \leftmargin\labelwidth - \advance\leftmargin\labelsep - \@openbib@code - \usecounter{enumiv}% - \let\p@enumiv\@empty - \renewcommand\theenumiv{\@arabic\c@enumiv}}% - \sloppy - \clubpenalty4000 - \@clubpenalty \clubpenalty - \widowpenalty4000% - \sfcode`\.\@m} - {\def\@noitemerr - {\@latex@warning{Empty `thebibliography' environment}}% - \endlist} - - \@ifpackagewith{chapterbib}{sectionbib}% - {\renewcommand{\sectionbib}[2]{}}% - {} - -\fi -%% -%% Copyright © 2009-2010 by Vafa Khalighi -%% -%% Distributable 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 "maintained" (as per LPPL maintenance status) -%% by Vafa Khalighi. -%% -%% -%% -%% -%% -%% End of file `tocbibind-bidi.def'. diff --git a/Master/texmf-dist/tex/xelatex/bidi/tocbibind-xetex-bidi.def b/Master/texmf-dist/tex/xelatex/bidi/tocbibind-xetex-bidi.def new file mode 100644 index 00000000000..152dd4df373 --- /dev/null +++ b/Master/texmf-dist/tex/xelatex/bidi/tocbibind-xetex-bidi.def @@ -0,0 +1,55 @@ +%% +%% This is file `tocbibind-xetex-bidi.def', + +%% +%% __________________________________ +%% Copyright © 2009-2010 Vafa Khalighi +%% +%% License information appended. +%% +%% +\ProvidesFile{tocbibind-xetex-bidi.def}[2010/07/25 v0.1 bidi adaptations for tocbibind package for XeTeX engine] +\if@dotocbib + \@ifpackageloaded{natbib}{}{% natbib not loaded + \renewcommand{\bibsection}{\t@cb@bchapsec} + \renewenvironment{thebibliography}[1]{% + \bibsection + \begin{thebibitemlist}{#1}}{\end{thebibitemlist}}} + \renewenvironment{thebibitemlist}[1]{ + \list{\@biblabel{\@arabic\c@enumiv}}% + {\settowidth\labelwidth{\@biblabel{#1}}% + \leftmargin\labelwidth + \advance\leftmargin\labelsep + \@openbib@code + \usecounter{enumiv}% + \let\p@enumiv\@empty + \renewcommand\theenumiv{\@arabic\c@enumiv}}% + \sloppy + \clubpenalty4000 + \@clubpenalty \clubpenalty + \widowpenalty4000% + \sfcode`\.\@m} + {\def\@noitemerr + {\@latex@warning{Empty `thebibliography' environment}}% + \endlist} + + \@ifpackagewith{chapterbib}{sectionbib}% + {\renewcommand{\sectionbib}[2]{}}% + {} + +\fi +%% +%% Copyright © 2009-2010 by Vafa Khalighi +%% +%% Distributable 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 "maintained" (as per LPPL maintenance status) +%% by Vafa Khalighi. +%% +%% +%% +%% +%% +%% End of file `tocbibind-xetex-bidi.def'. diff --git a/Master/texmf-dist/tex/xelatex/bidi/tocloft-bidi.def b/Master/texmf-dist/tex/xelatex/bidi/tocloft-bidi.def deleted file mode 100644 index 7bd3ce6a3d6..00000000000 --- a/Master/texmf-dist/tex/xelatex/bidi/tocloft-bidi.def +++ /dev/null @@ -1,332 +0,0 @@ -%% -%% This is file `tocloft-bidi.def', - -%% -%% __________________________________ -%% Copyright © 2009-2010 Vafa Khalighi -%% -%% License information appended. -%% -%% -\ProvidesFile{tocloft-bidi.def}[2010/03/01 v0.1 adaptations for tocloft package] -\if@cfthaspart -\renewcommand*{\l@part}[2]{ - \@cftdopartfalse - \ifnum \c@tocdepth >-2\relax - \if@cfthaschapter - \@cftdoparttrue - \fi - \ifnum \c@tocdepth >\m@ne - \if@cfthaschapter\else - \@cftdoparttrue - \fi - \fi - \fi - \if@cftdopart - \if@cfthaschapter - \addpenalty{-\@highpenalty} - \else - \addpenalty\@secpenalty - \fi - \addvspace{\cftbeforepartskip} - \begingroup - {\if@RTL\rightskip\else\leftskip\fi \cftpartindent\relax - \if@RTL\leftskip\else\rightskip\fi \@tocrmarg - \parfillskip -\if@RTL\leftskip\else\rightskip\fi - \parindent \cftpartindent\relax\@afterindenttrue - \interlinepenalty\@M - \leavevmode - \@tempdima \cftpartnumwidth\relax - \let\@cftbsnum \cftpartpresnum - \let\@cftasnum \cftpartaftersnum - \let\@cftasnumb \cftpartaftersnumb - \advance\if@RTL\rightskip\else\leftskip\fi \@tempdima \null\nobreak\hskip -\if@RTL\rightskip\else\leftskip\fi - {\cftpartfont \cftpartpresnum #1} - \cftpartfillnum{#2}} - \nobreak - \if@cfthaschapter - \global\@nobreaktrue - \everypar{\global\@nobreakfalse\everypar{}} - \else - \if@compatibility - \global\@nobreaktrue - \everypar{\global\@nobreakfalse\everypar{}} - \fi - \fi - \endgroup - \fi} -\fi -\if@cfthaschapter -\renewcommand*{\l@chapter}[2]{ - \ifnum \c@tocdepth >\m@ne - \addpenalty{-\@highpenalty} - \vskip \cftbeforechapskip - {\if@RTL\rightskip\else\leftskip\fi \cftchapindent\relax - \if@RTL\leftskip\else\rightskip\fi \@tocrmarg - \parfillskip -\if@RTL\leftskip\else\rightskip\fi - \parindent \cftchapindent\relax\@afterindenttrue - \interlinepenalty\@M - \leavevmode - \@tempdima \cftchapnumwidth\relax - \let\@cftbsnum \cftchappresnum - \let\@cftasnum \cftchapaftersnum - \let\@cftasnumb \cftchapaftersnumb - \advance\if@RTL\rightskip\else\leftskip\fi \@tempdima \null\nobreak\hskip -\if@RTL\rightskip\else\leftskip\fi - {\cftchapfont #1}\nobreak - \cftchapfillnum{#2}} - \fi} -\fi -\renewcommand*{\l@section}[2]{% - \ifnum \c@tocdepth >\z@ - \if@cfthaschapter - \vskip \cftbeforesecskip - \else - \addpenalty\@secpenalty - \addvspace{\cftbeforesecskip} - \fi - {\if@RTL\rightskip\else\leftskip\fi \cftsecindent\relax - \if@RTL\leftskip\else\rightskip\fi \@tocrmarg - \parfillskip -\if@RTL\leftskip\else\rightskip\fi - \parindent \cftsecindent\relax\@afterindenttrue - \interlinepenalty\@M - \leavevmode - \@tempdima \cftsecnumwidth\relax - \let\@cftbsnum \cftsecpresnum - \let\@cftasnum \cftsecaftersnum - \let\@cftasnumb \cftsecaftersnumb - \advance\if@RTL\rightskip\else\leftskip\fi \@tempdima \null\nobreak\hskip -\if@RTL\rightskip\else\leftskip\fi - {\cftsecfont #1}\nobreak - \cftsecfillnum{#2}} - \fi} -\renewcommand*{\l@subsection}[2]{% - \ifnum \c@tocdepth >\@ne - \vskip \cftbeforesubsecskip - {\if@RTL\rightskip\else\leftskip\fi \cftsubsecindent\relax - \if@RTL\leftskip\else\rightskip\fi \@tocrmarg - \parfillskip -\if@RTL\leftskip\else\rightskip\fi - \parindent \cftsubsecindent\relax\@afterindenttrue - \interlinepenalty\@M - \leavevmode - \@tempdima \cftsubsecnumwidth\relax - \let\@cftbsnum \cftsubsecpresnum - \let\@cftasnum \cftsubsecaftersnum - \let\@cftasnumb \cftsubsecaftersnumb - \advance\if@RTL\rightskip\else\leftskip\fi \@tempdima \null\nobreak\hskip -\if@RTL\rightskip\else\leftskip\fi - {\cftsubsecfont #1}\nobreak - \cftsubsecfillnum{#2}} - \fi} -\renewcommand*{\l@subsubsection}[2]{% - \ifnum \c@tocdepth >\tw@ - \vskip \cftbeforesubsubsecskip - {\if@RTL\rightskip\else\leftskip\fi \cftsubsubsecindent\relax - \if@RTL\leftskip\else\rightskip\fi \@tocrmarg - \parfillskip -\if@RTL\leftskip\else\rightskip\fi - \parindent \cftsubsubsecindent\relax\@afterindenttrue - \interlinepenalty\@M - \leavevmode - \@tempdima \cftsubsubsecnumwidth\relax - \let\@cftbsnum \cftsubsubsecpresnum - \let\@cftasnum \cftsubsubsecaftersnum - \let\@cftasnumb \cftsubsubsecaftersnumb - \advance\if@RTL\rightskip\else\leftskip\fi \@tempdima \null\nobreak\hskip -\if@RTL\rightskip\else\leftskip\fi - {\cftsubsubsecfont #1}\nobreak - \cftsubsubsecfillnum{#2}} - \fi} -\renewcommand*{\l@paragraph}[2]{% - \ifnum \c@tocdepth >3\relax - \vskip \cftbeforeparaskip - {\if@RTL\rightskip\else\leftskip\fi \cftparaindent\relax - \if@RTL\leftskip\else\rightskip\fi \@tocrmarg - \parfillskip -\if@RTL\leftskip\else\rightskip\fi - \parindent \cftparaindent\relax\@afterindenttrue - \interlinepenalty\@M - \leavevmode - \@tempdima \cftparanumwidth\relax - \let\@cftbsnum \cftparapresnum - \let\@cftasnum \cftparaaftersnum - \let\@cftasnumb \cftparaaftersnumb - \advance\if@RTL\rightskip\else\leftskip\fi \@tempdima \null\nobreak\hskip -\if@RTL\rightskip\else\leftskip\fi - {\cftparafont #1}\nobreak - \cftparafillnum{#2}} - \fi} -\renewcommand*{\l@subparagraph}[2]{% - \ifnum \c@tocdepth >4\relax - \vskip \cftbeforesubparaskip - {\if@RTL\rightskip\else\leftskip\fi \cftsubparaindent\relax - \if@RTL\leftskip\else\rightskip\fi \@tocrmarg - \parfillskip -\if@RTL\leftskip\else\rightskip\fi - \parindent \cftsubparaindent\relax\@afterindenttrue - \interlinepenalty\@M - \leavevmode - \@tempdima \cftsubparanumwidth\relax - \let\@cftbsnum \cftsubparapresnum - \let\@cftasnum \cftsubparaaftersnum - \let\@cftasnumb \cftsubparaaftersnumb - \advance\if@RTL\rightskip\else\leftskip\fi \@tempdima \null\nobreak\hskip -\if@RTL\rightskip\else\leftskip\fi - {\cftsubparafont #1}\nobreak - \cftsubparafillnum{#2}} - \fi} -\renewcommand*{\l@figure}[2]{% - \ifnum \c@lofdepth >\z@ - \vskip \cftbeforefigskip - {\if@RTL\rightskip\else\leftskip\fi \cftfigindent\relax - \if@RTL\leftskip\else\rightskip\fi \@tocrmarg - \parfillskip -\if@RTL\leftskip\else\rightskip\fi - \parindent \cftfigindent\relax\@afterindenttrue - \interlinepenalty\@M - \leavevmode - \@tempdima \cftfignumwidth\relax - \let\@cftbsnum \cftfigpresnum - \let\@cftasnum \cftfigaftersnum - \let\@cftasnumb \cftfigaftersnumb - \advance\if@RTL\rightskip\else\leftskip\fi \@tempdima \null\nobreak\hskip -\if@RTL\rightskip\else\leftskip\fi - {\cftfigfont #1}\nobreak - \cftfigfillnum{#2}} - \fi - } -\renewcommand*{\l@table}[2]{% - \ifnum\c@lotdepth >\z@ - \vskip \cftbeforetabskip - {\if@RTL\rightskip\else\leftskip\fi \cfttabindent\relax - \if@RTL\leftskip\else\rightskip\fi \@tocrmarg - \parfillskip -\if@RTL\leftskip\else\rightskip\fi - \parindent \cfttabindent\relax\@afterindenttrue - \interlinepenalty\@M - \leavevmode - \@tempdima \cfttabnumwidth\relax - \let\@cftbsnum \cfttabpresnum - \let\@cftasnum \cfttabaftersnum - \let\@cftasnumb \cfttabaftersnumb - \advance\if@RTL\rightskip\else\leftskip\fi \@tempdima \null\nobreak\hskip -\if@RTL\rightskip\else\leftskip\fi - {\cfttabfont #1}\nobreak - \cfttabfillnum{#2}} - \fi - } -\renewcommand{\@cftl@subfig}{ -\renewcommand*{\l@subfigure}[2]{% - \ifnum \c@lofdepth > \toclevel@subfigure - \vskip \cftbeforesubfigskip - {\if@RTL\rightskip\else\leftskip\fi \cftsubfigindent\relax - \if@RTL\leftskip\else\rightskip\fi \@tocrmarg - \parfillskip -\if@RTL\leftskip\else\rightskip\fi - \parindent \cftsubfigindent\relax\@afterindenttrue - \interlinepenalty\@M - \leavevmode - \@tempdima \cftsubfignumwidth\relax - \let\@cftbsnum \cftsubfigpresnum - \let\@cftasnum \cftsubfigaftersnum - \let\@cftasnumb \cftsubfigaftersnumb - \advance\if@RTL\rightskip\else\leftskip\fi \@tempdima \null\nobreak\hskip -\if@RTL\rightskip\else\leftskip\fi - {\cftsubfigfont ##1}\nobreak - \cftsubfigfillnum{##2}} - \fi - } -} -\renewcommand{\@cftl@subtab}{ -\renewcommand*{\l@subtable}[2]{% - \ifnum \c@lotdepth > \toclevel@subtable - \vskip \cftbeforesubtabskip - {\if@RTL\rightskip\else\leftskip\fi \cftsubtabindent\relax - \if@RTL\leftskip\else\rightskip\fi \@tocrmarg - \parfillskip -\if@RTL\leftskip\else\rightskip\fi - \parindent \cftsubtabindent\relax\@afterindenttrue - \interlinepenalty\@M - \leavevmode - \@tempdima \cftsubtabnumwidth\relax - \let\@cftbsnum \cftsubtabpresnum - \let\@cftasnum \cftsubtabaftersnum - \let\@cftasnumb \cftsubtabaftersnumb - \advance\if@RTL\rightskip\else\leftskip\fi \@tempdima \null\nobreak\hskip -\if@RTL\rightskip\else\leftskip\fi - {\cftsubtabfont ##1}\nobreak - \cftsubtabfillnum{##2}} - \fi - } -} -\renewcommand{\newlistentry}[4][\@empty]{% - \@ifundefined{c@#2}{% check & set the counter - \ifx \@empty#1\relax - \newcounter{#2} - \else - \@ifundefined{c@#1}{\PackageWarning{tocloft}% - {#1 has no counter for use as a `within'} - \newcounter{#2}}% - {\newcounter{#2}[#1]% - \expandafter\edef\csname the#2\endcsname{% - \expandafter\noexpand\csname the#1\endcsname.\noexpand\arabic{#2}}} - \fi - \setcounter{#2}{0} - } - {\PackageError{tocloft}{#2 has been previously defined}{\@eha}} - - \@namedef{l@#2}##1##2{% - \ifnum \@nameuse{c@#3depth} > #4\relax - \vskip \@nameuse{cftbefore#2skip} - {\if@RTL\rightskip\else\leftskip\fi \@nameuse{cft#2indent}\relax - \if@RTL\leftskip\else\rightskip\fi \@tocrmarg - \parfillskip -\if@RTL\leftskip\else\rightskip\fi - \parindent \@nameuse{cft#2indent}\relax\@afterindenttrue - \interlinepenalty\@M - \leavevmode - \@tempdima \@nameuse{cft#2numwidth}\relax - \expandafter\let\expandafter\@cftbsnum\csname cft#2presnum\endcsname - \expandafter\let\expandafter\@cftasnum\csname cft#2aftersnum\endcsname - \expandafter\let\expandafter\@cftasnumb\csname cft#2aftersnumb\endcsname - \advance\if@RTL\rightskip\else\leftskip\fi\@tempdima \null\nobreak\hskip -\if@RTL\rightskip\else\leftskip\fi - {\@nameuse{cft#2font}##1}\nobreak - \@nameuse{cft#2fillnum}{##2}} - \fi - } % end of \l@#2 - - \expandafter\newlength\csname cftbefore#2skip\endcsname - \setlength{\@nameuse{cftbefore#2skip}}{\z@ \@plus .2\p@} - \expandafter\newlength\csname cft#2indent\endcsname - \expandafter\newlength\csname cft#2numwidth\endcsname - \ifcase #4\relax % 0 - \setlength{\@nameuse{cft#2indent}}{0em} - \setlength{\@nameuse{cft#2numwidth}}{1.5em} - \or % 1 - \setlength{\@nameuse{cft#2indent}}{1.5em} - \setlength{\@nameuse{cft#2numwidth}}{2.3em} - \or % 2 - \setlength{\@nameuse{cft#2indent}}{3.8em} - \setlength{\@nameuse{cft#2numwidth}}{3.2em} - \or % 3 - \setlength{\@nameuse{cft#2indent}}{7.0em} - \setlength{\@nameuse{cft#2numwidth}}{4.1em} - \else % anything else - \setlength{\@nameuse{cft#2indent}}{10.0em} - \setlength{\@nameuse{cft#2numwidth}}{5.0em} - \fi - \@namedef{cft#2font}{\normalfont} - \@namedef{cft#2presnum}{} - \@namedef{cft#2aftersnum}{} - \@namedef{cft#2aftersnumb}{} - \@namedef{cft#2dotsep}{\cftdotsep} - \@namedef{cft#2leader}{\normalfont\cftdotfill{\@nameuse{cft#2dotsep}}} - \@namedef{cft#2pagefont}{\normalfont} - \@namedef{cft#2afterpnum}{} - \@namedef{toclevel@#2}{#4} - \@namedef{cft#2fillnum}##1{% - {\@nameuse{cft#2leader}}\nobreak - \hb@xt@\@pnumwidth{\hfil\@nameuse{cft#2pagefont}##1}\@nameuse{cft#2afterpnum}\par} -} % end \newlistentry -\renewcommand{\cftchapterprecistoc}[1]{\addtocontents{toc}{% - {\if@RTL\rightskip\else\leftskip\fi \cftchapindent\relax - \advance\if@RTL\righskip\else\leftskip\fi \cftchapnumwidth\relax - \if@RTL\leftskip\else\rightskip\fi \@tocrmarg\relax - \textit{#1}\protect\par}}} -%% -%% Copyright © 2009-2010 by Vafa Khalighi -%% -%% Distributable 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 "maintained" (as per LPPL maintenance status) -%% by Vafa Khalighi. -%% -%% -%% -%% -%% -%% End of file `tocloft-bidi.def'. diff --git a/Master/texmf-dist/tex/xelatex/bidi/tocloft-xetex-bidi.def b/Master/texmf-dist/tex/xelatex/bidi/tocloft-xetex-bidi.def new file mode 100644 index 00000000000..7e040da4025 --- /dev/null +++ b/Master/texmf-dist/tex/xelatex/bidi/tocloft-xetex-bidi.def @@ -0,0 +1,332 @@ +%% +%% This is file `tocloft-xetex-bidi.def', + +%% +%% __________________________________ +%% Copyright © 2009-2010 Vafa Khalighi +%% +%% License information appended. +%% +%% +\ProvidesFile{tocloft-xetex-bidi.def}[2010/07/25 v0.1 bidi adaptations for tocloft package for XeTeX engine] +\if@cfthaspart +\renewcommand*{\l@part}[2]{ + \@cftdopartfalse + \ifnum \c@tocdepth >-2\relax + \if@cfthaschapter + \@cftdoparttrue + \fi + \ifnum \c@tocdepth >\m@ne + \if@cfthaschapter\else + \@cftdoparttrue + \fi + \fi + \fi + \if@cftdopart + \if@cfthaschapter + \addpenalty{-\@highpenalty} + \else + \addpenalty\@secpenalty + \fi + \addvspace{\cftbeforepartskip} + \begingroup + {\if@RTL\rightskip\else\leftskip\fi \cftpartindent\relax + \if@RTL\leftskip\else\rightskip\fi \@tocrmarg + \parfillskip -\if@RTL\leftskip\else\rightskip\fi + \parindent \cftpartindent\relax\@afterindenttrue + \interlinepenalty\@M + \leavevmode + \@tempdima \cftpartnumwidth\relax + \let\@cftbsnum \cftpartpresnum + \let\@cftasnum \cftpartaftersnum + \let\@cftasnumb \cftpartaftersnumb + \advance\if@RTL\rightskip\else\leftskip\fi \@tempdima \null\nobreak\hskip -\if@RTL\rightskip\else\leftskip\fi + {\cftpartfont \cftpartpresnum #1} + \cftpartfillnum{#2}} + \nobreak + \if@cfthaschapter + \global\@nobreaktrue + \everypar{\global\@nobreakfalse\everypar{}} + \else + \if@compatibility + \global\@nobreaktrue + \everypar{\global\@nobreakfalse\everypar{}} + \fi + \fi + \endgroup + \fi} +\fi +\if@cfthaschapter +\renewcommand*{\l@chapter}[2]{ + \ifnum \c@tocdepth >\m@ne + \addpenalty{-\@highpenalty} + \vskip \cftbeforechapskip + {\if@RTL\rightskip\else\leftskip\fi \cftchapindent\relax + \if@RTL\leftskip\else\rightskip\fi \@tocrmarg + \parfillskip -\if@RTL\leftskip\else\rightskip\fi + \parindent \cftchapindent\relax\@afterindenttrue + \interlinepenalty\@M + \leavevmode + \@tempdima \cftchapnumwidth\relax + \let\@cftbsnum \cftchappresnum + \let\@cftasnum \cftchapaftersnum + \let\@cftasnumb \cftchapaftersnumb + \advance\if@RTL\rightskip\else\leftskip\fi \@tempdima \null\nobreak\hskip -\if@RTL\rightskip\else\leftskip\fi + {\cftchapfont #1}\nobreak + \cftchapfillnum{#2}} + \fi} +\fi +\renewcommand*{\l@section}[2]{% + \ifnum \c@tocdepth >\z@ + \if@cfthaschapter + \vskip \cftbeforesecskip + \else + \addpenalty\@secpenalty + \addvspace{\cftbeforesecskip} + \fi + {\if@RTL\rightskip\else\leftskip\fi \cftsecindent\relax + \if@RTL\leftskip\else\rightskip\fi \@tocrmarg + \parfillskip -\if@RTL\leftskip\else\rightskip\fi + \parindent \cftsecindent\relax\@afterindenttrue + \interlinepenalty\@M + \leavevmode + \@tempdima \cftsecnumwidth\relax + \let\@cftbsnum \cftsecpresnum + \let\@cftasnum \cftsecaftersnum + \let\@cftasnumb \cftsecaftersnumb + \advance\if@RTL\rightskip\else\leftskip\fi \@tempdima \null\nobreak\hskip -\if@RTL\rightskip\else\leftskip\fi + {\cftsecfont #1}\nobreak + \cftsecfillnum{#2}} + \fi} +\renewcommand*{\l@subsection}[2]{% + \ifnum \c@tocdepth >\@ne + \vskip \cftbeforesubsecskip + {\if@RTL\rightskip\else\leftskip\fi \cftsubsecindent\relax + \if@RTL\leftskip\else\rightskip\fi \@tocrmarg + \parfillskip -\if@RTL\leftskip\else\rightskip\fi + \parindent \cftsubsecindent\relax\@afterindenttrue + \interlinepenalty\@M + \leavevmode + \@tempdima \cftsubsecnumwidth\relax + \let\@cftbsnum \cftsubsecpresnum + \let\@cftasnum \cftsubsecaftersnum + \let\@cftasnumb \cftsubsecaftersnumb + \advance\if@RTL\rightskip\else\leftskip\fi \@tempdima \null\nobreak\hskip -\if@RTL\rightskip\else\leftskip\fi + {\cftsubsecfont #1}\nobreak + \cftsubsecfillnum{#2}} + \fi} +\renewcommand*{\l@subsubsection}[2]{% + \ifnum \c@tocdepth >\tw@ + \vskip \cftbeforesubsubsecskip + {\if@RTL\rightskip\else\leftskip\fi \cftsubsubsecindent\relax + \if@RTL\leftskip\else\rightskip\fi \@tocrmarg + \parfillskip -\if@RTL\leftskip\else\rightskip\fi + \parindent \cftsubsubsecindent\relax\@afterindenttrue + \interlinepenalty\@M + \leavevmode + \@tempdima \cftsubsubsecnumwidth\relax + \let\@cftbsnum \cftsubsubsecpresnum + \let\@cftasnum \cftsubsubsecaftersnum + \let\@cftasnumb \cftsubsubsecaftersnumb + \advance\if@RTL\rightskip\else\leftskip\fi \@tempdima \null\nobreak\hskip -\if@RTL\rightskip\else\leftskip\fi + {\cftsubsubsecfont #1}\nobreak + \cftsubsubsecfillnum{#2}} + \fi} +\renewcommand*{\l@paragraph}[2]{% + \ifnum \c@tocdepth >3\relax + \vskip \cftbeforeparaskip + {\if@RTL\rightskip\else\leftskip\fi \cftparaindent\relax + \if@RTL\leftskip\else\rightskip\fi \@tocrmarg + \parfillskip -\if@RTL\leftskip\else\rightskip\fi + \parindent \cftparaindent\relax\@afterindenttrue + \interlinepenalty\@M + \leavevmode + \@tempdima \cftparanumwidth\relax + \let\@cftbsnum \cftparapresnum + \let\@cftasnum \cftparaaftersnum + \let\@cftasnumb \cftparaaftersnumb + \advance\if@RTL\rightskip\else\leftskip\fi \@tempdima \null\nobreak\hskip -\if@RTL\rightskip\else\leftskip\fi + {\cftparafont #1}\nobreak + \cftparafillnum{#2}} + \fi} +\renewcommand*{\l@subparagraph}[2]{% + \ifnum \c@tocdepth >4\relax + \vskip \cftbeforesubparaskip + {\if@RTL\rightskip\else\leftskip\fi \cftsubparaindent\relax + \if@RTL\leftskip\else\rightskip\fi \@tocrmarg + \parfillskip -\if@RTL\leftskip\else\rightskip\fi + \parindent \cftsubparaindent\relax\@afterindenttrue + \interlinepenalty\@M + \leavevmode + \@tempdima \cftsubparanumwidth\relax + \let\@cftbsnum \cftsubparapresnum + \let\@cftasnum \cftsubparaaftersnum + \let\@cftasnumb \cftsubparaaftersnumb + \advance\if@RTL\rightskip\else\leftskip\fi \@tempdima \null\nobreak\hskip -\if@RTL\rightskip\else\leftskip\fi + {\cftsubparafont #1}\nobreak + \cftsubparafillnum{#2}} + \fi} +\renewcommand*{\l@figure}[2]{% + \ifnum \c@lofdepth >\z@ + \vskip \cftbeforefigskip + {\if@RTL\rightskip\else\leftskip\fi \cftfigindent\relax + \if@RTL\leftskip\else\rightskip\fi \@tocrmarg + \parfillskip -\if@RTL\leftskip\else\rightskip\fi + \parindent \cftfigindent\relax\@afterindenttrue + \interlinepenalty\@M + \leavevmode + \@tempdima \cftfignumwidth\relax + \let\@cftbsnum \cftfigpresnum + \let\@cftasnum \cftfigaftersnum + \let\@cftasnumb \cftfigaftersnumb + \advance\if@RTL\rightskip\else\leftskip\fi \@tempdima \null\nobreak\hskip -\if@RTL\rightskip\else\leftskip\fi + {\cftfigfont #1}\nobreak + \cftfigfillnum{#2}} + \fi + } +\renewcommand*{\l@table}[2]{% + \ifnum\c@lotdepth >\z@ + \vskip \cftbeforetabskip + {\if@RTL\rightskip\else\leftskip\fi \cfttabindent\relax + \if@RTL\leftskip\else\rightskip\fi \@tocrmarg + \parfillskip -\if@RTL\leftskip\else\rightskip\fi + \parindent \cfttabindent\relax\@afterindenttrue + \interlinepenalty\@M + \leavevmode + \@tempdima \cfttabnumwidth\relax + \let\@cftbsnum \cfttabpresnum + \let\@cftasnum \cfttabaftersnum + \let\@cftasnumb \cfttabaftersnumb + \advance\if@RTL\rightskip\else\leftskip\fi \@tempdima \null\nobreak\hskip -\if@RTL\rightskip\else\leftskip\fi + {\cfttabfont #1}\nobreak + \cfttabfillnum{#2}} + \fi + } +\renewcommand{\@cftl@subfig}{ +\renewcommand*{\l@subfigure}[2]{% + \ifnum \c@lofdepth > \toclevel@subfigure + \vskip \cftbeforesubfigskip + {\if@RTL\rightskip\else\leftskip\fi \cftsubfigindent\relax + \if@RTL\leftskip\else\rightskip\fi \@tocrmarg + \parfillskip -\if@RTL\leftskip\else\rightskip\fi + \parindent \cftsubfigindent\relax\@afterindenttrue + \interlinepenalty\@M + \leavevmode + \@tempdima \cftsubfignumwidth\relax + \let\@cftbsnum \cftsubfigpresnum + \let\@cftasnum \cftsubfigaftersnum + \let\@cftasnumb \cftsubfigaftersnumb + \advance\if@RTL\rightskip\else\leftskip\fi \@tempdima \null\nobreak\hskip -\if@RTL\rightskip\else\leftskip\fi + {\cftsubfigfont ##1}\nobreak + \cftsubfigfillnum{##2}} + \fi + } +} +\renewcommand{\@cftl@subtab}{ +\renewcommand*{\l@subtable}[2]{% + \ifnum \c@lotdepth > \toclevel@subtable + \vskip \cftbeforesubtabskip + {\if@RTL\rightskip\else\leftskip\fi \cftsubtabindent\relax + \if@RTL\leftskip\else\rightskip\fi \@tocrmarg + \parfillskip -\if@RTL\leftskip\else\rightskip\fi + \parindent \cftsubtabindent\relax\@afterindenttrue + \interlinepenalty\@M + \leavevmode + \@tempdima \cftsubtabnumwidth\relax + \let\@cftbsnum \cftsubtabpresnum + \let\@cftasnum \cftsubtabaftersnum + \let\@cftasnumb \cftsubtabaftersnumb + \advance\if@RTL\rightskip\else\leftskip\fi \@tempdima \null\nobreak\hskip -\if@RTL\rightskip\else\leftskip\fi + {\cftsubtabfont ##1}\nobreak + \cftsubtabfillnum{##2}} + \fi + } +} +\renewcommand{\newlistentry}[4][\@empty]{% + \@ifundefined{c@#2}{% check & set the counter + \ifx \@empty#1\relax + \newcounter{#2} + \else + \@ifundefined{c@#1}{\PackageWarning{tocloft}% + {#1 has no counter for use as a `within'} + \newcounter{#2}}% + {\newcounter{#2}[#1]% + \expandafter\edef\csname the#2\endcsname{% + \expandafter\noexpand\csname the#1\endcsname.\noexpand\arabic{#2}}} + \fi + \setcounter{#2}{0} + } + {\PackageError{tocloft}{#2 has been previously defined}{\@eha}} + + \@namedef{l@#2}##1##2{% + \ifnum \@nameuse{c@#3depth} > #4\relax + \vskip \@nameuse{cftbefore#2skip} + {\if@RTL\rightskip\else\leftskip\fi \@nameuse{cft#2indent}\relax + \if@RTL\leftskip\else\rightskip\fi \@tocrmarg + \parfillskip -\if@RTL\leftskip\else\rightskip\fi + \parindent \@nameuse{cft#2indent}\relax\@afterindenttrue + \interlinepenalty\@M + \leavevmode + \@tempdima \@nameuse{cft#2numwidth}\relax + \expandafter\let\expandafter\@cftbsnum\csname cft#2presnum\endcsname + \expandafter\let\expandafter\@cftasnum\csname cft#2aftersnum\endcsname + \expandafter\let\expandafter\@cftasnumb\csname cft#2aftersnumb\endcsname + \advance\if@RTL\rightskip\else\leftskip\fi\@tempdima \null\nobreak\hskip -\if@RTL\rightskip\else\leftskip\fi + {\@nameuse{cft#2font}##1}\nobreak + \@nameuse{cft#2fillnum}{##2}} + \fi + } % end of \l@#2 + + \expandafter\newlength\csname cftbefore#2skip\endcsname + \setlength{\@nameuse{cftbefore#2skip}}{\z@ \@plus .2\p@} + \expandafter\newlength\csname cft#2indent\endcsname + \expandafter\newlength\csname cft#2numwidth\endcsname + \ifcase #4\relax % 0 + \setlength{\@nameuse{cft#2indent}}{0em} + \setlength{\@nameuse{cft#2numwidth}}{1.5em} + \or % 1 + \setlength{\@nameuse{cft#2indent}}{1.5em} + \setlength{\@nameuse{cft#2numwidth}}{2.3em} + \or % 2 + \setlength{\@nameuse{cft#2indent}}{3.8em} + \setlength{\@nameuse{cft#2numwidth}}{3.2em} + \or % 3 + \setlength{\@nameuse{cft#2indent}}{7.0em} + \setlength{\@nameuse{cft#2numwidth}}{4.1em} + \else % anything else + \setlength{\@nameuse{cft#2indent}}{10.0em} + \setlength{\@nameuse{cft#2numwidth}}{5.0em} + \fi + \@namedef{cft#2font}{\normalfont} + \@namedef{cft#2presnum}{} + \@namedef{cft#2aftersnum}{} + \@namedef{cft#2aftersnumb}{} + \@namedef{cft#2dotsep}{\cftdotsep} + \@namedef{cft#2leader}{\normalfont\cftdotfill{\@nameuse{cft#2dotsep}}} + \@namedef{cft#2pagefont}{\normalfont} + \@namedef{cft#2afterpnum}{} + \@namedef{toclevel@#2}{#4} + \@namedef{cft#2fillnum}##1{% + {\@nameuse{cft#2leader}}\nobreak + \hb@xt@\@pnumwidth{\hfil\@nameuse{cft#2pagefont}##1}\@nameuse{cft#2afterpnum}\par} +} % end \newlistentry +\renewcommand{\cftchapterprecistoc}[1]{\addtocontents{toc}{% + {\if@RTL\rightskip\else\leftskip\fi \cftchapindent\relax + \advance\if@RTL\righskip\else\leftskip\fi \cftchapnumwidth\relax + \if@RTL\leftskip\else\rightskip\fi \@tocrmarg\relax + \textit{#1}\protect\par}}} +%% +%% Copyright © 2009-2010 by Vafa Khalighi +%% +%% Distributable 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 "maintained" (as per LPPL maintenance status) +%% by Vafa Khalighi. +%% +%% +%% +%% +%% +%% End of file `tocloft-xetex-bidi.def'. diff --git a/Master/texmf-dist/tex/xelatex/bidi/tocstyle-bidi.def b/Master/texmf-dist/tex/xelatex/bidi/tocstyle-bidi.def deleted file mode 100644 index 8cfd05bf693..00000000000 --- a/Master/texmf-dist/tex/xelatex/bidi/tocstyle-bidi.def +++ /dev/null @@ -1,271 +0,0 @@ -%% -%% This is file `tocstyle-bidi.def', - -%% -%% __________________________________ -%% Copyright © 2009-2010 Vafa Khalighi -%% -%% License information appended. -%% -%% -\ProvidesFile{tocstyle-bidi.def}[2010/03/01 v0.1 adaptations for tocstyle package] -\renewcommand*{\tocstyle@dottedtocline}[5]{% - \let\numberline\tocstyle@numberline - \ifnum #1>\c@tocdepth \else - \if@tocstyle@penalties - \begingroup - \@tempcnta 20010 - \advance \@tempcnta by -#1 - \ifnum \@tempcnta>\lastpenalty - \aftergroup\penalty\aftergroup\@lowpenalty - \fi - \endgroup - \fi - \edef\tocstyledepth{#1}% - \tocstyle@activate@features - \ifx\tocstyle@feature@entryvskip\relax - \vskip \z@ \@plus.2\p@ - \else - \addvspace{\tocstyle@feature@entryvskip}% - \fi - {% - \parskip \z@ \parindent \z@ \if@RTL\rightskip\else\leftskip\fi \z@ \if@RTL\leftskip\else\rightskip\fi \z@ - \tocstyle@feature@raggedhook - \@tempdima #3\relax - \@tempdimb #2\relax - \typeout{m (\tocstyleTOC, \tocstyledepth): \the\@tempdima}% - \ifnum #1>\z@\relax - \@tempcnta #1\relax \advance\@tempcnta \m@ne - \ifcsname tocstyle@skipwidth@\tocstyleTOC @\the\@tempcnta\endcsname - \ifcsname tocstyle@numwidth@\tocstyleTOC @\the\@tempcnta\endcsname - \@tempdimb - \csname tocstyle@skipwidth@\tocstyleTOC @\the\@tempcnta\endcsname - \advance\@tempdimb - \csname tocstyle@numwidth@\tocstyleTOC @\the\@tempcnta\endcsname - \fi - \fi - \fi - \typeout{C (\tocstyleTOC, \tocstyledepth): \the\@tempdimb}% - \ifcsname tocstyle@skipwidth@\tocstyleTOC @#1\endcsname - \ifdim \@tempdimb> - \csname tocstyle@skipwidth@\tocstyleTOC @#1\endcsname\relax - \expandafter\xdef\csname tocstyle@skipwidth@\tocstyleTOC - @#1\endcsname{\the\@tempdimb}% - \fi - \else - \expandafter\xdef\csname tocstyle@skipwidth@\tocstyleTOC - @#1\endcsname{\the\@tempdimb}% - \fi - \iftocstyle@autolength - \ifcsname tocstyle@maxskipwidth@\tocstyleTOC @#1\endcsname - \@tempdimb \csname tocstyle@maxskipwidth@\tocstyleTOC @#1\endcsname - \relax - \fi - \ifcsname tocstyle@maxnumwidth@\tocstyleTOC @#1\endcsname - \@tempdima \csname tocstyle@maxnumwidth@\tocstyleTOC @#1\endcsname - \relax - \fi - \typeout{a (\tocstyleTOC, \tocstyledepth): \the\@tempdima}% - \typeout{A (\tocstyleTOC, \tocstyledepth): \the\@tempdimb}% - \else - \@tempdimb #2\relax - \typeout{M (\tocstyleTOC, \tocstyledepth): \the\@tempdimb}% - \fi - \ifcsname tocstyle@unumwidth@\tocstyleTOC @\endcsname - \ifdim \@tempdima> - \csname tocstyle@unumwidth@\tocstyleTOC @\endcsname\relax - \expandafter\xdef\csname tocstyle@unumwidth@\tocstyleTOC - @\endcsname{\the\@tempdima}% - \fi - \else - \expandafter\xdef\csname tocstyle@unumwidth@\tocstyleTOC - @\endcsname{\the\@tempdima}% - \fi - \ifcase\tocstyle@indentstyle\relax\else - \@tempdimb \z@ - \ifcsname tocstyle@maxunumwidth@\tocstyleTOC @\endcsname - \@tempdima \csname tocstyle@maxunumwidth@\tocstyleTOC @\endcsname - \relax - \fi - \typeout{s (\tocstyleTOC, \tocstyledepth): \the\@tempdima}% - \typeout{S (\tocstyleTOC, \tocstyledepth): \the\@tempdimb}% - \fi - \advance\parindent \@tempdimb\@afterindenttrue - \advance\if@RTL\rightskip\else\leftskip\fi \parindent - \advance\if@RTL\leftskip\else\rightskip\fi \@tocrmarg - \parfillskip -\if@RTL\leftskip\else\rightskip\fi - \ifx\tocstyle@feature@parfillskip\relax\else - \advance\parfillskip \tocstyle@feature@parfillskip\relax - \fi - \interlinepenalty\@M - \leavevmode - \advance\if@RTL\rightskip\else\leftskip\fi \@tempdima - \null\nobreak - \iftocstyle@indentnotnumbered\else - \hskip -\if@RTL\rightskip\else\leftskip\fi - \fi - \tocstyle@feature@entryhook - {#4}\nobreak - \ifx\tocstyle@feature@leaders\relax - \leaders\hbox{$\m@th - \mkern \@dotsep mu\hbox{\tocstyle@feature@dothook .}% - \mkern \@dotsep mu$}\hfill - \else - \tocstyle@feature@leaders - \fi - \nobreak - \ifx\tocstyle@feature@pagenumberbox\relax - \hb@xt@\@pnumwidth{\hfil\tocstyle@feature@pagenumberhook #5}% - \else - \tocstyle@feature@pagenumberbox{\tocstyle@feature@pagenumberhook #5}% - \fi - \par - }% - \if@tocstyle@penalties - \bgroup - \@tempcnta 20009 - \advance\@tempcnta by -#1 - \edef\reserved@a{\egroup\penalty\the\@tempcnta\relax}% - \reserved@a - \fi - \fi} -\renewcommand*{\tocstyle@numberline}[1]{% - \begingroup - \ifx\tocstyle@feature@spaceafternumber\relax - \settowidth\@tempdima{\tocstyle@@numberline{#1}\enskip}% - \else - \settowidth\@tempdima{\tocstyle@@numberline{#1}}% - \advance \@tempdima \tocstyle@feature@spaceafternumber\relax - \fi - \ifcsname tocstyle@numwidth@\tocstyleTOC @\tocstyledepth\endcsname - \ifdim \@tempdima > - \csname tocstyle@numwidth@\tocstyleTOC @\tocstyledepth\endcsname\relax - \expandafter\xdef\csname tocstyle@numwidth@\tocstyleTOC - @\tocstyledepth\endcsname{\the\@tempdima}% - \fi - \else - \expandafter\xdef\csname tocstyle@numwidth@\tocstyleTOC - @\tocstyledepth\endcsname{\the\@tempdima}% - \fi - \endgroup - \iftocstyle@indentnotnumbered - \hskip -\if@RTL\rightskip\else\leftskip\fi - \fi - \ifcase \tocstyle@indentstyle - \hb@xt@\@tempdima{\tocstyle@@numberline{#1}\hfil}% - \or - \hb@xt@\@tempdima{\tocstyle@@numberline{#1}\hfil}% - \else - \ifx\tocstyle@feature@spaceafternumber\relax - \hbox{\tocstyle@@numberline{#1}\enskip}% - \else - \hbox{\tocstyle@@numberline{#1}\hskip - \tocstyle@feature@spaceafternumber\relax}% - \fi - \fi -} -\AtBeginDocument{% - \ifcsname l@part\endcsname - \ifcsname l@chapter\endcsname - \setbox\@tempboxa\vbox{\hsize\maxdimen - \l@part{\tocstyle@l@define{part}{-1}}{}}% - \else - \setbox\@tempboxa\vbox{\hsize\maxdimen - \l@part{\tocstyle@l@define{part}{0}}{}}% - \fi - \fi - \ifcsname l@chapter\endcsname - \setbox\@tempboxa\vbox{\hsize\maxdimen - \l@chapter{\tocstyle@l@define{chapter}{0}}{}}% - \fi - \ifcsname l@section\endcsname - \setbox\@tempboxa\vbox{\hsize\maxdimen - \l@section{\tocstyle@l@define{section}{1}}{}}% - \fi - \ifcsname l@subsection\endcsname - \setbox\@tempboxa\vbox{\hsize\maxdimen - \l@subsection{\tocstyle@l@define{subsection}{2}}{}}% - \fi - \ifcsname l@subsubsection\endcsname - \setbox\@tempboxa\vbox{\hsize\maxdimen - \l@subsubsection{\tocstyle@l@define{subsubsection}{3}}{}}% - \fi - \ifcsname l@paragraph\endcsname - \setbox\@tempboxa\vbox{\hsize\maxdimen - \l@paragraph{\tocstyle@l@define{paragraph}{4}}{}}% - \fi - \ifcsname l@subparagraph\endcsname - \setbox\@tempboxa\vbox{\hsize\maxdimen - \l@subparagraph{\tocstyle@l@define{subparagraph}{5}}{}}% - \fi - \ifcsname l@table\endcsname - \setbox\@tempboxa\vbox{\hsize\maxdimen - \l@table{\tocstyle@l@define{table}{1}}{}}% - \fi - \ifcsname l@figure\endcsname - \setbox\@tempboxa\vbox{\hsize\maxdimen - \l@figure{\tocstyle@l@define{figure}{1}}{}}% - \fi - \def\@tempa#1#2#3#4#5{% - \ifnum #1>\c@tocdepth \else - \vskip \z@ \@plus.2\p@ - {\if@RTL\rightskip\else\leftskip\fi #2\relax \if@RTL\leftskip\else\rightskip\fi \@tocrmarg \parfillskip -\if@RTL\leftskip\else\rightskip\fi - \parindent #2\relax\@afterindenttrue - \interlinepenalty\@M - \leavevmode - \@tempdima #3\relax - \advance\if@RTL\rightskip\else\leftskip\fi \@tempdima \null\nobreak\hskip -\if@RTL\rightskip\else\leftskip\fi - {#4}\nobreak - \leaders\hbox{$\m@th - \mkern \@dotsep mu\hbox{.}\mkern \@dotsep - mu$}\hfill - \nobreak - \hb@xt@\@pnumwidth{\hfil \normalfont \normalcolor #5}% - \par}% - \fi}% - \ifx\@dottedtocline\@tempa\else - \tocstyle@macrochangewarning\@dottedtocline - \fi - \let\tocstyle@saved@dottedtocline\@dottedtocline - \def\@tempa#1{\hb@xt@\@tempdima{#1\autodot\hfil}}% - \ifx\numberline\@tempa\else - \def\@tempa#1{\hb@xt@\@tempdima{#1\hfil}}% - \ifx\numberline@tempa\else - \tocstyle@macrochangewarning\numberline - \fi - \fi - \let\tocstyle@saved@numberline\numberline -} -\renewcommand*{\tocstyle@l@define}[2]{% - \advance\if@RTL\rightskip\else\leftskip\fi-\@tempdima - \edef\@tempa{% - \noexpand\global\noexpand\let - \expandafter\noexpand\csname tocstyle@saved@l@#1\endcsname - \expandafter\noexpand\csname l@#1\endcsname - \noexpand\gdef - \expandafter\noexpand\csname tocstyle@l@#1\endcsname{% - \noexpand\@dottedtocline{#2}{\the\if@RTL\rightskip\else\leftskip\fi}{\the\@tempdima}}% - \noexpand\g@addto@macro\noexpand\tocstyle@activate@all@l{% - \noexpand\let\expandafter\noexpand\csname l@#1\endcsname - \expandafter\noexpand\csname tocstyle@l@#1\endcsname - }% - }% - \PackageInfo{tocstyle}{prepare \expandafter\string - \csname l@#1\endcsname\space for redefinition}% - \@tempa -} -%% -%% Copyright © 2009-2010 by Vafa Khalighi -%% -%% Distributable 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 "maintained" (as per LPPL maintenance status) -%% by Vafa Khalighi. -%% -%% -%% -%% -%% -%% End of file `tocstyle-bidi.def'. diff --git a/Master/texmf-dist/tex/xelatex/bidi/tocstyle-xetex-bidi.def b/Master/texmf-dist/tex/xelatex/bidi/tocstyle-xetex-bidi.def new file mode 100644 index 00000000000..9bb376df52c --- /dev/null +++ b/Master/texmf-dist/tex/xelatex/bidi/tocstyle-xetex-bidi.def @@ -0,0 +1,271 @@ +%% +%% This is file `tocstyle-xetex-bidi.def', + +%% +%% __________________________________ +%% Copyright © 2009-2010 Vafa Khalighi +%% +%% License information appended. +%% +%% +\ProvidesFile{tocstyle-xetex-bidi.def}[2010/07/25 v0.1 bidi adaptations for tocstyle package for XeTeX engine] +\renewcommand*{\tocstyle@dottedtocline}[5]{% + \let\numberline\tocstyle@numberline + \ifnum #1>\c@tocdepth \else + \if@tocstyle@penalties + \begingroup + \@tempcnta 20010 + \advance \@tempcnta by -#1 + \ifnum \@tempcnta>\lastpenalty + \aftergroup\penalty\aftergroup\@lowpenalty + \fi + \endgroup + \fi + \edef\tocstyledepth{#1}% + \tocstyle@activate@features + \ifx\tocstyle@feature@entryvskip\relax + \vskip \z@ \@plus.2\p@ + \else + \addvspace{\tocstyle@feature@entryvskip}% + \fi + {% + \parskip \z@ \parindent \z@ \if@RTL\rightskip\else\leftskip\fi \z@ \if@RTL\leftskip\else\rightskip\fi \z@ + \tocstyle@feature@raggedhook + \@tempdima #3\relax + \@tempdimb #2\relax + \typeout{m (\tocstyleTOC, \tocstyledepth): \the\@tempdima}% + \ifnum #1>\z@\relax + \@tempcnta #1\relax \advance\@tempcnta \m@ne + \ifcsname tocstyle@skipwidth@\tocstyleTOC @\the\@tempcnta\endcsname + \ifcsname tocstyle@numwidth@\tocstyleTOC @\the\@tempcnta\endcsname + \@tempdimb + \csname tocstyle@skipwidth@\tocstyleTOC @\the\@tempcnta\endcsname + \advance\@tempdimb + \csname tocstyle@numwidth@\tocstyleTOC @\the\@tempcnta\endcsname + \fi + \fi + \fi + \typeout{C (\tocstyleTOC, \tocstyledepth): \the\@tempdimb}% + \ifcsname tocstyle@skipwidth@\tocstyleTOC @#1\endcsname + \ifdim \@tempdimb> + \csname tocstyle@skipwidth@\tocstyleTOC @#1\endcsname\relax + \expandafter\xdef\csname tocstyle@skipwidth@\tocstyleTOC + @#1\endcsname{\the\@tempdimb}% + \fi + \else + \expandafter\xdef\csname tocstyle@skipwidth@\tocstyleTOC + @#1\endcsname{\the\@tempdimb}% + \fi + \iftocstyle@autolength + \ifcsname tocstyle@maxskipwidth@\tocstyleTOC @#1\endcsname + \@tempdimb \csname tocstyle@maxskipwidth@\tocstyleTOC @#1\endcsname + \relax + \fi + \ifcsname tocstyle@maxnumwidth@\tocstyleTOC @#1\endcsname + \@tempdima \csname tocstyle@maxnumwidth@\tocstyleTOC @#1\endcsname + \relax + \fi + \typeout{a (\tocstyleTOC, \tocstyledepth): \the\@tempdima}% + \typeout{A (\tocstyleTOC, \tocstyledepth): \the\@tempdimb}% + \else + \@tempdimb #2\relax + \typeout{M (\tocstyleTOC, \tocstyledepth): \the\@tempdimb}% + \fi + \ifcsname tocstyle@unumwidth@\tocstyleTOC @\endcsname + \ifdim \@tempdima> + \csname tocstyle@unumwidth@\tocstyleTOC @\endcsname\relax + \expandafter\xdef\csname tocstyle@unumwidth@\tocstyleTOC + @\endcsname{\the\@tempdima}% + \fi + \else + \expandafter\xdef\csname tocstyle@unumwidth@\tocstyleTOC + @\endcsname{\the\@tempdima}% + \fi + \ifcase\tocstyle@indentstyle\relax\else + \@tempdimb \z@ + \ifcsname tocstyle@maxunumwidth@\tocstyleTOC @\endcsname + \@tempdima \csname tocstyle@maxunumwidth@\tocstyleTOC @\endcsname + \relax + \fi + \typeout{s (\tocstyleTOC, \tocstyledepth): \the\@tempdima}% + \typeout{S (\tocstyleTOC, \tocstyledepth): \the\@tempdimb}% + \fi + \advance\parindent \@tempdimb\@afterindenttrue + \advance\if@RTL\rightskip\else\leftskip\fi \parindent + \advance\if@RTL\leftskip\else\rightskip\fi \@tocrmarg + \parfillskip -\if@RTL\leftskip\else\rightskip\fi + \ifx\tocstyle@feature@parfillskip\relax\else + \advance\parfillskip \tocstyle@feature@parfillskip\relax + \fi + \interlinepenalty\@M + \leavevmode + \advance\if@RTL\rightskip\else\leftskip\fi \@tempdima + \null\nobreak + \iftocstyle@indentnotnumbered\else + \hskip -\if@RTL\rightskip\else\leftskip\fi + \fi + \tocstyle@feature@entryhook + {#4}\nobreak + \ifx\tocstyle@feature@leaders\relax + \leaders\hbox{$\m@th + \mkern \@dotsep mu\hbox{\tocstyle@feature@dothook .}% + \mkern \@dotsep mu$}\hfill + \else + \tocstyle@feature@leaders + \fi + \nobreak + \ifx\tocstyle@feature@pagenumberbox\relax + \hb@xt@\@pnumwidth{\hfil\tocstyle@feature@pagenumberhook #5}% + \else + \tocstyle@feature@pagenumberbox{\tocstyle@feature@pagenumberhook #5}% + \fi + \par + }% + \if@tocstyle@penalties + \bgroup + \@tempcnta 20009 + \advance\@tempcnta by -#1 + \edef\reserved@a{\egroup\penalty\the\@tempcnta\relax}% + \reserved@a + \fi + \fi} +\renewcommand*{\tocstyle@numberline}[1]{% + \begingroup + \ifx\tocstyle@feature@spaceafternumber\relax + \settowidth\@tempdima{\tocstyle@@numberline{#1}\enskip}% + \else + \settowidth\@tempdima{\tocstyle@@numberline{#1}}% + \advance \@tempdima \tocstyle@feature@spaceafternumber\relax + \fi + \ifcsname tocstyle@numwidth@\tocstyleTOC @\tocstyledepth\endcsname + \ifdim \@tempdima > + \csname tocstyle@numwidth@\tocstyleTOC @\tocstyledepth\endcsname\relax + \expandafter\xdef\csname tocstyle@numwidth@\tocstyleTOC + @\tocstyledepth\endcsname{\the\@tempdima}% + \fi + \else + \expandafter\xdef\csname tocstyle@numwidth@\tocstyleTOC + @\tocstyledepth\endcsname{\the\@tempdima}% + \fi + \endgroup + \iftocstyle@indentnotnumbered + \hskip -\if@RTL\rightskip\else\leftskip\fi + \fi + \ifcase \tocstyle@indentstyle + \hb@xt@\@tempdima{\tocstyle@@numberline{#1}\hfil}% + \or + \hb@xt@\@tempdima{\tocstyle@@numberline{#1}\hfil}% + \else + \ifx\tocstyle@feature@spaceafternumber\relax + \hbox{\tocstyle@@numberline{#1}\enskip}% + \else + \hbox{\tocstyle@@numberline{#1}\hskip + \tocstyle@feature@spaceafternumber\relax}% + \fi + \fi +} +\AtBeginDocument{% + \ifcsname l@part\endcsname + \ifcsname l@chapter\endcsname + \setbox\@tempboxa\vbox{\hsize\maxdimen + \l@part{\tocstyle@l@define{part}{-1}}{}}% + \else + \setbox\@tempboxa\vbox{\hsize\maxdimen + \l@part{\tocstyle@l@define{part}{0}}{}}% + \fi + \fi + \ifcsname l@chapter\endcsname + \setbox\@tempboxa\vbox{\hsize\maxdimen + \l@chapter{\tocstyle@l@define{chapter}{0}}{}}% + \fi + \ifcsname l@section\endcsname + \setbox\@tempboxa\vbox{\hsize\maxdimen + \l@section{\tocstyle@l@define{section}{1}}{}}% + \fi + \ifcsname l@subsection\endcsname + \setbox\@tempboxa\vbox{\hsize\maxdimen + \l@subsection{\tocstyle@l@define{subsection}{2}}{}}% + \fi + \ifcsname l@subsubsection\endcsname + \setbox\@tempboxa\vbox{\hsize\maxdimen + \l@subsubsection{\tocstyle@l@define{subsubsection}{3}}{}}% + \fi + \ifcsname l@paragraph\endcsname + \setbox\@tempboxa\vbox{\hsize\maxdimen + \l@paragraph{\tocstyle@l@define{paragraph}{4}}{}}% + \fi + \ifcsname l@subparagraph\endcsname + \setbox\@tempboxa\vbox{\hsize\maxdimen + \l@subparagraph{\tocstyle@l@define{subparagraph}{5}}{}}% + \fi + \ifcsname l@table\endcsname + \setbox\@tempboxa\vbox{\hsize\maxdimen + \l@table{\tocstyle@l@define{table}{1}}{}}% + \fi + \ifcsname l@figure\endcsname + \setbox\@tempboxa\vbox{\hsize\maxdimen + \l@figure{\tocstyle@l@define{figure}{1}}{}}% + \fi + \def\@tempa#1#2#3#4#5{% + \ifnum #1>\c@tocdepth \else + \vskip \z@ \@plus.2\p@ + {\if@RTL\rightskip\else\leftskip\fi #2\relax \if@RTL\leftskip\else\rightskip\fi \@tocrmarg \parfillskip -\if@RTL\leftskip\else\rightskip\fi + \parindent #2\relax\@afterindenttrue + \interlinepenalty\@M + \leavevmode + \@tempdima #3\relax + \advance\if@RTL\rightskip\else\leftskip\fi \@tempdima \null\nobreak\hskip -\if@RTL\rightskip\else\leftskip\fi + {#4}\nobreak + \leaders\hbox{$\m@th + \mkern \@dotsep mu\hbox{.}\mkern \@dotsep + mu$}\hfill + \nobreak + \hb@xt@\@pnumwidth{\hfil \normalfont \normalcolor #5}% + \par}% + \fi}% + \ifx\@dottedtocline\@tempa\else + \tocstyle@macrochangewarning\@dottedtocline + \fi + \let\tocstyle@saved@dottedtocline\@dottedtocline + \def\@tempa#1{\hb@xt@\@tempdima{#1\autodot\hfil}}% + \ifx\numberline\@tempa\else + \def\@tempa#1{\hb@xt@\@tempdima{#1\hfil}}% + \ifx\numberline@tempa\else + \tocstyle@macrochangewarning\numberline + \fi + \fi + \let\tocstyle@saved@numberline\numberline +} +\renewcommand*{\tocstyle@l@define}[2]{% + \advance\if@RTL\rightskip\else\leftskip\fi-\@tempdima + \edef\@tempa{% + \noexpand\global\noexpand\let + \expandafter\noexpand\csname tocstyle@saved@l@#1\endcsname + \expandafter\noexpand\csname l@#1\endcsname + \noexpand\gdef + \expandafter\noexpand\csname tocstyle@l@#1\endcsname{% + \noexpand\@dottedtocline{#2}{\the\if@RTL\rightskip\else\leftskip\fi}{\the\@tempdima}}% + \noexpand\g@addto@macro\noexpand\tocstyle@activate@all@l{% + \noexpand\let\expandafter\noexpand\csname l@#1\endcsname + \expandafter\noexpand\csname tocstyle@l@#1\endcsname + }% + }% + \PackageInfo{tocstyle}{prepare \expandafter\string + \csname l@#1\endcsname\space for redefinition}% + \@tempa +} +%% +%% Copyright © 2009-2010 by Vafa Khalighi +%% +%% Distributable 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 "maintained" (as per LPPL maintenance status) +%% by Vafa Khalighi. +%% +%% +%% +%% +%% +%% End of file `tocstyle-xetex-bidi.def'. diff --git a/Master/texmf-dist/tex/xelatex/bidi/wrapfig-bidi.def b/Master/texmf-dist/tex/xelatex/bidi/wrapfig-bidi.def deleted file mode 100644 index 37513381c86..00000000000 --- a/Master/texmf-dist/tex/xelatex/bidi/wrapfig-bidi.def +++ /dev/null @@ -1,101 +0,0 @@ -%% -%% This is file `wrapfig-bidi.def', - -%% -%% __________________________________ -%% Copyright © 2009-2010 Vafa Khalighi -%% -%% License information appended. -%% -%% -\ProvidesFile{wrapfig-bidi.def}[2010/03/01 v0.2 adaptations for wrapfig package] -\let\WF@@everypar\n@everypar -\def\WF@putfigmaybe{% -\ifinner - \vskip-\parskip \global\WF@floatfalse - \let\pagetotal\maxdimen % kludge flag for "not top of page" -\else % outer page - \@tempdima\pagedepth % save page depth - {\advance\parskip\if@RTL\baselineskip\else\@tempdima\fi\vskip-\parskip}% back up to baseline - \penalty\interlinepenalty % update pg. parameters - \@tempdimb\pagegoal \advance\@tempdimb-\pagetotal % room left on page - \ifdim\@tempdimb<\z@ % \WF@info{Page overfull already;}% - \global\WF@floatfalse - \ifdim-\@tempdimb>\pageshrink \else \pagebreak \fi - \else - \ifdim\WF@size>\@tempdimb - \ifWF@float \dimen@.5\baselineskip \else \dimen@ 2\baselineskip\fi - \ifdim\pagestretch>\dimen@ \dimen@\pagestretch \fi - \ifdim\pagefilstretch>\z@ \dimen@\@tempdimb \fi - \ifdim\pagefillstretch>\z@ \dimen@\@tempdimb \fi - \advance\dimen@.5\baselineskip - \ifdim\dimen@>\@tempdimb % \WF@info{Page nearly full; can stretch}% - \global\WF@floatfalse \pagebreak - \fi - \else % \WF@info{Fits in \the\@tempdimb;}% - \global\WF@floatfalse - \fi\fi - \vskip\@tempdima\relax % (return erased page depth) -\fi -\noindent -\ifWF@float - \WF@fltmes -\else % putting here; - \WF@info{Put \WF@wfname here:}% - {\ifodd\if@twoside\c@page\else\@ne\fi % assign l/r to i/o placement - \lccode`i`l\lccode`o`r\else \lccode`i`r\lccode`o`l\fi - \xdef\WF@place{\the\lccode\lccode\WF@place}}% twice to get only l or r - \hbox to\z@{% llap or rlap depending on {l} or {r}; calc effective width - \@tempdima\wd\WF@box \@tempdimb\WF@ovh - \advance\@tempdima-\@tempdimb \advance\@tempdima\columnsep - \@tempdimb\hsize \advance\@tempdimb-\@tempdima - \xdef\WF@adjlw{\the\@tempdima}% - \ifnum `l=\WF@place % fig on left - \if@RTL% - \kern\@tempdimb \kern\columnsep - \def\@tempa{\hss}% position to left of the gap - \else% - \hss % figure overlaps space to the left - \def\@tempa{\kern\columnsep}% position to left of the gap - \fi% - \else % fig on right - \if@RTL% - \hss - \@tempdima\z@ - \def\@tempa{\kern\columnsep} - \else% - \@tempdima\z@ % no left indentation - \kern\@tempdimb \kern\columnsep - \def\@tempa{\hss}% figure overlaps space to the right - \fi% - \fi - \ifdim\@tempdimb<\hsize - \xdef\WF@wrapil{\the\@tempdima \the\@tempdimb}% indentation and length - \xdef\WF@adjtlm{\the\@tempdima}% - \else - \xdef\WF@wrapil{\z@ \the\hsize}% - \xdef\WF@adjlw{\z@}\xdef\WF@adjtlm{\z@}% - \fi - \ifdim\pagetotal=\z@ % \WF@info{Put \WF@wfname at top of p.\thepage}% - \global\advance\WF@size-\intextsep - \else % \WF@info{Putting \WF@wfname in middle of page}% - \setbox\WF@box\hbox{\lower\intextsep\box\WF@box}% - \fi \dp\WF@box\z@ \box\WF@box \@tempa - }% end \hbox to 0pt - \aftergroup\WF@startwrapping % after the \endgroup which immediately follows -\fi} -%% -%% Copyright © 2009-2010 by Vafa Khalighi -%% -%% Distributable 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 "maintained" (as per LPPL maintenance status) -%% by Vafa Khalighi. -%% -%% -%% -%% -%% -%% End of file `wrapfig-bidi.def'. diff --git a/Master/texmf-dist/tex/xelatex/bidi/wrapfig-xetex-bidi.def b/Master/texmf-dist/tex/xelatex/bidi/wrapfig-xetex-bidi.def new file mode 100644 index 00000000000..b35f7733e31 --- /dev/null +++ b/Master/texmf-dist/tex/xelatex/bidi/wrapfig-xetex-bidi.def @@ -0,0 +1,101 @@ +%% +%% This is file `wrapfig-xetex-bidi.def', + +%% +%% __________________________________ +%% Copyright © 2009-2010 Vafa Khalighi +%% +%% License information appended. +%% +%% +\ProvidesFile{wrapfig-xetex-bidi.def}[2010/07/25 v0.2 bidi adaptations for wrapfig package for XeTeX engine] +\let\WF@@everypar\n@everypar +\def\WF@putfigmaybe{% +\ifinner + \vskip-\parskip \global\WF@floatfalse + \let\pagetotal\maxdimen % kludge flag for "not top of page" +\else % outer page + \@tempdima\pagedepth % save page depth + {\advance\parskip\if@RTL\baselineskip\else\@tempdima\fi\vskip-\parskip}% back up to baseline + \penalty\interlinepenalty % update pg. parameters + \@tempdimb\pagegoal \advance\@tempdimb-\pagetotal % room left on page + \ifdim\@tempdimb<\z@ % \WF@info{Page overfull already;}% + \global\WF@floatfalse + \ifdim-\@tempdimb>\pageshrink \else \pagebreak \fi + \else + \ifdim\WF@size>\@tempdimb + \ifWF@float \dimen@.5\baselineskip \else \dimen@ 2\baselineskip\fi + \ifdim\pagestretch>\dimen@ \dimen@\pagestretch \fi + \ifdim\pagefilstretch>\z@ \dimen@\@tempdimb \fi + \ifdim\pagefillstretch>\z@ \dimen@\@tempdimb \fi + \advance\dimen@.5\baselineskip + \ifdim\dimen@>\@tempdimb % \WF@info{Page nearly full; can stretch}% + \global\WF@floatfalse \pagebreak + \fi + \else % \WF@info{Fits in \the\@tempdimb;}% + \global\WF@floatfalse + \fi\fi + \vskip\@tempdima\relax % (return erased page depth) +\fi +\noindent +\ifWF@float + \WF@fltmes +\else % putting here; + \WF@info{Put \WF@wfname here:}% + {\ifodd\if@twoside\c@page\else\@ne\fi % assign l/r to i/o placement + \lccode`i`l\lccode`o`r\else \lccode`i`r\lccode`o`l\fi + \xdef\WF@place{\the\lccode\lccode\WF@place}}% twice to get only l or r + \hbox to\z@{% llap or rlap depending on {l} or {r}; calc effective width + \@tempdima\wd\WF@box \@tempdimb\WF@ovh + \advance\@tempdima-\@tempdimb \advance\@tempdima\columnsep + \@tempdimb\hsize \advance\@tempdimb-\@tempdima + \xdef\WF@adjlw{\the\@tempdima}% + \ifnum `l=\WF@place % fig on left + \if@RTL% + \kern\@tempdimb \kern\columnsep + \def\@tempa{\hss}% position to left of the gap + \else% + \hss % figure overlaps space to the left + \def\@tempa{\kern\columnsep}% position to left of the gap + \fi% + \else % fig on right + \if@RTL% + \hss + \@tempdima\z@ + \def\@tempa{\kern\columnsep} + \else% + \@tempdima\z@ % no left indentation + \kern\@tempdimb \kern\columnsep + \def\@tempa{\hss}% figure overlaps space to the right + \fi% + \fi + \ifdim\@tempdimb<\hsize + \xdef\WF@wrapil{\the\@tempdima \the\@tempdimb}% indentation and length + \xdef\WF@adjtlm{\the\@tempdima}% + \else + \xdef\WF@wrapil{\z@ \the\hsize}% + \xdef\WF@adjlw{\z@}\xdef\WF@adjtlm{\z@}% + \fi + \ifdim\pagetotal=\z@ % \WF@info{Put \WF@wfname at top of p.\thepage}% + \global\advance\WF@size-\intextsep + \else % \WF@info{Putting \WF@wfname in middle of page}% + \setbox\WF@box\hbox{\lower\intextsep\box\WF@box}% + \fi \dp\WF@box\z@ \box\WF@box \@tempa + }% end \hbox to 0pt + \aftergroup\WF@startwrapping % after the \endgroup which immediately follows +\fi} +%% +%% Copyright © 2009-2010 by Vafa Khalighi +%% +%% Distributable 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 "maintained" (as per LPPL maintenance status) +%% by Vafa Khalighi. +%% +%% +%% +%% +%% +%% End of file `wrapfig-xetex-bidi.def'. diff --git a/Master/texmf-dist/tex/xelatex/bidi/xcolor-bidi.def b/Master/texmf-dist/tex/xelatex/bidi/xcolor-bidi.def deleted file mode 100644 index b769811fcd0..00000000000 --- a/Master/texmf-dist/tex/xelatex/bidi/xcolor-bidi.def +++ /dev/null @@ -1,127 +0,0 @@ -%% -%% This is file `xcolor-bidi.def', - -%% -%% __________________________________ -%% Copyright © 2009-2010 Vafa Khalighi -%% -%% License information appended. -%% -%% -\ProvidesFile{xcolor-bidi.def}[2010/03/01 v0.1 adaptations for xcolor package] -\long\def\color@b@x#1#2#3% - {\leavevmode\if@RTL\beginL\fi - \setbox\z@\hbox{\kern\fboxsep{\set@color\if@RTL\beginR\fi#3\if@RTL\endR\fi}\kern\fboxsep}% - \dimen@\ht\z@\advance\dimen@\fboxsep\ht\z@\dimen@ - \dimen@\dp\z@\advance\dimen@\fboxsep\dp\z@\dimen@ - {#1{#2\color@block{\wd\z@}{\ht\z@}{\dp\z@}\box\z@}}\if@RTL\endL\fi} -\DeclareRobustCommand\color - {\ifhmode\if@RTL\beginL\aftergroup\endR\fi\fi\@ifnextchar[\@undeclaredcolor\@declaredcolor} -\def\@undeclaredcolor[#1]#2% - {\begingroup - \let\@@cls\@empty - \XC@getmodclr12{#1}{#2}{}% - {\ifblendcolors - \ifx\colorblend\@empty\else - \edef\@@mix{\expandafter\@gobble\colorblend}\@tempswafalse - \XC@coremodel\@@mod\@@clr\@xcolor@{}{}\@@mod\@@clr - \fi - \fi - \ifconvertcolorsU - \edef\@@tmp{\XC@tgt@mod{\@@mod}}% - \convertcolorspec\@@mod\@@clr\@@tmp\@@clr \let\@@mod\@@tmp - \fi - \ifmaskcolors - \convertcolorspec\@@mod\@@clr\XC@mmod\@@clr - \let\@@mod\XC@mmod - \XC@inflate\@@mod\XC@mclr\@@clr\@@tmp - \expandafter\XC@mul\@@tmp,\@@clr - \fi - \edef\@@tmp{\noexpand\XC@undeclaredcolor{\@@mod}{\@@clr}}% - \expandafter\endgroup\@@tmp}} -\def\@declaredcolor#1% - {\XC@edef\XC@@tmp{#1}\XC@@tstfalse - \ifcase\XC@type\XC@@tmp\relax \XC@@tsttrue\or \relax\else - \ifblendcolors\XC@@tsttrue\fi \ifmaskcolors\XC@@tsttrue\fi - \ifconvertcolorsU\XC@@tsttrue\fi - \fi - \ifXC@@tst - \expandafter\XC@declaredcolor\else - \expandafter\XC@declaredc@lor\fi} -\def\XC@undeclaredcolor#1#2% - {\@ifundefinedmodel{#1}% - {\c@lor@error{model `#1'}}% - {\@nameuse{color@#1}\current@color{#2}% - \edef\XC@current@color{\noexpand\xcolor@{}{\current@color}{#1}{#2}}% - \XC@display}\ifhmode\if@RTL\beginR\aftergroup\endL\fi\fi} -\def\XC@declaredc@lor - {\XC@let@Nc\XC@current@color{\string\color@\XC@@tmp}% - \edef\current@color{\XC@current@color}% - \XC@display\ifhmode\if@RTL\beginR\aftergroup\endL\fi\fi} -\DeclareRobustCommand\bidicolor - {\@ifnextchar[\@bidiundeclaredcolor\@bidideclaredcolor} -\def\@bidiundeclaredcolor[#1]#2% - {\begingroup - \let\@@cls\@empty - \XC@getmodclr12{#1}{#2}{}% - {\ifblendcolors - \ifx\colorblend\@empty\else - \edef\@@mix{\expandafter\@gobble\colorblend}\@tempswafalse - \XC@coremodel\@@mod\@@clr\@xcolor@{}{}\@@mod\@@clr - \fi - \fi - \ifconvertcolorsU - \edef\@@tmp{\XC@tgt@mod{\@@mod}}% - \convertcolorspec\@@mod\@@clr\@@tmp\@@clr \let\@@mod\@@tmp - \fi - \ifmaskcolors - \convertcolorspec\@@mod\@@clr\XC@mmod\@@clr - \let\@@mod\XC@mmod - \XC@inflate\@@mod\XC@mclr\@@clr\@@tmp - \expandafter\XC@mul\@@tmp,\@@clr - \fi - \edef\@@tmp{\noexpand\XC@bidiundeclaredcolor{\@@mod}{\@@clr}}% - \expandafter\endgroup\@@tmp}} -\def\XC@bidiundeclaredcolor#1#2% - {\@ifundefinedmodel{#1}% - {\c@lor@error{model `#1'}}% - {\@nameuse{color@#1}\current@color{#2}% - \edef\XC@current@color{\noexpand\xcolor@{}{\current@color}{#1}{#2}}% - \XC@display}} -\def\@bidideclaredcolor#1% - {\XC@edef\XC@@tmp{#1}\XC@@tstfalse - \ifcase\XC@type\XC@@tmp\relax \XC@@tsttrue\or \relax\else - \ifblendcolors\XC@@tsttrue\fi \ifmaskcolors\XC@@tsttrue\fi - \ifconvertcolorsU\XC@@tsttrue\fi - \fi - \ifXC@@tst - \expandafter\XC@bidideclaredcolor\else - \expandafter\XC@bidideclaredc@lor\fi} -\def\XC@bidideclaredcolor - {\XC@split\XC@@tmp - \edef\@@tmp{\noexpand\@bidiundeclaredcolor[\@@mod]{\@@clr}}% - \expandafter\endgroup\@@tmp} -\def\XC@bidideclaredc@lor - {\XC@let@Nc\XC@current@color{\string\color@\XC@@tmp}% - \edef\current@color{\XC@current@color}% - \XC@display} -\def\color@box#1#2{\color@b@x\relax{\bidicolor#1{#2}}} -\def\color@fbox#1#2#3#{\protect\color@fb@x{#1}{#2}{#3}} -\def\color@fb@x#1#2#3#4% - {\color@b@x{\fboxsep\z@\bidicolor#1{#2}\XC@fbox}% - {\@ifxempty{#3}{\bidicolor#1}{\bidicolor#3}{#4}}} -%% -%% Copyright © 2009-2010 by Vafa Khalighi -%% -%% Distributable 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 "maintained" (as per LPPL maintenance status) -%% by Vafa Khalighi. -%% -%% -%% -%% -%% -%% End of file `xcolor-bidi.def'. diff --git a/Master/texmf-dist/tex/xelatex/bidi/xcolor-xetex-bidi.def b/Master/texmf-dist/tex/xelatex/bidi/xcolor-xetex-bidi.def new file mode 100644 index 00000000000..3a33bbb25de --- /dev/null +++ b/Master/texmf-dist/tex/xelatex/bidi/xcolor-xetex-bidi.def @@ -0,0 +1,127 @@ +%% +%% This is file `xcolor-xetex-bidi.def', + +%% +%% __________________________________ +%% Copyright © 2009-2010 Vafa Khalighi +%% +%% License information appended. +%% +%% +\ProvidesFile{xcolor-xetex-bidi.def}[2010/07/25 v0.1 bidi adaptations for xcolor package for XeTeX engine] +\long\def\color@b@x#1#2#3% + {\leavevmode\if@RTL\beginL\fi + \setbox\z@\hbox{\kern\fboxsep{\set@color\if@RTL\beginR\fi#3\if@RTL\endR\fi}\kern\fboxsep}% + \dimen@\ht\z@\advance\dimen@\fboxsep\ht\z@\dimen@ + \dimen@\dp\z@\advance\dimen@\fboxsep\dp\z@\dimen@ + {#1{#2\color@block{\wd\z@}{\ht\z@}{\dp\z@}\box\z@}}\if@RTL\endL\fi} +\DeclareRobustCommand\color + {\ifhmode\if@RTL\beginL\aftergroup\endR\fi\fi\@ifnextchar[\@undeclaredcolor\@declaredcolor} +\def\@undeclaredcolor[#1]#2% + {\begingroup + \let\@@cls\@empty + \XC@getmodclr12{#1}{#2}{}% + {\ifblendcolors + \ifx\colorblend\@empty\else + \edef\@@mix{\expandafter\@gobble\colorblend}\@tempswafalse + \XC@coremodel\@@mod\@@clr\@xcolor@{}{}\@@mod\@@clr + \fi + \fi + \ifconvertcolorsU + \edef\@@tmp{\XC@tgt@mod{\@@mod}}% + \convertcolorspec\@@mod\@@clr\@@tmp\@@clr \let\@@mod\@@tmp + \fi + \ifmaskcolors + \convertcolorspec\@@mod\@@clr\XC@mmod\@@clr + \let\@@mod\XC@mmod + \XC@inflate\@@mod\XC@mclr\@@clr\@@tmp + \expandafter\XC@mul\@@tmp,\@@clr + \fi + \edef\@@tmp{\noexpand\XC@undeclaredcolor{\@@mod}{\@@clr}}% + \expandafter\endgroup\@@tmp}} +\def\@declaredcolor#1% + {\XC@edef\XC@@tmp{#1}\XC@@tstfalse + \ifcase\XC@type\XC@@tmp\relax \XC@@tsttrue\or \relax\else + \ifblendcolors\XC@@tsttrue\fi \ifmaskcolors\XC@@tsttrue\fi + \ifconvertcolorsU\XC@@tsttrue\fi + \fi + \ifXC@@tst + \expandafter\XC@declaredcolor\else + \expandafter\XC@declaredc@lor\fi} +\def\XC@undeclaredcolor#1#2% + {\@ifundefinedmodel{#1}% + {\c@lor@error{model `#1'}}% + {\@nameuse{color@#1}\current@color{#2}% + \edef\XC@current@color{\noexpand\xcolor@{}{\current@color}{#1}{#2}}% + \XC@display}\ifhmode\if@RTL\beginR\aftergroup\endL\fi\fi} +\def\XC@declaredc@lor + {\XC@let@Nc\XC@current@color{\string\color@\XC@@tmp}% + \edef\current@color{\XC@current@color}% + \XC@display\ifhmode\if@RTL\beginR\aftergroup\endL\fi\fi} +\DeclareRobustCommand\bidicolor + {\@ifnextchar[\@bidiundeclaredcolor\@bidideclaredcolor} +\def\@bidiundeclaredcolor[#1]#2% + {\begingroup + \let\@@cls\@empty + \XC@getmodclr12{#1}{#2}{}% + {\ifblendcolors + \ifx\colorblend\@empty\else + \edef\@@mix{\expandafter\@gobble\colorblend}\@tempswafalse + \XC@coremodel\@@mod\@@clr\@xcolor@{}{}\@@mod\@@clr + \fi + \fi + \ifconvertcolorsU + \edef\@@tmp{\XC@tgt@mod{\@@mod}}% + \convertcolorspec\@@mod\@@clr\@@tmp\@@clr \let\@@mod\@@tmp + \fi + \ifmaskcolors + \convertcolorspec\@@mod\@@clr\XC@mmod\@@clr + \let\@@mod\XC@mmod + \XC@inflate\@@mod\XC@mclr\@@clr\@@tmp + \expandafter\XC@mul\@@tmp,\@@clr + \fi + \edef\@@tmp{\noexpand\XC@bidiundeclaredcolor{\@@mod}{\@@clr}}% + \expandafter\endgroup\@@tmp}} +\def\XC@bidiundeclaredcolor#1#2% + {\@ifundefinedmodel{#1}% + {\c@lor@error{model `#1'}}% + {\@nameuse{color@#1}\current@color{#2}% + \edef\XC@current@color{\noexpand\xcolor@{}{\current@color}{#1}{#2}}% + \XC@display}} +\def\@bidideclaredcolor#1% + {\XC@edef\XC@@tmp{#1}\XC@@tstfalse + \ifcase\XC@type\XC@@tmp\relax \XC@@tsttrue\or \relax\else + \ifblendcolors\XC@@tsttrue\fi \ifmaskcolors\XC@@tsttrue\fi + \ifconvertcolorsU\XC@@tsttrue\fi + \fi + \ifXC@@tst + \expandafter\XC@bidideclaredcolor\else + \expandafter\XC@bidideclaredc@lor\fi} +\def\XC@bidideclaredcolor + {\XC@split\XC@@tmp + \edef\@@tmp{\noexpand\@bidiundeclaredcolor[\@@mod]{\@@clr}}% + \expandafter\endgroup\@@tmp} +\def\XC@bidideclaredc@lor + {\XC@let@Nc\XC@current@color{\string\color@\XC@@tmp}% + \edef\current@color{\XC@current@color}% + \XC@display} +\def\color@box#1#2{\color@b@x\relax{\bidicolor#1{#2}}} +\def\color@fbox#1#2#3#{\protect\color@fb@x{#1}{#2}{#3}} +\def\color@fb@x#1#2#3#4% + {\color@b@x{\fboxsep\z@\bidicolor#1{#2}\XC@fbox}% + {\@ifxempty{#3}{\bidicolor#1}{\bidicolor#3}{#4}}} +%% +%% Copyright © 2009-2010 by Vafa Khalighi +%% +%% Distributable 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 "maintained" (as per LPPL maintenance status) +%% by Vafa Khalighi. +%% +%% +%% +%% +%% +%% End of file `xcolor-xetex-bidi.def'. diff --git a/Master/texmf-dist/tex/xelatex/bidi/xetex-bidi.def b/Master/texmf-dist/tex/xelatex/bidi/xetex-bidi.def new file mode 100644 index 00000000000..831687a69f2 --- /dev/null +++ b/Master/texmf-dist/tex/xelatex/bidi/xetex-bidi.def @@ -0,0 +1,441 @@ +%% +%% This is file `xetex-bidi.def', + +%% +%% __________________________________ +%% Copyright © 2009-2010 Vafa Khalighi +%% +%% License information appended. +%% +%% +\ProvidesFile{xetex-bidi.def}[2010/07/25 v0.1 bidi adaptations for XeTeX engine] +\ifx\TeXXeTstate\undefined\else% + \TeXXeTstate=1 +\fi +\def\Bidi@RTL@everypar{\if@RTL{\setbox\z@\lastbox\beginR\usebox\z@}\fi} + \let\o@everypar=\everypar + \newtoks\n@everypar + \n@everypar\expandafter{\the\o@everypar} + \o@everypar{\Bidi@RTL@everypar\the\n@everypar} + \let\everypar=\n@everypar +\def\moreLRE{\bracetext \aftergroup\endL \beginL\@RTLfalse} +\def\moreRLE{\bracetext \aftergroup\endR \beginR\@RTLtrue} +\def\lr#1{\begingroup\beginL\rmfamily#1\endL\endgroup} +\def\LTR{\bgroup\par\@RTLfalse\@RTL@footnotefalse} +\def\endLTR{\par\egroup} +\def\RTL{\bgroup\par\@RTLtrue\@RTL@footnotetrue} +\def\endRTL{\par\egroup} +\def\ltr{\if@RTL\par\@RTLfalse\@RTL@footnotefalse\fi} +\def\rtl{\if@RTL\relax\else\par\@RTLtrue\@RTL@footnotetrue\fi} +\def\setRTL{\@RTLtrue\@RTL@footnotetrue} +\def\setLTR{\@RTLfalse\@RTL@footnotefalse} +\let\unsetRTL=\setLTR +\let\unsetLTR=\setRTL +\let\LR=\LRE +\let\RL=\RLE +\def\@ensure@RTL#1{\if@RTL#1\else\RLE{#1}\fi} +\def\@ensure@LTR#1{\if@RTL\LRE{#1}\else#1\fi} +\let\@ensure@RL=\@ensure@RTL +\let\@ensure@LR=\@ensure@LTR +\def\@ensure@dir#1{\if@RTL\RLE{#1}\else{#1}\fi} +\let\@ensure@maindir=\@ensure@dir +\def\@@RTL{RTL} +\def\@@LTR{LTR} +\def\save@dir{\if@RTL\gdef\saved@@dir{RTL}\else\gdef\saved@@dir{LTR}\fi} +\def\reset@dir{\ifx\saved@@dir\@@RTL\setRTL\else\ifx\saved@@dir\@@LTR\setLTR\else\relax\fi\fi} +\let\@@TeX\TeX +\def\TeX{\@ensure@LTR{\@@TeX}} +\let\@@LaTeX\LaTeX +\def\LaTeX{\@ensure@LTR{\@@LaTeX}} +\let\@@LaTeXe\LaTeXe +\def\LaTeXe{\@ensure@LTR{\@@LaTeXe}} +\def\reflect#1{{\setbox0=\hbox{#1}\rlap{\kern0.5\wd0 + \special{x:gsave}\special{x:scale -1 1}}\box0 \special{x:grestore}}} +\def\XeTeX{\LR{\leavevmode$\smash{\hbox{X\lower.5ex + \hbox{\kern-.125em\reflect{E}}\kern-.1667em \TeX}}$}} +\def\XeLaTeX{\LR{\leavevmode$\smash{\hbox{X\lower.5ex + \hbox{\kern-.125em\reflect{E}}\kern-.1667em \LaTeX}}$}} +\let\setRL=\setRTL +\let\setLR=\setLTR +\let\unsetRL=\setLTR +\DeclareOption{RTLdocument}{\@RTLtrue\@RTL@footnotetrue\autofootnoterule} +\DeclareOption{rldocument}{\@RTLtrue\@RTL@footnotetrue\autofootnoterule} +\def\rcases#1{\left.\vcenter{\normalbaselines\m@th + \ialign{$##\hfil$&\quad{##}\hfil\crcr#1\crcr}}\,\right\}} +\def\SepMark#1{\gdef\@SepMark{\if@RTL\beginR\fi#1\if@RTL\endR\fi}} +\SepMark{.} +\def\@thmcountersep{\@SepMark} +\def\list#1#2{% + \ifnum \@listdepth >5\relax + \@toodeep + \else + \global\advance\@listdepth\@ne + \fi + \rightmargin\z@ + \listparindent\z@ + \itemindent\z@ + \csname @list\romannumeral\the\@listdepth\endcsname + \def\@itemlabel{#1}% + \let\makelabel\@mklab + \@nmbrlistfalse + #2\relax + \@trivlist + \parskip\parsep + \parindent\listparindent + \advance\linewidth -\rightmargin + \advance\linewidth -\leftmargin + \if@RTL + \advance\@totalleftmargin \rightmargin + \else + \advance\@totalleftmargin \leftmargin + \fi + \parshape \@ne \@totalleftmargin \linewidth + \ignorespaces} +\def\raggedright{% + \let\\\@centercr + \leftskip\z@skip\rightskip\@flushglue + \parindent\z@\parfillskip\z@skip} +\let\@@raggedleft=\raggedleft +\let\@@raggedright=\raggedright +\renewcommand\raggedleft{\if@RTL\@@raggedright% + \else\@@raggedleft\fi} +\renewcommand\raggedright{\if@RTL\@@raggedleft% + \else\@@raggedright\fi} +\def\raggedright{% + \let\\\@centercr + \rightskip\z@skip\rightskip\@flushglue + \parindent\z@\parfillskip\z@skip} +\renewcommand\raggedleft{\@@raggedleft} +\renewcommand\raggedright{\@@raggedright} +\def\centerline#1{% +\if@RTL\@@line{\hss\beginR#1\endR\hss} +\else\@@line{\hss#1\hss}\fi} +\def\leftline#1{% +\if@RTL\@@line{\beginR#1\endR\hss} +\else\@@line{#1\hss}\fi} +\def\rightline#1{% +\if@RTL\@@line{\hss\beginR#1\endR} +\else\@@line{\hss#1}\fi} +\def\narrower{% + \advance\if@RTL\rightskip\else\leftskip\fi\parindent + \advance\if@RTL\leftskip\else\rightskip\fi\parindent} +\def\underline#1{% + \relax + \ifmmode\@@underline{#1}% + \else +\if@RTL $\@@underline{\hbox{\beginR#1\endR}}\m@th$\relax +\else +$\@@underline{\hbox{#1}}\m@th$\relax\fi\fi} +\if@compatibility + \let\undertext=\underline +\fi +\global\@RTLtabfalse +\def\@tabular{\if@RTL\global\@RTLtabtrue\fi + \leavevmode \hbox \bgroup \if@RTLtab\beginR \fi + $\let\@acol\@tabacol + \let\@classz\@tabclassz + \let\@classiv\@tabclassiv \let\\\@tabularcr\@tabarray} +\def\endtabular{\crcr\egroup\if@RTLtab\egroup\endR\egroup\fi + \egroup $\if@RTLtab\endR\fi\egroup + \global\@RTLtabfalse} +\expandafter \let \csname endtabular*\endcsname = \endtabular +\def\@array[#1]#2{% + \if #1t\vtop \else \if#1b\vbox \else \vcenter \fi\fi + \bgroup + \setbox\@arstrutbox\hbox{% + \vrule \@height\arraystretch\ht\strutbox + \@depth\arraystretch \dp\strutbox + \@width\z@}% + \@mkpream{#2}% + \edef\@preamble{% + \ialign \noexpand\@halignto + \bgroup \@arstrut \@preamble \tabskip\z@skip \cr}% + \let\@startpbox\@@startpbox \let\@endpbox\@@endpbox + \let\tabularnewline\\% + \let\par\@empty + \let\@sharp##% + \set@typeset@protect + \lineskip\z@skip\baselineskip\z@skip + \ifhmode \@preamerr\z@ \@@par\fi + \if@RTLtab\hbox\bgroup\beginR\vbox\bgroup\fi + \@preamble} +\def\@testpach#1{\@chclass \ifnum \@lastchclass=\tw@ 4 \else + \ifnum \@lastchclass=3 5 \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 \else + \if #1@\tw@ \else + \if #1p3 \else \z@ \@preamerr 0\fi + \fi \fi \fi \fi \fi \fi +\fi} +\def\@dottedtocline#1#2#3#4#5{% + \ifnum #1>\c@tocdepth \else + \vskip \z@ \@plus.2\p@ + {\if@RTL\rightskip\else\leftskip\fi #2\relax \if@RTL\leftskip\else\rightskip\fi \@tocrmarg \parfillskip -\if@RTL\leftskip\else\rightskip\fi + \parindent #2\relax\@afterindenttrue + \interlinepenalty\@M + \leavevmode + \@tempdima #3\relax + \advance\if@RTL\rightskip\else\leftskip\fi \@tempdima \null\nobreak\hskip -\if@RTL\rightskip\else\leftskip\fi + {#4}\nobreak + \leaders\hbox{$\m@th + \mkern \@dotsep mu\hbox{.}\mkern \@dotsep + mu$}\hfill + \nobreak + \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} +\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 + {\normalcolor\vrule \@width\columnseprule}% + \hfil + \hb@xt@\columnwidth {% + \box\@outputbox \hss}% + }% + }% + \@combinedblfloats + \@outputpage + \begingroup + \@dblfloatplacement + \@startdblcolumn + \@whilesw\if@fcolmade \fi + {\@outputpage + \@startdblcolumn}% + \endgroup + \fi +} +\renewcommand{\@outputdblcol}{\if@RTLmain\RTL@outputdblcol\else\LTR@outputdblcol\fi} +\newcommand{\RTLdblcol}{\renewcommand{\@outputdblcol}{\RTL@outputdblcol}} +\newcommand{\LTRdblcol}{\renewcommand{\@outputdblcol}{\LTR@outputdblcol}} +\def \@setminipage{% + \@minipagetrue + \everypar{\@minipagefalse\everypar{}\if@RTL\beginR\else\beginL\fi}% +} +\def\@arrayparboxrestore{% + \let\if@nobreak\iffalse + \let\if@noskipsec\iffalse + \let\par\@@par + \let\-\@dischyph + \let\'\@acci\let\`\@accii\let\=\@acciii + \parindent\z@ \parskip\z@skip + \everypar{\if@RTL\beginR\else\beginL\fi}% + \linewidth\hsize + \@totalleftmargin\z@ + \leftskip\z@skip \rightskip\z@skip \@rightskip\z@skip + \parfillskip\@flushglue \lineskip\normallineskip + \baselineskip\normalbaselineskip + \sloppy} +\def\@addmarginpar{\@next\@marbox\@currlist{\@cons\@freelist\@marbox + \@cons\@freelist\@currbox}\@latexbug\@tempcnta\@ne + \if@twocolumn + \if@firstcolumn \@tempcnta\m@ne \fi + \else + \if@mparswitch + \ifodd\c@page \else\@tempcnta\m@ne \fi + \fi + \if@reversemargin \@tempcnta -\@tempcnta \fi + \fi + \ifnum\@tempcnta <\z@ \global\setbox\@marbox\box\@currbox \fi + \@tempdima\@mparbottom + \advance\@tempdima -\@pageht + \advance\@tempdima\ht\@marbox + \ifdim\@tempdima >\z@ + \@latex@warning@no@line {Marginpar on page \thepage\space moved}% + \else + \@tempdima\z@ + \fi + \global\@mparbottom\@pageht + \global\advance\@mparbottom\@tempdima + \global\advance\@mparbottom\dp\@marbox + \global\advance\@mparbottom\marginparpush + \advance\@tempdima -\ht\@marbox + \global\setbox \@marbox + \vbox {\vskip \@tempdima + \box \@marbox}% + \global \ht\@marbox \z@ + \global \dp\@marbox \z@ + \kern -\@pagedp + \nointerlineskip + \hb@xt@\columnwidth + {\if@RTL\beginR\fi\ifnum \@tempcnta >\z@ + \hskip\columnwidth \hskip\marginparsep + \else + \hskip -\marginparsep \hskip -\marginparwidth + \fi + \box\@marbox \hss\if@RTL\endR\fi}% + \nointerlineskip + \hbox{\vrule \@height\z@ \@width\z@ \@depth\@pagedp}} +\def\@stopline{\unskip\@stopfield\if@rjfield \global\@rjfieldfalse + \@tempdima\@totalleftmargin \advance\@tempdima\linewidth +\hbox to\@tempdima{\if@RTL\beginR\fi\@itemfudge\hskip\dimen\@curtabmar + \box\@curline\hfil\box\@curfield\if@RTL\endR\fi}\else\@addfield + \hbox to\linewidth{\if@RTL\beginR\fi\@itemfudge + \hskip\dimen\@curtabmar\box\@curline\hfil\if@RTL\endR\fi}% +\fi} +\def\@outputpage{% +\begingroup % the \endgroup is put in by \aftergroup + \let \protect \noexpand + \@resetactivechars + \global\let\@@if@newlist\if@newlist + \global\@newlistfalse + \@parboxrestore + \shipout \vbox{% + \set@typeset@protect + \aftergroup \endgroup + \aftergroup \set@typeset@protect + % correct? or just restore by ending + % the group? + \if@specialpage + \global\@specialpagefalse\@nameuse{ps@\@specialstyle}% + \fi + \if@twoside + \ifodd\count\z@ \let\@thehead\@oddhead \let\@thefoot\@oddfoot + \let\@themargin\oddsidemargin + \else \let\@thehead\@evenhead + \let\@thefoot\@evenfoot \let\@themargin\evensidemargin + \fi + \ifx\@thehead\@empty \let\@thehead\hfil \fi + \ifx\@thefoot\@empty \let\@thefoot\hfil \fi + \else %% not @twoside + \ifx\@oddhead\@empty \let\@thehead\hfil \fi + \ifx\@oddfoot\@empty \let\@thefoot\hfil \fi + \fi + \reset@font + \normalsize + \normalsfcodes + \let\label\@gobble + \let\index\@gobble + \let\glossary\@gobble + \baselineskip\z@skip \lineskip\z@skip \lineskiplimit\z@ + \@begindvi + \vskip \topmargin + \moveright\@themargin \vbox {% + \setbox\@tempboxa \vbox to\headheight{% + \vfil + \color@hbox + \normalcolor + \hb@xt@\textwidth{\if@RTLmain\beginR\fi\@thehead\if@RTLmain\endR\fi}% + \color@endbox + }% %% 22 Feb 87 + \dp\@tempboxa \z@ + \box\@tempboxa + \vskip \headsep + \box\@outputbox + \baselineskip \footskip + \color@hbox + \normalcolor + \hb@xt@\textwidth{\if@RTLmain\beginR\fi\@thefoot\if@RTLmain\endR\fi}% + \color@endbox + }% + }% + \global\let\if@newlist\@@if@newlist + \global \@colht \textheight + \stepcounter{page}% + \let\firstmark\botmark +} +\long\def\@makecaption#1#2{% + \vskip\abovecaptionskip + \sbox\@tempboxa{#1: #2}% + \ifdim \wd\@tempboxa >\hsize + \if@RTL\beginR\fi#1: #2\if@RTL\endR\fi\par + \else + \global \@minipagefalse + \hb@xt@\hsize{\if@RTL\beginR\fi\hfil\box\@tempboxa\hfil\if@RTL\endR\fi}% + \fi + \vskip\belowcaptionskip} +\def\equation{\beginL$$\refstepcounter{equation}} +\def\endequation{\eqno \hbox{\@eqnnum}$$\endL\@ignoretrue} +\def\@eqnnum{{\normalfont \normalcolor \if@RTL\beginR\fi(\theequation)\if@RTL\endR\fi}} +\input{footnote-xetex-bidi.def} +\@iftagsloaded{leqno}{\input{leqno-xetex-bidi.def}}{} +\@iftagsloaded{fleqn}{\input{fleqn-xetex-bidi.def}}{} +\@ifpackageloaded{amsmath}{\input{amsmath-xetex-bidi.def}}{} +\@ifpackageloaded{amsthm}{\input{amsthm-xetex-bidi.def}}{} +\@ifpackageloaded{breqn}{\input{breqn-xetex-bidi.def}}{} +\@ifpackageloaded{caption}{\input{caption-xetex-bidi.def}}{} +\@ifpackageloaded{color}{\input{color-xetex-bidi.def}}{} +\@ifpackageloaded{xcolor}{\input{xcolor-xetex-bidi.def}}{} +\@ifpackageloaded{colortbl}{\input{colortbl-xetex-bidi.def}}{} +\@ifpackageloaded{flowfram}{\input{flowfram-xetex-bidi.def}}{} +\@ifpackageloaded{xltxtra}{\input{xltxtra-xetex-bidi.def}}{} +\@ifpackageloaded{wrapfig}{\input{wrapfig-xetex-bidi.def}}{} +\@ifpackageloaded{graphicx}{\input{graphicx-xetex-bidi.def}}{} +\@ifpackageloaded{hyperref}{\input{hyperref-xetex-bidi.def}}{} +\@ifpackageloaded{fancyhdr}{\input{fancyhdr-xetex-bidi.def}}{} +\@ifpackageloaded{draftwatermark}{\input{draftwatermark-xetex-bidi.def}}{} +\@ifpackageloaded{pdfpages}{\input{pdfpages-xetex-bidi.def}}{} +\@ifpackageloaded{listings}{\input{listings-xetex-bidi.def}}{} +\@ifpackageloaded{pstricks}{\input{pstricks-xetex-bidi.def}}{} +\@ifpackageloaded{pgf}{\input{pgf-xetex-bidi.def}}{} +\@ifpackageloaded{tikz}{\input{tikz-xetex-bidi.def}}{} +\@ifpackageloaded{array}{\input{array-xetex-bidi.def}}{} +\@ifpackageloaded{stabular}{\input{stabular-xetex-bidi.def}}{} +\@ifpackageloaded{subfigure}{\input{subfigure-xetex-bidi.def}}{} +\@ifpackageloaded{longtable}{\input{longtable-xetex-bidi.def}}{} +\@ifpackageloaded{arydshln}{\input{arydshln-xetex-bidi.def}}{} +\@ifpackageloaded{multicol}{\input{multicol-xetex-bidi.def}}{} +\@ifpackageloaded{minitoc}{\input{minitoc-xetex-bidi.def}}{} +\@ifpackageloaded{ragged2e}{\input{ragged2e-xetex-bidi.def}}{} +\@ifpackageloaded{tabls}{\input{tabls-xetex-bidi.def}}{} +\@ifpackageloaded{tabulary}{\input{tabulary-xetex-bidi.def}}{} +\@ifpackageloaded{tocstyle}{\input{tocstyle-xetex-bidi.def}}{} +\@ifclassloaded{article}{\input{article-xetex-bidi.def}}{} +\@ifclassloaded{amsart}{\input{amsart-xetex-bidi.def}}{} +\@ifclassloaded{letter}{\input{letter-xetex-bidi.def}}{} +\@ifclassloaded{memoir}{\input{memoir-xetex-bidi.def}}{} +\@ifclassloaded{refrep}{\input{refrep-xetex-bidi.def}}{} +\@ifclassloaded{report}{\@ifpackageloaded{flowfram}{}{\input{report-xetex-bidi.def}}}{} +\@ifclassloaded{rapport3}{\input{rapport3-xetex-bidi.def}}{} +\@ifclassloaded{scrartcl}{\input{scrartcl-xetex-bidi.def}}{} +\@ifclassloaded{scrbook}{\input{scrbook-xetex-bidi.def}}{} +\@ifclassloaded{scrreprt}{\input{scrreprt-xetex-bidi.def}}{} +\@ifclassloaded{amsbook}{\input{amsbook-xetex-bidi.def}}{} +\@ifclassloaded{extbook}{\input{extbook-xetex-bidi.def}}{} +\@ifclassloaded{book}{\@ifpackageloaded{flowfram}{}{\input{book-xetex-bidi.def}}}{} +\@ifclassloaded{bookest}{\input{bookest-xetex-bidi.def}}{} +\@ifpackageloaded{tocbibind}{\@ifclassloaded{memoir}{}{\input{tocbibind-xetex-bidi.def}}}{} +\@ifpackageloaded{tocloft}{\@ifclassloaded{memoir}{}{\input{tocloft-xetex-bidi.def}}}{} + + +%% +%% Copyright © 2009-2010 by Vafa Khalighi +%% +%% Distributable 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 "maintained" (as per LPPL maintenance status) +%% by Vafa Khalighi. +%% +%% +%% +%% +%% +%% End of file `xetex-bidi.def'. diff --git a/Master/texmf-dist/tex/xelatex/bidi/xltxtra-bidi.def b/Master/texmf-dist/tex/xelatex/bidi/xltxtra-bidi.def deleted file mode 100644 index 208a8211f52..00000000000 --- a/Master/texmf-dist/tex/xelatex/bidi/xltxtra-bidi.def +++ /dev/null @@ -1,30 +0,0 @@ -%% -%% This is file `xltxtra-bidi.def', - -%% -%% __________________________________ -%% Copyright © 2009-2010 Vafa Khalighi -%% -%% License information appended. -%% -%% -\ProvidesFile{xltxtra-bidi.def}[2010/03/01 v0.1 adaptations for xltxtra package] -\let\@@XeTeX\XeTeX -\def\XeTeX{\@ensure@LTR{\@@XeTeX}} -\let\@@XeLaTeX\XeLaTeX -\def\XeLaTeX{\@ensure@LTR{\@@XeLaTeX}} -%% -%% Copyright © 2009-2010 by Vafa Khalighi -%% -%% Distributable 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 "maintained" (as per LPPL maintenance status) -%% by Vafa Khalighi. -%% -%% -%% -%% -%% -%% End of file `xltxtra-bidi.def'. diff --git a/Master/texmf-dist/tex/xelatex/bidi/xltxtra-xetex-bidi.def b/Master/texmf-dist/tex/xelatex/bidi/xltxtra-xetex-bidi.def new file mode 100644 index 00000000000..fbef2973005 --- /dev/null +++ b/Master/texmf-dist/tex/xelatex/bidi/xltxtra-xetex-bidi.def @@ -0,0 +1,30 @@ +%% +%% This is file `xltxtra-xetex-bidi.def', + +%% +%% __________________________________ +%% Copyright © 2009-2010 Vafa Khalighi +%% +%% License information appended. +%% +%% +\ProvidesFile{xltxtra-xetex-bidi.def}[2010/07/25 v0.1 bidi adaptations for xltxtra package for XeTeX engine] +\let\@@XeTeX\XeTeX +\def\XeTeX{\@ensure@LTR{\@@XeTeX}} +\let\@@XeLaTeX\XeLaTeX +\def\XeLaTeX{\@ensure@LTR{\@@XeLaTeX}} +%% +%% Copyright © 2009-2010 by Vafa Khalighi +%% +%% Distributable 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 "maintained" (as per LPPL maintenance status) +%% by Vafa Khalighi. +%% +%% +%% +%% +%% +%% End of file `xltxtra-xetex-bidi.def'. -- cgit v1.2.3