aboutsummaryrefslogtreecommitdiff
path: root/samples/template-01.tex
blob: 1a5ea4f8afd4adc10ba5e6ea20ac32df5559937b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
\documentclass[paper=letter, DIV=classic, headings=small]{scrartcl}

\usepackage{ccicons}
\usepackage{paralist}

\usepackage{arabluatex}

\usepackage{hyperref}
\hypersetup{colorlinks, linkcolor=blue, breaklinks}

\subject{\textsf{arabluatex} sample files}
\title{The Basics}
\author{Robert Alessi\thanks{\cczero\ This file is public domain.}}

\begin{document}
\maketitle

\begin{abstract}
  This file demonstrates the basic features of \texttt{arabluatex}.
\end{abstract}

\section{The less, the better}
\label{sec:less-better}
\textsf{arabluatex} is loaded by one single line in the preamble:
\begin{verbatim}
\usepackage{arabluatex}
\end{verbatim}
That said, there are two subsequent requirements:
\begin{compactenum}
\item An Arabic font: \textsf{arabluatex} tries to load the
  \textsf{Amiri} Arabic font which is already part of
  \textsf{texlive}.
\item A Roman font that has all the characters that are needed for
  the transliteration of the Arabic.
\end{compactenum}

Once these requirements are met, one may insert Arabic words in
left-to-right paragraphs like so: \verb|\arb{da_hala mubtasimaN}|,
\arb{da_hala mubtasimaN}. Or insert running paragraphs of Arabic text
inside the \verb|arab| environment, like so:---
\begin{verbatim}
\begin{arab}
  'at_A .sadIquN 'il_A ju.hA ya.tlubu min-hu .himAra-hu li-yarkaba-hu
  fI safraTiN qa.sIraTiN fa-qAla la-hu: sawfa 'u`Idu-hu 'ilay-ka fI
  'l-masA'-i wa-'adfa`u la-ka 'ujraTaN. fa-qAla ju.hA: 'anA 'AsifuN
  jiddaN 'annI lA 'asta.tI`u 'an 'u.haqqiqa la-ka ra.gbata-ka
  fa-'l-.himAr-u laysa hunA 'l-yawm-a.  wa-qabla 'an yutimma ju.hA
  kalAma-hu bada'a 'l-.himAr-u yanhaqu fI 'i.s.tabli-hi. fa-qAla la-hu
  .sadIqu-hu: 'innI 'asma`u .himAra-ka yA ju.hA yanhaqu. fa-qAla la-hu
  ju.hA: .garIbuN 'amru-ka yA .sadIqI 'a-tu.saddiqu 'l-.himAr-a
  wa-tuka_d_diba-nI?
\end{arab}
\end{verbatim}
\begin{arab}
  'at_A .sadIquN 'il_A ju.hA ya.tlubu min-hu .himAra-hu li-yarkaba-hu
  fI safraTiN qa.sIraTiN fa-qAla la-hu: sawfa 'u`Idu-hu 'ilay-ka fI
  'l-masA'-i wa-'adfa`u la-ka 'ujraTaN. fa-qAla ju.hA: 'anA 'AsifuN
  jiddaN 'annI lA 'asta.tI`u 'an 'u.haqqiqa la-ka ra.gbata-ka
  fa-'l-.himAr-u laysa hunA 'l-yawm-a.  wa-qabla 'an yutimma ju.hA
  kalAma-hu bada'a 'l-.himAr-u yanhaqu fI 'i.s.tabli-hi. fa-qAla la-hu
  .sadIqu-hu: 'innI 'asma`u .himAra-ka yA ju.hA yanhaqu. fa-qAla la-hu
  ju.hA: .garIbuN 'amru-ka yA .sadIqI 'a-tu.saddiqu 'l-.himAr-a
  wa-tuka_d_diba-nI?
\end{arab}

\section{Options}
\label{sec:options}
\textsf{arabluatex} may be loaded with four mutually exclusive options:---
\begin{compactdesc}
\item[voc] To have every short vowel written. This option is loaded by
  default.
\item[fullvoc] To have the \arb[trans]{sukUn} and the
  \arb[trans]{wa.slaT} expressed in addition to what \verb|voc|
  already does.
\item[novoc] To have all the diacritics discarded.
\item[trans] To have the Arabic transliterated into one of the
  accepted standards.
\end{compactdesc}
\begin{verbatim}
% <preamble>
\usepackage{arabluatex} % this loads 'voc' by default
\usepackage[voc]{arabluatex}
\usepackage[fullvoc]{arabluatex}
\usepackage[novoc]{arabluatex}
\usepackage[trans]{arabluatex}
\end{verbatim}

At any point of the document, any mode can be set locally, like so:---
\begin{verbatim}
English paragraph: To have the \arb[trans]{sukUn} and the
  \arb[trans]{wa.slaT} expressed...

\begin{arab}[trans] % Arabic paragraph
  'at_A .sadIquN 'il_A \uc{j}u.hA ya.tlubu min-hu .himAra-hu
  li-yarkaba-hu fI safraTiN qa.sIraTiN fa-qAla la-hu: sawfa 'u`Idu-hu
  'ilay-ka fI 'l-masA'-i wa-'adfa`u la-ka 'ujraTaN.
\end{arab}
\end{verbatim}

English paragraph: To have the \arb[trans]{sukUn} and the
  \arb[trans]{wa.slaT} expressed...

\begin{arab}[trans] % Arabic paragraph
  'at_A .sadIquN 'il_A \uc{j}u.hA ya.tlubu min-hu .himAra-hu
  li-yarkaba-hu fI safraTiN qa.sIraTiN fa-qAla la-hu: sawfa 'u`Idu-hu
  'ilay-ka fI 'l-masA'-i wa-'adfa`u la-ka 'ujraTaN.
\end{arab}

\end{document}