diff options
-rw-r--r-- | ekdosis.dtx | 188 |
1 files changed, 106 insertions, 82 deletions
diff --git a/ekdosis.dtx b/ekdosis.dtx index 1174a9f..63ac19d 100644 --- a/ekdosis.dtx +++ b/ekdosis.dtx | |||
@@ -2676,12 +2676,13 @@ argument of the | |||
2676 | % been used for Arabic. | 2676 | % been used for Arabic. |
2677 | % \end{remarks} | 2677 | % \end{remarks} |
2678 | % | 2678 | % |
2679 | % As one can see, the important point about languages written from | 2679 | % As one can see, the important points about languages written from |
2680 | % right to left is to use \pkg{babel} only to select the Arabic fonts, | 2680 | % right to left are to use \pkg{babel} only to select the Arabic |
2681 | % avoid using the bidirectional mechanism it provides and define | 2681 | % fonts, avoid using the bidirectional mechanism it provides and |
2682 | % commands and environments that use \LuaTeX\ primitives to set the | 2682 | % define commands and environments that use only \LuaTeX\ primitives |
2683 | % writing direction. Then, an Arabic edition text\---to continue with | 2683 | % to set the writing direction. Then, an Arabic edition text\---to |
2684 | % this example\---can be entered as follows:--- | 2684 | % continue with this example\---can be entered as plainly as |
2685 | % follows:--- | ||
2685 | % | 2686 | % |
2686 | % \iffalse | 2687 | % \iffalse |
2687 | %<*example> | 2688 | %<*example> |
@@ -2724,9 +2725,9 @@ argument of the | |||
2724 | % \end{specimen} | 2725 | % \end{specimen} |
2725 | % \end{alignment} | 2726 | % \end{alignment} |
2726 | % | 2727 | % |
2727 | % And here is the PDF output with right-to-left apparatus criticus:--- | 2728 | % And here follows the PDF output with right-to-left apparatus |
2728 | % \medskip | 2729 | % criticus:--- |
2729 | % \resetlinenumber | 2730 | % \medskip \resetlinenumber |
2730 | % \begin{alignment}[flush,tcols=1,texts=specimen,apparatus=specimen] | 2731 | % \begin{alignment}[flush,tcols=1,texts=specimen,apparatus=specimen] |
2731 | % \begin{specimen} | 2732 | % \begin{specimen} |
2732 | % \begin{arab}[fullvoc] | 2733 | % \begin{arab}[fullvoc] |
@@ -2744,16 +2745,16 @@ argument of the | |||
2744 | % \pkg{arabluatex} is a \hologo{LuaLaTeX} package that provides | 2745 | % \pkg{arabluatex} is a \hologo{LuaLaTeX} package that provides |
2745 | % commands and environments which return Arabic writing from an ASCII | 2746 | % commands and environments which return Arabic writing from an ASCII |
2746 | % transliteration (either Arab\TeX\ or Buckwalter | 2747 | % transliteration (either Arab\TeX\ or Buckwalter |
2747 | % schemes).\footcite{arabluatex} It is particularly well-suited for | 2748 | % scheme).\footcite{arabluatex} It is particularly well-suited for |
2748 | % complex documents such as critical editions where a lot of commands | 2749 | % complex documents such as critical editions where a lot of commands |
2749 | % intertwine with Arabic writing. \pkg{arabluatex} can output Unicode | 2750 | % intertwine with Arabic writing. \pkg{arabluatex} can output Unicode |
2750 | % Arabic in the same modes as \pkg{arabtex}\footcite{arabtex} or in | 2751 | % Arabic in the same modes as \pkg{arabtex}\footcite{arabtex} or in |
2751 | % different accepted standards of romanization. It is also able to | 2752 | % different accepted standards of romanization. It is also able to |
2752 | % produce a duplicate of the original |.tex| source file in which all | 2753 | % produce a duplicate of the original |.tex| source file in which all |
2753 | % |arabtex| or |buckwalter| strings will have been replaced with | 2754 | % |arabtex| or |buckwalter| strings are replaced with Unicode |
2754 | % Unicode equivalents, either in Arabic script or in any accepted | 2755 | % equivalents, either in Arabic script or in any accepted standard of |
2755 | % standard of transliteration.\footcite[See][\mkbibquote{Exporting | 2756 | % transliteration.\footcite[See][\mkbibquote{Exporting Unicode Arabic |
2756 | % Unicode Arabic to an External File}]{arabluatex} | 2757 | % to an External File}]{arabluatex} |
2757 | % | 2758 | % |
2758 | % \pkg{arabluatex} is fully supported by \pkg{ekdosis}. The following | 2759 | % \pkg{arabluatex} is fully supported by \pkg{ekdosis}. The following |
2759 | % example illustrates how \pkg{arabluatex} and \pkg{ekdosis} interact | 2760 | % example illustrates how \pkg{arabluatex} and \pkg{ekdosis} interact |
@@ -2768,7 +2769,7 @@ argument of the | |||
2768 | % Preamble: | 2769 | % Preamble: |
2769 | % load ekdosis and ask for TEI xml output: | 2770 | % load ekdosis and ask for TEI xml output: |
2770 | \usepackage[teiexport]{ekdosis} | 2771 | \usepackage[teiexport]{ekdosis} |
2771 | % load arabluatex and ask for LaTeX ouput with Unicode Arabic: | 2772 | % load arabluatex and request a LaTeX ouput with Unicode Arabic: |
2772 | \usepackage[export,fullvoc]{arabluatex} | 2773 | \usepackage[export,fullvoc]{arabluatex} |
2773 | 2774 | ||
2774 | % document: | 2775 | % document: |
@@ -2823,13 +2824,34 @@ subtype="arabtex">'inna 'abI kAna mina | |||
2823 | %</example> | 2824 | %</example> |
2824 | % \fi | 2825 | % \fi |
2825 | % | 2826 | % |
2826 | % While \pkg{arabluatex} is instructed to produce on his own from the | 2827 | % At the same time, \pkg{arabluatex} is instructed to produce on its |
2827 | % same |source.tex| an additional |source_out.tex| in which all | 2828 | % own from the same |source.tex| an additional |source_out.tex| in |
2828 | % |arabtex| strings found within \cs{begin}|{arabexport}| \dots\ | 2829 | % which all |arabtex| strings found within \cs{begin}|{arabexport}| |
2829 | % \cs{end}|{arabexport}| (see \vref{lst:arabluatex-ekd}, ll.~9--19) | 2830 | % \dots\ \cs{end}|{arabexport}| (see \vref{lst:arabluatex-ekd}, |
2830 | % are replaced with full-vocalized Arabic Unicode strings. | 2831 | % ll.~9--19) are replaced with full-vocalized Arabic Unicode |
2831 | % | 2832 | % strings. Finally, compiling this latter file produces the following |
2833 | % |sample-arabic_out-tei.xml| an extract of which follows:--- | ||
2832 | % | 2834 | % |
2835 | % \iffalse | ||
2836 | %<*example> | ||
2837 | % \fi | ||
2838 | \begin{minted}[linenos=false,escapeinside=++]{xml} | ||
2839 | <p xml:lang="arb">+\txarb{إِنَّ أَبِي كَانَ مِنَ}+ | ||
2840 | <app> | ||
2841 | <lem>+\txarb{ٱلْمُقَاتِلَةِ}+</lem> | ||
2842 | <rdg>+\txarb{ٱلْمُقَاتِلِينَ}+</rdg> | ||
2843 | </app>+\txarb{وَكَانَتْ أُمِّي مِنْ عُظَمَآءِ بُيُوتِ}+ | ||
2844 | +\txarb{ٱلزَّمَازِمَةِ.}+</p> | ||
2845 | \end{minted} | ||
2846 | % \iffalse | ||
2847 | %</example> | ||
2848 | % \fi | ||
2849 | % | ||
2850 | % The reader will find the full |arabic-sample.tex| source file with | ||
2851 | % instructions in \vref{sec:arabic-sample}, and is invited to refer to | ||
2852 | % the documentation of the \pkg{arabluatex} package for more | ||
2853 | % information on the way to use its Arabic environments and exporting | ||
2854 | % features.\footcite{arabluatex} | ||
2833 | % | 2855 | % |
2834 | % \section{To Be Continued...} | 2856 | % \section{To Be Continued...} |
2835 | % v1.0 of \pkg{ekdosis}, which should be available by the end of July | 2857 | % v1.0 of \pkg{ekdosis}, which should be available by the end of July |
@@ -3382,8 +3404,70 @@ subtype="arabtex">'inna 'abI kAna mina | |||
3382 | % recommend releasing these examples in parallel under your choice of | 3404 | % recommend releasing these examples in parallel under your choice of |
3383 | % free software license, such as the GNU General Public License, | 3405 | % free software license, such as the GNU General Public License, |
3384 | % to permit their use in free software. | 3406 | % to permit their use in free software. |
3407 | % | ||
3408 | % \section{References} | ||
3409 | % \label{sec:references} | ||
3410 | % \printbibliography[heading=none] | ||
3411 | % | ||
3412 | % \section{Sample: C. J. Caesar, \emph{Gallic War}, | ||
3413 | % VI, XIII.1} | ||
3414 | % \label{sec:caesar-gw-6-1-13} | ||
3415 | % \subsection{\texttt{.tex} Source File} | ||
3416 | % \label{sec:caesar-gw-tex} | ||
3417 | % \inputminted[linenos=false]{latex}{samples/Caesar_BG-6-13-1.tex} | ||
3418 | % \subsection{\texttt{TEI xml} Output} | ||
3419 | % \label{sec:caesar-gw-tei} | ||
3420 | % \inputminted[linenos=false]{xml}{samples/Caesar_BG-6-13-1-tei.xml} | ||
3385 | % | 3421 | % |
3386 | % \printbibliography[heading=bibintoc] | 3422 | % \section{Arabic Sample File} |
3423 | % \label{sec:arabic-sample} | ||
3424 | % |arabic-sample.tex|:--- | ||
3425 | % \iffalse | ||
3426 | %<*example> | ||
3427 | % \fi | ||
3428 | \begin{minted}[linenos=false]{latex} | ||
3429 | % Instructions: | ||
3430 | % 1. Compile this file three times. | ||
3431 | % - Open arabic-sample.pdf and arabic-sample-tei.xml and see the | ||
3432 | % result. | ||
3433 | % 2. Compile arabic-sample_out.tex three times. | ||
3434 | % - Open arabic-sample_out.pdf and arabic-sample-out-tei.xml and | ||
3435 | % see the result. | ||
3436 | % | ||
3437 | \documentclass{article} | ||
3438 | |||
3439 | % The following three lines are only needed by the | ||
3440 | % 'arabic-sample_out.tex' that arabluatex is instructed to produce: | ||
3441 | \usepackage{babel} | ||
3442 | \babelprovide[onchar=fonts]{arabic} | ||
3443 | \babelfont[*arabic]{rm}{Amiri} | ||
3444 | |||
3445 | % instruct ekdosis to output TEI xml (arabic-sample-tei.xml): | ||
3446 | \usepackage[teiexport=tidy]{ekdosis} | ||
3447 | |||
3448 | % instruct arabluatex to ouput sample-arabic_out.tex with Unicode | ||
3449 | % Arabic strings in place of arabtex ASCII scheme: | ||
3450 | \usepackage[fullvoc,export]{arabluatex} | ||
3451 | |||
3452 | \begin{document} | ||
3453 | |||
3454 | \begin{arabexport} % export arabtex strings to Unicode Arabic | ||
3455 | \begin{ekdosis} | ||
3456 | \begin{arab} | ||
3457 | 'inna 'abI kAna mina | ||
3458 | \app{ | ||
3459 | \lem{'l-muqAtilaTi} | ||
3460 | \rdg{'l-muqAtilIna} | ||
3461 | } | ||
3462 | wa-kAnat 'ummI min `u.zamA'i buyUti 'l-zamAzimaTi. | ||
3463 | \end{arab} | ||
3464 | \end{ekdosis} | ||
3465 | \end{arabexport} | ||
3466 | \end{document} | ||
3467 | \end{minted} | ||
3468 | % \iffalse | ||
3469 | %</example> | ||
3470 | % \fi | ||
3387 | % | 3471 | % |
3388 | % \StopEventually{} | 3472 | % \StopEventually{} |
3389 | % | 3473 | % |
@@ -6644,65 +6728,5 @@ end | |||
6644 | % \iffalse | 6728 | % \iffalse |
6645 | %</lua> | 6729 | %</lua> |
6646 | % \fi | 6730 | % \fi |
6647 | % | ||
6648 | % \section{Sample: C. J. Caesar, \emph{Gallic War}, | ||
6649 | % VI, XIII.1} | ||
6650 | % \label{sec:caesar-gw-6-1-13} | ||
6651 | % \subsection{\texttt{.tex} Source File} | ||
6652 | % \label{sec:caesar-gw-tex} | ||
6653 | % \inputminted[linenos=false]{latex}{samples/Caesar_BG-6-13-1.tex} | ||
6654 | % \subsection{\texttt{TEI xml} Output} | ||
6655 | % \label{sec:caesar-gw-tei} | ||
6656 | % \inputminted[linenos=false]{xml}{samples/Caesar_BG-6-13-1-tei.xml} | ||
6657 | % | ||
6658 | % \section{Arabic Sample File} | ||
6659 | % \label{sec:arabic-sample} | ||
6660 | % |arabic-sample.tex|:--- | ||
6661 | % \iffalse | ||
6662 | %<*example> | ||
6663 | % \fi | ||
6664 | \begin{minted}[linenos=false]{latex} | ||
6665 | % Instructions: | ||
6666 | % 1. Compile this file three times. | ||
6667 | % - Open arabic-sample.pdf and arabic-sample-tei.xml and see the | ||
6668 | % result. | ||
6669 | % 2. Compile arabic-sample_out.tex three times. | ||
6670 | % - Open arabic-sample_out.pdf and arabic-sample-out-tei.xml and | ||
6671 | % see the result. | ||
6672 | % | ||
6673 | \documentclass{article} | ||
6674 | |||
6675 | % The following three lines are only needed by the | ||
6676 | % 'arabic-sample_out.tex' that arabluatex is instructed to produce: | ||
6677 | \usepackage{babel} | ||
6678 | \babelprovide[onchar=fonts]{arabic} | ||
6679 | \babelfont[*arabic]{rm}{Amiri} | ||
6680 | |||
6681 | % instruct ekdosis to output TEI xml (arabic-sample-tei.xml): | ||
6682 | \usepackage[teiexport=tidy]{ekdosis} | ||
6683 | |||
6684 | % instruct arabluatex to ouput sample-arabic_out.tex with Unicode | ||
6685 | % Arabic strings in place of arabtex ASCII scheme: | ||
6686 | \usepackage[fullvoc,export]{arabluatex} | ||
6687 | |||
6688 | \begin{document} | ||
6689 | |||
6690 | \begin{arabexport} % export arabtex strings to Unicode Arabic | ||
6691 | \begin{ekdosis} | ||
6692 | \begin{arab} | ||
6693 | 'inna 'abI kAna mina | ||
6694 | \app{ | ||
6695 | \lem{'l-muqAtilaTi} | ||
6696 | \rdg{'l-muqAtilIna} | ||
6697 | } | ||
6698 | wa-kAnat 'ummI min `u.zamA'i buyUti 'l-zamAzimaTi. | ||
6699 | \end{arab} | ||
6700 | \end{ekdosis} | ||
6701 | \end{arabexport} | ||
6702 | \end{document} | ||
6703 | \end{minted} | ||
6704 | % \iffalse | ||
6705 | %</example> | ||
6706 | % \fi | ||
6707 | % | 6731 | % |
6708 | \endinput | 6732 | \endinput |