aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRobert Alessi <alessi@robertalessi.net>2016-03-10 20:21:12 +0100
committerRobert Alessi <alessi@robertalessi.net>2016-03-10 20:21:12 +0100
commite23d740f2c94f7e105eabade859149e559038104 (patch)
tree0d14f16a5fc24ea35f48c100ce414c46ad86086f
parent313be0a19b4a86c898fe3bc73cd4442f9132034d (diff)
downloadarabluatex-e23d740f2c94f7e105eabade859149e559038104.tar.gz
writing documentation (continued) + added quoting u|a|i
-rw-r--r--arabluatex.bib32
-rw-r--r--arabluatex.dtx61
-rw-r--r--arabluatex_fullvoc.lua4
-rw-r--r--arabluatex_novoc.lua3
-rw-r--r--arabluatex_voc.lua7
5 files changed, 91 insertions, 16 deletions
diff --git a/arabluatex.bib b/arabluatex.bib
index cd56afc..1023e84 100644
--- a/arabluatex.bib
+++ b/arabluatex.bib
@@ -20,14 +20,40 @@
20% Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 20% Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
21% 02111-1307, USA. 21% 02111-1307, USA.
22 22
23@package{pkg:arabtex, 23@software{pkg:arabtex,
24 author = {Lagally, Klaus}, 24 author = {Lagally, Klaus},
25 maintainer = {Lagally, Klaus}, 25 maintainer = {Lagally, Klaus},
26 title = {Arab\TeX}, 26 title = {Arab\TeX},
27 indextitle = {Arab\TeX},
27 date = {2004-11-03}, 28 date = {2004-11-03},
28 version = {4.00}, 29 version = {4.00},
29 url = 30 url =
30 {http://mirrors.ctan.org/language/arabic/arabtex/doc/html/arabtex.htm}, 31 {http://mirrors.ctan.org/language/arabic/arabtex/doc/html/arabtex.htm},
31 subtitle = {Typesetting Arabic and Hebrew}, 32 subtitle = {Typesetting Arabic and Hebrew},
32 titleaddon = {User Manual Version 4.00} 33 titleaddon = {User Manual Version 4.00}
33} 34}
35
36@software{pkg:amiri,
37 author = {Hosny, Khaled},
38 maintainer = {Hosny, Khaled},
39 title = {Amiri},
40 indextitle = {Amiri},
41 date = {2015-09-20},
42 url = {http://www.amirifont.org/}
43}
44
45@MVBook{Wright,
46 author = {Wright, W. LL.D},
47 title = {A Grammar of the Arabic Language},
48 indextitle = {Grammar of the Arabic Language, A},
49 year = 1896,
50 editor = {Robertson Smith, W. and de Goeje, M. J.},
51 editortype = {reviser},
52 edition = 3,
53 volumes = 2,
54 pagination = {none},
55 publisher = {Librairie du Liban},
56 location = {Beirut},
57 annote = {New impression, 1996}
58}
59
diff --git a/arabluatex.dtx b/arabluatex.dtx
index 797af14..54e5024 100644
--- a/arabluatex.dtx
+++ b/arabluatex.dtx
@@ -44,18 +44,25 @@
44\usepackage{hypdoc} 44\usepackage{hypdoc}
45\hypersetup{colorlinks, allcolors=blue} 45\hypersetup{colorlinks, allcolors=blue}
46\usepackage{multicol} 46\usepackage{multicol}
47\newcommand{\package}[1]{\textsf{#1}}
48\usepackage{paralist} 47\usepackage{paralist}
49\setdefaultitem{\textendash}{\textendash}{\textendash}{\textendash} 48\setdefaultitem{\textendash}{\textendash}{\textendash}{\textendash}
50\usepackage{longtable} 49\usepackage{longtable}
51\usepackage{booktabs} 50\usepackage{booktabs}
52\usepackage{tikz} 51\usepackage{tikz}
53\usepackage[skins,listings]{tcolorbox} 52\usepackage[breakable, skins,listings,xparse]{tcolorbox}
54\newtcblisting{arabluacode}[1]{colback=white, boxrule=.15mm, 53\DeclareTCBListing{arabluacode}{s}{colback=white, boxrule=.15mm,
55 colframe=red!50!white, listing options={style=tcblatex, 54 colframe=red!50!white, listing options={style=tcblatex,
56 numbers=left, numberstyle=\tiny}, #1} 55 numbers=left, numberstyle=\tiny}, IfBooleanTF={#1}{listing side
56 text}{}}
57\DeclareTotalTCBox{\arabluaverb}{v}{verbatim, colback=white,
58 boxrule=.15mm, colframe=red!50!white}{#1}
59\DeclareTotalTCBox{\arabluabox}{m}{left=0mm, right=0mm, top=0mm,
60 bottom=0mm, colback=white, boxrule=.15mm,
61 colframe=red!50!white}{#1}
62\newcommand{\package}[1]{\textsf{#1}\index{#1=#1 (package)}}
57\usepackage{csquotes} 63\usepackage{csquotes}
58\usepackage[style=authoryear, natbib]{biblatex} 64\usepackage[style=authoryear, indexing=cite]{biblatex}
65\DeclareIndexFieldFormat{indextitle}{\index{#1=\emph{#1}}}
59\addbibresource{arabluatex.bib} 66\addbibresource{arabluatex.bib}
60\EnableCrossrefs 67\EnableCrossrefs
61\CodelineIndex 68\CodelineIndex
@@ -253,16 +260,47 @@
253% 260%
254% \section{Usage} 261% \section{Usage}
255% \subsection{Activating \package{arabluatex}} 262% \subsection{Activating \package{arabluatex}}
256% As usual put in your preamble: 263% As usual put in your preamble:\\
257% |\usepackage{arabluatex}| 264% \arabluaverb{\usepackage{arabluatex}}\\
258% The only requirement of \package{arabluatex} is \LuaLaTeX; it will 265% The only requirement of \package{arabluatex} is \LuaLaTeX; it will
259% complain if you try to compile your document with another 266% complain if you try to compile your document with another
260% engine. That aside, \package{arabluatex} does not load packages such 267% engine. That aside, \package{arabluatex} does not load packages such
261% as \package{polyglossia} or \package{luabidi}. It can work with 268% as \package{polyglossia} or \package{luabidi}. It can work with
262% \package{polyglossia} but does not require it. 269% \package{polyglossia} though, but does not require it.
270%
271% \paragraph{Font setup}
272% If you wish to use your own Arabic font, you can define it before
273% loading \package{arabluatex}. Assuming that \package{fontspec} is
274% loaded, put this in your preamble just above the line that loads
275% \package{arabluatex}:
276% \arabluabox{\cs{newfontfamily}\cs{arabicfont}[Script=Arabic]\marg{fontname}}
277% \noindent where \meta{fontname} is the standard name of the Arabic
278% font you wish to use.
279%
280% By default, if no Arabic font is selected, \package{arabluatex} will
281% issue a warning message and attempt to load the Amiri
282% font\footnote{\textcite{pkg:amiri}.} like so:\\
283% \arabluaverb{\newfontfamily\arabicfont[Script=Arabic]{Amiri}}
284% \begin{quote}\footnotesize
285% \textbf{Rem.} By default Amiri places the \arb[trans]{kasra} in
286% combination with the \arb[trans]{ta^sdId} below the consonant,
287% like so: \arb{BBi}\,. This is correct, as at least in the oldest
288% manuscripts {\newfontfamily\arabicfont[Script=Arabic,
289% RawFeature={+ss05}]{Amiri}\arb{BBi}} may stand for \arb{BBa} as
290% well as \arb{BBi}\,. See \textcite[i.14.C--D]{Wright}. The placement
291% of the \arb[trans]{kasra} above the consonant may be obtained by
292% selecting the |ss05| feature of the Amiri font, like
293% so:\footnote{See the documentation of \package{amiri},
294% \textcite[5]{pkg:amiri}.}\\
295% \arabluaverb{\newfontfamily\arabicfont[Script=Arabic,RawFeature={+ss05}]{Amiri}}
296%
297% Other Arabic fonts may behave differently.
298% \end{quote}
299%
300% \subsection{Options}
301%
263% 302%
264% \DescribeOption{voc} 303% \DescribeOption{voc}\hfill\arabluaverb{default}\\ good for me
265% good for me
266% \begin{itemize} 304% \begin{itemize}
267% \item voc Vocalized Arabic 305% \item voc Vocalized Arabic
268% \item novoc Full vocalized Arabic 306% \item novoc Full vocalized Arabic
@@ -332,6 +370,7 @@
332\def\al@mode@novoc{novoc} 370\def\al@mode@novoc{novoc}
333\def\al@mode@trans{trans} 371\def\al@mode@trans{trans}
334% \newif\ifal@mode@defined 372% \newif\ifal@mode@defined
373\RequirePackage{fontspec}
335\RequirePackage{amsmath} 374\RequirePackage{amsmath}
336\RequirePackage{etoolbox} 375\RequirePackage{etoolbox}
337\RequirePackage{luacode} 376\RequirePackage{luacode}
diff --git a/arabluatex_fullvoc.lua b/arabluatex_fullvoc.lua
index 0b591e7..8fb564e 100644
--- a/arabluatex_fullvoc.lua
+++ b/arabluatex_fullvoc.lua
@@ -173,6 +173,8 @@ digraphsfv = {
173 {a="ww", b="وّ"}, 173 {a="ww", b="وّ"},
174 {a="yy", b="يّ"}, 174 {a="yy", b="يّ"},
175 -- sukūn begin 175 -- sukūn begin
176 {a="\"", b=""},
177 {a="([%_%^%.]?[btjghxdrzs%`fqklmnwy])$", b="%1ْ"},
176 {a="([%_%^%.]?[btjghxdrzs%`fqklmnwy])([%s])", b="%1ْ%2"}, 178 {a="([%_%^%.]?[btjghxdrzs%`fqklmnwy])([%s])", b="%1ْ%2"},
177 {a="([%_%^%.]?[btjghxdrzs%`fqklmnwy])([^%_uaiUAIًٌٍ])", b="%1ْ%2"}, 179 {a="([%_%^%.]?[btjghxdrzs%`fqklmnwy])([^%_uaiUAIًٌٍ])", b="%1ْ%2"},
178 -- sukūn end 180 -- sukūn end
@@ -197,5 +199,5 @@ digraphsfv = {
197 {a="%.b", b="ٮ"}, 199 {a="%.b", b="ٮ"},
198 {a="%.f", b="ڡ"}, 200 {a="%.f", b="ڡ"},
199 {a="%.k", b="ک"}, 201 {a="%.k", b="ک"},
200 {a="%.n", b="ں"} 202 {a="%.n", b="ں"},
201} 203}
diff --git a/arabluatex_novoc.lua b/arabluatex_novoc.lua
index 199059b..b6d59d2 100644
--- a/arabluatex_novoc.lua
+++ b/arabluatex_novoc.lua
@@ -43,6 +43,9 @@ longvnv = {
43} 43}
44 44
45shortvnv = { 45shortvnv = {
46 {a="\"u", b="ُ"},
47 {a="\"a", b="َ"},
48 {a="\"i", b="ِ"},
46 {a="u", b=""}, 49 {a="u", b=""},
47 {a="a", b=""}, 50 {a="a", b=""},
48 {a="i", b=""} 51 {a="i", b=""}
diff --git a/arabluatex_voc.lua b/arabluatex_voc.lua
index 9451074..25d46bb 100644
--- a/arabluatex_voc.lua
+++ b/arabluatex_voc.lua
@@ -269,7 +269,9 @@ single = {
269 {a="w", b="و"}, 269 {a="w", b="و"},
270 {a="y", b="ي"}, 270 {a="y", b="ي"},
271 {a="T", b="ة"}, 271 {a="T", b="ة"},
272 {a="\"", b="ْ"}, 272 {a="\"$", b="ْ"},
273 {a="\"(%W)", b="ْ%1"},
274 {a="\"([^uaiUAI])", b="ْ%1"},
273 {a="([^0-9])%-([^0-9])", b="%1%2"}, 275 {a="([^0-9])%-([^0-9])", b="%1%2"},
274 {a="B", b="ـ"} 276 {a="B", b="ـ"}
275} 277}
@@ -282,6 +284,9 @@ longv = {
282} 284}
283 285
284shortv = { 286shortv = {
287 {a="\"u", b="ُ"},
288 {a="\"a", b="َ"},
289 {a="\"i", b="ِ"},
285 {a="u", b="ُ"}, 290 {a="u", b="ُ"},
286 {a="a", b="َ"}, 291 {a="a", b="َ"},
287 {a="i", b="ِ"} 292 {a="i", b="ِ"}