From e0c6872cf40896c7be36b11dcc744620f10adf1d Mon Sep 17 00:00:00 2001
From: Norbert Preining <norbert@preining.info>
Date: Mon, 2 Sep 2019 13:46:59 +0900
Subject: Initial commit

---
 ...reledpar_pages_different_languages_lualatex.tex | 73 ++++++++++++++++++++++
 1 file changed, 73 insertions(+)
 create mode 100644 macros/latex/contrib/reledmac/examples/3-reledpar_pages_different_languages_lualatex.tex

(limited to 'macros/latex/contrib/reledmac/examples/3-reledpar_pages_different_languages_lualatex.tex')

diff --git a/macros/latex/contrib/reledmac/examples/3-reledpar_pages_different_languages_lualatex.tex b/macros/latex/contrib/reledmac/examples/3-reledpar_pages_different_languages_lualatex.tex
new file mode 100644
index 0000000000..751bde69f6
--- /dev/null
+++ b/macros/latex/contrib/reledmac/examples/3-reledpar_pages_different_languages_lualatex.tex
@@ -0,0 +1,73 @@
+\documentclass{article}
+\usepackage[osf,p]{libertinus}
+\usepackage{microtype}
+\usepackage[pdfusetitle,hidelinks]{hyperref}
+
+\usepackage[series={},nocritical,noend,nofamiliar,noledgroup]{reledmac}
+\usepackage{reledpar}
+
+\newfontfamily\syriacfont{Estrangelo Edessa}[Script=Syriac,Scale=1.2]
+
+\usepackage{ifluatex}
+\ifluatex
+  \newcommand{\textsyriac}[1] % Syriac inside LTR
+             {\bgroup\textdir TRT\syriacfont #1\egroup}
+  \newenvironment{syriac}     % Syriac paragraph
+             {\textdir TRT\pardir TRT\syriacfont}{}
+\else
+  \usepackage{graphicx}
+  \usepackage{polyglossia}
+  \setmainlanguage{english}
+  \setotherlanguage{syriac}
+  \renewcommand{\textsyriac}[1]{\bgroup\syriacfont #1\egroup}
+\fi
+\usepackage{metalogo}
+
+\newcommand{\n}[1] % for digits inside Arabic text
+           {\bgroup\LTR  #1\egroup}
+\newcommand{\syriacfootnote}[1] % Syriac Footnotes
+           {\footnote{\textsyriac{#1}}}
+
+\begin{document}
+\date{}
+\title{Using \LuaLaTeX\ to typeset RTL text with reledpar}
+\maketitle
+\begin{abstract}
+This file provides an example on how to use  reledpar and \LuaLaTeX\ to typeset a right to left text with its translation on the facing page\footnote{The text was provided by Latechneuse on \url{https://tex.stackexchange.com/q/227837/}.}.  
+
+As you can see, the switch to RTL convention is made \emph{before} the \verb+pstart+.
+It must be also called inside \verb+\eledsection+.
+
+For an example with \XeLaTeX, look at \href{./parallel-column-two-languages.tex}{parallel-column-two-languages.tex} file.
+\end{abstract}
+
+\begin{pages}
+\begin{Leftside}
+\begin{syriac}
+\beginnumbering
+   \pstart
+       \eledsection*{\textsyriac{ܡܿܟܪܟܝ}}
+   \pend
+
+   \pstart
+        1ܘܟܕ 2ܡܿܟܪܟܝ3ܢܢ ܐܪܟ4ܐܢܐ ܗ̄ 5ܡܘܪܐ6 ܗܿܝ ܩ7ܕܡܝܬܐ
+   \pend
+\endnumbering
+\end{syriac}
+\end{Leftside}
+
+\begin{Rightside}
+\beginnumbering
+   \pstart
+       \eledsection{English headline} 
+   \pend
+
+   \pstart
+        Some english text. 
+   \pend
+\endnumbering
+\end{Rightside}
+
+\end{pages} 
+\Pages
+\end{document}
-- 
cgit v1.2.3

