arabluatex.dtx 174 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240124112421243124412451246124712481249125012511252125312541255125612571258125912601261126212631264126512661267126812691270127112721273127412751276127712781279128012811282128312841285128612871288128912901291129212931294129512961297129812991300130113021303130413051306130713081309131013111312131313141315131613171318131913201321132213231324132513261327132813291330133113321333133413351336133713381339134013411342134313441345134613471348134913501351135213531354135513561357135813591360136113621363136413651366136713681369137013711372137313741375137613771378137913801381138213831384138513861387138813891390139113921393139413951396139713981399140014011402140314041405140614071408140914101411141214131414141514161417141814191420142114221423142414251426142714281429143014311432143314341435143614371438143914401441144214431444144514461447144814491450145114521453145414551456145714581459146014611462146314641465146614671468146914701471147214731474147514761477147814791480148114821483148414851486148714881489149014911492149314941495149614971498149915001501150215031504150515061507150815091510151115121513151415151516151715181519152015211522152315241525152615271528152915301531153215331534153515361537153815391540154115421543154415451546154715481549155015511552155315541555155615571558155915601561156215631564156515661567156815691570157115721573157415751576157715781579158015811582158315841585158615871588158915901591159215931594159515961597159815991600160116021603160416051606160716081609161016111612161316141615161616171618161916201621162216231624162516261627162816291630163116321633163416351636163716381639164016411642164316441645164616471648164916501651165216531654165516561657165816591660166116621663166416651666166716681669167016711672167316741675167616771678167916801681168216831684168516861687168816891690169116921693169416951696169716981699170017011702170317041705170617071708170917101711171217131714171517161717171817191720172117221723172417251726172717281729173017311732173317341735173617371738173917401741174217431744174517461747174817491750175117521753175417551756175717581759176017611762176317641765176617671768176917701771177217731774177517761777177817791780178117821783178417851786178717881789179017911792179317941795179617971798179918001801180218031804180518061807180818091810181118121813181418151816181718181819182018211822182318241825182618271828182918301831183218331834183518361837183818391840184118421843184418451846184718481849185018511852185318541855185618571858185918601861186218631864186518661867186818691870187118721873187418751876187718781879188018811882188318841885188618871888188918901891189218931894189518961897189818991900190119021903190419051906190719081909191019111912191319141915191619171918191919201921192219231924192519261927192819291930193119321933193419351936193719381939194019411942194319441945194619471948194919501951195219531954195519561957195819591960196119621963196419651966196719681969197019711972197319741975197619771978197919801981198219831984198519861987198819891990199119921993199419951996199719981999200020012002200320042005200620072008200920102011201220132014201520162017201820192020202120222023202420252026202720282029203020312032203320342035203620372038203920402041204220432044204520462047204820492050205120522053205420552056205720582059206020612062206320642065206620672068206920702071207220732074207520762077207820792080208120822083208420852086208720882089209020912092209320942095209620972098209921002101210221032104210521062107210821092110211121122113211421152116211721182119212021212122212321242125212621272128212921302131213221332134213521362137213821392140214121422143214421452146214721482149215021512152215321542155215621572158215921602161216221632164216521662167216821692170217121722173217421752176217721782179218021812182218321842185218621872188218921902191219221932194219521962197219821992200220122022203220422052206220722082209221022112212221322142215221622172218221922202221222222232224222522262227222822292230223122322233223422352236223722382239224022412242224322442245224622472248224922502251225222532254225522562257225822592260226122622263226422652266226722682269227022712272227322742275227622772278227922802281228222832284228522862287228822892290229122922293229422952296229722982299230023012302230323042305230623072308230923102311231223132314231523162317231823192320232123222323232423252326232723282329233023312332233323342335233623372338233923402341234223432344234523462347234823492350235123522353235423552356235723582359236023612362236323642365236623672368236923702371237223732374237523762377237823792380238123822383238423852386238723882389239023912392239323942395239623972398239924002401240224032404240524062407240824092410241124122413241424152416241724182419242024212422242324242425242624272428242924302431243224332434243524362437243824392440244124422443244424452446244724482449245024512452245324542455245624572458245924602461246224632464246524662467246824692470247124722473247424752476247724782479248024812482248324842485248624872488248924902491249224932494249524962497249824992500250125022503250425052506250725082509251025112512251325142515251625172518251925202521252225232524252525262527252825292530253125322533253425352536253725382539254025412542254325442545254625472548254925502551255225532554255525562557255825592560256125622563256425652566256725682569257025712572257325742575257625772578257925802581258225832584258525862587258825892590259125922593259425952596259725982599260026012602260326042605260626072608260926102611261226132614261526162617261826192620262126222623262426252626262726282629263026312632263326342635263626372638263926402641264226432644264526462647264826492650265126522653265426552656265726582659266026612662266326642665266626672668266926702671267226732674267526762677267826792680268126822683268426852686268726882689269026912692269326942695269626972698269927002701270227032704270527062707270827092710271127122713271427152716271727182719272027212722272327242725272627272728272927302731273227332734273527362737273827392740274127422743274427452746274727482749275027512752275327542755275627572758275927602761276227632764276527662767276827692770277127722773277427752776277727782779278027812782278327842785278627872788278927902791279227932794279527962797279827992800280128022803280428052806280728082809281028112812281328142815281628172818281928202821282228232824282528262827282828292830283128322833283428352836283728382839284028412842284328442845284628472848284928502851285228532854285528562857285828592860286128622863286428652866286728682869287028712872287328742875287628772878287928802881288228832884288528862887288828892890289128922893289428952896289728982899290029012902290329042905290629072908290929102911291229132914291529162917291829192920292129222923292429252926292729282929293029312932293329342935293629372938293929402941294229432944294529462947294829492950295129522953295429552956295729582959296029612962296329642965296629672968296929702971297229732974297529762977297829792980298129822983298429852986298729882989299029912992299329942995299629972998299930003001300230033004300530063007300830093010301130123013301430153016301730183019302030213022302330243025302630273028302930303031303230333034303530363037303830393040304130423043304430453046304730483049305030513052305330543055305630573058305930603061306230633064306530663067306830693070307130723073307430753076307730783079308030813082308330843085308630873088308930903091309230933094309530963097309830993100310131023103310431053106310731083109311031113112311331143115311631173118311931203121312231233124312531263127312831293130313131323133313431353136313731383139314031413142314331443145314631473148314931503151315231533154315531563157315831593160316131623163316431653166316731683169317031713172317331743175317631773178317931803181318231833184318531863187318831893190319131923193319431953196319731983199320032013202320332043205320632073208320932103211321232133214321532163217321832193220322132223223322432253226322732283229323032313232323332343235323632373238323932403241324232433244324532463247324832493250325132523253325432553256325732583259326032613262326332643265326632673268326932703271327232733274327532763277327832793280328132823283328432853286328732883289329032913292329332943295329632973298329933003301330233033304330533063307330833093310331133123313331433153316331733183319332033213322332333243325332633273328332933303331333233333334333533363337333833393340334133423343334433453346334733483349335033513352335333543355335633573358335933603361336233633364336533663367336833693370337133723373337433753376337733783379338033813382338333843385338633873388338933903391339233933394339533963397339833993400340134023403340434053406340734083409341034113412341334143415341634173418341934203421342234233424342534263427342834293430343134323433343434353436343734383439344034413442344334443445344634473448344934503451345234533454345534563457345834593460346134623463346434653466346734683469347034713472347334743475347634773478347934803481348234833484348534863487348834893490349134923493349434953496349734983499350035013502350335043505350635073508350935103511351235133514351535163517351835193520352135223523352435253526352735283529353035313532353335343535353635373538353935403541354235433544354535463547354835493550355135523553355435553556355735583559356035613562356335643565356635673568356935703571357235733574357535763577357835793580358135823583358435853586358735883589359035913592359335943595359635973598359936003601360236033604360536063607360836093610361136123613361436153616361736183619362036213622362336243625362636273628362936303631363236333634363536363637363836393640364136423643364436453646364736483649365036513652365336543655365636573658365936603661366236633664366536663667366836693670367136723673367436753676367736783679368036813682368336843685368636873688368936903691369236933694369536963697369836993700370137023703370437053706370737083709371037113712371337143715371637173718371937203721372237233724372537263727372837293730373137323733373437353736373737383739374037413742374337443745374637473748374937503751375237533754375537563757375837593760376137623763376437653766376737683769377037713772377337743775377637773778377937803781378237833784378537863787378837893790379137923793379437953796379737983799380038013802380338043805380638073808380938103811381238133814381538163817381838193820382138223823382438253826382738283829383038313832383338343835383638373838383938403841384238433844384538463847384838493850385138523853385438553856385738583859386038613862386338643865386638673868386938703871387238733874387538763877387838793880388138823883388438853886388738883889389038913892389338943895389638973898389939003901390239033904390539063907390839093910391139123913391439153916391739183919392039213922392339243925392639273928392939303931393239333934393539363937393839393940394139423943394439453946394739483949395039513952395339543955395639573958395939603961396239633964396539663967396839693970397139723973397439753976397739783979398039813982398339843985398639873988398939903991399239933994399539963997399839994000400140024003400440054006400740084009401040114012401340144015401640174018401940204021402240234024402540264027402840294030403140324033403440354036403740384039404040414042404340444045404640474048404940504051405240534054405540564057405840594060406140624063406440654066406740684069407040714072407340744075407640774078407940804081408240834084408540864087408840894090409140924093409440954096409740984099410041014102410341044105410641074108410941104111411241134114411541164117411841194120412141224123412441254126412741284129413041314132413341344135413641374138413941404141414241434144414541464147414841494150415141524153415441554156415741584159416041614162416341644165416641674168416941704171417241734174417541764177417841794180418141824183418441854186418741884189419041914192
  1. % \iffalse meta-comment
  2. % ArabLuaTeX -- Processing ArabTeX notation under LuaLaTeX
  3. % Copyright (C) 2016--2018 Robert Alessi
  4. %
  5. % Please send error reports and suggestions for improvements to Robert
  6. % Alessi <alessi@robertalessi.net>
  7. %
  8. % This program is free software: you can redistribute it and/or modify
  9. % it under the terms of the GNU General Public License as published by
  10. % the Free Software Foundation, either version 3 of the License, or
  11. % (at your option) any later version.
  12. %
  13. % This program is distributed in the hope that it will be useful, but
  14. % WITHOUT ANY WARRANTY; without even the implied warranty of
  15. % MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
  16. % General Public License for more details.
  17. %
  18. % You should have received a copy of the GNU General Public License
  19. % along with this program. If not, see
  20. % <http://www.gnu.org/licenses/>.
  21. % \fi
  22. %
  23. % \iffalse
  24. %<*driver>
  25. \ProvidesFile{arabluatex.dtx}
  26. %</driver>
  27. %<package-info>\NeedsTeXFormat{LaTeX2e}[1999/12/01]
  28. %<package-info>\ProvidesPackage{arabluatex}
  29. %<*package-info>
  30. [2018/03/31 v1.11 An ArabTeX-like interface for LuaLaTeX]
  31. %</package-info>
  32. %
  33. %<*driver>
  34. \documentclass{ltxdoc}
  35. \usepackage{filecontents}
  36. \begin{filecontents}{\jobname.bib}
  37. % This file is part of the `arabluatex' package
  38. %
  39. % ArabLuaTeX -- Processing ArabTeX notation under LuaLaTeX
  40. % Copyright (C) 2016--2018 Robert Alessi
  41. %
  42. % Please send error reports and suggestions for improvements to Robert
  43. % Alessi <alessi@robertalessi.net>
  44. %
  45. % This program is free software: you can redistribute it and/or modify
  46. % it under the terms of the GNU General Public License as published by
  47. % the Free Software Foundation, either version 3 of the License, or
  48. % (at your option) any later version.
  49. %
  50. % This program is distributed in the hope that it will be useful, but
  51. % WITHOUT ANY WARRANTY; without even the implied warranty of
  52. % MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
  53. % General Public License for more details.
  54. %
  55. % You should have received a copy of the GNU General Public License
  56. % along with this program. If not, see
  57. % <http://www.gnu.org/licenses/>.
  58. @software{pkg:arabtex,
  59. author = {Lagally, Klaus},
  60. maintainer = {Lagally, Klaus},
  61. title = {Arab\TeX},
  62. indextitle = {Arab\TeX},
  63. date = {2004-11-03},
  64. version = {4.00},
  65. url =
  66. {http://mirrors.ctan.org/language/arabic/arabtex/doc/html/arabtex.htm},
  67. subtitle = {Typesetting Arabic and Hebrew},
  68. titleaddon = {User Manual Version 4.00}
  69. }
  70. @software{pkg:amiri,
  71. author = {Hosny, Khaled},
  72. maintainer = {Hosny, Khaled},
  73. title = {Amiri},
  74. indextitle = {Amiri},
  75. date = {2015-09-20},
  76. url = {http://www.amirifont.org/}
  77. }
  78. @Book{Habash,
  79. author = {Habash, Nizar Y.},
  80. title = {Introduction to Arabic Natural Language Processing},
  81. year = 2010,
  82. series = {Synthesis Lectures on Human Language Technologies},
  83. number = 10,
  84. publisher = {Morgan \& Claypool Publishers},
  85. location = {Toronto}
  86. }
  87. @MVBook{Wright,
  88. author = {Wright, W. LL.D},
  89. title = {A Grammar of the Arabic Language},
  90. indextitle = {Grammar of the Arabic Language, A},
  91. year = 1896,
  92. editor = {Robertson Smith, W. and de Goeje, M. J.},
  93. editortype = {reviser},
  94. foreword = {Cachia, Pierre},
  95. edition = 3,
  96. volumes = 2,
  97. pagination = {none},
  98. publisher = {Librairie du Liban},
  99. location = {Beirut},
  100. annote = {New impression, 1996}
  101. }
  102. @Manual{din31635,
  103. label = {{DIN 31~635}},
  104. title = {Information and Documentation - Romanization of the
  105. Arabic Alphabet for Arabic, Ottoman-Turkish,
  106. Persian, Kurdish, Urdu and Pushto},
  107. date = {2011-07},
  108. url = {http://www.din.de}
  109. }
  110. @InProceedings{dmg,
  111. author = {Brockelmann, Carl and Fischer, August and Heffening,
  112. W. and Taeschner, Franz},
  113. shorttitle = {Die Transliteration der arabischen Schrift},
  114. title = {Die Transliteration der arabischen Schrift in ihrer
  115. Anwendung auf die Hauptliteratursprachen der
  116. islamischen Welt},
  117. indextitle = {Transliteration der arabischen Schrift, Die},
  118. year = 1935,
  119. booktitle = {Denkschrift dem 19. internationalen
  120. Orientalistenkongreß in Rom vorgelegt von der
  121. Transkriptionkommission der Deutschen
  122. Morgenländischen Gesellschaft},
  123. editor = {van Ronkel, Ph. S. and Spies, Otto},
  124. editortype = {collaborator},
  125. publisher = {Deutsche Morgenländische Gesellschaft, in Kommission
  126. bei F. A. Brockaus},
  127. url =
  128. {http://www.naher-osten.uni-muenchen.de/studium_lehre/werkzeugkasten/dmgtransliteration.pdf},
  129. location = {Leipzig}
  130. }
  131. @MVBook{Lane,
  132. author = {Lane, Edward William},
  133. title = {An Arabic-English lexicon},
  134. date = {1863/1893},
  135. indextitle = {Arabic-English Lexicon, An},
  136. volumes = 8,
  137. shorthand = {Lane, \emph{Lexicon}},
  138. pagination = {none},
  139. publisher = {Williams and Norgate},
  140. location = {London -- Edinburgh}
  141. }
  142. \end{filecontents}
  143. \usepackage[english]{babel}
  144. \usepackage{dox}
  145. \doxitem{Option}{option}{options}
  146. %\def\actualchar{ =} % there's a bug in doxitem; quick fix.
  147. \usepackage{fontspec,luatextra}
  148. \defaultfontfeatures{RawFeature={+liga}}
  149. \setmainfont{Old Standard}[SmallCapsFont={Latin Modern Roman Caps},
  150. RawFeature={+mark;+ccmp;+ss05;+ss06}]
  151. \usepackage{arabluatex}[2018/03/31]
  152. \usepackage[nopar]{quran}
  153. \usepackage[noindex]{nameauth}
  154. \usepackage{varioref}
  155. \usepackage{hyperxmp}
  156. \PassOptionsToPackage{pdfa}{hyperref}
  157. \usepackage{hypdoc}
  158. \usepackage{authblk}
  159. \hypersetup{unicode=true, colorlinks, allcolors=blue,
  160. linktocpage=true, pdfauthor={Robert Alessi}, pdftitle={The
  161. arabluatex package}, pdfcontactemail={alessi@robertalessi.net},
  162. pdfcontacturl={http://www.robertalessi.net/arabluatex},
  163. pdfcopyright={Copyright (C) 2016--2018 Robert Alessi
  164. <alessi@robertalessi.net>. This document is licensed under the
  165. Creative Commons Attribution-ShareAlike 4.0 International
  166. License. To view a copy of this license, visit
  167. http://creativecommons.org/licenses/by-sa/4.0/ or send a letter to
  168. Creative Commons, PO Box 1866, Mountain View, CA 94042, USA.},
  169. pdflicenseurl={https://creativecommons.org/licenses/by-sa/4.0/legalcode},
  170. pdfmetalang={en-US}, pdftype={Text}, pdfkeywords={Arabic language,
  171. arabtex, luatex}}
  172. \usepackage[scale=1.5]{ccicons}
  173. \usepackage[toc,lot]{multitoc}
  174. \usepackage{paralist}
  175. \setdefaultitem{\textendash}{\textendash}{\textendash}{\textendash}
  176. \usepackage{cleveref}
  177. \usepackage{quoting}
  178. \quotingsetup{noorphans, rightmargin=0pt}
  179. \renewcommand*{\quotingfont}{\footnotesize}
  180. \usepackage[position=below]{caption}
  181. \usepackage{lineno}
  182. \usepackage{longtable}
  183. \usepackage{booktabs}
  184. \usepackage[defaultlines=3,all]{nowidow}
  185. \usepackage{tikz}
  186. \usepackage[breakable, skins, listings, xparse]{tcolorbox}
  187. \DeclareTCBListing{arabluacode}{s O{}}{colback=white, boxrule=.15mm,
  188. colframe=red!50!white, left=6mm, breakable, listing
  189. options={style=tcblatex, numbers=left, numberstyle=\tiny},
  190. IfBooleanTF={#1}{listing side text}{#2}}
  191. \DeclareTCBListing{arabluaverbatim}{}{colback=white, boxrule=.15mm,
  192. colframe=red!50!white, left=6mm, breakable, listing
  193. options={style=tcblatex, numbers=left, numberstyle=\tiny}, listing
  194. only}
  195. \DeclareTotalTCBox{\arabluaverb}{v}{verbatim, colback=white,
  196. boxrule=.15mm, colframe=red!50!white}{#1}
  197. \DeclareTotalTCBox{\arabluabox}{m}{left=0mm, right=0mm, top=0mm,
  198. bottom=0mm, colback=white, boxrule=.15mm,
  199. colframe=red!50!white}{#1}
  200. \usepackage{xcolor}
  201. \newcommand{\package}[1]{\textsf{#1}\index{#1=#1 (package)}}
  202. \usepackage{csquotes}
  203. \DeclareQuoteStyle{arabic}
  204. {\rmfamily\textquotedblright}{\rmfamily\textquotedblleft}
  205. {\rmfamily\textquoteright}{\rmfamily\textquoteleft}
  206. \usepackage[style=authoryear, indexing=cite]{biblatex}
  207. \DeclareIndexFieldFormat{indextitle}{\index{#1=\emph{#1}}}
  208. \addbibresource{arabluatex.bib}
  209. \EnableCrossrefs
  210. \RecordChanges
  211. \CodelineIndex
  212. \begin{document}
  213. \DocInput{arabluatex.dtx}
  214. \printbibliography[heading=bibintoc]
  215. \phantomsection
  216. \addcontentsline{toc}{section}{Change History}
  217. \PrintChanges
  218. \phantomsection
  219. \addcontentsline{toc}{section}{Index}
  220. \PrintIndex
  221. \end{document}
  222. %</driver>
  223. % \fi
  224. %
  225. % \CheckSum{728}
  226. %
  227. % \CharacterTable
  228. % {Upper-case \A\B\C\D\E\F\G\H\I\J\K\L\M\N\O\P\Q\R\S\T\U\V\W\X\Y\Z
  229. % Lower-case \a\b\c\d\e\f\g\h\i\j\k\l\m\n\o\p\q\r\s\t\u\v\w\x\y\z
  230. % Digits \0\1\2\3\4\5\6\7\8\9
  231. % Exclamation \! Double quote \" Hash (number) \#
  232. % Dollar \$ Percent \% Ampersand \&
  233. % Acute accent \' Left paren \( Right paren \)
  234. % Asterisk \* Plus \+ Comma \,
  235. % Minus \- Point \. Solidus \/
  236. % Colon \: Semicolon \; Less than \<
  237. % Equals \= Greater than \> Question mark \?
  238. % Commercial at \@ Left bracket \[ Backslash \\
  239. % Right bracket \] Circumflex \^ Underscore \_
  240. % Grave accent \` Left brace \{ Vertical bar \|
  241. % Right brace \} Tilde \~}
  242. %
  243. % \makeatletter
  244. % \let\org@changes@\changes@
  245. % \def\my@changes v#1.#2.#3\@nil{%
  246. % \org@changes@{v#1.\six@digits{#2}.#3=v#1.#2.#3}%
  247. % }%
  248. % \newcommand*{\six@digits}[1]{%
  249. % \ifnum#1<100000 0\fi
  250. % \ifnum#1<10000 0\fi
  251. % \ifnum#1<1000 0\fi
  252. % \ifnum#1<100 0\fi
  253. % \two@digits{#1}%
  254. % }%
  255. % \renewcommand*{\changes@}[1]{%
  256. % \my@changes#1.\@nil
  257. % }%
  258. % \makeatother
  259. %
  260. % \changes{v1.0}{2016/03/29}{Initial release}
  261. % \changes{v1.0.1}{2016/03/31}{Minor update of the documentation}
  262. %
  263. % \DoNotIndex{\newcommand,\newenvironment,\renewcommand}
  264. % \DoNotIndex{\~,\AtBeginDocument,\bgroup,\csname}
  265. % \DoNotIndex{\DeclareDocumentCommand,\def,\edef,\egroup}
  266. % \DoNotIndex{\else,\endcsname,\endinput,\expandafter,\fi}
  267. % \DoNotIndex{\ifdef,\ifdefined,\ifx,\MessageBreak,\NeedsTeXFormat}
  268. % \DoNotIndex{\NewDocumentCommand,\newif,\PackageError,\PackageWarning}
  269. % \DoNotIndex{\relax,\RenewDocumentCommand,\string,\verb,\let}
  270. % \DoNotIndex{\enskip}
  271. %
  272. % \providecommand*{\url}{\texttt}
  273. % \GetFileInfo{arabluatex.dtx}
  274. %
  275. % \newcommand*{\NEWfeature}[1]{%
  276. % \hskip 1sp \marginpar{\small\sffamily\raggedright
  277. % New feature\\#1}}
  278. %
  279. % \title{\tcbox[enhanced, tikznode, drop lifted shadow, colback=white,
  280. % boxrule=.25mm]%
  281. % {The \textsf{arabluatex} package\\
  282. % \fileversion\ -- \filedate}}
  283. %
  284. % \author{Robert Alessi \\
  285. % \href{mailto:alessi@robertalessi.net?Subject=arabluatex}%
  286. % {\texttt{alessi@robertalessi.net}}\thanks{Institutional email:
  287. % \href{mailto:robert.alessi@cnrs.fr?Subject=arabluatex}%
  288. % {\texttt{robert.alessi@cnrs.fr}}}}
  289. % \affil{\normalsize CNRS UMR 8167 Paris (France)}
  290. % \date{}
  291. %
  292. % \maketitle
  293. % \footnotesize
  294. % \tableofcontents
  295. % \pagebreak
  296. % \listoftables
  297. % \normalsize
  298. %
  299. % \begin{abstract}
  300. % This package provides for \LuaLaTeX\ an Arab{\TeX}-like interface
  301. % to generate Arabic writing from an \textsc{ascii}
  302. % transliteration. It is particularly well-suited for complex
  303. % documents such as technical documents or critical editions where a
  304. % lot of left-to-right commands intertwine with Arabic
  305. % writing. \package{arabluatex} is able to process any Arab\TeX\
  306. % input notation. Its output can be set in the same modes of
  307. % vocalization as Arab\TeX, or in different roman
  308. % transliterations. It further allows many typographical
  309. % refinements. It will eventually interact with some other packages
  310. % yet to come to produce from \verb|.tex| source files, in addition
  311. % to printed books, \texttt{TEI xml} compliant critical editions
  312. % and/or lexicons that can be searched, analyzed and correlated in
  313. % various ways.
  314. % \end{abstract}
  315. %
  316. % \section*{License and disclamer}
  317. % \addcontentsline{toc}{section}{License and disclamer}
  318. % \subsection*{License applicable to the software}
  319. % \label{sec:license-software}
  320. %
  321. % \package{arabluatex} --- Processing Arab\TeX\ notation under Lua\LaTeX.\\
  322. % Copyright \textcopyright\ 2016--2018 Robert Alessi
  323. %
  324. % Please send error reports and suggestions for improvements to Robert
  325. % Alessi:
  326. % \begin{compactitem}
  327. % \item email: <\href{mailto:alessi@robertalessi.net?Subject=arabluatex}%
  328. % {\texttt{alessi@robertalessi.net}}>
  329. % \item website: \url{http://www.robertalessi.net/arabluatex}
  330. % \item development: \url{http://git.robertalessi.net/arabluatex}
  331. % \item comments, feature requests, bug reports:
  332. % \url{https://notabug.org/ralessi/arabluatex/issues}
  333. % \end{compactitem}
  334. %
  335. % \marginpar{\texttt{gpl3+}}
  336. % This program is free software: you can redistribute it and/or modify
  337. % it under the terms of the GNU General Public License as published by
  338. % the Free Software Foundation, either version 3 of the License, or
  339. % (at your option) any later version.
  340. %
  341. % This program is distributed in the hope that it will be useful, but
  342. % WITHOUT ANY WARRANTY; without even the implied warranty of
  343. % MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
  344. % General Public License for more details.
  345. %
  346. % You should have received a copy of the GNU General Public License
  347. % along with this program. If not, see
  348. % <http://www.gnu.org/licenses/>.
  349. %
  350. % This release of \package{arabluatex} consists of the following
  351. % source files:
  352. % \begin{compactitem}
  353. % \item |arabluatex.ins|
  354. % \item |arabluatex.dtx|
  355. % \item |arabluatex.lua|
  356. % \item |arabluatex_voc.lua|
  357. % \item |arabluatex_fullvoc.lua|
  358. % \item |arabluatex_novoc.lua|
  359. % \item |arabluatex_trans.lua|
  360. % \item |arabluatex.el|
  361. % \end{compactitem}
  362. %
  363. % \subsection*{License applicable to this document}
  364. % \label{sec:documentation-license}
  365. % Copyright \textcopyright\ 2016--2018 Robert Alessi
  366. %
  367. % \ccbysa\marginpar{\texttt{CC BY-SA 4.0}}
  368. % This document is licensed under the Creative Commons
  369. % Attribution-ShareAlike 4.0 International License. To view a copy of
  370. % this license, visit
  371. % \url{http://creativecommons.org/licenses/by-sa/4.0/} or send a
  372. % letter to Creative Commons, PO Box 1866, Mountain View, CA 94042,
  373. % USA.
  374. %
  375. % \section{Introduction}
  376. % In comparison to Prof. Lagally's outstanding Arab\TeX,\footnote{See
  377. % \url{http://ctan.org/pkg/arabtex}} Arab\LuaTeX\ is at present
  378. % nothing more than a modest piece of software. Hopefully---if I may
  379. % say so---it will eventually provide all of its valuable qualities to
  380. % the \LuaLaTeX\ users.
  381. %
  382. % \package{arabtex} dates back to 1992. As far as I know, it was then
  383. % the first and only way to typeset Arabic texts with \TeX\ and
  384. % \LaTeX. To achieve that, \package{arabtex} provided---and still
  385. % does---an Arabic font in \arb[trans]{\uc{nasxI}} style and a macro
  386. % package that defined its own input notation which was, as the author
  387. % stated, \enquote{both machine, and human, readable, and suited for
  388. % electronic transmission and e-mail
  389. % communication}.\footnote{\textcite[2]{pkg:arabtex}.} Even if the
  390. % same can be said about Unicode, Arab\TeX\ \textsc{ASCII} input
  391. % notation still surpasses Unicode input, in my opinion, when it comes
  392. % to typesetting complex documents, such as scientific documents or
  393. % critical editions where footnotes and other kind of annotations can
  394. % be particulary abundant. It must also be said that most text editors
  395. % have trouble in displaying Arabic script connected with preceding or
  396. % following \LaTeX\ commands: it often happens that commands seem
  397. % misplaced, not to mention punctuation marks, or opening or closing
  398. % braces, brackets or parentheses that are unexpectedly displayed in
  399. % the wrong direction. Of course, some text editors provide ways to
  400. % get around such difficulties by inserting invisible Unicode
  401. % characters, such as LEFT-TO-RIGHT or RIGHT-TO-LEFT MARKS
  402. % (\texttt{U+200E}, \texttt{U+200F}), RTL/LTR \enquote{embed}
  403. % characters (\texttt{U+202B}, \texttt{U+202A}) and RLO/LRO
  404. % \enquote{bidi-override} characters (\texttt{U+202E},
  405. % \texttt{U+202D}).\footnote{Gáspár Sinai's Yudit probably has the
  406. % best Unicode support. See \url{http://www.yudit.org}.} Nonetheless,
  407. % it remains that inserting all the time these invisible characters in
  408. % complex documents rapidly becomes confusing and cumbersome.
  409. %
  410. % The great advantage of Arab\TeX\ notation is that it is immune from
  411. % all these difficulties, let alone its being clear and
  412. % straightforward. One also must remember that computers are designed
  413. % to process code. Arab\TeX\ notation is a way of encoding Arabic
  414. % language, just as \TeX\ \enquote{mathematics mode} is a way of
  415. % processing code to display mathematics. As such, not only does it
  416. % allow greater control over typographical features, but it also can
  417. % be processed in several different ways: so without going into
  418. % details, depending on one's wishes, Arab\TeX\ input can be full
  419. % vocalized Arabic (\emph{scriptio plena}), vocalized Arabic or
  420. % non-vocalized Arabic (\emph{scriptio defectiva}); it further can be
  421. % transliterated into whichever romanization standard the user may
  422. % choose.
  423. %
  424. % \label{ref:tei-to-come}
  425. % But there may be more to be said on that point, as encoding Arabic
  426. % also naturally encourages the coder to vocalize the texts---without
  427. % compelling him to do so, of course. Accurate coding may even have
  428. % other virtuous effects. For instance, hyphens may be used for tying
  429. % particles or prefixes to words, or to mark inflectional endings, and
  430. % so forth. In other words, accurate coding produces accurate texts
  431. % that can stand to close grammatical scrutiny and to complex textual
  432. % searches as well.
  433. %
  434. % Having that in mind, I started \package{arabluatex}. With the help
  435. % of Lua, it will eventually interact with some other packages yet to
  436. % come to produce from \verb|.tex| source files, in addition to
  437. % printed books, \texttt{TEI xml} compliant critical editions and/or
  438. % lexicons that can be searched, analyzed and correlated in various
  439. % ways.
  440. %
  441. %\subsection{\package{arabluatex} is for \LuaLaTeX}
  442. % It goes without saying that \package{arabluatex} requires
  443. % \LuaLaTeX. \TeX\ and \LaTeX\ have \package{arabtex}, and \XeLaTeX\
  444. % has \package{arabxetex}. Both of them are much more advanced than
  445. % \package{arabluatex}, as they can process a number of different
  446. % languages,\footnote{\label{fn:arabtex-languages}To date, both
  447. % packages support Arabic, Maghribi, Urdu, Pashto, Sindhi, Kashmiri,
  448. % Uighuric and Old Malay; in addition to these, \package{arabtex} also
  449. % has a Hebrew mode, including Judeo-Arabic and Yiddish.} whereas
  450. % \package{arabluatex} can process only Arabic for the time
  451. % being. More languages will be included in future releases of
  452. % \package{arabluatex}.
  453. %
  454. % In comparison to \package{arabxetex}, \package{arabluatex} works in
  455. % a very different way. The former relies on the
  456. % \href{http://scripts.sil.org/TECkitIntro}{\texttt{TECkit}} engine
  457. % which converts Arab\TeX\ input on the fly into Unicode Arabic
  458. % script, whereas the latter passes Arab\TeX\ input on to a set of Lua
  459. % functions. At first, \LaTeX\ commands are taken care of in different
  460. % ways: some, as \cs{emph}, \cs{textbf} and the like are expected to
  461. % have Arabic text as arguments, while others, as \cs{LR}, for
  462. % \enquote{left-to-right text}, are not. Then, once what is Arabic is
  463. % carefully separated form what is not, it is processed by other Lua
  464. % functions which rely on different sets of correpondence tables to do
  465. % the actual conversion in accordance with one's wishes. Finally, Lua
  466. % returns to \TeX\ the converted strings---which may in turn contain
  467. % some other Arab\TeX\ input yet to be processed---for further
  468. % processing.
  469. %
  470. % \section{The basics of \package{arabluatex}}
  471. % \subsection{Activating \package{arabluatex}}
  472. % As usual put in your preamble:\\
  473. % \arabluaverb{\usepackage{arabluatex}}\\
  474. % The only requirement of \package{arabluatex} is \LuaLaTeX; it will
  475. % complain if you try to compile your document with another
  476. % engine. That aside, \package{arabluatex} does not load packages such
  477. % as \package{polyglossia} or \package{luabidi}. It can work with
  478. % \package{polyglossia} though, but does not require it.
  479. %
  480. % \paragraph{Font setup}
  481. % If you wish to use your own Arabic font, you can define it before
  482. % loading \package{arabluatex}. Assuming that \package{fontspec} is
  483. % loaded, put this in your preamble just above the line that loads
  484. % \package{arabluatex}:
  485. % \arabluabox{\cs{newfontfamily}\cs{arabicfont}\marg{fontname}[Script=Arabic]}
  486. % \noindent where \meta{fontname} is the standard name of the Arabic
  487. % font you wish to use.
  488. %
  489. % By default, if no Arabic font is selected, \package{arabluatex} will
  490. % issue a warning message and attempt to load the Amiri
  491. % font\footnote{\textcite{pkg:amiri}.} like so:---\\
  492. % \arabluaverb{\newfontfamily\arabicfont{Amiri}[Script=Arabic]}
  493. % \begin{quoting}
  494. % \textsc{Rem.} By default Amiri places the \arb[trans]{kasraT} in
  495. % combination with the \arb[trans]{ta^sdId} below the consonant,
  496. % like so: \arb{BBi}\,. That is correct, as at least in the oldest
  497. % manuscripts {\newfontfamily\arabicfont{Amiri}[Script=Arabic,
  498. % RawFeature={+ss05}]\arb{BBi}} may stand for \arb{BBa} as
  499. % well as \arb{BBi}\,. See \textcite[i. 14 C--D]{Wright}. The placement
  500. % of the \arb[trans]{kasraT} above the consonant may be obtained by
  501. % selecting the |ss05| feature of the Amiri font, like
  502. % so:---\footnote{See the documentation of \package{amiri},
  503. % \textcite[5]{pkg:amiri}.}\\
  504. % \arabluaverb{\newfontfamily\arabicfont{Amiri}[Script=Arabic,RawFeature={+ss05}]}
  505. %
  506. % Other Arabic fonts may behave differently.
  507. % \end{quoting}
  508. %
  509. % \subsection{Options}
  510. % \label{sec:options}
  511. % \package{arabluatex} may be loaded with four mutually exclusive
  512. % global options, each of which may be overriden at any point of the
  513. % document (see below \vref{sec:local-options}):
  514. %
  515. % \DescribeOption{voc}\hfill\arabluaverb{default}\\ In this mode,
  516. % which is the one selected by default, every short vowel written
  517. % generates its corresponding diacritical mark: \arb[trans]{.dammaT}
  518. % (\arb{Bu}), \arb[trans]{fat.haT} (\arb{Ba}) and \arb[trans]{kasraT}
  519. % (\arb{Bi}). If a vowel is followed by |N|, viz. \meta{uN, aN, iN},
  520. % then the corresponding \arb[trans]{tanwIn} (\arb{BuN}, \arb{B|aN}\,,
  521. % \arb{TaN}, \arb{BaN_A} or \arb{BiN}) is generated. Finally, \meta{u,
  522. % a, i} at the commencement of a word indicate a \enquote{connective
  523. % \arb[trans]{'alif}\,} (\arb[trans]{'alifu 'l-wa.sli}), but |voc|
  524. % mode does not show the \arb[trans]{wa.slaT} above the
  525. % \arb[trans]{'alif}; instead, the accompanying vowel may be expressed
  526. % at the beginning of a sentence (\arb{u} \arb{a} \arb{i}).
  527. %
  528. % \DescribeOption{fullvoc}\\ \label{fullvoc-mode}In addition to what
  529. % the |voc| mode does, |fullvoc| expresses the \arb[trans]{sukUn} and
  530. % the \arb[trans]{wa.slaT}.
  531. %
  532. % \DescribeOption{novoc}\\ None of the diacritics is showed in |novoc|
  533. % mode, unless otherwise specified (see \enquote{quoting} technique
  534. % below \vref{sec:quoting}).
  535. %
  536. % \DescribeOption{trans} \\ \label{ref:describe-trans}This mode
  537. % transliterates the Arab\TeX\ input into one of the accepted
  538. % standards. At present, three standards are supported (see below
  539. % \vref{sec:transliteration} for more details):
  540. % \begin{compactdesc}
  541. % \item[dmg] \emph{Deutsche Morgenländische Gesellschaft}, which is
  542. % selected by default;
  543. % \item[loc] \emph{Library of Congress};
  544. % \item[arabica] \emph{Arabica}.
  545. % \end{compactdesc}
  546. % More standards will be included in future releases of
  547. % \package{arabluatex}.
  548. %
  549. % \subsubsection{Classic contrasted with modern typesetting of Arabic}
  550. % \label{sec:classic-modern-typesetting}
  551. % \NEWfeature{v.1.2} By default, \package{arabluatex} typesets Arabic
  552. % in a classic, traditional style the most prominent features of which
  553. % are the following:
  554. % \begin{compactitem}
  555. % \item \enquote*{Classic} \arb[trans]{maddaT}: when
  556. % \arb[trans]{'alif} and \arb[trans]{hamzaT} accompanied by a simple
  557. % vowel or \arb[trans]{tanwIn} is preceded by an \arb[trans]{'alif} of
  558. % prolongation (\arb[voc]{BA}), then a mere \arb[trans]{hamzaT} is
  559. % written on the line, and a \arb[trans]{maddaT} is placed over the
  560. % \arb[trans]{'alif}, like so:---
  561. % \begin{quote}
  562. % |samA'uN| \arb[voc]{samA'uN} \arb[trans]{samA'uN}, |jA'a|
  563. % \arb[voc]{jA'a} \arb[trans]{jA'a}, |yatasA'alUna|
  564. % \arb[voc]{yatasA'alUna} \arb[trans]{yatasA'alUna}\footnote{Note
  565. % that in old mss. such forms as \arb[voc]{samA"'a"'a},
  566. % \arb[voc]{jA"'a"'a} are also found; see \textcite[i. 24
  567. % D]{Wright}.} (see \vpageref{ref:madda} for further details).
  568. % \end{quote}
  569. % \item The euphonic \arb[trans]{ta^sdId} is generated (see
  570. % \vpageref{ref:euphonic-tashdid}).
  571. % \item In |fullvoc| mode, the \arb[trans]{sukUn} is expressed.
  572. % \item In such words as \arb{^say'aN}, \arb{.zim'aN} and the like,
  573. % the \arb[trans]{hamzaT} alone is not written over the letter
  574. % \arb[trans]{yA'} with no diacritical points below as in
  575. % \arb{^sayy"'aN}, \arb{.zimy"'aN}, but over a horizontal stroke
  576. % placed in the continuation of the preceding letter. %
  577. % \iffalse
  578. %<*example>
  579. % \fi
  580. \begin{arabluacode}[text only]
  581. Please note that only few Arabic fonts provide such contrivances. In
  582. case this feature is not supported by some Arabic font, it is
  583. advisable to use \cs{SetArbEasy}.
  584. \end{arabluacode}
  585. % \iffalse
  586. %</example>
  587. % \fi
  588. % \end{compactitem}
  589. %
  590. % \DescribeMacro{\SetArbEasy} \NEWfeature{v1.4.4}
  591. % \DescribeMacro{\SetArbEasy*} \DescribeMacro{\SetArbDflt} Such
  592. % refinements as \enquote*{classic} \arb[trans]{maddaT} may be
  593. % discarded by the \cs{SetArb\allowbreak{}Easy} command, either
  594. % globally in the preamble or locally at any point of the
  595. % document. The difference between \cs{SetArbEasy} and its
  596. % \enquote*{starred} version \cs{SetArbEasy*} is that the former keeps
  597. % the \arb[trans]{sukUn} that is generated by the |fullvoc| mode,
  598. % while the latter further takes it away. Default \enquote*{classic}
  599. % rules may be set back at any point of the document with the
  600. % \cs{SetArbDflt} command. \NEWfeature{v1.6}
  601. % \DescribeMacro{\SetArbDflt*}Assimilation rules laid on
  602. % \vref{ref:assimilation} may also be applied by the
  603. % \enquote*{starred} version of this command \cs{SetArbDflt*} either
  604. % in the preamble or at any point of the document.\footnote{For an
  605. % example, see \vref{sec:poetry-example}.} Examples follow:---
  606. % \begin{compactenum}[(a)]
  607. % \item \cs{SetArbDflt}:
  608. % \begin{compactenum}[i.]
  609. % \item |voc| \arb[voc]{wa-mAta istisqA'aN qabla 'an yutimma
  610. % kitAba-hu fI nujUm-i 'l-samA'-i}
  611. % \item |fullvoc| \arb[fullvoc]{wa-mAta istisqA'aN qabla 'an yutimma
  612. % kitAba-hu fI nujUm-i 'l-samA'-i}
  613. % \item |trans| \arb[trans]{wa-mAta istisqA'aN qabla 'an yutimma
  614. % kitAba-hu fI nujUm-i 'l-samA'-i}
  615. % \end{compactenum}
  616. % \item \cs{SetArbDflt*}:
  617. % \begin{compactenum}[i.]\SetArbDflt*
  618. % \item |voc| \arb[voc]{wa-mAta istisqA'aN qabla 'an yutimma
  619. % kitAba-hu fI nujUm-i 'l-samA'-i}
  620. % \item |fullvoc| \arb[fullvoc]{wa-mAta istisqA'aN qabla 'an yutimma
  621. % kitAba-hu fI nujUm-i 'l-samA'-i}
  622. % \item |trans| \arb[trans]{wa-mAta istisqA'aN qabla 'an yutimma
  623. % kitAba-hu fI nujUm-i 'l-samA'-i}\SetArbDflt
  624. % \end{compactenum}
  625. % \item \cs{SetArbEasy}:
  626. % \begin{compactenum}[i.]\SetArbEasy
  627. % \item |voc| \arb[voc]{wa-mAta istisqA'aN qabla 'an yutimma
  628. % kitAba-hu fI nujUm-i 'l-samA'-i}
  629. % \item |fullvoc| \arb[fullvoc]{wa-mAta istisqA'aN qabla 'an yutimma
  630. % kitAba-hu fI nujUm-i 'l-samA'-i}
  631. % \item |trans| \arb[trans]{wa-mAta istisqA'aN qabla 'an yutimma
  632. % kitAba-hu fI nujUm-i 'l-samA'-i}\SetArbDflt
  633. % \end{compactenum}
  634. % \item \cs{SetArbEasy*}:
  635. % \begin{compactenum}[i.]\SetArbEasy*
  636. % \item |voc| \arb[voc]{wa-mAta istisqA'aN qabla 'an yutimma
  637. % kitAba-hu fI nujUm-i 'l-samA'-i}
  638. % \item |fullvoc| \arb[fullvoc]{wa-mAta istisqA'aN qabla 'an yutimma
  639. % kitAba-hu fI nujUm-i 'l-samA'-i}
  640. % \item |trans| \arb[trans]{wa-mAta istisqA'aN qabla 'an yutimma
  641. % kitAba-hu fI nujUm-i 'l-samA'-i}\SetArbDflt
  642. % \end{compactenum}
  643. % \end{compactenum}
  644. %
  645. % \iffalse
  646. %<*example>
  647. % \fi
  648. \begin{arabluacode}[text only]
  649. Please note that this document is typeset with \cs{SetArbDflt} throughout.
  650. \end{arabluacode}
  651. % \iffalse
  652. %</example>
  653. % \fi
  654. %
  655. %\subsection{Typing Arabic}
  656. % \DescribeMacro{\arb} Once \package{arabluatex} is loaded, a
  657. % \cs{arb}\marg{Arabic text} command is available for inserting Arabic
  658. % text in paragraphs, like so:---%
  659. % \iffalse
  660. %<*example>
  661. % \fi
  662. \begin{arabluacode}
  663. From \textcite[i. 1 A]{Wright}:--- Arabic, like Hebrew and
  664. Syriac, is written and read from right to left. The letters
  665. of the alphabet (\arb{.hurUf-u 'l-hijA'-i}, \arb{.hurUf-u
  666. 'l-tahajjI}, \arb{al-.hurUf-u 'l-hijA'iyyaT-u}, or
  667. \arb{.hurUf-u 'l-mu`jam-i}) are twenty-eight in number and
  668. are all consonants, though three of them are also used as
  669. vowels (see §~3).
  670. \end{arabluacode}
  671. % \iffalse
  672. %</example>
  673. % \fi
  674. %
  675. % \paragraph{Caveat}
  676. % For some reason, left-to-right paragraphs that start with Arabic
  677. % words lose their indentation. For the time being, this can be
  678. % circumvented by appending the \cs{indent} command at the
  679. % commencement of such paragraphs.
  680. %
  681. % \label{ref:ltr-lists}%
  682. % The same remark applies to left-to-right list environments: when
  683. % items start with Arabic words, the \cs{arb} command must be prefixed
  684. % with \cs{indent}. The following example comes from \textcite[i. 213
  685. % C]{Wright}:--- %
  686. % \iffalse
  687. %<*example>
  688. % \fi
  689. \begin{arabluacode}
  690. \begin{enumerate}[XVI.]
  691. \item \indent\arb{fawA`ilu}*.
  692. \begin{enumerate}[1.]
  693. \item \indent\arb{fA`aluN}; as \arb{_hAtamuN} \emph{a
  694. signet-ring}, ...
  695. \end{enumerate}
  696. \end{enumerate}
  697. \end{arabluacode}
  698. % \iffalse
  699. %</example>
  700. % \fi
  701. %
  702. % \DescribeEnv{arab} Running paragraphs of Arabic text should rather
  703. % be placed inside an \emph{Arabic environment}
  704. %
  705. % \iffalse
  706. %<*example>
  707. % \fi
  708. \begin{arabluaverbatim}
  709. \begin{arab}
  710. [...]
  711. \end{arab}
  712. \end{arabluaverbatim}
  713. % \iffalse
  714. %</example>
  715. % \fi
  716. % like so:---\label{ref:juha-code}
  717. % \setquotestyle{arabic}
  718. % \iffalse
  719. %<*example>
  720. % \fi
  721. \begin{arabluacode}
  722. \begin{arab}
  723. 'at_A .sadIquN 'il_A ju.hA ya.tlubu min-hu .himAra-hu
  724. li-yarkaba-hu fI safraTiN qa.sIraTiN fa-qAla la-hu:
  725. \enquote{sawfa 'u`Idu-hu 'ilay-ka fI 'l-masA'-i
  726. wa-'adfa`u la-ka 'ujraTaN.} fa-qAla ju.hA:
  727. \enquote{'anA 'AsifuN jiddaN 'annI lA 'asta.tI`u 'an
  728. 'u.haqqiqa la-ka ra.gbata-ka fa-'l-.himAr-u laysa hunA
  729. 'l-yawm-a.} wa-qabla 'an yutimma ju.hA kalAma-hu bada'a
  730. 'l-.himAr-u yanhaqu fI 'i.s.tabli-hi. fa-qAla la-hu
  731. .sadIqu-hu: \enquote{'innI 'asma`u .himAra-ka yA ju.hA
  732. yanhaqu.} fa-qAla la-hu ju.hA: \enquote{.garIbuN
  733. 'amru-ka yA .sadIqI 'a-tu.saddiqu 'l-.himAr-a
  734. wa-tuka_d_diba-nI?}
  735. \end{arab}
  736. \end{arabluacode}
  737. % \iffalse
  738. %</example>
  739. % \fi
  740. % \setquotestyle{english}
  741. %
  742. % \subsubsection{Local options}
  743. % \label{sec:local-options}
  744. % As seen above in \vref{sec:options}, \package{arabluatex} may be
  745. % loaded with four mutually exclusive global options: |voc| (which is
  746. % the default option), |fullvoc|, |novoc| and |trans|. Whatever choice
  747. % has been made globally, it may be overriden at any point of the
  748. % document, as the \cs{arb} command may take any of the |voc|,
  749. % |fullvoc|, |novoc| or |trans| modes as optional argument, like
  750. % so:---
  751. % \begin{compactitem}
  752. % \item \DescribeOption{voc} \cs{arb}|[voc]|\marg{Arabic text};
  753. % \item \DescribeOption{fullvoc} \cs{arb}|[fullvoc]|\marg{Arabic text};
  754. % \item \DescribeOption{novoc} \cs{arb}|[novoc]|\marg{Arabic text};
  755. % \item \DescribeOption{trans} \cs{arb}|[trans]|\marg{Arabic text}.
  756. % \end{compactitem}
  757. %
  758. % The same optional arguments may be passed to the environment |arab|:
  759. % one may have \cs{begin}|{arab}|\oarg{mode}|...|\cs{end}|{arab}|,
  760. % where \meta{mode} may be any of |voc|, |fullvoc|, |novoc| or
  761. % |trans|.
  762. %
  763. %\section{Standard Arab\TeX\ input}
  764. %\subsection{Consonants}
  765. % \Cref{tab:arabtex-consonants} gives the Arab\TeX\ equivalents for
  766. % all of the Arabic consonants.
  767. %
  768. % \newcommand{\dmg}[1]{%
  769. % \SetTranslitConvention{dmg}%
  770. % \arb[trans]{#1}}
  771. % \newcommand{\loc}[1]{%
  772. % \SetTranslitConvention{loc}%
  773. % \arb[trans]{#1}\SetTranslitConvention{dmg}}
  774. % \newcommand{\brill}[1]{%
  775. % \SetTranslitConvention{arabica}%
  776. % \arb[trans]{#1}\SetTranslitConvention{dmg}}
  777. % \begin{longtable}{lllll}
  778. % \captionlistentry{Arab\TeX\ consonants}\\[-1em]
  779. % \toprule
  780. % Letter & \multicolumn{3}{l}{Transliteration\footnotemark}
  781. % & Arab\TeX\ notation \\
  782. % & \texttt{dmg} & \texttt{loc} & \texttt{arabica} & \\ \midrule
  783. % \endfirsthead
  784. % \toprule
  785. % Letter & \multicolumn{3}{l}{Transliteration}
  786. % & Arab\TeX\ notation \\
  787. % & \texttt{dmg} & \texttt{loc} & \texttt{arabica} & \\ \midrule
  788. % \endhead \footnotetext{See below \vref{sec:transliteration}.}
  789. % \label{tab:arabtex-consonants}
  790. % \arb[voc]{'i 'a 'u}\footnote{See below, \emph{Rem{.} a.} For
  791. % \arb[trans]{'alif} as a consonant, see \textcite[i. 16
  792. % D]{Wright}. The \arb[trans]{hamzaT} itself is encoded \texttt{<'>}
  793. % and may be followed by either \meta{u, a} or \meta{i}. See below
  794. % \vref{ref:hamza}.} & \dmg{'u 'a 'i} &
  795. % \loc{|'u, |'a, |'i} & \brill{|'u, |'a, |'i} & |'u| or |'a| or |'i| \\
  796. % \arb[novoc]{b} & \dmg{b} & \loc{b} & \brill{b} & |b| \\
  797. % \arb[novoc]{t} & \dmg{t} & \loc{t} & \brill{t} & |t| \\
  798. % \arb[novoc]{_t} & \dmg{_t} & \loc{_t} & \brill{_t} & |_t| \\
  799. % \arb[novoc]{j} & \dmg{j} & \loc{j} & \brill{j} & |^g| or |j| \\
  800. % \arb[novoc]{.h} & \dmg{.h} & \loc{.h} & \brill{.h} & |.h| \\
  801. % \arb[novoc]{x} & \dmg{x} & \loc{x} & \brill{x} & |_h| or |x|\\
  802. % \arb[novoc]{d} & \dmg{d} & \loc{d} & \brill{d} & |d| \\
  803. % \arb[novoc]{_d} & \dmg{_d} & \loc{_d} & \brill{_d} & |_d| \\
  804. % \arb[novoc]{r} & \dmg{r} & \loc{r} & \brill{r} & |r| \\
  805. % \arb[novoc]{z} & \dmg{z} & \loc{z} & \brill{z} & |z| \\
  806. % \arb[novoc]{s} & \dmg{s} & \loc{s} & \brill{s} & |s| \\
  807. % \arb[novoc]{^s} & \dmg{^s} & \loc{^s} & \brill{^s} & |^s| \\
  808. % \arb[novoc]{.s} & \dmg{.s} & \loc{.s} & \brill{.s} & |.s| \\
  809. % \arb[novoc]{.d} & \dmg{.d} & \loc{.d} & \brill{.d} & |.d| \\
  810. % \arb[novoc]{.t} & \dmg{.t} & \loc{.t} & \brill{.t} & |.t| \\
  811. % \arb[novoc]{.z} & \dmg{.z} & \loc{.z} & \brill{.z} & |.z| \\
  812. % \arb[novoc]{`} & \dmg{`} & \loc{`} & \brill{`} & |`| \\
  813. % \arb[novoc]{.g} & \dmg{.g} & \loc{.g} & \brill{.g} & |.g| \\
  814. % \arb[novoc]{f} & \dmg{f} & \loc{f} & \brill{f} & |f| \\
  815. % \arb[novoc]{q} & \dmg{q} & \loc{q} & \brill{q} & |q| \\
  816. % \arb[novoc]{k} & \dmg{k} & \loc{k} & \brill{k} & |k| \\
  817. % \arb[novoc]{l} & \dmg{l} & \loc{l} & \brill{l} & |l| \\
  818. % \arb[novoc]{m} & \dmg{m} & \loc{m} & \brill{m} & |m| \\
  819. % \arb[novoc]{n} & \dmg{n} & \loc{n} & \brill{n} & |n| \\
  820. % \arb[novoc]{h} & \dmg{h} & \loc{h} & \brill{h} & |h| \\
  821. % \arb[novoc]{w} & \dmg{w} & \loc{w} & \brill{w} & |w| \\
  822. % \arb[novoc]{y} & \dmg{y} & \loc{y} & \brill{y} & |y|\footnote{For
  823. % the letter \arb[novoc]{.y} with no diacritical points below, see
  824. % \emph{Rem{.} b.} below.} \\
  825. % \arb[novoc]{T} & \dmg{aT} & \loc{aT} & \brill{aT} & |T| \\
  826. % \bottomrule
  827. % \caption*{\Cref*{tab:arabtex-consonants}: Standard Arab\TeX\ (consonants)}
  828. % \end{longtable}
  829. % \begin{quoting}
  830. % \textsc{Rem.}~\emph{a.} Please note that in all cases of elision,
  831. % the \arb[trans]{'alifu 'l-wa.sli} is expressed only by the vowel
  832. % that accompanies the omitted \arb[trans]{hamzaT}: \meta{u, a, i}
  833. % as in |wa-inhazama| \arb[fullvoc]{wa-inhazama}
  834. % \arb[trans]{wa-inhazama}. For more details on the definite article
  835. % and the \arb[trans]{'alifu 'l-wa.sli} see
  836. % \vref{ref:definite-article}.
  837. %
  838. % That said, \arb{.A} as a consonant is actually the \emph{spiritus
  839. % lenis} of the Greeks and is distinguished by the
  840. % \arb[trans]{hamzaT} \arb[novoc]{(|"')} as it is shown in the above
  841. % table. However, the bare \arb[trans]{'alif} may also be encoded as
  842. % |.A| whether it be followed by a vowel or not, like so: |wa-.An|
  843. % \arb{wa-.An} \arb[trans]{wa-.An} (where the dot symbolizes the
  844. % absence of vowel), |wa-.Aan| \arb{wa-.Aan} \arb[trans]{wa-.Aan},
  845. % |wa-.Ain| \arb{wa-.Ain} \arb[trans]{wa-.Ain}.
  846. %
  847. % \textsc{Rem.}~\emph{b.} The letter \arb[novoc]{y} with two points
  848. % below, \arb{al-yA'u 'l-mu_tannATu min ta.hti-hA}, may also be
  849. % written without diacritical points as \arb[novoc]{Y}. When it is
  850. % used as a consonant, it is encoded |aY|, where |a| recalls the
  851. % \arb[trans]{fat.haT} placed above the preceding letter in
  852. % vocalized Arabic, like so: |qaY'uN| \arb{qaY'uN}
  853. % \arb[trans]{qaY'uN}, |^saY'uN| \arb{^saY'uN} \arb[trans]{^saY'uN},
  854. % |^saY'aN| \arb[trans]{^saY'aN} \arb{^saY'aN}.
  855. %
  856. % The same result may be achieved by encoding this letter as |.y|,
  857. % like so: |qa.y'uN| \arb{qa.y'uN} \arb[trans]{qa.y'uN}, |^sa.y'uN|
  858. % \arb{^sa.y'uN} \arb[trans]{^sa.y'uN}, |^sa.y'aN|
  859. % \arb[trans]{^sa.y'aN} \arb{^sa.y'aN}.
  860. % \end{quoting}
  861. %
  862. % \subsection{Additional characters}
  863. % \changes{v1.8.5}{2017/06/20}{Six additional Persian characters are
  864. % now available}
  865. % \NEWfeature{v1.8.5}\Cref{tab:arabtex-additional-characters} gives
  866. % the Arab\TeX\ equivalents for some additional Persian characters.
  867. %
  868. % \begin{longtable}{lllll}
  869. % \captionlistentry{Arab\TeX\ additional characters}\\[-1em]
  870. % \toprule
  871. % Letter & \multicolumn{3}{l}{Transliteration\footnotemark}
  872. % & Arab\TeX\ notation \\
  873. % & \texttt{dmg} & \texttt{loc} & \texttt{arabica}\footnotemark
  874. % & \\ \midrule
  875. % \endfirsthead
  876. % \toprule
  877. % Letter & \multicolumn{3}{l}{Transliteration}
  878. % & Arab\TeX\ notation \\
  879. % & \texttt{dmg} & \texttt{loc} & \texttt{arabica} & \\ \midrule
  880. % \endhead
  881. % \addtocounter{footnote}{-1}
  882. % \footnotetext{See below \vref{sec:transliteration}.}
  883. % \stepcounter{footnote}
  884. % \footnotetext{The characters that are listed in this table are not
  885. % included in this standard. However, as \texttt{arabica} is based on
  886. % \texttt{dmg}, the \texttt{dmg} equivalents have been used here.}
  887. % \label{tab:arabtex-additional-characters}
  888. % \hskip-1em\arb[novoc]{p} & \dmg{p} & \loc{p} & \brill{p} & \verb|p| \\
  889. % \arb[novoc]{^c} & \dmg{^c} & \loc{^c} & \brill{^c} & \verb|^c| \\
  890. % \arb[novoc]{^z} & \dmg{^z} & \loc{^z} & \brill{^z} & \verb|^z| \\
  891. % \arb[novoc]{v}\footnote{\label{fn:not-in-dmg}This character is not found in
  892. % \textcite[2]{dmg}. It is taken from the \textcite{din31635} standard.} &
  893. % \dmg{v} & \loc{v} & \brill{v} & \verb|v| \\
  894. % \arb[novoc]{g} & \dmg{g} & \loc{g} & \brill{g} & \verb|g| \\
  895. % \arb[novoc]{^n}\footnote{See \cref{fn:not-in-dmg}.} & \dmg{^n} &
  896. % \loc{^n} & \brill{^n} & \verb|^n| \\
  897. % \bottomrule
  898. % \caption*{\Cref*{tab:arabtex-additional-characters}: Standard
  899. % Arab\TeX\ (additional characters)}
  900. % \end{longtable}
  901. % \begin{quoting}
  902. % \textsc{Rem.} The alveolar consonants \arb[novoc]{^c} and
  903. % \arb[novoc]{^z} are processed as solar letters by
  904. % \package{arabluatex}.
  905. % \end{quoting}
  906. %
  907. % \subsection{Vowels}
  908. % \subsubsection{Long vowels}
  909. % \Cref{tab:arabtex-long-vowels} gives the Arab\TeX\ equivalents for
  910. % the Arabic long vowels.
  911. %
  912. % \begin{longtable}{lllll}
  913. % \captionlistentry{Arab\TeX\ long vowels}\\[-1em]
  914. % \toprule
  915. % Letter & \multicolumn{3}{l}{Transliteration\footnotemark}
  916. % & Arab\TeX\ notation \\
  917. % & \texttt{dmg} & \texttt{loc} & \texttt{arabica} & \\ \midrule
  918. % \endfirsthead
  919. % \toprule
  920. % Letter & \multicolumn{3}{l}{Transliteration}
  921. % & Arab\TeX\ notation \\
  922. % & \texttt{dmg} & \texttt{loc} & \texttt{arabica} & \\ \midrule
  923. % \endhead \footnotetext{See below \vref{sec:transliteration}.}
  924. % \label{tab:arabtex-long-vowels}
  925. % \arb[novoc]{A} & \dmg{A} & \loc{A} & \brill{A} & \verb|A| \\
  926. % \arb[novoc]{U} & \dmg{U} & \loc{U} & \brill{U} & \verb|U| \\
  927. % \arb[novoc]{I} & \dmg{I} & \loc{I} & \brill{I} &
  928. % \verb|I|\footnote{For the letter \arb[novoc]{I} with no diacritical
  929. % points, see \emph{Rem{.} c.} below.} \\
  930. % \arb[novoc]{_A}\footnote{$=$ \arb[trans]{al-'alif-u 'l-maq.sUraT-u}.}
  931. % & \dmg{_A} & \loc{_A} & \brill{_A} & \verb|_A| or \verb|Y| \\
  932. % \arb[novoc]{B_a} & \dmg{B_a} & \loc{B_a} & \brill{B_a} & \verb|_a| \\
  933. % \arb[novoc]{B_u} & \dmg{B_u} & \loc{B_u} & \brill{B_u} & \verb|_u| \\
  934. % \arb[novoc]{B_i} & \dmg{B_i} & \loc{B_i} & \brill{B_i} & \verb|_i| \\
  935. % \bottomrule
  936. % \caption*{\Cref*{tab:arabtex-long-vowels}: Standard Arab\TeX\ (long vowels)}
  937. % \end{longtable}
  938. %
  939. % \begin{quoting}
  940. % \textsc{Rem.}~\emph{a.} The long vowels \arb[trans]{A, U, I},
  941. % otherwise called \arb[trans]{.hurUf-u 'l-madd-i}, \emph{the
  942. % letters of prolongation}, involve the placing of the short vowels
  943. % \arb[trans]{Ba, Bu, Bi} before the letters \arb[novoc]{A},
  944. % \arb[novoc]{U}, \arb[novoc]{I} respectively. \package{arabluatex}
  945. % does that automatically in case any from |voc|, |fullvoc| or
  946. % |trans| modes is selected e.g. \arb[voc]{qAla} \arb[trans]{qAla},
  947. % \arb[voc]{qIla} \arb[trans]{qIla}, \arb[voc]{yaqUlu}
  948. % \arb[trans]{yaqUlu}.
  949. %
  950. % \textsc{Rem.}~\emph{b.} Defective writings, such as
  951. % \arb[novoc]{B_a}, \arb[trans]{al-'alif-u 'l-ma.h_dUfaT-u}, or
  952. % defective writings of \arb[trans]{B_u} and \arb[trans]{B_i} are
  953. % encoded |_a| |_u| and |_i| respectively, e.g. |_d_alika|
  954. % \arb[voc]{_d_alika}, |al-mal_a'ikaT-u| |'l-ra.hm_an-u|
  955. % \arb[voc]{al-mal_a'ikaT-u 'l-ra.hm_an-u}, |.hu_dayfaT-u| |bn-u|
  956. % |'l-yamAn_i| \arb[fullvoc]{.hu_dayfaT-u bn-u 'l-yamAn_i} for
  957. % \arb[trans]{\uc{.hu_dayfaT-u} bn-u 'l-\uc{yamAn_i}}, etc.
  958. %
  959. % \textsc{Rem.}~\emph{c.} The letter \arb[novoc]{y} with two points
  960. % below, \arb{al-yA'u 'l-mu_tannATu min ta.hti-hA}, may also be
  961. % written without diacritical points as \arb[novoc]{Y}. When it is
  962. % used as a long vowel, it is encoded |iY|, where |i| recalls the
  963. % \arb[trans]{kasraT} placed below the preceding letter in vocalized
  964. % Arabic, like so: |liY| \arb{liY} \arb[trans]{liY}, |yam^siY|
  965. % \arb{yam^siY} \arb[trans]{yam^siY}.
  966. % \end{quoting}
  967. %
  968. % \subsubsection{Short vowels}
  969. % \Cref{tab:arabtex-short-vowels} gives the Arab\TeX\ equivalents for
  970. % the Arabic short vowels.
  971. %
  972. % \begin{longtable}{lllll}
  973. % \captionlistentry{Arab\TeX\ short vowels}\\[-1em]
  974. % \toprule
  975. % Letter & \multicolumn{3}{l}{Transliteration\footnotemark}
  976. % & Arab\TeX\ notation \\
  977. % & \texttt{dmg} & \texttt{loc} & \texttt{arabica} & \\ \midrule
  978. % \endfirsthead
  979. % \toprule
  980. % Letter & \multicolumn{3}{l}{Transliteration}
  981. % & Arab\TeX\ notation \\
  982. % & \texttt{dmg} & \texttt{loc} & \texttt{arabica} & \\ \midrule
  983. % \endhead \footnotetext{See below \vref{sec:transliteration}.}
  984. % \label{tab:arabtex-short-vowels}
  985. % \arb[voc]{Ba} & \dmg{Ba} & \loc{Ba} & \brill{Ba} & \verb|a| \\
  986. % \arb[voc]{Bu} & \dmg{Bu} & \loc{Bu} & \brill{Bu} & \verb|u| \\
  987. % \arb[voc]{Bi} & \dmg{Bi} & \loc{Bi} & \brill{Bi} & \verb|i| \\
  988. % \arb[voc]{BaN} & \dmg{BaN} & \loc{BaN} & \brill{BaN} & \verb|aN| \\
  989. % \arb[voc]{BuN} & \dmg{BuN} & \loc{BuN} & \brill{BuN} & \verb|uN| \\
  990. % \arb[voc]{BiN} & \dmg{BiN} & \loc{BiN} & \brill{BiN} & \verb|iN| \\
  991. % \bottomrule
  992. % \caption*{\Cref*{tab:arabtex-short-vowels}: Standard Arab\TeX\ (short vowels)}
  993. % \end{longtable}
  994. %
  995. % Whether Arabic texts be vocalized or not is essentially a matter of
  996. % personal choice. So one may use |voc| mode and decide not to write
  997. % vowels except at some particular places for disambiguation purposes,
  998. % or use |novoc| mode, not write vowels---as |novoc| normally does not
  999. % show them---except, again, where disambiguation is needed.\footnote{See
  1000. % below \vref{sec:quoting}.}
  1001. %
  1002. % \iffalse
  1003. %<*example>
  1004. % \fi
  1005. \begin{arabluacode}[text only]
  1006. However, it may be wise to always write the vowels, leaving to the
  1007. various modes provided by \package{arabluatex} to take care of
  1008. showing or not showing the vowels.
  1009. \end{arabluacode}
  1010. % \iffalse
  1011. %</example>
  1012. % \fi
  1013. %
  1014. % That said, there is no need to write the short vowels
  1015. % \arb[trans]{fat.haT}, \arb[trans]{.dammaT} or \arb[trans]{kasraT}
  1016. % except in the following cases:---
  1017. % \begin{compactitem}
  1018. % \item at the commencement of a word, to indicate that a connective
  1019. % \arb[trans]{'alif} is needed, with the exception of the article (see
  1020. % below \vref{sec:quoting});
  1021. % \item when \package{arabluatex} needs to perform a contextual
  1022. % analysis to determine the carrier of the \arb[trans]{hamzaT};
  1023. % \item in the various transliteration modes, as vowels are always
  1024. % expressed in romanized Arabic.
  1025. % \end{compactitem}
  1026. %
  1027. %\section{\package{arabluatex} in action}
  1028. %\subsection{The vowels and diphthongs}
  1029. % \paragraph{Short vowels} As said above, they are written \meta{a, u,
  1030. % i}:
  1031. % \begin{quote}
  1032. % |_halaqa| (or |xalaqa|) \arb[voc]{xalaqa} \arb[trans]{xalaqa},
  1033. % |^samsuN| \arb[voc]{^samsuN} \arb[trans]{^samsuN}, |karImuN|
  1034. % \arb[voc]{karImuN} \arb[trans]{\uc{karImuN}}.
  1035. %
  1036. % |bi-hi| \arb[voc]{bi-hi} \arb[trans]{bi-hi}, |'aqi.tuN|
  1037. % \arb[voc]{'aqi.tuN} \arb[trans]{'aqi.tuN}.
  1038. %
  1039. % |la-hu| \arb[voc]{la-hu} \arb[trans]{la-hu}, |.hujjaTuN|
  1040. % \arb[voc]{.hujjaTuN} \arb[trans]{.hujjaTuN}.
  1041. % \end{quote}
  1042. %
  1043. %\paragraph{Long vowels} They are written \meta{U, A, I}:
  1044. % \begin{quote}
  1045. % |qAla| \arb[voc]{qAla} \arb[trans]{qAla}, |bI`a| \arb[voc]{bI`a}
  1046. % \arb[trans]{bI`a}, |.tUruN| \arb[voc]{.tUruN} \arb[trans]{.tUruN},
  1047. % |.tInuN| \arb[voc]{.tInuN} \arb[trans]{.tInuN}, |murU'aTuN|
  1048. % \arb[voc]{murU'aTuN} \arb[trans]{murU'aTuN}.
  1049. % \end{quote}
  1050. %
  1051. % \paragraph{\arb[trans]{'alif maq.sUraT}} It is written \meta{\_A} or
  1052. % \meta{Y}:
  1053. % \begin{quote}
  1054. % |al-fat_A| \arb[voc]{al-fat_A} \arb[trans]{al-fat_A}, |al-maqh_A|
  1055. % \arb[voc]{al-maqh_A} \arb[trans]{al-maqh_A}, |'il_A|
  1056. % \arb[voc]{'il_A} \arb[trans]{'il_A}.
  1057. % \end{quote}
  1058. %
  1059. % \paragraph{\arb[trans]{'alif} \emph{otiosum}} Said
  1060. % \arb[trans]{'alif-u 'l-wiqAyaT-i}, \enquote{the guarding
  1061. % \arb[trans]{'alif}}\,, after \arb[novoc]{U} at the end of a word, both
  1062. % when preceded by \arb[trans]{.dammaT} and by \arb[trans]{fat.haT} is
  1063. % written \meta{UA} or \meta{aW, aWA}:
  1064. % \begin{quote}
  1065. % |na.sarUA| \arb[voc]{na.sarUA} \arb[trans]{na.sarUA}, |katabUA|
  1066. % \arb[voc]{katabUA} \arb[trans]{katabUA}, |ya.gzUA|
  1067. % \arb[voc]{ya.gzUA} \arb[trans]{ya.gzUA}, |ramaW|
  1068. % \arb[fullvoc]{ramaW} \arb[trans]{ramaW}, |banaWA|
  1069. % \arb[fullvoc]{banaWA}, \arb[trans]{banaWA}.
  1070. % \end{quote}
  1071. %
  1072. % \paragraph{\arb[trans]{'alif ma.h_dUfaT} and defective \arb[trans]{U,
  1073. % I}} They are written \meta{\_a, \_i \_u}:
  1074. % \begin{quote}
  1075. % |al-l_ah-u| \arb[voc]{al-l_ah-u} \arb[trans]{al-l_ah-u},
  1076. % |'il_ahuN| \arb[voc]{'il_ahuN} \arb[trans]{'il_ahuN}.
  1077. %
  1078. % |al-ra.hm_an-u| \arb[voc]{al-ra.hm_an-u}
  1079. % \arb[trans]{al-ra.hm_an-u}, |l_akin| \arb[voc]{l_akin}
  1080. % \arb[trans]{l_akin}, |h_ahunA| \arb[voc]{h_ahunA}
  1081. % \arb[trans]{h_ahunA}, |.hunayn-u| |bn-u| |'is.h_aq-a|
  1082. % \arb[voc]{.hunayn-u bn-u 'is.h_aq-a} \arb[trans]{\uc{.hunayn}-u
  1083. % bn-u \uc{'is.h_aq-a}}, |rabb_i| \arb[voc]{rabb_i}
  1084. % \arb[trans]{rabb_i}, |al-`A.s_i| \arb[voc]{al-`A.s_i}
  1085. % \arb[trans]{al-\uc{`A.s_i}}.
  1086. % \end{quote}
  1087. %
  1088. % \paragraph{Silent \arb[novoc]{U}/\arb[novoc]{I}}
  1089. % Some words ending with \arb[voc]{BAT} are usually written
  1090. % \arb[voc]{BawT} or \arb[voc]{B_aUT} instead of \arb[voc]{BAT}: see
  1091. % \textcite[i. 12 A]{Wright}. \package{arabluatex} preserves that
  1092. % particular writing; the same applies to words ending in
  1093. % \arb[voc]{BayT} for \arb[voc]{BAT}\,. Long vowels \meta{U, I} shall
  1094. % receive no \arb[trans]{sukUn} after a \arb[trans]{'alif ma.h_dUfaT}
  1095. % and are discarded in |trans| mode:
  1096. % \begin{quote}
  1097. % |.hay_aUTuN| \arb[voc]{.hay_aUTuN} \arb[trans]{.hay_aUTuN},
  1098. % |.sal_aUTuN| \arb[voc]{.sal_aUTuN} \arb[trans]{.sal_aUTuN},
  1099. % |mi^sk_aUTuN| \arb[voc]{mi^sk_aUTuN} \arb[trans]{mi^s\-k_aUTuN},
  1100. % |tawr_aITuN| \arb[voc]{tawr_aITuN} \arb[trans]{tawr_aITuN}.
  1101. %
  1102. % And so also: |al-rib_aIT-u| \arb[voc]{al-rib_aIT-u}
  1103. % \arb[trans]{al-rib_aIT-u}.
  1104. % \end{quote}
  1105. %
  1106. % \paragraph{\arb[trans]{\uc{`amruNU}}, and the silent
  1107. % \arb[novoc]{U}} To that name a silent \arb[novoc]{U} is added to
  1108. % distinguish it from \arb[trans]{\uc{`umar-u}}: see \textcite[i. 12
  1109. % C]{Wright}. In no way this affects the sound of the
  1110. % \arb[trans]{tanwIn}, so it has to be discarded in |trans| mode:
  1111. % \begin{quote}
  1112. % |`amruNU| \arb[voc]{`amruNU} \arb[trans]{`amruNU}, |`amraNU|
  1113. % \arb[voc]{`amraNU} \arb[trans]{`amraNU}, |`amriNU|
  1114. % \arb[voc]{`amriNU} \arb[trans]{`amriNU}.
  1115. %
  1116. % When the \arb[trans]{tanwIn} falls away \parencite[i. 249
  1117. % B]{Wright}: |`amr-uU| |bn-u| |mu.hammadiN| \arb[fullvoc]{`amr-uU
  1118. % bnu mu.hammadiN} \arb[trans]{\uc{`amr-uU} bn-u
  1119. % \uc{mu.hammadiN}}, |mu.hammad-u| |bn-u| |`amr-iU| |bn-i|
  1120. % |_hAlidiN| \arb[fullvoc]{mu.hammad-u bn-u `amr-iU bn-i _hAlidiN}
  1121. % \arb[trans]{\uc{mu.hammad-u} bn-u \uc{`amr-iU} bn-i
  1122. % \uc{_hAlidiN}}.
  1123. %
  1124. % And so also: |al-rib_aUA| \arb[voc]{al-rib_aUA}
  1125. % \arb[trans]{al-rib_aUA}, |ribaNU| \arb[voc]{ribaNU}
  1126. % \arb[trans]{ribaNU}.
  1127. % \end{quote}
  1128. %
  1129. %\paragraph{\arb[trans]{tanwIn}}
  1130. % The marks of doubled short vowels, \arb{BuN}, \arb{BaN}, \arb{BiN},
  1131. % are written \meta{uN, aN, iN} respectively. \package{arabluatex}
  1132. % deals with special cases, such as \arb{BaN} taking an \arb[novoc]{A}
  1133. % after all consonants except \arb[novoc]{T}, and \arb[trans]{tanwIn}
  1134. % preceding \arb[novoc]{Y} as in \arb[voc]{hudaN_A}, which is written
  1135. % \meta{aN\_A} or \meta{aNY}:
  1136. % \begin{quote}
  1137. % |mAluN| \arb[voc]{mAluN} \arb[trans]{mAluN}, |bAbaN|
  1138. % \arb[voc]{bAbaN} \arb[trans]{bAbaN}, |madInaTaN|
  1139. % \arb[voc]{madInaTaN} \arb[trans]{madInaTaN}, |bintiN|
  1140. % \arb[voc]{bintiN} \arb[trans]{bintiN} |maqhaN_A|
  1141. % \arb[voc]{maqhaN_A} \arb[trans]{maqhaN_A}, |fataNY|
  1142. % \arb[voc]{fataNY} \arb[trans]{fataNY}.
  1143. %
  1144. % \package{arabluatex} is aware of special orthographies: |^say'uN|
  1145. % \arb[voc]{^say'uN} \arb[trans]{^say'uN}, |^say'aN|
  1146. % \arb[voc]{^say'aN} \arb[trans]{^say'aN}, |^say'iN|
  1147. % \arb[voc]{^say'iN} \arb[trans]{^say'iN}.
  1148. % \end{quote}
  1149. %
  1150. % In some cases, it may be useful to mark the root form of defective
  1151. % words so as to produce a more accurate transliteration of ending
  1152. % \arb[trans]{tanwIn}. As seen above, \arb[trans]{tanwIn} preceding
  1153. % \arb[novoc]{_A} is written \meta{aN\_A} or \meta{aNY}. Such forms as
  1154. % \arb[voc]{qA.diNI} may likewise be written \meta{iNI}:---
  1155. % \begin{quote}
  1156. % |al-qA.dI| \arb[voc]{al-qA.dI} \arb[trans]{al-qA.dI}, |qA.diyaN|
  1157. % \arb[voc]{qA.diyaN} \arb[trans]{qA.diyaN}, |qA.diNI|
  1158. % \arb[voc]{qA.diNI} \arb[trans]{qA.diNI}.
  1159. % \end{quote}
  1160. %
  1161. % \subsection{Other orthographic signs}
  1162. % \paragraph{\arb[trans]{tA' marbU.taT}}
  1163. % It is written \meta{T}:
  1164. % \begin{quote}
  1165. % |madInaTuN| \arb[voc]{madInaTuN} \arb[trans]{madInaTuN},
  1166. % |madInaTaN| \arb[voc]{madInaTaN} \arb[trans]{madInaTaN},
  1167. % |madInaTiN| \arb[voc]{madInaTiN} \arb[trans]{madInaTiN}.
  1168. % \end{quote}
  1169. %
  1170. % \paragraph{\arb[trans]{hamzaT}} \label{ref:hamza}It is written
  1171. % \meta{\texttt{'}}, its carrier being determined by contextual
  1172. % analysis. In case one wishes to bypass this mechanism, he can use
  1173. % the \enquote{quoting} feature that is described below in
  1174. % \vref{sec:quoting}.
  1175. % \begin{quote}
  1176. % \textbf{Initial \arb[trans]{hamzaT}}: |'asaduN| \arb[voc]{'asaduN}
  1177. % \arb[trans]{'asaduN}, |'u_htuN| \arb[voc]{'u_htuN}
  1178. % \arb[trans]{'u_htuN}, |'iqlIduN| \arb[voc]{'iqlIduN}
  1179. % \arb[trans]{'iqlIduN}, |'anna| \arb[voc]{'anna}
  1180. % \arb[trans]{'anna}, |'inna| \arb[voc]{'inna} \arb[trans]{'inna}.
  1181. %
  1182. % \label{ref:initial-hamza}
  1183. % \arb[trans]{hamzaT} followed by the long vowel \arb[novoc]{U} is
  1184. % encoded |'_U|: |'_Ul_A| \arb[voc]{'_Ul_A} \arb[trans]{'_Ul_A}, |'_UlU|
  1185. % \arb[voc]{'_UlU} \arb[trans]{'_UlU}, |'_UlA'ika|
  1186. % \arb[voc]{'_UlA'ika} \arb[trans]{'_UlA'ika}.
  1187. %
  1188. % \arb[trans]{hamzaT} followed by the long vowel \arb[novoc]{I} is
  1189. % encoded |'_I|: |'_ImAnuN| \arb[voc]{'_ImAnuN}
  1190. % \arb[trans]{'_ImA\-nuN}\footnote{For another way of encoding the
  1191. % initial \arb[trans]{hamzaT} followed by a long vowel, see the
  1192. % \arb[trans]{ta_hfIf-u 'l-hamzaT-i}\vpageref{ref:taxfif-hamzah}.}.
  1193. %
  1194. % \textbf{Middle \arb[trans]{hamzaT}}: |xA.ti'-Ina|
  1195. % \arb[voc]{xA.ti'-Ina} \arb[trans]{xA.ti'-Ina}, |ru'UsuN|
  1196. % \arb[voc]{ru'UsuN}, \arb[trans]{ru'UsuN}, |xa.tI'aTuN|
  1197. % \arb[voc]{xa.tI'aTuN} \arb[trans]{xa.tI'aTuN}, |su'ila|
  1198. % \arb[voc]{su'ila} \arb[trans]{su'ila}, |'as'ilaTuN|
  1199. % \arb[voc]{'as'i\-laTuN} \arb[trans]{'as'ilaTuN}, |mas'alaTuN|
  1200. % \arb[voc]{mas'alaTuN} \arb[trans]{mas'alaTuN}, |'as'alu|
  1201. % \arb[voc]{'as'alu} \arb[trans]{'as'alu}, |yatasA'alUna|
  1202. % \arb[voc]{yatasA'alUna}\linebreak \arb[trans]{yatasA'alUna},
  1203. % |murU'aTuN| \arb[voc]{murU'aTuN}, |taw'amuN|
  1204. % \arb[fullvoc]{taw'amuN} \arb[trans]{taw'amuN},
  1205. % \arb[trans]{murU'aTuN}, |ta'xIruN| \arb[fullvoc]{ta'xIruN}
  1206. % \arb[trans]{ta'xIruN}, |ta'ax|\allowbreak|xara|
  1207. % \arb[voc]{ta'axxara} \arb[trans]{ta'axxara}, |ji'tu-ka|
  1208. % \arb[voc]{ji'tu-ka} \arb[trans]{ji'tu-ka}, |qA'iluN|
  1209. % \arb[voc]{qA'iluN} \arb[trans]{qA'iluN}, |.hIna'i_diN|
  1210. % \arb[trans]{.hIna'i_diN} \arb[voc]{.hIna'i_diN}, |hay'aTuN|
  1211. % \arb[voc]{hay'aTuN} \arb[trans]{hay\-'aTuN}, |hay'AtuN|
  1212. % \arb[voc]{hay'AtuN} \arb[trans]{hay'AtuN}.
  1213. %
  1214. % From \textcite[i. 14 B]{Wright}:--- All consonants, whatsoever,
  1215. % not even \arb[trans]{'alif} \emph{hèmzatum} excepted, admit of
  1216. % being doubled and take \arb[trans]{ta^sdId}. Hence we speak and
  1217. % write |ra''AsuN| \arb[voc]{ra''AsuN} \arb[trans]{ra''AsuN},
  1218. % |sa''AluN| \arb[voc]{sa''AluN} \arb[trans]{sa''AluN}, |na''AjuN|
  1219. % \arb[voc]{na''AjuN} \arb[trans]{na''AjuN}.
  1220. %
  1221. % \textbf{Final \arb[trans]{hamzaT}}: |xa.ta'uN| \arb[voc]{xa.ta'uN}
  1222. % \arb[trans]{xa.ta'uN}, |xa.ta'aN| \arb[voc]{xa.ta'aN}
  1223. % \arb[trans]{xa.ta'aN}, |xa.ta'iN| \arb[voc]{xa.ta'iN}
  1224. % \arb[trans]{xa.ta'iN}, |'aqra'u| \arb[voc]{'aqra'u}
  1225. % \arb[trans]{'aqra'u}, |taqra'Ina| \arb[voc]{taqra'Ina}
  1226. % \arb[trans]{taqra'Ina}, |taqra'Una| \arb[voc]{taqra'Una}
  1227. % \arb[trans]{taqra'Una}, |yaqra'na| \arb[fullvoc]{yaqra'na}
  1228. % \arb[trans]{yaqra'na}, |yaxba'Ani| \arb[voc]{yaxba'Ani}
  1229. % \arb[trans]{yaxba'Ani}, |xaba'A| \arb[voc]{xaba'A}
  1230. % \arb[trans]{xaba'A}, |xubi'a| \arb[voc]{xubi'a}
  1231. % \arb[trans]{xubi'a}, |xubi'UA| \arb[voc]{xubi'UA}
  1232. % \arb[trans]{xubi'UA}, |jA'a| \arb[voc]{jA'a} \arb[trans]{jA'a},
  1233. % |ridA'uN| \arb[voc]{ridA'uN} \arb[trans]{ridA'uN}, |ridA'aN|
  1234. % \arb[voc]{ridA'aN} \arb[trans]{ridA'aN}, |jI'a| \arb[voc]{jI'a}
  1235. % \arb[trans]{jI'a}, |radI'iN| \arb[voc]{radI'iN}
  1236. % \arb[trans]{radI'iN}, |sU'uN| \arb[voc]{sU'uN} \arb[trans]{sU'uN},
  1237. % |.daw'uN| \arb[voc]{.daw'uN} \arb[trans]{.daw'uN}, |qay'iN|
  1238. % \arb[voc]{qay'iN} \arb[trans]{qay'iN}, |^sifA'I|
  1239. % \arb[voc]{^sifA'I} \arb[trans]{^sifA'I}, |man^sa'I|
  1240. % \arb[trans]{man^sa'I} \arb[voc]{man^sa'I}, |nisA'uN|
  1241. % \arb[voc]{nisA'uN} \arb[trans]{ni\-sA'uN}, |nisA'u-hu|
  1242. % \arb[voc]{nisA'u-hu} \arb[trans]{nisA'u-hu}, |nisA'i-hi|
  1243. % \arb[voc]{nisA'i-hi} \arb[trans]{nisA'i-hi}, |nisA'I|
  1244. % \arb[voc]{nisA'I} \arb[trans]{nisA'I}.
  1245. %
  1246. % |^say'uN| \arb[voc]{^say'uN} \arb[trans]{^say'uN}, |^say'aN|
  1247. % \arb[voc]{^say'aN} \arb[trans]{^say'aN}, |^say'iN|
  1248. % \arb[voc]{^say'iN} \arb[trans]{^say'iN}, |al-^say'-u|
  1249. % \arb[voc]{al-^say'-u} \arb[trans]{al-^say'-u}, |'a^syA'-u|
  1250. % \arb[voc]{'a^syA'-u} \arb[trans]{'a^syA'-u}, |'a^syA'-a|
  1251. % \arb[voc]{'a^syA'-a} \arb[trans]{'a^syA'-a}, |.zim'aN|
  1252. % \arb[voc]{.zim'aN} \arb[trans]{.zim'aN}, |radI'aN|
  1253. % \arb[voc]{radI'aN} \arb[trans]{radI'aN}.
  1254. %
  1255. % \label{ref:taxfif-hamzah}
  1256. % \textbf{\arb[trans]{ta_hfIf-u 'l-hamzaT-i}}: if the
  1257. % \arb[trans]{hamzaT} has \arb[trans]{jazmaT} and is preceded by
  1258. % \emph{\arb[trans]{'alif} hamzatum}, it must be changed into the
  1259. % letter of prolongation that is homogeneous with the preceding
  1260. % vowel; hence: |'a'mana| \arb[voc]{'a'mana} \arb[trans]{'a'mana},
  1261. % |'u'minu| \arb[voc]{'u'minu} \arb[trans]{'u'minu}, |'i'mAnuN|
  1262. % \arb[voc]{'i'mAnuN} \arb[trans]{'i'mAnuN}. For other possible ways
  1263. % of encoding such sequences, see \vpageref{ref:initial-hamza}
  1264. % (\arb[trans]{hamzaT} followed by \arb[novoc]{U} and \arb[novoc]{I})
  1265. % and the \arb[trans]{maddaT} \vpageref{ref:madda}.
  1266. %
  1267. % Imperatives of verbs that have the \arb[trans]{hamzaT} as the
  1268. % first radical are other cases of \arb[trans]{ta_hfIf-u
  1269. % 'l-hamzaT-i}: |i'sir| \arb[fullvoc]{i'sir} \arb[trans]{i'sir},
  1270. % |i'_dan| \arb[fullvoc]{i'_dan} \arb[trans]{i'_dan}, |u'mul|
  1271. % \arb[fullvoc]{u'mul} \arb[trans]{u'mul}. \package{arabluatex}
  1272. % also provides ways of encoding those words when the initial
  1273. % \arb[trans]{'alif} comes into \arb[trans]{wa.sl}, so as to make
  1274. % the \arb[trans]{'alif wa.sl} fall away when preceded by
  1275. % \arb[voc]{wa} or \arb[voc]{fa}: |wa-'sir| \arb[fullvoc]{wa-'sir}
  1276. % \arb[trans]{wa-'sir}, |fa-'_dan| \arb[fullvoc]{fa-'_dan}
  1277. % \arb[trans]{fa-'_dan}, |fa-'ti| \arb[fullvoc]{fa-'ti}
  1278. % \arb[trans]{fa-'ti}, |wa-'tamirUA| \arb[fullvoc]{wa-'tamirUA}
  1279. % \arb[trans]{wa-'tamirUA}; or be retained outside the imperative,
  1280. % as in |fa-i'tazarat| \arb[fullvoc]{fa-i'tazarat}
  1281. % \arb[trans]{fa-i'tazarat}, |ba`da| |i'tilAfiN| \arb[fullvoc]{ba`da
  1282. % i'tilAfiN} \arb[trans]{ba`da i'tilAfiN}.
  1283. %
  1284. % \textbf{The strange spelling of \arb[trans]{mi'aTuN}}: |mi'aTuN|
  1285. % \arb[voc]{mi'aTuN} \arb[trans]{mi'aTuN}, \linebreak |mi'atAni|
  1286. % \arb[voc]{mi'atAni} \arb[trans]{mi'atAni}, |mi'atayni|
  1287. % \arb[voc]{mi'atayni} \arb[trans]{mi'atayni}, |mi'Una|
  1288. % \arb[voc]{mi'Una} \arb[trans]{mi'Una}, |mi'AtuN|
  1289. % \arb[voc]{mi'AtuN} \arb[trans]{mi'AtuN}, |mi'aN_A|
  1290. % \arb[voc]{mi'aN_A} \arb[trans]{mi'aN_A}. Of course, the
  1291. % \enquote*{pipe} character can be used to prevent this rule from
  1292. % being applied (see \vref{sec:pipe}): \verb+mi'a|TuN+
  1293. % \arb[voc]{mi'a|TuN} \arb[trans]{mi'a|TuN}.
  1294. % \end{quote}
  1295. %
  1296. % \paragraph{\arb[trans]{maddaT}} \label{ref:madda}At the beginning of
  1297. % a syllabe, \arb[trans]{'alif} with \arb[trans]{hamzaT} and
  1298. % \arb[trans]{fat.haT} (\arb[voc]{'a}) followed by \arb[trans]{'alifu
  1299. % 'l-maddi} (\arb[trans]{'alif} of prolongation) or \arb[trans]{'alif}
  1300. % with \arb[trans]{hamzaT} and \arb[trans]{jazmaT} (\arb[voc]{a"'"})
  1301. % are both represented in writing \arb[trans]{'alif} with
  1302. % \arb[trans]{maddaT}: \arb[voc]{A"'} \parencite[see][i. 25
  1303. % A--B]{Wright}.
  1304. %
  1305. % \iffalse
  1306. %<*example>
  1307. % \fi
  1308. \begin{arabluacode}[text only]
  1309. Hence one should keep to this distinction and encode |'a'kulu|
  1310. \arb[voc]{'a'kulu} \arb[trans]{'a'kulu} and |'AkiluN|
  1311. \arb[voc]{'AkiluN} \arb[trans]{'AkiluN} respectively.
  1312. \end{arabluacode}
  1313. % \iffalse
  1314. %</example>
  1315. % \fi
  1316. %
  1317. % \package{arabluatex} otherwise determines \arb[trans]{al-'alif-u
  1318. % 'l-mamdUdaT-u} by context analysis.
  1319. %
  1320. % \begin{quote}
  1321. % |'is'AduN| \arb[voc]{'is'AduN} \arb[trans]{'is'AduN}, |'AkilUna|
  1322. % \arb[voc]{'AkilUna} \arb[trans]{'AkilUna}, |'a'mannA|
  1323. % \arb[voc]{'a'mannA} \arb[trans]{'a'mannA}, |al-qur'An-u|
  1324. % \arb[voc]{al-qur'An-u} \arb[trans]{al-qur'An-u}.
  1325. %
  1326. % |jA'a| \arb[voc]{jA'a} \arb[trans]{jA'a}, |yatasA'alUna|
  1327. % \arb[voc]{yatasA'alUna} \arb[trans]{yatasA'alUna}, |ridA'uN|
  1328. % \arb[voc]{ridA'uN} \arb[trans]{ridA'uN}, |xaba'A|
  1329. % \arb[voc]{xaba'A} \arb[trans]{xaba'A}, |yaxba'Ani|
  1330. % \arb[voc]{yaxba'Ani} \arb[trans]{yaxba'Ani}.
  1331. % \end{quote}
  1332. %
  1333. % \paragraph{\arb[trans]{^saddaT}}
  1334. % \arb[trans]{ta^sdId} is either \emph{necessary} or \emph{euphonic}.
  1335. %
  1336. % \subparagraph{The necessary
  1337. % \arb[trans]{ta^sdId}} \label{ref:necessary-tashdid}always follows a
  1338. % vowel, whether short or long \parencite[see][i. 15 A--B]{Wright}. It
  1339. % is encoded in writing the consonant that carries it twice:
  1340. % \begin{quote}
  1341. % |`allaqa| \arb[voc]{`allaqa} \arb[trans]{`allaqa}, |mAdduN|
  1342. % \arb[voc]{mAdduN} \arb[trans]{mAdduN}, |'ammara|
  1343. % \arb[voc]{'ammara} \arb[trans]{ammara}, |murruN| \arb[voc]{murruN}
  1344. % \arb[trans]{murruN}.
  1345. % \end{quote}
  1346. %
  1347. % \subparagraph{The euphonic \arb[trans]{ta^sdId}}
  1348. % \label{ref:euphonic-tashdid} always follows a vowelless consonant
  1349. % which is passed over in pronunciation and assimilated to a following
  1350. % consonant. It may be found \parencite[i. 15 B--16 C]{Wright}:---
  1351. % \begin{compactenum}[(a)]
  1352. % \item With the \emph{solar} letters \arb[novoc]{t}, \arb[novoc]{_t},
  1353. % \arb[novoc]{d}, \arb[novoc]{_d}, \arb[novoc]{r}, \arb[novoc]{z},
  1354. % \arb[novoc]{s}, \arb[novoc]{^s}, \arb[novoc]{.s}, \arb[novoc]{.d},
  1355. % \arb[novoc]{.t}, \arb[novoc]{.z}, \arb[novoc]{l}, \arb[novoc]{n},
  1356. % after the article \arb[fullvoc]{al-}:---
  1357. % \iffalse
  1358. %<*example>
  1359. % \fi
  1360. \begin{arabluacode}[text only]
  1361. Unlike \package{arabtex} and \package{arabxetex},
  1362. \package{arabluatex} \emph{never requires the solar letter to be
  1363. written twice}, as it automatically generates the euphonic
  1364. \arb[trans]{ta^sdId} above the letter that carries it, whether the
  1365. article be written in the assimilated form or not, e.g. |al-^sams-u|
  1366. \arb[voc]{al-^sams-u} \arb[trans]{al-^sams-u}, or |a^s-^sams-u|
  1367. \arb[voc]{a^s-^sams-u} \arb[trans]{a^s-^sams-u}.
  1368. \end{arabluacode}
  1369. % \iffalse
  1370. %</example>
  1371. % \fi
  1372. % \begin{quote}
  1373. % |al-tamr-u| \arb[voc]{al-tamr-u} \arb[trans]{al-tamr-u},
  1374. % |al-ra.hm_an-u| \arb[voc]{al-ra.hm_an-u}
  1375. % \arb[trans]{al-ra.hm_an-u}, |al-.zulm-u| \arb[voc]{al-.zulm-u}
  1376. % \arb[trans]{al-.zulm-u}, |al-lu.gaT-u| \arb[voc]{al-lu.gaT-u}
  1377. % \arb[trans]{al-lu.gaT-u}.
  1378. % \end{quote}
  1379. % \item \label{ref:assimilation} With the letters \arb[novoc]{r},
  1380. % \arb[novoc]{l}, \arb[novoc]{m}, \arb[novoc]{w}, \arb[novoc]{y}
  1381. % after \arb[voc]{n} with \arb[trans]{jazmaT}, and also after the
  1382. % \arb[trans]{tanwIn}:---
  1383. % \begin{quote}\SetArbDflt*
  1384. % Note the absence of \arb[trans]{sukUn} above the passed over
  1385. % \arb[novoc]{n} in the following examples, each of which is
  1386. % accompanied by a consistent transliteration: |min rabbi-hi|
  1387. % \arb[fullvoc]{min rabbi-hi}, \arb[trans]{min rabbi-hi},
  1388. % |min| |layliN| \arb[fullvoc]{min layliN} \arb[trans]{min layliN},
  1389. % |'an| |yaqtula| \arb[fullvoc]{'an yaqtula} \arb[trans]{'an yaqtula}.
  1390. %
  1391. % With \arb[trans]{tanwIn}: |kitAbuN| |mubInuN| \arb[voc]{kitAbuN
  1392. % mubInuN} \arb[trans]{kitAbuN mubInuN}.\SetArbDflt
  1393. % \end{quote}
  1394. % \iffalse
  1395. %<*example>
  1396. % \fi
  1397. \begin{arabluacode}[text only]
  1398. \textsc{Rem.} This particular feature must be put into operation by
  1399. the \cs{SetArbDflt*} command explicitly. See above
  1400. \vref{sec:classic-modern-typesetting} for further details. Other
  1401. kinds of assimilations, including the various cases of
  1402. \arb[trans]{'id.gAm}, will be included in \package{arabluatex}
  1403. gradually.
  1404. \end{arabluacode}
  1405. % \iffalse
  1406. %</example>
  1407. % \fi
  1408. % \item With the letter \arb[voc]{t} after the dentals
  1409. % \arb[novoc]{_t}, \arb[novoc]{d}, \arb[novoc]{_d}, \arb[novoc]{.d},
  1410. % \arb[novoc]{.t}, \arb[novoc]{.z} in certain parts of the verb:
  1411. % this kind of assimilation, e.g. \arb[voc]{labi_tttu} for
  1412. % \arb[voc]{labi_ttu} \arb[trans]{labi_ttu}, will be discarded here,
  1413. % as it is largely condemned by the
  1414. % grammarians \parencite[see][i. 16 B--C]{Wright}.
  1415. % \end{compactenum}
  1416. %
  1417. % \paragraph{The definite article and the \arb[trans]{'alif-u 'l-wa.sl-i}}
  1418. % \label{ref:definite-article}
  1419. % At the beginning of a sentence, \arb[fullvoc]{"a} is never written,
  1420. % as \arb[fullvoc]{'l-.hamd-u li-ll_ah-i}; instead, to indicate that
  1421. % the \arb[trans]{'alif} is a connective \arb[trans]{'alif}
  1422. % (\arb[trans]{'alif-u 'l-wa.sl-i}), the \arb[trans]{hamzaT} is
  1423. % omitted and only its accompanying vowel is expressed:
  1424. % \begin{quote}
  1425. % |al-.hamd-u| |li-l-l_ah-i| \arb[fullvoc]{al-.hamd-u li-l-l_ah-i}
  1426. % \arb[trans]{al-.hamd-u li-l-l_ah-i}.
  1427. % \end{quote}
  1428. % As said above on \cpageref{fullvoc-mode}, |fullvoc| is the mode
  1429. % in which \package{arabluatex} expresses the \arb[trans]{sukUn} and
  1430. % the \arb[trans]{wa.slaT}. \package{arabluatex} will take care of
  1431. % doing that automatically provided that the vowel which is to be
  1432. % absorbed by the final vowel of the preceding word be properly
  1433. % encoded, like so:---
  1434. % \begin{compactenum}[(a)]
  1435. % \item Definite article at the beginning of a sentence is encoded\\
  1436. % \arabluaverb{al-}, or \arabluaverb{a<solar letter>-}\\ if one
  1437. % wishes to mark the assimilation---which is in no way required, as
  1438. % \package{arabulatex} will detect all cases of assimilation.
  1439. % \item Definite article inside sentences is encoded\\ \arabluaverb{'l-}
  1440. % or \arabluaverb{'<solar letter>-}.
  1441. % \item In all remaining cases of elision, the \arb[trans]{'alifu
  1442. % 'l-wa.sli} is expressed by the vowel that accompanies the omitted
  1443. % \arb[trans]{hamzaT}: \meta{u, a, i}.
  1444. % \end{compactenum}
  1445. % \begin{quote}
  1446. % \textbf{Article}: |bAb-u| |'l-madrasaT-i| \arb[fullvoc]{bAb-u
  1447. % 'l-madrasaT-i} \arb[trans]{bAb-u 'l-madrasaT-i},
  1448. % |al-maqA|\allowbreak|laT-u| |'l-'_Ul_A| \arb[fullvoc]{al-maqAlaT-u
  1449. % 'l-'_Ul_A} \arb[trans]{al-maqAlaT-u 'l-'_Ul_A}, |al-lu.gaT-u|
  1450. % |'l-`ara|\allowbreak|biyyaT-u| \arb[fullvoc]{al-lu.gaT-u
  1451. % 'l-`arabiyyaT-u} \arb[trans]{al-lu.gaT-u 'l-`arabiyyaT-u}, |fI|
  1452. % |.sinA`aT-i| |'l-.tibb-i| \arb[fullvoc]{fI .sinA`aT-i 'l-.tibb-i}
  1453. % \arb[trans]{fI .sinA`aT-i 'l-.tibb-i}, |'il_A| |'l-intiqA.d-i|
  1454. % \arb[fullvoc]{'il_A 'l-intiqA.d-i} \arb[trans]{'il_A
  1455. % 'l-intiqA.d-i}, |fI| |'l-ibtidA'-i| \arb[fullvoc]{fI 'l-ibtidA'-i}
  1456. % \arb[trans]{fI 'l-ibtidA'-i}, |'abU| |'l-wazIr-i|
  1457. % \arb[fullvoc]{'abU 'l-wazIr-i} \arb[trans]{'abU 'l-wazIr-i},
  1458. % |fa-lammA| |ra'aW| |'l-najm-a| \arb[fullvoc]{fa-lammA ra'aW
  1459. % 'l-najm-a} \arb[trans]{fa-lammA ra'aW 'l-najm-a}.
  1460. %
  1461. % \textbf{Particles}:---
  1462. % \begin{compactenum}[(a)]
  1463. % \item \arb[trans]{li-}: \arb[trans]{'alif-u 'l-wa.sl-i} is omitted
  1464. % in the article \arb[fullvoc]{al} when it is preceded by the
  1465. % preposition \arb[fullvoc]{li}: |li-l-rajul-i|
  1466. % \arb[fullvoc]{li-l-rajul-i}
  1467. % \arb[trans]{li-l-rajul-i}.\\
  1468. % If the first letter of the noun be \arb[novoc]{l}, then the
  1469. % \arb[novoc]{l} of the article also falls away, but
  1470. % \package{arabluatex} is aware of that: |li-l-laylaT-i|
  1471. % \arb[fullvoc]{li-l-laylaT-i} \arb[trans]{li-l-laylaT-i}.
  1472. % \item \arb[trans]{la-}: the same applies to the affirmative
  1473. % particle \arb[fullvoc]{la}: |la-l-.haqq-u|
  1474. % \arb[fullvoc]{la-l-.haqq-u} \arb[trans]{la-l-.haqq-u}.
  1475. % \item With the other particles, \arb[trans]{'alif-u 'l-wa.sl-i} is
  1476. % expressed: |fI| |'l-madIna|\allowbreak|T-i| \arb[fullvoc]{fI
  1477. % 'l-madInaT-i} \arb[trans]{fI 'l-madInaT-i}, |wa-'l-rajul-u|
  1478. % \arb[fullvoc]{wa-'l-rajul-u} \arb[trans]{wa-'l-rajul-u},
  1479. % |bi-'l-|\allowbreak|qalam-i| \arb[fullvoc]{bi-'l-qalam-i}
  1480. % \arb[trans]{bi-'l-qalam-i}, |bi-'l-ru`b-i|
  1481. % \arb[fullvoc]{bi-'l-ru`b-i} \arb[trans]{bi-'l-ru`b-i}.
  1482. % \end{compactenum}
  1483. %
  1484. % \textbf{Perfect active, imperative, nomen actionis}: |qAla|
  1485. % |isma`| \arb[fullvoc]{qAla isma`} \arb[trans]{qAla isma`}, |qAla|
  1486. % |uqtul| \arb[fullvoc]{qAla uqtul} \arb[trans]{qAla uqtul}, |huwa|
  1487. % |inhazama| \arb[fullvoc]{huwa inhazama} \arb[trans]{huwa
  1488. % inhazama}, |wa-ustu`mila| \arb[fullvoc]{wa-ustu`mila}
  1489. % \arb[trans]{wa-ustu`mila}, |qad-i| |in.sarafa| \arb[fullvoc]{qadi
  1490. % in.sarafa} \arb[trans]{qadi in.sarafa}, |al-iqtidAr-u|
  1491. % \arb[fullvoc]{al-iqtidAr-u} \arb[trans]{al-iqtidAr-u}, |'il_A|
  1492. % |'l-inti|\allowbreak|qA.d-i| \arb[fullvoc]{'il_A 'l-intiqA.d-i}
  1493. % \arb[trans]{'il_A 'l-intiqA.d-i}, |law| |istaqbala|
  1494. % \arb[fullvoc]{law istaqbala} \arb[trans]{law istaqbala}.
  1495. %
  1496. % \textbf{Other cases}: |'awi| |ismu-hu| \arb[fullvoc]{'awi ismu-hu}
  1497. % \arb[trans]{'awi ismu-hu}, |zayduN| |ibn-u| |`amriNU|
  1498. % \arb[fullvoc]{\uc{z}ayduN ibn-u \uc{`amriNU}}
  1499. % \arb[trans]{\uc{z}ayduN ibn-u
  1500. % \uc{`amriNU}},\footnote{\label{fn:zayd-is-son}%
  1501. % \enquote{\arb[trans]{\uc{z}ayd} is the son of
  1502. % \arb[trans]{\uc{`a}mr}}: the second noun is not in apposition to
  1503. % the first, but forms part of the predicate. Hence \arb[voc]{zayduN
  1504. % ibn-u `amriNU} and not \arb[voc]{zayd-u bn-u `amriNU},
  1505. % \enquote{Zayd, son of ʿAmr}.} |`umar-u| |ibn-u| |'l-_ha.t.tAb-i|
  1506. % \arb[fullvoc]{\uc{`umar}-u ibn-u \uc{'l-_ha.t.tAb-i}}
  1507. % \arb[trans]{\uc{`umar}-u ibn-u
  1508. % \uc{'l-_ha.t.tAb-i}},\footnote{\enquote{\arb[trans]{\uc{`umar}}
  1509. % is the son of \arb[trans]{\uc{al-_ha.t.tAb}}} (see
  1510. % \vref{fn:zayd-is-son}).} |imru'-u| |'l-qays-i|
  1511. % \arb[fullvoc]{imru'-u 'l-qays-i} \arb[trans]{\uc{i}mru'-u
  1512. % \uc{'l-qays-i}}, |la-aymun-u| |'l-l_ah-i|
  1513. % \arb[fullvoc]{la-aymun-u 'l-l_ah-i} \arb[trans]{la-aymun-u
  1514. % 'l-l_ah-i}.
  1515. % \end{quote}
  1516. %
  1517. % \subparagraph{\arb[trans]{'alif-u 'l-wa.sl-i} preceded by a long
  1518. % vowel} The long vowel preceding the connective \arb[trans]{'alif} is
  1519. % shortened in pronunciation \parencite[i. 21 B--D]{Wright}. This does
  1520. % not appear in the Arabic script, but \package{arabluatex} takes it
  1521. % into account in some transliteration standards:---
  1522. % \begin{quote}
  1523. % |fI| |'l-nAs-i| \arb[fullvoc]{fI 'l-nAs-i} \arb[trans]{fI
  1524. % 'l-nAs-i}, |'abU| |'l-wazIr-i| \arb[fullvoc]{'abU 'l-wazIr-i}
  1525. % \arb[trans]{'abU 'l-wazIr-i}, |fI| |'l-ibtidA'-i| \arb[fullvoc]{fI
  1526. % 'l-ibtidA'-i} \arb[trans]{fI 'l-ibtidA'-i}, |_dU 'l-i`lAl-i|
  1527. % \arb[fullvoc]{_dU 'l-i`lAl-i} \arb[trans]{_dU 'l-i`lAl-i},
  1528. % |maqh_A| |'l-'amIr-i| \arb[voc]{maqh_A 'l-'amIr-i}
  1529. % \arb[trans]{maqh_A 'l-'amIr-i}.
  1530. % \end{quote}
  1531. %
  1532. % \subparagraph{\arb[trans]{'alif-u 'l-wa.sl-i} preceded by a diphthong}
  1533. % \label{sec:diphthong-alif}
  1534. % The diphthong is resolved into two simple vowels \parencite[i. 21
  1535. % D--22 A]{Wright} viz. \emph{ay}~→ \emph{\u{a}\u{i}} and \emph{aw}~→
  1536. % \emph{\u{a}\u{u}}. \package{arabluatex} detects the cases in which
  1537. % this rule applies:---
  1538. % \begin{quote}
  1539. % |fI| |`aynay| |'l-malik-i| \arb[fullvoc]{fI `aynay 'l-malik-i}
  1540. % \arb[trans]{fI `aynay 'l-malik-i}, |ix^say|
  1541. % |'l-qaw|\allowbreak|m-a| \arb[fullvoc]{ix^say 'l-qawm-a}
  1542. % \arb[trans]{ix^say 'l-qawm-a}, |mu.s.tafaw| |'l-l_ah-i|
  1543. % \arb[fullvoc]{mu.s.tafaw 'l-l_ah-i} \arb[trans]{mu.s.ta\-faw
  1544. % 'l-l_ah-i}.
  1545. %
  1546. % |ramaW| |'l-.hijAraT-a| \arb[fullvoc]{ramaW 'l-.hijAraT-a}
  1547. % \arb[trans]{ramaW 'l-.hijAraT-a}, |fa-lammA| |ra'aW |\allowbreak{}
  1548. % |'l-najm-a| \arb[fullvoc]{fa-lammA ra'aW 'l-najm-a}
  1549. % \arb[trans]{fa-lammA ra'aW 'l-najm-a}.
  1550. % \end{quote}
  1551. %
  1552. % \subparagraph{\arb[trans]{'alif-u 'l-wa.sl-i} preceded by a consonant
  1553. % with \arb[trans]{sukUn}} The vowel which the consonant takes is
  1554. % either its original vowel, or that which belongs to the connective
  1555. % \arb[trans]{'alif} or the \arb[trans]{kasraT}; in most of the
  1556. % cases \parencite[i. 22 A--C]{Wright}, it is encoded explicitly, like
  1557. % so:---
  1558. % \begin{quote}
  1559. % |'antumu| |'l-kA_dib-Una| \arb[fullvoc]{'antumu 'l-kA_dib-Una}
  1560. % \arb[trans]{'antumu 'l-kA_dib-Una}, |ra'aytumu| |'l-rajul-a|
  1561. % \arb[fullvoc]{ra'aytumu 'l-rajul-a} \arb[trans]{ra'aytumu
  1562. % 'l-rajul-a}, |mani| |'l-ka_d_dAb-u| \arb[fullvoc]{mani
  1563. % 'l-ka_d_dAb-u} \arb[trans]{mani 'l-ka_d_dAb-u}, |qatalati|
  1564. % |'l-rUm-u| \arb[fullvoc]{qatalati 'l-rUm-u} \arb[trans]{qatalati
  1565. % \uc{'l-rUm-u}}.
  1566. % \end{quote}
  1567. % \label{ref:muhammaduni}
  1568. % However, the Arabic script does not show the \arb[trans]{kasraT} or
  1569. % the \arb[trans]{.dammaT} which may be taken by the nouns having
  1570. % \arb[trans]{tanwIn} although it is explicit in pronunciation and
  1571. % must appear in some transliteration standards. \package{arabluatex}
  1572. % takes care of that automatically:---
  1573. % \begin{quote}
  1574. % |mu.hammaduN| |'l-nabI| \arb[fullvoc]{mu.hammaduN 'l-nabI}
  1575. % \arb[trans]{\uc{m}u.hammaduN 'l-nabI}, |salAmuN| |ud_hulUA|
  1576. % \arb[fullvoc]{salAmuN ud_hulUA} \arb[trans]{salAmuN ud_hulUA},
  1577. % |qa.sIdata-hu| |fI| |qatl-i| |\uc{'a}bI| |\uc{m}uslimiN|
  1578. % |'llatI| |yaqUlu| |fI-hA| \arb[fullvoc]{qa.sIdata-hu fI qatl-i
  1579. % \uc{'a}bI \uc{m}uslimiN 'llatI yaqUlu fI-hA}
  1580. % \arb[trans]{qa.sIdata-hu fI qatl-i \uc{'a}bI \uc{m}uslimiN
  1581. % 'llatI yaqUlu fI-hA}.
  1582. % \end{quote}
  1583. %
  1584. % \subsection{Special orthographies}
  1585. % \paragraph{The name of God}
  1586. % The name of God, \arb[voc]{al-l_ahu}, is compounded of the article
  1587. % \arb[fullvoc]{al-}, and \arb[fullvoc]{'ilAh-u} (noted
  1588. % \arb[fullvoc]{'il_ah-u} with the defective \arb[trans]{'alif}) so
  1589. % that it becomes \arb[fullvoc]{al-'ilAh-u}; then the
  1590. % \arb[trans]{hamzaT} is suppressed, its vowel being transferred to
  1591. % the \arb[novoc]{l} before it, so that there remains
  1592. % \arb[voc]{alil_ah-u} \parencite[I refer to][I. 83
  1593. % col. 1]{Lane}. Finally, the first \arb[novoc]{l} is made quiescent
  1594. % and incorporated into the other, hence the \arb[trans]{ta^sdId}
  1595. % above it. As \package{arabluatex} never requires a solar letter to
  1596. % be written twice (see above, \vpageref{ref:euphonic-tashdid}), the
  1597. % name of God is therefore encoded |al-l_ah-u| or |'l-l_ah-u|:---
  1598. % \begin{quote}
  1599. % |al-l_ah-u| \arb[fullvoc]{al-l_ah-u} \arb[trans]{al-l_ah-u},
  1600. % \verb+yA|+\footnote{\label{fn:pipe-allah-01}Note the
  1601. % \enquote{pipe} character \enquote*{\textbar} here after |yA| and
  1602. % below after |fa| before footnote mark \ref{fn:pipe-allah-02}: it
  1603. % is needed by the |dmg| transliteration mode as in this mode any
  1604. % vowel at the commencement of a word preceded by a word that ends
  1605. % with a vowel, either short or long, is absorbed by this vowel
  1606. % viz. \arb[trans]{`al_A 'l-.tarIq-i}. See \vref{sec:pipe} on the
  1607. % \enquote{pipe} and \vref{sec:transliteration} on |dmg| mode.}
  1608. % |al-l_ah-u| \arb[fullvoc]{yA| al-l_ah-u} \arb[trans]{yA|
  1609. % al-l_ah-u}, \verb+'a-fa|+\footnote{\label{fn:pipe-allah-02}See
  1610. % \cref{fn:pipe-allah-01}.}|-al-|\allowbreak|l_ah-i|
  1611. % |la-ta.g`alanna| \arb[fullvoc]{'a-fa|-al-l_ah-i la-ta.g`alanna}
  1612. % \arb[trans]{'a-fa|-al-l_ah-i la-ta.g`alanna},
  1613. % |bi-'l-|\allowbreak|l_ah-i| \arb[fullvoc]{bi-'l-l_ah-i}
  1614. % \arb[trans]{bi-'l-l_ah-i}, |wa-'l-l_ah-i|
  1615. % \arb[fullvoc]{wa-'l-l_ah-i} \arb[trans]{wa-'l-l_ah-i}, |bi-sm-i|
  1616. % |'l-l_ah-i| \arb[fullvoc]{bi-sm-i 'l-l_ah-i} \arb[trans]{bi-sm-i
  1617. % 'l-l_ah-i}, |al-.hamd-u| |li-l-l_ah-i| \arb[fullvoc]{al-.hamd-u
  1618. % li-l-l_ah-i} \arb[trans]{al-.hamd-u li-l-l_ah-i}, |li-l-l_ah-i|
  1619. % |'l-qA'il-u| \arb[fullvoc]{li-l-l_ah-i 'l-qA'il-u}
  1620. % \arb[trans]{li-l-l_ah-i 'l-qA'il-u}.
  1621. % \end{quote}
  1622. %
  1623. % \paragraph{The conjunctive \arb[voc]{alla_dI}}
  1624. % Although it is compounded of the article \arb[fullvoc]{al}, the
  1625. % demonstrative letter \arb[novoc]{l} and the demonstrative pronoun
  1626. % \arb[voc]{_dA}, both masculine and feminine forms that are written
  1627. % defectively are encoded |alla_dI| and |allatI| respectively. Forms
  1628. % starting with the connective \arb[trans]{'alif} are encoded
  1629. % |'lla_dI| and |'llatI|:---
  1630. % \begin{quote}
  1631. % |'a_hAfu| |mina| |'l-malik-i| |'lla_dI| |ya.zlimu| |'l-nAs-a|
  1632. % \arb[fullvoc]{'a_hAfu mina 'l-malik-i 'lla_dI ya.zlimu 'l-nAs-a}
  1633. % \arb[trans]{'a_hAfu mina 'l-malik-i 'lla_dI ya.zlimu 'l-nAs-a},
  1634. % |`udtu| |'l-^say_h-a| |'lla_dI| |huwa| |marI.duN|
  1635. % \arb[fullvoc]{`udtu 'l-^say_h-a 'lla_dI huwa marI.duN}
  1636. % \arb[trans]{`udtu 'l-^say_h-a 'lla_dI huwa marI.duN}, |mA| |'anA|
  1637. % |bi-'lla_dI| |qA'iluN| |la-ka| |^say'aN| \arb[fullvoc]{mA 'anA
  1638. % bi-'lla_dI qA'iluN la-ka ^say'aN} \arb[trans]{mA 'anA bi-'lla_dI
  1639. % qA'iluN la-ka ^say'aN}.
  1640. %
  1641. % |'ari-nA| |'lla_dayni| |'a.dallA-nA| |mina| |'l-jinn-i|
  1642. % |wa-'l-'ins-i| \arb[fullvoc]{'ari-nA 'lla_dayni 'a.dallA-nA mina
  1643. % 'l-jinn-i wa-'l-'ins-i} \arb[trans]{'ari-nA 'lla_dayni 'a.dallA-nA
  1644. % mina 'l-jinn-i wa-'l-'ins-i}.
  1645. % \end{quote}
  1646. % The other forms are encoded regularly as |al-l| or |'l-l|:---
  1647. % \begin{quote}
  1648. % |fa-'innA| |na_dkuru| |'l-.sawt-ayni| |'l-la_dayni| |rawaynA-humA|
  1649. % |`an| |ja.h.zaT-a| \arb[fullvoc]{fa-'innA na_dkuru 'l-.sawt-ayni
  1650. % 'l-la_dayni rawaynA-humA `an \uc{ja.h.zaT-a}}
  1651. % \arb[trans]{fa-'innA na_dkuru 'l-.sawt-ayni 'l-la_dayni
  1652. % rawaynA-humA `an \uc{ja.h.zaT-a}}.
  1653. %
  1654. % And also: |al-la_dAni| \arb[fullvoc]{al-la_dAni}
  1655. % \arb[trans]{al-la_dAni}, |al-la_dayni| \arb[fullvoc]{al-la_dayni}
  1656. % \arb[trans]{al-la_dayni}, |al-latAni| \arb[fullvoc]{al-latAni}
  1657. % \arb[trans]{al-latAni}, |al-latayni| \arb[fullvoc]{al-latayni}
  1658. % \arb[trans]{al-latayni}, |al-lAtI| \arb[fullvoc]{al-lAtI}
  1659. % \arb[trans]{al-lAtI},
  1660. % \verb+al-lA'|Ati+\footnote{\label{fn:pipe-madda}Note here the
  1661. % \enquote{pipe} character \enquote*{\textbar}: as already stated
  1662. % \vpageref{ref:madda}, the sequence |'A| usually encodes
  1663. % \arb[trans]{'alif} with \arb[trans]{hamzaT} followed by
  1664. % \arb[trans]{'alif} of prolongation, which is represented in writing
  1665. % \arb[trans]{'alif} with \arb[trans]{maddaT}: \arb[voc]{A"'}. The
  1666. % \enquote{pipe} character prevents this rule from being
  1667. % applied. See \vref{sec:pipe}.} \arb[fullvoc]{al-lA'|Ati}
  1668. % \arb[trans]{al-lA'|Ati}, |al-lA'I| \arb[fullvoc]{al-lA'I}
  1669. % \arb[trans]{al-lA'I}, and so forth.
  1670. % \end{quote}
  1671. %
  1672. % \subsection{Quoting}
  1673. % \label{sec:quoting}
  1674. % It is here referred to \enquote{quoting} after the \package{arabtex}
  1675. % package.\footnote{See \textcite[22]{pkg:arabtex}} The
  1676. % \enquote{quoting} mechanism of \package{arabluatex} is designed to
  1677. % be very similar in effect to the one of \package{arabtex}.
  1678. %
  1679. % To start with an example, suppose one types the following in |novoc|
  1680. % mode: \arb[novoc]{`ullima `ilm-a 'l-hay'aT-i}; is it
  1681. % \arb[fullvoc]{`ullima}, \emph{he was taught the science of
  1682. % astronomy}, or \arb[fullvoc]{`allama}, \emph{he taught the science
  1683. % of astronomy}? In order to disambiguate this clause, it may be
  1684. % sensible to put a \arb[trans]{.dammaT} above the first \arb[voc]{`}:
  1685. % \arb[novoc]{`"ullima `ilm-a 'l-hay'aT-i}, which is achieved by
  1686. % \enquote{quoting} the vowel |u|, like so: |`"ullima|, or, with no
  1687. % other vowel than the required |u|: |`"ullm|.
  1688. %
  1689. % This is how the \enquote{quoting} mechanism works: metaphorically
  1690. % speaking, it acts as a \emph{toggle switch}. If something, in a
  1691. % given mode, is supposed to be visible, \enquote{quoting} hides it;
  1692. % conversely, if it is supposed not to, it makes it visible.
  1693. %
  1694. % As shown above, \enquote{quoting} means inserting one straight
  1695. % double quote (|"|) \emph{before} the letter that is to be acted
  1696. % upon. Its effects depend on the mode which is currently selected,
  1697. % either |novoc|, |voc| or |fullvoc|:---
  1698. %
  1699. % \paragraph{\texttt{novoc}} In this mode, \enquote{quoting}
  1700. % essentially means make visible something that ought not to be so.
  1701. % \begin{compactenum}[(a)]
  1702. % \item Quoting a vowel, either short or long, makes the
  1703. % \arb[trans]{.dammaT}, \arb[trans]{fat.haT} or \arb[trans]{kasraT}
  1704. % appear above the appropriate consonant:---
  1705. % \begin{quote}
  1706. % |`"ullima| |`ilm-a| |'l-hay'aT-i| \arb[novoc]{`"ullima `ilm-a
  1707. % 'l-hay'aT-i} \arb[trans]{`"ullima `ilm-a 'l-hay'aT-i}, |ya.gz"UA|
  1708. % \arb[novoc]{ya.gz"UA} \arb[trans]{ya.gz"UA}.
  1709. % \end{quote}
  1710. % \item The same applies when \enquote{quoting} the
  1711. % \arb[trans]{tanwIn}:---
  1712. % \begin{quote}
  1713. % |wa-'innA| |sawfa| |tudriku-nA| |'l-manAyA| |muqadd"araT"aN|
  1714. % \arb[novoc]{wa-'innA sawfa tudriku-nA 'l-manAyA muqadd"araT"aN},
  1715. % \arb[trans]{wa-'innA sawfa tudriku-nA 'l-manAyA muqadd"araT"aN}.
  1716. % \end{quote}
  1717. % \item \label{ref:quoted-sukun-b}If no vowel follows the straight
  1718. % double quote, then a \arb[trans]{sukUn} is put above the preceding
  1719. % consonant:---
  1720. % \begin{quote}
  1721. % |qAla isma`"| \arb[novoc]{qAla isma`"} \arb[trans]{qAla isma`"},
  1722. % |jA'at"| |hinduN| \arb[voc]{jA'at" \uc{hinduN}}
  1723. % \arb[trans]{jA'at" \uc{hinduN}}, |^sabIhuN| |bi-man| |q"u.ti`at"|
  1724. % |qadamA-hu| \arb[novoc]{^sabIhuN bi-man q"u.ti`at" qadamA-hu}
  1725. % \arb[trans]{^sabIhuN bi-man q"u.ti`at" qadamA-hu}.
  1726. % \end{quote}
  1727. % \item At the commencement of a word, the straight double quote is
  1728. % interpreted as \arb[trans]{'alif-u 'l-wa.sl-i}:---
  1729. % \begin{quote}
  1730. % |wa-"ust"u`mila| \arb[novoc]{wa-"ust"u`mila}
  1731. % \arb[trans]{wa-"ust"u`mila}, |huwa| |"inhazama| \arb[novoc]{huwa
  1732. % "inhazama} \arb[trans]{huwa "inhazama}, |al-"intiqA.d-u|
  1733. % \arb[novoc]{al-"intiqA.d-u} \arb[trans]{al-"intiqA.d-u}.
  1734. % \end{quote}
  1735. % \end{compactenum}
  1736. %
  1737. % \paragraph{\texttt{voc}}
  1738. % In accordance with the general rule, in this mode, \enquote{quoting}
  1739. % makes the vowels and the \arb[trans]{tanwIn} disappear, should this
  1740. % feature be required for some reason:---
  1741. % \begin{compactenum}[(a)]
  1742. % \item Short and long vowels:---
  1743. % \begin{quote}
  1744. % |q"Ala q"A'iluN| \arb[voc]{q"Ala q"A'iluN} \arb[trans]{q"Ala
  1745. % q"A'iluN}, |ibn-u 'abI 'u.saybi`aT-"a| \arb[voc]{ibn-u 'abI
  1746. % 'u.saybi`aT-"a} \arb[trans]{\uc{ibn-u} \uc{'abI}
  1747. % \uc{'u.saybi`aT-"a}}.
  1748. % \end{quote}
  1749. % \item \arb[trans]{tanwIn}:---
  1750. % \begin{quote}
  1751. % |madInaT"aN| \arb[voc]{madInaT"aN} \arb[trans]{madInaT"aN},
  1752. % |bAb"aN| \arb[voc]{bAb"aN} \arb[trans]{bAb"aN}, |hud"aN_A|
  1753. % \arb[voc]{hud"aN_A} \arb[trans]{hud"aN_A}, |^say'"iN|
  1754. % \arb[voc]{^say'"iN} \arb[trans]{^say'"iN}.
  1755. % \end{quote}
  1756. % \end{compactenum}
  1757. % One may more usefully \enquote{quote} the initial vowels to write
  1758. % the \arb[trans]{wa.slaT} above the \arb[trans]{'alif} or insert a
  1759. % straight double quote after a consonant not followed by a vowel to
  1760. % make the \arb[trans]{sukUn} appear:---
  1761. % \begin{compactenum}[(a)]
  1762. % \item \arb[trans]{'alif-u 'l-wa.sl-i}:---
  1763. % \begin{quote}
  1764. % |fI "istiq.sA'-iN| \arb[voc]{fI "istiq.sA'-iN} \arb[trans]{fI
  1765. % "istiq.sA'-iN}, |wa-"istiq.sA'-uN| \arb[voc]{wa-"istiq.sA'-uN}
  1766. % \allowbreak\arb[trans]{wa-"istiq.sA'-uN}, |qAla| |"uhrub|
  1767. % |fa-lan| |tuqtala| \arb[voc]{qAla "uhrub fa-lan tuqtala}
  1768. % \arb[trans]{qAla "uhrub fa-lan tuqtala}.
  1769. % \end{quote}
  1770. % \item \arb[trans]{sukUn}:---
  1771. % \begin{quote}
  1772. % |qAla| |"uqtul"| |fa-lan| |tuqtala| \arb[voc]{qAla "uqtul"
  1773. % fa-lan tuqtala} \arb[trans]{qAla "uqtul" fa-lan tuqtala}, |mA|
  1774. % |jA'at"| |mini| |imra'aTiN| \arb[voc]{mA jA'at" mini imra'aTiN}
  1775. % \arb[trans]{mA jA'at" mini imra'aTiN}, |kam"| |qad"| |ma.dat"|
  1776. % |min"| |laylaTiN| \arb[voc]{kam" qad" ma.dat" min" laylaTiN}
  1777. % \arb[trans]{kam" qad" ma.dat" min"
  1778. % laylaTiN}.\label{ref:quoted-sukun-e}
  1779. % \end{quote}
  1780. % \end{compactenum}
  1781. %
  1782. % \paragraph{\texttt{fullvoc}}
  1783. % In this mode, \enquote{quoting} can be used to take away any short
  1784. % vowel (or \arb[trans]{tanwIn}, as seen above) or any
  1785. % \arb[trans]{sukUn}:---
  1786. % \begin{quote}\label{ref:qrannun-full}
  1787. % |al-jamr-u| |'l-.sayfiyy-u| |'lla_dI| |kAna|
  1788. % \verb+bi-q"rAn"|nUn-a+ \arb[fullvoc]{al-jamr-u 'l-.sayfiyy-u
  1789. % 'lla_dI kAna \uc{bi-q"rAn"|nUn-a}} \arb[trans]{al-jamr-u
  1790. % 'l-.sayfiyy-u 'lla_dI kAna \uc{bi-q"rAn"|nUn-a}}.
  1791. % \end{quote}
  1792. %
  1793. % \subsubsection{\texorpdfstring{Quoting the
  1794. % \arb[trans]{hamzaT}}{Quoting the hamzah}}
  1795. % \label{sec:quoting-hamza}
  1796. % As said above in \vref{ref:hamza}, the \arb[trans]{hamzaT} is always
  1797. % written \meta{\texttt{'}}, its carrier being determined by contextual
  1798. % analysis. \enquote{Quoting} that straight single quote character
  1799. % like so: \meta{\texttt{"'}} allows to determine the carrier of the
  1800. % \arb[trans]{hamzaT} freely, without any consideration for the
  1801. % context. \Cref{tab:quoted-hamza} gives the equivalents for all the
  1802. % possible carriers the \arb[trans]{hamzaT} may take.
  1803. %
  1804. % \begin{longtable}{lllll}
  1805. % \captionlistentry{\enquote{Quoted} \arb[trans]{hamzaT}}\\[-1em]
  1806. % \toprule
  1807. % Letter & \multicolumn{3}{l}{Transliteration\footnotemark}
  1808. % & Arab\TeX\ notation \\
  1809. % & \texttt{dmg} & \texttt{loc} & \texttt{arabica} & \\ \midrule
  1810. % \endfirsthead
  1811. % \toprule
  1812. % Letter & \multicolumn{3}{l}{Transliteration}
  1813. % & Arab\TeX\ notation \\
  1814. % & \texttt{dmg} & \texttt{loc} & \texttt{arabica} & \\ \midrule
  1815. % \endhead \footnotetext{See below \vref{sec:transliteration}.}
  1816. % \label{tab:quoted-hamza}
  1817. % \arb[novoc]{|"'} & \dmg{|"'} & \loc{|"'} & \brill{|"'} & \verb+|"'+ \\
  1818. % \arb[novoc]{A"'} & \dmg{A"'} & \loc{A"'} & \brill{A"'} & \verb|A"'| \\
  1819. % \arb[novoc]{a"'} & \dmg{a"'} & \loc{a"'} & \brill{a"'} & \verb|a"'| \\
  1820. % \arb[novoc]{u"'} & \dmg{u"'} & \loc{u"'} & \brill{u"'} & \verb|u"'| \\
  1821. % \arb[novoc]{w"'} & \dmg{w"'} & \loc{w"'} & \brill{w"'} & \verb|w"'| \\
  1822. % \arb[novoc]{i"'} & \dmg{i"'} & \loc{i"'} & \brill{i"'} & \verb|i"'| \\
  1823. % \arb[novoc]{y"'} & \dmg{y"'} & \loc{y"'} & \brill{y"'} & \verb|y"'| \\
  1824. % \bottomrule
  1825. % \caption*{\Cref*{tab:quoted-hamza}: \enquote{Quoted} \arb[trans]{hamzaT}}
  1826. % \end{longtable}
  1827. %
  1828. % As one can see from \vref{tab:quoted-hamza}, the carrier of the
  1829. % \arb[trans]{hamzaT} is inferred from the letter that precedes the
  1830. % straight double quote \meta{\texttt{"}}. Of course, any
  1831. % \enquote{quoted} \arb[trans]{hamzaT} may take a short vowel, which
  1832. % is to be written \emph{after} the Arab\TeX\ equivalent for the
  1833. % \arb[trans]{hamzaT} itself, namely \meta{\texttt{'}}. For example,
  1834. % \arb[voc]{w"'a} is encoded \meta{\texttt{w"'a}}, while
  1835. % \arb[voc]{w"'"} is encoded \meta{\texttt{w"'"}}. In the latter
  1836. % example, the second straight double quote encodes the
  1837. % \arb[trans]{sukUn} in |voc| mode in accordance with the rule laid
  1838. % above \vpagerefrange{ref:quoted-sukun-b}{ref:quoted-sukun-e}.
  1839. % \begin{quote}
  1840. % |'a`dA'ukum| \arb[fullvoc]{'a`dA'ukum} \arb[trans]{'a`dA'ukum},
  1841. % \verb+'a`dA|"'ukum+ \arb[fullvoc]{'a`daA"'|"'ukum}
  1842. % \arb[trans]{'a`dA|"'ukum}, |'a`dA'ikum| \arb[fullvoc]{'a`dA'ikum}
  1843. % \arb[trans]{'a`dA'ikum}, \verb+'a`dA|"'ikum+
  1844. % \arb[fullvoc]{'a`daA"'|"'ikum} \arb[trans]{'a`dA|"'ikum}.
  1845. % \end{quote}
  1846. %
  1847. % \subsection{The \enquote{pipe} character (\textbar)}
  1848. % \label{sec:pipe}
  1849. % In the terminology of Arab\TeX, the \enquote{pipe} character
  1850. % \enquote*{\textbar} is referred to as the \enquote{invisible
  1851. % consonant}. Hence, as already seen above in
  1852. % \vref{sec:quoting-hamza}, its usage to encode the
  1853. % \arb[trans]{hamzaT} alone, with no carrier: \verb+|"'+
  1854. % \arb[novoc]{|"'}.
  1855. %
  1856. % Aside from that usage, the \enquote{pipe} character is used to
  1857. % prevent almost any of the contextual analysis rules that are
  1858. % described above from being applied. Two examples have already been
  1859. % given to demonstrate how that particular mechanism works in
  1860. % \vref{fn:pipe-allah-01} and in \vref{fn:pipe-madda}. One more example
  1861. % follows:---
  1862. % \begin{quote}
  1863. % \verb+bi-qrAn|nUn-a+ \arb[voc]{\uc{bi-qrAn|nUn-a}}
  1864. % \arb[trans]{\uc{bi-qrAn|nUn-a}}, \enquote{in Crannon} (Thessaly,
  1865. % Greece).\footnote{See more context \vpageref{ref:qrannun-full}.}
  1866. % \end{quote}
  1867. % As one can see, the \enquote{pipe} character between the two
  1868. % \meta{n} prevents the necessary \arb[trans]{ta^sdId} rule
  1869. % (\cpageref{ref:necessary-tashdid}) from being applied.
  1870. %
  1871. % \subsection{Putting back on broken contextual analysis rules}
  1872. % \label{sec:arbnull}
  1873. % \NEWfeature{v1.7} In complex documents such as critical editions
  1874. % where footnotes and other kind of annotations can be particularly
  1875. % abundant, the contextual analysis rules that are described above may
  1876. % be broken by \LaTeX\ commands. To take an example, consider the
  1877. % following:---%
  1878. % \iffalse
  1879. %<*example>
  1880. % \fi
  1881. \begin{arabluacode}
  1882. This is wrong:
  1883. \begin{arab}[fullvoc]
  1884. fa-lammA ra'aW\LRfootnote{A footnote that interferes with the
  1885. contextual analysis.} 'l-na^gma...
  1886. \end{arab}
  1887. \end{arabluacode}
  1888. % \iffalse
  1889. %</example>
  1890. % \fi%
  1891. % According to the rule stated \vpageref{sec:diphthong-alif}, the
  1892. % diphthong in \arb[trans]{ra'aW} must be resolved into two simple
  1893. % vowels before the \arb[trans]{'alif-u 'l-wa.sl-i}, as
  1894. % \arb[fullvoc]{ra'aW 'l-na^gma}.
  1895. %
  1896. % \DescribeMacro{\arbnull} The \cs{arbnull} command is provided so as
  1897. % to put back on contextual analysis rules in such situations. It
  1898. % takes as argument the word that must be brought back for any given
  1899. % rule to be applied as it ought to. Depending on the contexts that
  1900. % have to be restored, \cs{arbnull} may be found just after or before
  1901. % Arabic words.%
  1902. % \iffalse
  1903. %<*example>
  1904. % \fi
  1905. \begin{arabluacode}[text only]
  1906. In any case, \emph{no space must be left} after or before the Arabic
  1907. word that \cs{arbnull} is applied to.
  1908. \end{arabluacode}
  1909. % \iffalse
  1910. %</example>
  1911. % \fi%
  1912. % The following shows how the Arabic should have been written in the
  1913. % preceding example and gives further illustrations of the same
  1914. % technique:---%
  1915. % \iffalse
  1916. %<*example>
  1917. % \fi
  1918. \begin{arabluacode}
  1919. \begin{arab}[fullvoc]
  1920. fa-lammA ra'aW\arbnull{'l-na^gma}\LRfootnote{A footnote that
  1921. interferes with the contextual analysis.} 'l-na^gma...
  1922. qAla\LRfootnote{A footnote that interferes with the contextual
  1923. analysis.} \arbnull{qAla}uhrub fa-lan tuqtala.
  1924. \uc{z}ayduN\arbnull{ibnu}\LRfootnote{A footnote that interferes
  1925. with the contextual analysis.} \arbnull{zayduN}ibn-u
  1926. \uc{`a}mriNU.\LRfootnote{See \vref{fn:zayd-is-son}.}
  1927. \end{arab}
  1928. \begin{arab}[trans]
  1929. \uc{z}ayduN\arbnull{ibnu}\LRfootnote{A footnote that interferes
  1930. with the contextual analysis.} \arbnull{zayduN}ibn-u
  1931. \uc{`a}mriNU.\LRfootnote{See \vref{fn:zayd-is-son}.}
  1932. \end{arab}
  1933. \end{arabluacode}
  1934. % \iffalse
  1935. %</example>
  1936. % \fi%
  1937. %
  1938. % \subsection{\texorpdfstring{Stretching characters: the
  1939. % \arb[trans]{ta.twIl}}{Stretching characters: the taṭwīl}}
  1940. % \label{sec:tatwil}
  1941. % A double hyphen \meta{-\,-} stretches the ligature in which one
  1942. % letter is bound to another. Although it is always better to rely on
  1943. % automatic stretching, this technique can be used to a modest extent,
  1944. % especially to increase legibility of letters and diacritics which
  1945. % stand one above the other:--
  1946. % \begin{quote}
  1947. % |.hunayn-u| |bn-u| |'is.h--_aq-a| \arb[voc]{.hunayn-u bn-u
  1948. % 'is.h--_aq-a} \arb[trans]{\uc{.hunayn-u} bn-u \uc{'is.h--_aq-a}}
  1949. % \end{quote}
  1950. %
  1951. % \subsection{Digits}
  1952. % \label{sec:digits}
  1953. % \subsubsection{Numerical figures}
  1954. % \label{sec:numerical-figures}
  1955. % The \emph{Indian numbers}, \arb[trans]{al-raqam-u 'l-hindiyy-u}, are
  1956. % ten in number, and they are compounded in exactly the same way as
  1957. % our numerals:---
  1958. % \begin{quote}
  1959. % |1874| \arb[voc]{1874}, |123-456,789| \arb[voc]{123-456,789}, |fI|
  1960. % |sanaT-i| |1024| \arb[voc]{fI sanaT-i 1024}
  1961. % \end{quote}
  1962. %
  1963. % \subsubsection{The \emph{abjad}}
  1964. % \label{sec:abjad}
  1965. % The numbers may also be expressed with letters from right to left
  1966. % arranged in accordance with the order of the Hebrew and Aramaic
  1967. % alphabets \parencite[see][i. 28 B--C]{Wright}. The
  1968. % \arb[trans]{'abjad} numbers are usually distinguished from the
  1969. % surrounding words by a stroke placed over them.
  1970. %
  1971. % \DescribeMacro{\abjad} \NEWfeature{v.1.1} \arb[trans]{'abjad}
  1972. % numbers are inserted with the \cs{abjad}\marg{number} command in any
  1973. % of the |voc|, |fullvoc| and |novoc| modes, where \meta{number} may
  1974. % be any number between 1 and 1999, like so:---
  1975. % \begin{quote}
  1976. % |\abjad{45}| |kitAbu-hu| |fI| |'l-`AdAt-i| \arb[voc]{\abjad{45}
  1977. % kitAbu-hu fI 'l-`AdAt-i} \arb[trans]{\abjad{45} kitAbu-hu fI
  1978. % 'l-`AdAt-i}.
  1979. % \end{quote}
  1980. % \begin{quoting}
  1981. % \textsc{Rem.}~\emph{a.} As can be seen in the above given example,
  1982. % \package{arabluatex} expresses the \arb[trans]{'abjad} numbers in
  1983. % Roman numerals if it finds the \cs{abjad} command in any of the
  1984. % transliteration modes.
  1985. %
  1986. % \textsc{Rem.}~\emph{b.} \cs{abjad} may also be found outside
  1987. % Arabic environments. In that case, \package{arabluatex} does not
  1988. % print the stroke as a distinctive mark over the number for it is
  1989. % not surrounded by other Arabic words. In case one nonetheless
  1990. % wishes to print the stroke, he can use the \cs{aemph} command that
  1991. % is described below in \vref{sec:emphasis}:---
  1992. % \begin{quote}
  1993. % |The| |\arb[trans]{'abjad}| |number| |for| |1874| |is|
  1994. % |\abjad{1874}| The \arb[trans]{'abjad} number for 1874 is
  1995. % \abjad{1874}.
  1996. %
  1997. % |The| |\arb[trans]{'abjad}| |number| |for| |1874| |is|
  1998. % |\aemph*{\abjad{1874}}| The \arb[trans]{'abjad} number for 1874
  1999. % is \aemph*{\abjad{1874}}.
  2000. % \end{quote}
  2001. % \end{quoting}
  2002. %
  2003. % \subsection{Additional characters}
  2004. % \label{sec:additional-characters}
  2005. % In the manuscripts, the unpointed letters, \arb[trans]{al-.hurUfu
  2006. % 'l-muhmalaTu}, are sometimes further distinguished from the pointed
  2007. % by various contrivances, as explained in \textcite[i. 4
  2008. % B--C]{Wright}. One may find these letters written in a smaller size
  2009. % below the line, or with a dot or another mark below. As representing
  2010. % all the possible contrivances leads to much complexity and also
  2011. % needs to be agreed among scholars, new ways of encoding them will be
  2012. % proposed and gradually included as \package{arabluatex} will mature.
  2013. %
  2014. % For the time being, the following is included:---
  2015. % \begin{longtable}{lllll}
  2016. % \captionlistentry{Additional Arabic codings}\\[-1em]
  2017. % \toprule
  2018. % Letter & \multicolumn{3}{l}{Transliteration\footnotemark}
  2019. % & Arab\TeX\ notation \\
  2020. % & \texttt{dmg} & \texttt{loc} & \texttt{arabica} & \\ \midrule
  2021. % \endfirsthead
  2022. % \toprule
  2023. % Letter & \multicolumn{3}{l}{Transliteration}
  2024. % & Arab\TeX\ notation \\
  2025. % & \texttt{dmg} & \texttt{loc} & \texttt{arabica} \\ \midrule
  2026. % \endhead \footnotetext{See below \vref{sec:transliteration}.}
  2027. % \label{tab:additional-arabic-codings}
  2028. % \arb[novoc]{.b} & \dmg{.b} & \loc{.b} & \brill{.b} & |.b| \\
  2029. % \arb[novoc]{^d} & \dmg{^d} & \loc{^d} & \brill{^d} & |^d| \\
  2030. % \arb[novoc]{.f} & \dmg{.f} & \loc{.f} & \brill{.f} & |.f| \\
  2031. % \arb[novoc]{.q} & \dmg{.q} & \loc{.q} & \brill{.q} & |.q| \\
  2032. % \arb[novoc]{.k} & \dmg{.k} & \loc{.k} & \brill{.k} & |.k| \\
  2033. % \arb[novoc]{.n} & \dmg{.n} & \loc{.n} & \brill{.n} & |.n| \\
  2034. % \arb[novoc]{((} & \dmg{((} & \loc{((} & \brill{((} & |((| \\
  2035. % \arb[novoc]{))} & \dmg{))} & \loc{))} & \brill{))} & |))| \\
  2036. % \bottomrule
  2037. % \caption*{\Cref*{tab:additional-arabic-codings}: Additional Arabic
  2038. % codings}
  2039. % \end{longtable}
  2040. %
  2041. % \begin{quote}
  2042. % |'afAman.tUs| Gal.(M) |.fmn.n.ts| (sic) Gal.(E1),
  2043. % \arb[novoc]{'afAman.tUs} Gal.(M) \arb[novoc]{.fmn.n.ts} (sic)
  2044. % Gal.(E1), \arb[trans]{'afAman.tUs} Gal.(M) \arb[trans]{.fmn.n.ts}
  2045. % (sic) Gal.(E1).
  2046. % \end{quote}
  2047. %
  2048. % \subsection{Arabic emphasis}
  2049. % \label{sec:emphasis}
  2050. % As already seen in \vref{sec:abjad}, the \arb[trans]{'abjad} numbers
  2051. % are distinguished from the surrounding words by a stroke placed
  2052. % over them. This technique is used to distinguish further words that
  2053. % are proper names or book titles.
  2054. %
  2055. % \DescribeMacro{\aemph} One may use the \cs{aemph}\marg{Arabic
  2056. % text} command to use the same technique to emphasize words, like so:---
  2057. % \begin{quote}
  2058. % |\abjad{45}:| |kitAbu-hu| |\aemph{fI| |'l-`AdAt-i}|
  2059. % \arb[voc]{\abjad{45}: kitAbu-hu \aemph{fI 'l-`AdAt-i}}
  2060. % \arb[trans]{\abjad{45}: kitAbu-hu \aemph{fI 'l-\uc{`AdAt-i}}}.
  2061. % \end{quote}
  2062. %
  2063. % \begin{quoting}
  2064. % \textsc{Rem.}~\emph{a.} As the above example shows,
  2065. % \package{arabluatex} places the horizontal stroke \emph{under} the
  2066. % emphasized words in any of the transliteration modes.
  2067. %
  2068. % \textsc{Rem.}~\emph{b.} \NEWfeature{v1.9.2}\DescribeMacro{\aemph*}
  2069. % \cs{aemph*} is also provided should one wish to always have the
  2070. % horizontal stroke printed over the emphasized words, like so:
  2071. % |\abjad{45}:| |kitAbu-hu| |\aemph*{fI| |'l-`AdAt-i}|
  2072. % \arb[voc]{\abjad{45}: kitAbu-hu \aemph*{fI 'l-`AdAt-i}}
  2073. % \arb[trans]{\abjad{45}: kitAbu-hu \aemph*{fI 'l-\uc{`AdAt-i}}}.
  2074. % \end{quoting}
  2075. %
  2076. % \section{Arabic poetry}
  2077. % \label{sec:poetry}
  2078. % \NEWfeature{v1.6} \package{arabluatex} provides a special
  2079. % environment for typesetting Arabic poetry. Every line in this
  2080. % environment must end with |\\|.
  2081. %
  2082. % \DescribeEnv{arabverse} The |arabverse| environment may take up to
  2083. % six optional \enquote*{named arguments} each of which is set using
  2084. % the syntax \meta{key}$=$\meta{value}, like so:---%
  2085. % \iffalse
  2086. %<*example>
  2087. % \fi
  2088. \begin{arabluaverbatim}
  2089. \begin{arabverse}[key1=value1, key2=value2, ...]
  2090. <verses>
  2091. \end{arabverse}
  2092. \end{arabluaverbatim}
  2093. % \iffalse
  2094. %</example>
  2095. % \fi
  2096. %
  2097. % The description of the optional arguments follows:---
  2098. %
  2099. % \DescribeOption{mode} |mode|$=$\meta{mode}, either |voc|, |fullvoc|,
  2100. % |novoc| or |trans|. The default mode is the one that is set at load
  2101. % time as already seen \vref{sec:options}.
  2102. %
  2103. % \DescribeOption{width} |width|$=$\meta{length}
  2104. % \hfill\arabluaverb{Default: 0.3\linewidth}\\ The default width of
  2105. % each hemistich that the verse consists of. It may be expressed in
  2106. % any accepted unit of measurement, such as |4cm| or |2in|. However,
  2107. % one must keep in mind that the total length of the two hemistichs
  2108. % added to the one of the gutter that separates them must not exceed
  2109. % the length of the base line, unless one wishes to have the
  2110. % hemistichs distributed on subsequent lines.
  2111. %
  2112. % \DescribeOption{gutter} |gutter|$=$\meta{width}
  2113. % \hfill\arabluaverb{Default: 0.15 x (hemistich width)}\\ The gutter
  2114. % consists of the blank space that is between the two hemistichs. By
  2115. % default, it is commensurate with the width of the hemistich, but it
  2116. % may be expressed in any accepted unit of measurement as well.
  2117. %
  2118. % \DescribeOption{metre} |metre|$=$\meta{name}
  2119. % \hfill\arabluaverb{Default: none}\\ If the name of the metre is
  2120. % expressed, it is printed after the lines and set flush left in
  2121. % |voc|, |fullvoc| and |novoc| modes or flush right in |trans| mode.
  2122. %
  2123. % \DescribeOption{delim} |delim|$=$|true|\verb+|+|false|
  2124. % \hfill\arabluaverb{Default: false}\\ This named argument does not
  2125. % need a value as it defaults to |true| if it is used. If so, a
  2126. % delimiter is printed between each of the hemistichs. By default, it
  2127. % is set to the \enquote*{star} character \enquote*{*}. The
  2128. % \DescribeMacro{\SetHemistichDelim}\cs{SetHemistichDelim}\marg{delimiter}
  2129. % command may be used at any point of the document to change this
  2130. % default setting.
  2131. %
  2132. % \DescribeOption{utf} |utf|$=$|true|\verb+|+|false|
  2133. % \hfill\arabluaverb{Default: false}\\ As the preceding one, this
  2134. % named argument does not need a value as it defaults to |true| if it
  2135. % is used. If so, Unicode Arabic input is expected in the |arabverse|
  2136. % environment instead of \textsc{ascii} Arab\TeX\ or Buckwalter input
  2137. % schemes. See \vref{sec:unicode-input} for more details.
  2138. %
  2139. % \DescribeMacro{\bayt} Inside the |arabverse| environment, each line
  2140. % is typeset by the \cs{bayt} command which takes two mandatory
  2141. % arguments and may accept one optional argument. Additionally, every
  2142. % \cs{bayt} command \emph{must} be followed with |\\| like so:---%
  2143. % \iffalse
  2144. %<*example>
  2145. % \fi
  2146. \begin{arabluacode}[text only]
  2147. \cs{bayt}\marg{\arb[trans]{.sadr}}\oarg{\arb[trans]{tadwIr}}%
  2148. \marg{\arb[trans]{`ajuz}}|\\|
  2149. \end{arabluacode}
  2150. % \iffalse
  2151. %</example>
  2152. % \fi
  2153. %
  2154. % That two subsequent hemistichs should be connected with one another
  2155. % is technically named \arb[trans]{tadwIr}. Should that happen, either
  2156. % the \arb[trans]{.sadr} or the \arb[trans]{`ajuz} or both of them,
  2157. % may be connected to one another by letters that are naturally bound
  2158. % to the following or the preceding ones over the
  2159. % \arb[trans]{tadwIr}. The optional argument of the \cs{bayt} command
  2160. % is designed to deal with the various situations that may arise:---
  2161. % \begin{compactenum}[(a)]
  2162. % \item If the two hemistichs be connected with one another by a
  2163. % prominent horizontal flexible stroke, the \arb[trans]{ta.twIl} should
  2164. % be used, like so: |[--]| (see \vref{sec:tatwil}). Of course, the
  2165. % ending word of the \arb[trans]{.sadr} and the word at the
  2166. % commencement of the \arb[trans]{`a^guz} must have the
  2167. % \arb[trans]{ta.twIl} too so that the proper shapes of the letters be
  2168. % selected. Consider for example the following:---
  2169. % \iffalse
  2170. %<*example>
  2171. % \fi
  2172. \begin{arabluacode}
  2173. \begin{arabverse}[mode=fullvoc, width=.3\linewidth]
  2174. \bayt{lA 'ar_A man `ahidtu fI-hA fa-'abkI 'l---}[--]{---yawma
  2175. dalhaN wa-mA yaruddu 'l-bukA'u}\\
  2176. \end{arabverse}
  2177. \end{arabluacode}
  2178. % \iffalse
  2179. %</example>
  2180. % \fi%
  2181. % As one can see, \emph{triple hyphens} have been used. In the
  2182. % \arb[trans]{.sadr}, the first hyphen triggers the rules that are
  2183. % related to the definite article and the \arb[trans]{'alif-u
  2184. % 'l-wa.sl-i},\footnote{See \vref{ref:definite-article}} while the
  2185. % following two select the figure of the letter \arb[trans]{lAm}
  2186. % connected with a following letter. In the \arb[trans]{`a^guz}, the
  2187. % last two hyphens select the letter \arb[trans]{yA'} connected with a
  2188. % preceding letter, while the first one is simply discarded in this
  2189. % mode, but still may appear as it should, if the |trans| mode be
  2190. % selected:---%
  2191. % \iffalse
  2192. %<*example>
  2193. % \fi
  2194. \begin{arabluacode}
  2195. \begin{arabverse}[mode=trans, width=.4\linewidth]
  2196. \bayt{lA 'ar_A man `ahidtu fI-hA fa-'abkI 'l---}[--]{---yawma
  2197. dalhaN wa-mA yaruddu 'l-bukA'u}\\
  2198. \end{arabverse}
  2199. \end{arabluacode}
  2200. % \iffalse
  2201. %</example>
  2202. % \fi%
  2203. % \item In some other cases, it may seem difficult, if not fairly
  2204. % impossible, to split a given word into two parts. This happens
  2205. % mostly because of the \arb[trans]{^saddaT}. Consider for example
  2206. % the following:---
  2207. % \iffalse
  2208. %<*example>
  2209. % \fi
  2210. \begin{arabluacode}
  2211. \begin{arabverse}[mode=fullvoc, width=.25\linewidth, gutter=1cm]
  2212. \bayt{.gayra 'annI qad 'asta`Inu `al_A 'l-ha--}[--mmi ]{'i_dA
  2213. _haffa bi-'l-_tawiyyi 'l-na^gA'u}\\
  2214. \bayt{bi-zaf--UfiN ka-'anna-hA hiq--laTuN}[ 'ummu ]{ri'AliN
  2215. dawwiyyaTuN saqfA'u}\\
  2216. \end{arabverse}
  2217. \end{arabluacode}
  2218. % \iffalse
  2219. %</example>
  2220. % \fi%
  2221. % In the first line, the word \arb{al-hammi} should be split into
  2222. % \arb{al-ham"-- --mi} as the first part of it belongs to the
  2223. % \arb[trans]{.sadr} and the second to the \arb[trans]{`a^guz}. One
  2224. % solution to avoid splitting this word in such a way is to write
  2225. % inside the \arb[trans]{tadwIr} the part of it that belongs to either
  2226. % hemistich, without omitting to add a space after it. In the second
  2227. % line, the word \arb{'ummu} should be split into \arb{'um"-- --mu},
  2228. % so that the only way to avoid splitting it into two parts is to
  2229. % write it all inside the \arb[trans]{tadwIr}. In that case, as the
  2230. % word is to be placed in the middle, it has been surrounded by
  2231. % spaces.
  2232. % \end{compactenum}
  2233. %
  2234. % \paragraph{Scaling and distortion of characters}
  2235. % The |arabverse| environment and the \cs{bayt} command are designed
  2236. % to typeset the verses in a two-column, fixed width layout. This may
  2237. % result in a somewhat distorted text. Should that happen, one may
  2238. % adapt the layout by modifying the values of the above described
  2239. % |width| and |gutter| named arguments until the visual aspect of the
  2240. % layout be satisfactory. It has to be noted that distortion and
  2241. % warping may be even more perceptible in Roman than in Arabic
  2242. % characters.
  2243. %
  2244. % \paragraph{Footnotes}
  2245. % Footnotes are not set by default inside the \cs{bayt} command, but
  2246. % there are two easy ways to have them printed.
  2247. %
  2248. % If they are little in number, each footnote may be split into pairs
  2249. % of \cs{footnote\allowbreak{}mark}|{}| (please mind the braces) in
  2250. % the argument of the \cs{bayt} command and \cs{footnotetext} outside
  2251. % the \cs{bayt} command.
  2252. %
  2253. % If the footnotes are abundant in number, it is advised to load the
  2254. % \package{footnotehyper} package which \package{arabluatex} will then
  2255. % use to typeset any kind of footnote that is called from the
  2256. % arguments of the \cs{bayt} command.\footnote{The \package{footnote}
  2257. % package can also be used for the same effect. However, it must be
  2258. % loaded \emph{after} \package{arabluatex}.}
  2259. %
  2260. % \paragraph{Line numbering}
  2261. % Inside the |arabverse| environment, the |linenumbers| environment of
  2262. % the \package{lineno} package can be used to have the lines of
  2263. % succeeding verses numbered. Please refer to the documentation of
  2264. % this package for more information or to the example below for a
  2265. % basic implementation of this technique.
  2266. %
  2267. % \subsection{Example}
  2268. % \label{sec:poetry-example}
  2269. % Here follow the first lines of \arb[trans]{\upshape{}\uc{i}mru'u
  2270. % 'l-\uc{q}aysi}'s \arb[trans]{\uc{m}u`allaqaT}. In this example,
  2271. % \cs{SetArbDflt*} has been selected so as to mark the
  2272. % \arb[trans]{'id.gAm} that is fit to this declamatory
  2273. % poetry:---\footnote{Please note that for the time being only the
  2274. % assimilation rules that are laid on \vref{ref:assimilation} are
  2275. % applied. See \vref{sec:classic-modern-typesetting} for more
  2276. % information. None of the editions of the
  2277. % \arb[trans]{\uc{M}u`allaqAt} that I know of feature the
  2278. % \arb[trans]{'id.gAm} in the Arabic text, although it is often
  2279. % strongly marked in declamation.}%
  2280. % \iffalse
  2281. %<*example>
  2282. % \fi
  2283. \begin{arabluaverbatim}
  2284. \begin{arab}[fullvoc]
  2285. qAla \uc{i}mru'u 'l-\uc{q}aysi fI mu`allaqati-hi:
  2286. \end{arab}
  2287. \begin{arabverse}[mode=fullvoc, metre={(al-.darbu 'l-_tAnI mina
  2288. 'l-`arU.di 'l-'_Ul_A mina 'l-.tawIli)}]
  2289. \SetArbDflt*
  2290. \begin{linenumbers*}
  2291. \bayt{qifA nabki min _dikr_A .habIbiN wa-manzili}{bi-saq.ti
  2292. 'l-liw_A bayna \uc{'l-d}a_hUli fa-\uc{.h}awmali}\\
  2293. \bayt{fa-\uc{t}U.di.ha fa-'l-\uc{m}iqrATi lam ya`fu
  2294. rasmu-hA}{limA nasa^gat-hA min ^ganUbiN wa-^sam'ali}\\
  2295. \bayt{tar_A ba`ara 'l-'ar'Ami fI `ara.sAti-hA}{wa-qI`Ani-hA
  2296. ka-'anna-hu .habbu fulfuli}\\
  2297. \bayt{ka-'annI .gadATa 'l-bayni yawma ta.hammalUA}{lad_A
  2298. samurAti 'l-.hayyi nAqifu .han.zali}\\
  2299. \bayt{wuqUfaN bi-hA .sa.hbI `alayya ma.tiyya-hum}{yaqUlUna lA
  2300. tahlik 'asaN_A wa-ta^gammali}\\
  2301. \bayt{wa-'inna ^sifA'I `abraTuN muharAqaTuN}{fa-hal `inda rasmiN
  2302. dAsiriN min mu`awwali}\\
  2303. \end{linenumbers*}
  2304. \end{arabverse}
  2305. \end{arabluaverbatim}
  2306. % \iffalse
  2307. %</example>
  2308. % \fi%
  2309. % \begin{arab}[fullvoc]
  2310. % qAla \uc{i}mru'u 'l-\uc{q}aysi fI mu`allaqati-hi:
  2311. % \end{arab}
  2312. %
  2313. % \begin{arabverse}[mode=fullvoc, metre={(al-.darbu 'l-_tAnI mina
  2314. % 'l-`arU.di 'l-'_Ul_A mina 'l-.tawIli)}, width=.25\linewidth]
  2315. % \SetArbDflt*
  2316. % \begin{linenumbers*}
  2317. % \bayt{qifA nabki min _dikr_A .habIbiN wa-manzili}{bi-saq.ti
  2318. % 'l-liw_A bayna \uc{'l-d}a_hUli fa-\uc{.h}awmali}\\
  2319. % \bayt{fa-\uc{t}U.di.ha fa-'l-\uc{m}iqrATi lam ya`fu
  2320. % rasmu-hA}{limA nasa^gat-hA min ^ganUbiN wa-^sam'ali}\\
  2321. % \bayt{tar_A ba`ara 'l-'ar'Ami fI `ara.sAti-hA}{wa-qI`Ani-hA
  2322. % ka-'anna-hu .habbu fulfuli}\\
  2323. % \bayt{ka-'annI .gadATa 'l-bayni yawma ta.hammalUA}{lad_A
  2324. % samurAti
  2325. % 'l-.hayyi nAqifu .han.zali}\\
  2326. % \bayt{wuqUfaN bi-hA .sa.hbI `alayya ma.tiyya-hum}{yaqUlUna lA
  2327. % tahlik 'asaN_A wa-ta^gammali}\\
  2328. % \bayt{wa-'inna ^sifA'I `abraTuN muharAqaTuN}{fa-hal `inda rasmiN
  2329. % dAsiriN min mu`awwali}\\
  2330. % \end{linenumbers*}
  2331. % \end{arabverse}
  2332. %
  2333. % \medskip
  2334. %
  2335. % \begin{arab}[trans]
  2336. % qAla \uc{i}mru'u 'l-\uc{q}aysi fI mu`allaqati-hi:
  2337. % \end{arab}
  2338. %
  2339. % \begin{arabverse}[mode=trans, metre={(al-.darbu 'l-_tAnI mina
  2340. % 'l-`arU.di 'l-'_Ul_A mina 'l-.tawIli)}, width=.4\linewidth]
  2341. % \SetArbDflt*
  2342. % \begin{linenumbers*}
  2343. % \bayt{qifA nabki min _dikr_A .habIbiN wa-manzili}{bi-saq.ti
  2344. % 'l-liw_A bayna \uc{'l-d}a_hUli fa-\uc{.h}awmali}\\
  2345. % \bayt{fa-\uc{t}U.di.ha fa-'l-\uc{m}iqrATi lam ya`fu
  2346. % rasmu-hA}{limA nasa^gat-hA min ^ganUbiN wa-^sam'ali}\\
  2347. % \bayt{tar_A ba`ara 'l-'ar'Ami fI `ara.sAti-hA}{wa-qI`Ani-hA
  2348. % ka-'anna-hu .habbu fulfuli}\\
  2349. % \bayt{ka-'annI .gadATa 'l-bayni yawma ta.hammalUA}{lad_A
  2350. % samurAti
  2351. % 'l-.hayyi nAqifu .han.zali}\\
  2352. % \bayt{wuqUfaN bi-hA .sa.hbI `alayya ma.tiyya-hum}{yaqUlUna lA
  2353. % tahlik 'asaN_A wa-ta^gammali}\\
  2354. % \bayt{wa-'inna ^sifA'I `abraTuN muharAqaTuN}{fa-hal `inda rasmiN
  2355. % dAsiriN min mu`awwali}\\
  2356. % \end{linenumbers*}
  2357. % \end{arabverse}
  2358. %
  2359. % \section{Special applications}
  2360. % \label{sec:special-applications}
  2361. % \paragraph{Linguistics}
  2362. % The same horizontal stroke as the \arb[trans]{ta.twIl} (see
  2363. % \vref{sec:tatwil}) may be encoded \meta{B}; \meta{BB} will receive
  2364. % the \arb[trans]{ta^sdId}. This is useful to make linguistic
  2365. % annotations and comments on vowels:---
  2366. % \begin{quote}
  2367. % |Bu| |Ba| |Bi| |BuN| |BaN| |BiN| \arb[voc]{Bu Ba Bi BuN BaN BiN}
  2368. % \arb[trans]{Bu Ba Bi BuN BaN BiN}, |BBu| |BBa| |BBi| \arb[voc]{BBu
  2369. % BBa BBi} \arb[trans]{BBu BBa BBi}, |B--aN| \arb[voc]{B--aN}
  2370. % \arb[trans]{B--aN}, |B"| \arb[voc]{B"}\,.
  2371. % \end{quote}
  2372. %
  2373. % \paragraph{Brackets}
  2374. % \NEWfeature{v1.4.3} The various bracket symbols are useful in
  2375. % technical documents such as critical editions for indicating that
  2376. % some words or some letters must be added or
  2377. % removed. \package{arabluatex} will automatically fit those symbols
  2378. % to the direction of the text. For the time being, the following
  2379. % symbols are supported:
  2380. % \begin{compactitem}
  2381. % \item parentheses: |()|
  2382. % \item square brackets: |[]|
  2383. % \item angle brackets: |<>|
  2384. % \item braces: |{}|
  2385. % \end{compactitem}
  2386. %
  2387. % \DescribeMacro{\abraces} Parentheses, square and angle brackets may
  2388. % be input directly at the keyboard; however, words or letters that
  2389. % are to be read between braces must be passed as arguments to the
  2390. % \cs{abraces} command:---%
  2391. % \iffalse
  2392. %<*example>
  2393. % \fi
  2394. \begin{arabluacode}
  2395. \begin{arab}
  2396. \abraces{wa-qAla} 'inna 'abI kAna mina 'l-muqAtilaTi
  2397. wa-kAna--<--t> 'ummI min `u.zamA'i buyUti 'l-zamAzimaTi.
  2398. \end{arab}
  2399. \end{arabluacode}
  2400. % \iffalse
  2401. %</example>
  2402. % \fi
  2403. %
  2404. % \paragraph{Additional Arabic marks}
  2405. % In addition to common letters, many symbols and ligatures are
  2406. % encoded in Arabic Unicode standard, such as honorifics consisting of
  2407. % complex ligatures, and annotation signs used in the
  2408. % \arb[trans]{\uc{qur'An}} or in classical poetry.
  2409. %
  2410. % \DescribeMacro{\arbmark}
  2411. % \NEWfeature{v1.11}\cs{arbmark}\marg{shorthand} can be used to insert
  2412. % such characters either in Unicode or in romanized Arabic
  2413. % environments. It takes as argument a shorthand defined beforehand in
  2414. % a default list which consists of the following
  2415. % at the time of writing:---\\
  2416. % \begin{longtable}{llp{.3\linewidth}p{.3\linewidth}}
  2417. % \captionlistentry{Additional Arabic marks}\\[-1em]
  2418. % \toprule
  2419. % Codepoint & Shorthand & Glyph & Transliteration \\ \midrule
  2420. % \endfirsthead
  2421. % \toprule
  2422. % Codepoint & Shorthand & Glyph & Transliteration \\ \midrule
  2423. % \endhead\label{tab:arabtex-additional-marks}%
  2424. % |FDFD| & |bismillah| & \arb{\arbmark{bismillah}} &
  2425. % \arbmark{bismillah} \\
  2426. % |FDF5| & |salam| & \arb{\arbmark{salam}} & \arbmark{salam} \\
  2427. % |FDFA| & |slm| & \arb{\arbmark{slm}} & \arbmark{slm} \\
  2428. % |FDFB| & |jalla| & \arb{\arbmark{jalla}} & \arbmark{jalla} \\
  2429. % \bottomrule
  2430. % \caption*{\Cref*{tab:arabtex-additional-marks}: Additional Arabic
  2431. % marks}
  2432. % \end{longtable}
  2433. %
  2434. % \DescribeMacro{\newarbmark} \NEWfeature{v1.11} \cs{newarbmark} is
  2435. % also provided should one wish to define new marks in addition to the
  2436. % marks defined above. This command takes three arguments, like so:---
  2437. % \arabluabox{\cs{newarbmark}\marg{shorthand}\marg{RTL
  2438. % codepoint}\marg{LTR rendition}}.
  2439. %
  2440. % As regards the right-to-left codepoint, it may be either typed in
  2441. % Unicode or selected as Unicode codepoint. To that end, the \LaTeX\
  2442. % command \arabluaverb{\symbol{"XYZT}} or its plain \TeX\ variant
  2443. % \arabluaverb{\char"XYZT\relax} may be used, where |XYZT| are
  2444. % uppercase hex digits (|0| to |9| or |A| to |F|).
  2445. %
  2446. % It is also possible to use the so-called `|^^^^| notation' like so:
  2447. % \arabluaverb{^^^^xyzt}, where |xyzt| are lowercase hex digits (|0|
  2448. % to |9| or |a| to |f|).
  2449. %
  2450. % As regards the third argument (left-to-right rendition), it may be
  2451. % either left empty or typed by means of
  2452. % \cs{arb}|[trans]|\marg{arabtex code} so as to have it printed in
  2453. % romanized Arabic.%
  2454. % \iffalse
  2455. %<*example>
  2456. % \fi
  2457. \begin{arabluacode}[text only]
  2458. It must be noted that \cs{newarbmark} expects Arab\TeX\ input scheme
  2459. inside \cs{arb}|[trans]{}| to the exclusion of \textsf{buckwalter}
  2460. input scheme.
  2461. \end{arabluacode}
  2462. % \iffalse
  2463. %</example>
  2464. % \fi%
  2465. %
  2466. % The example below provides an implementation of this technique. It
  2467. % may be observed that \cs{textcolor} is used so as to have the marks
  2468. % printed in red:---%
  2469. % \iffalse
  2470. %<*example>
  2471. % \fi
  2472. \begin{arabluacode}
  2473. \SetArbDflt*
  2474. \newarbmark{sly}{\textcolor{red}{^^^^06d6}}{}
  2475. \newarbmark{jim}{\textcolor{red}{^^^^06da}}{}
  2476. \begin{arab}
  2477. sUraTu 'l-nisA'i, 19:
  2478. \end{arab}
  2479. \begin{center}
  2480. \begin{arab}
  2481. \arbmark{bismillah}
  2482. \end{arab}
  2483. \end{center}
  2484. \begin{arab}[fullvoc]
  2485. y_a'ayyuhA 'lla_dIna 'a'manUA lA ya.hillu la-kum 'an tari_tUA
  2486. 'l-nisA'a karhaN\arbmark{sly} wa-lA ta`.dulU-hunna li-ta_dhabUA
  2487. bi-ba`.di mA 'a'taytumU-hunna 'illA 'an ya'tIna bi-fA.hi^saTiN
  2488. mubayyinaTiN\arbmark{jim} wa-`A^sirU-hunna
  2489. bi-'l-ma`rUfi\arbmark{jim} fa-'in karihtumU-hunna fa-`as_A_a
  2490. 'an takrahUA ^say'aN wa-ya^g`ala 'l-l_ahu fI-hi _hayraN
  2491. ka_tIraN ((19))
  2492. \end{arab}
  2493. \end{arabluacode}
  2494. % \iffalse
  2495. %</example>
  2496. % \fi
  2497. %
  2498. % \section{Transliteration}
  2499. % \label{sec:transliteration}
  2500. % It may be more appropriate to speak of \enquote{romanization} than
  2501. % \enquote{transliteration} of Arabic. As seen above in
  2502. % \cref{sec:options} \vpagerefrange{sec:options}{sec:local-options},
  2503. % the \enquote{transliteration mode} may be selected globally or locally.
  2504. %
  2505. % This mode transliterates the Arab\TeX\ input into one of the
  2506. % accepted standards. As said above \vpageref{ref:describe-trans},
  2507. % three standards are supported at present:
  2508. % \begin{compactdesc}
  2509. % \item[dmg] \emph{Deutsche Morgenländische Gesellschaft}, which was
  2510. % adopted by the International Convention of Orientalist Scholars in
  2511. % Rome in 1935.\footnote{See \textcite{dmg}.} |dmg| transliteration
  2512. % convention is selected by default;
  2513. % \item[loc] \emph{Library of Congress}: this standard is part of a
  2514. % large set of standards for romanization of non-roman scripts
  2515. % adopted by the American Library Association and the Library of
  2516. % Congress;\footnote{See
  2517. % \url{http://www.loc.gov/catdir/cpso/roman.html} for the
  2518. % \href{http://www.loc.gov/catdir/cpso/romanization/arabic.pdf}{source
  2519. % document concerning Arabic language}.}
  2520. % \item[arabica] \NEWfeature{v1.8}
  2521. % \changes{v1.8}{2017/03/30}{\texttt{arabica} transliteration
  2522. % standard is now supported} \emph{Journal of Arabic and Islamic
  2523. % Studies}/\emph{Revue d'études arabes et islamiques}: this standard
  2524. % is most widely used by scholars in the field of Arabic
  2525. % studies.\footnote{See
  2526. % \url{http://www.brill.nl/files/brill.nl/specific/authors_instructions/ARAB.pdf}.}
  2527. % \end{compactdesc}
  2528. % More standards will be included in future releases of
  2529. % \package{arabluatex}.
  2530. %
  2531. % \paragraph{Convention} \DescribeMacro{\SetTranslitConvention} The
  2532. % transliteration mode, which is set to |dmg| by default, may be
  2533. % changed at any point of the document by the
  2534. % \cs{SetTranslitConvention}\marg{mode} command , where \meta{mode}
  2535. % may be either |dmg|, |loc| or |arabica|. This command is also
  2536. % accepted in the preamble should one wish to set the transliteration
  2537. % mode globally, eg.:---%
  2538. % \iffalse
  2539. %<*example>
  2540. % \fi
  2541. \begin{arabluaverbatim}
  2542. \usepackage{arabluatex}
  2543. \SetTranslitConvention{loc}
  2544. \end{arabluaverbatim}
  2545. % \iffalse
  2546. %</example>
  2547. % \fi
  2548. %
  2549. % \paragraph{Style} \DescribeMacro{\SetTranslitStyle} Any
  2550. % transliterated Arabic text is printed in italics by default. This
  2551. % also can be changed either globally in the preamble or locally at
  2552. % any point of the document by the \cs{SetTranslitStyle}\marg{style}
  2553. % command, where \meta{style} may be any font shape selection
  2554. % command, eg. \cs{upshape}, \cs{itshape}, \cs{slshape}, and so forth.
  2555. %
  2556. % \paragraph{Font} \NEWfeature{v1.4} \DescribeMacro{\SetTranslitFont}
  2557. % \cs{SetTranslitFont}\marg{font selection command} allows any
  2558. % specific font to be selected for rendering transliterated text with
  2559. % the font-selecting commands of the \package{fontspec} or
  2560. % \package{luaotfload} package. Of course, this font must have been
  2561. % defined properly. To take one example, here is how the \emph{Gentium
  2562. % Plus} font can be used for rendering transliterated text:---
  2563. % \iffalse
  2564. %<*example>
  2565. % \fi
  2566. \begin{arabluaverbatim}
  2567. \newfontfamily\translitfont{Gentium Plus}[Ligatures=TeX]
  2568. \SetTranslitFont{\translitfont}
  2569. \end{arabluaverbatim}
  2570. % \iffalse
  2571. %</example>
  2572. % \fi
  2573. %
  2574. % \paragraph{Proper names} \DescribeMacro{\uc} Proper names or book
  2575. % titles that must have their first letters uppercased may be passed
  2576. % as arguments to the \cs{uc}\marg{word} command. \cs{uc} is a
  2577. % clever command, for it will give the definite article
  2578. % \arb[trans]{al-} in lower case in all positions. Moreover, if the
  2579. % inital letter, apart from the article, cannot be uppercased,
  2580. % viz. \arb[trans]{|"'} or \arb[trans]{`}, the letter next to it will be
  2581. % uppercased:---
  2582. % \begin{quote}
  2583. % |\uc{.hunayn-u}| |bn-u| |\uc{'is.h_aq-a}|
  2584. % \arb[voc]{\uc{.hunayn-u} bn-u \uc{'is.h_aq-a}}
  2585. % \arb[trans]{\uc{.hunayn-u} bn-u \uc{'is.h_aq-a}},
  2586. % |\uc{`u_tm_an-u}| \arb[voc]{\uc{`u_tm_an-u}}
  2587. % \arb[trans]{\uc{`u_tm_an-u}}, |.daraba| |\uc{zayd-u}| |bn-u|
  2588. % |\uc{_h_alidiN}| |\uc{sa`d-a}| |bn-a| |\uc{`awf-i}| |bn-i|
  2589. % |\uc{|\allowbreak|`abd-i}| |\uc{'l-l_ah-i}|
  2590. % \arb[fullvoc]{.daraba \uc{zayd-u} bn-u \uc{_h_alidiN}
  2591. % \uc{sa`d-a} bn-a \uc{`awf-i} bn-i \uc{`abd-i} \uc{'l-l_ah-i}}
  2592. % \arb[trans]{.daraba \uc{zayd-u} bn-u \uc{_h_alidiN} \uc{sa`d-a}
  2593. % bn-a \uc{`awf-i} bn-i \uc{`abd-i} \uc{'l-l_ah-i}}.
  2594. % \end{quote}
  2595. % However, \cs{uc} must be used cautiously in some very particular
  2596. % cases, for the closing brace of its argument may prevent a rule from
  2597. % being applied. To take an example, as seen above
  2598. % \vpageref{ref:muhammaduni}, the transliteration of
  2599. % \arb[fullvoc]{\uc{m}u.hammaduN 'l-nabI} must be
  2600. % \arb[trans]{\uc{m}u.hammaduN 'l-nabI}, as nouns having the
  2601. % \arb[trans]{tanwIn} take a \arb[trans]{kasraT} in pronunciation
  2602. % before \arb[trans]{'alifu 'l-wa.sli}. In that case, encoding
  2603. % \arb[fullvoc]{mu.hammaduN} like so: |\uc{mu.hammaduN}| is wrong,
  2604. % because the closing brace would prevent \package{arabluatex} from
  2605. % detecting the sequence \meta{-uN} immediately followed by
  2606. % \meta{'l-}. Fortunately, this can be circumvented in a
  2607. % straightforward way by inserting only part of the noun in the
  2608. % argument of \cs{uc} vz. up to the first letter that is to be
  2609. % uppercased, like so: |\uc{m}u.hammaduN|.
  2610. %
  2611. % \paragraph{Hyphenation}
  2612. % In case transliterated Arabic words break the \TeX\ hyphenation
  2613. % algorithm, one may use the |\-| command to insert discretionary
  2614. % hyphens. This command will be discarded in all of the Arabic modes
  2615. % of \package{arabluatex}, but will be processed by any of the
  2616. % transliteration modes:---
  2617. % \begin{quote}
  2618. % |\uc{'abU}| |\uc{bakriN}| |\uc{mu\-.ham\-madu}| |bnu|
  2619. % |\uc{za\-ka| |\-riy\-yA'a}| |\uc{'l-rAziyyu}| \arb{\uc{'abU}
  2620. % \uc{bakriN} \uc{mu\-.ham\-mad-u} bnu \uc{za\-ka\-riy\-yA'a}
  2621. % \uc{'l-rAziyyu}} \arb[trans]{\uc{'abU} \uc{bakriN}
  2622. % \uc{mu\-.ham\-mad-u} bn-u \uc{za\-ka\-riy\-yA'-a}
  2623. % \uc{'l-rAziyyu}}.
  2624. % \end{quote}
  2625. %
  2626. % \paragraph{\enquote*{Long} proper names}
  2627. % \NEWfeature{v1.10} \cs{uc} is also able to process proper names
  2628. % consisting of several subsequent words:---
  2629. % \begin{quote}
  2630. % |\arb[trans]{\uc{'abU| |zaydiN| |.hunaynu| |bnu| |'is.h_aqa|
  2631. % |'l-`ibAdiyyu}}| \arb[trans]{\uc{'abU zaydiN .hunaynu bnu
  2632. % 'is.h_aqa 'l-`ibAdiyyu}}.
  2633. % \end{quote}
  2634. %
  2635. % \paragraph{Proper names outside Arabic environments}
  2636. % \changes{v1.10}{2018/01/03}{\cs{uc} supersedes \cs{cap}}
  2637. % \DescribeMacro{\prname}\NEWfeature{v1.10} Transliterated proper
  2638. % names inserted in paragraphs of English text should be printed in
  2639. % the same typeface as the surrounding text. \cs{prname}\marg{Arabic
  2640. % proper name} is provided to that effect:\footnote{Just as \cs{uc},
  2641. % \cs{prname} is also able to process proper names consisting of
  2642. % several subsequent words.}---
  2643. %\iffalse
  2644. %<*example>
  2645. % \fi
  2646. \begin{arabluacode}
  2647. From \textcite[i. 23 C]{Wright}:--- If the name following
  2648. \arb[fullvoc]{ibnuN} be that of the mother or the grandfather, the
  2649. \arb[fullvoc]{"a} is retained; as \arb[fullvoc]{`Is_A ibnu maryama},
  2650. \enquote{Jesus the son of Mary}; \arb[fullvoc]{`ammAru ibnu
  2651. man.sUriN}, \enquote{\prname{`ammAr} the (grand)son of
  2652. \prname{man.sUr}}.
  2653. \end{arabluacode}
  2654. % \iffalse
  2655. %</example>
  2656. % \fi
  2657. %
  2658. % The following example shows how \cs{prname} can be used in
  2659. % conjunction with the \package{nameauth} package to have Arabic
  2660. % proper names printed first in full then in partial
  2661. % forms:\footnote{See the documentation of \package{nameauth} for more
  2662. % details: \url{https://ctan.org/pkg/nameauth}}--- %
  2663. %\iffalse
  2664. %<*example>
  2665. % \fi
  2666. \begin{arabluacode}
  2667. \begin{nameauth}
  2668. \< Hunayn & \prname{'abU zayd} & \prname{.hunayn}, \prname{{i}bn
  2669. 'is.h_aq al-`ibAdiyy} & > %
  2670. \< Razi & \prname{'abU bakr mu.hammad ibn zakariyyA'} &
  2671. \prname{al-rAziyy} & > %
  2672. \end{nameauth}
  2673. On first occurrence, proper names are printed as \Hunayn, \Razi.
  2674. Then as \Hunayn, \Razi.
  2675. \end{arabluacode}
  2676. % \iffalse
  2677. %</example>
  2678. % \fi
  2679. %
  2680. % \subsection{Additional note on \texttt{dmg} convention}
  2681. % \label{sec:additional-note-dmg}
  2682. % \NEWfeature{v1.3} According to \textcite[6]{dmg}, Arabic
  2683. % \arb[trans]{'i`rAb} may be rendered into |dmg| in three different
  2684. % ways:
  2685. % \begin{compactenum}[(a)]
  2686. % \item \label{ref:dmg-full-rend}In full:
  2687. % \NoArbUp\arb[trans]{\uc{`amruNU}}\ArbUpDflt\,;
  2688. % \item \label{ref:dmg-up-rend}As superscript text:
  2689. % \arb[trans]{\uc{`amruNU}}\,;
  2690. % \item \label{ref:irab-discarded}Discarded: \arb[trans]{\uc{`amr}}.
  2691. % \end{compactenum}
  2692. % \DescribeMacro{\arbup} By default, \package{arabluatex} applies rule
  2693. % \ref{ref:dmg-up-rend}. Once delimited by a set of Lua functions,
  2694. % \arb[trans]{'i`rAb} is passed as an argument on to a \cs{arbup}
  2695. % command which is set to \cs{textsuperscript}.
  2696. %
  2697. % \DescribeMacro{\NoArbUp} \DescribeMacro{\ArbUpDflt} \cs{NoArbUp} may
  2698. % be used either in the preamble or at any point of the document in
  2699. % case one wishes to apply rule \ref{ref:dmg-full-rend}. The default
  2700. % rule \ref{ref:dmg-up-rend} can be set back with \cs{ArbUpDflt} at
  2701. % any point of the document.
  2702. %
  2703. % \DescribeMacro{\SetArbUp} Finally, \cs{SetArbUp}\marg{formatting
  2704. % directives} can be used to customize the way \arb[trans]{'i`rAb} is
  2705. % displayed. To take one example, here is how Arabic
  2706. % \arb[trans]{'i`rAb} may be rendered as subscript text:---
  2707. % \iffalse
  2708. %<*example>
  2709. % \fi
  2710. \begin{arabluacode}
  2711. \SetArbUp{\textsubscript{#1}}
  2712. Arabic |dmg| transliteration for \arb{ra'aytu ^gAmi`aN
  2713. muhaddamaTaN mi'_danatu-hu}: \arb[trans]{ra'aytu
  2714. ^gAmi`aN muhaddamaTaN mi'_danatu-hu.}
  2715. \end{arabluacode}
  2716. % \iffalse
  2717. %</example>
  2718. % \fi
  2719. %
  2720. % As shown in the above example, |#1| is the token that is replaced
  2721. % with the actual \arb[trans]{tanwIn} in the formatting directives of
  2722. % the \cs{SetArbUp} command.
  2723. %
  2724. % \paragraph{\arb[trans]{'i`rAb} boundaries}
  2725. % Every declinable noun (\arb[trans]{mu`rab}) may be declined either
  2726. % with or without \arb[trans]{tanwIn}, viz. \arb[trans]{mun.sarifuN}
  2727. % or \arb[trans]{.gayr-u mun.sarifiN}. The former is automatically
  2728. % parsed by \package{arabluatex}, whereas the latter has to be
  2729. % delimited with an hyphen, like so:---
  2730. % \begin{quote}
  2731. % \arb[trans]{\textbf{mun.sarif}}: |mu`allimuN|
  2732. % \arb[voc]{mu`allimuN} \arb[trans]{mu`allimuN}, |kA'inuN|
  2733. % \arb[voc]{kA'inuN} \arb[trans]{kA'inuN}, |kA'inAtuN|
  2734. % \arb[voc]{kA'inAtuN} \arb[trans]{kA'inAtuN}, |\uc{`amraNU}|
  2735. % \arb[voc]{\uc{`amraNU}} \arb[trans]{\uc{`amraNU}}, |fataN_A|
  2736. % \arb[voc]{fataN_A} \arb[trans]{fataN_A}, |qA.diNI| \arb{qA.diNI}
  2737. % \arb[trans]{qA.diNI}.
  2738. %
  2739. % \arb[trans]{\textbf{.gayr mun.sarif}}: |al-mu`allim-u|
  2740. % \arb[voc]{al-mu`allim-u} \arb[trans]{al-mu`allim-u}, |kitAb-Ani|
  2741. % \arb[voc]{kitAb-Ani} \arb[trans]{kitAb-Ani}, |ra^sa'-Ani|
  2742. % \arb[voc]{ra^sa'-Ani} \arb[trans]{ra^sa'-Ani}, |sAriq-Una|
  2743. % \arb[voc]{sAriq-Una} \arb[trans]{sAriq-Una}, |qA.d-Una|
  2744. % \arb[voc]{qA.d-Una} \arb[trans]{qA.d-Una}, |al-.zulm-Atu|
  2745. % \arb[voc]{al-.zulm-Atu} \arb[trans]{al-.zulm-Atu}.
  2746. % \end{quote}
  2747. %
  2748. % \begin{quoting}
  2749. % \textsc{Rem.}~\emph{a.} As the \arb[trans]{tanwIn} is passed over
  2750. % in pronunciation when it is followed by the letters
  2751. % \arb[novoc]{r}, \arb[novoc]{l}, \arb[novoc]{m}, \arb[novoc]{w},
  2752. % \arb[novoc]{y} (see \vref{ref:assimilation}), it may be desirable
  2753. % to further distinguish it by putting it above the line, but not to
  2754. % do the same for \arb[trans]{.gayr mun.sarif} terminations. This
  2755. % can be achieved by simply omitting the hyphen before any
  2756. % \arb[trans]{.gayr mun.sarif} termination:---\\
  2757. % |kAna| |.ganiyyaN| |l_akinna-hu| |labisa| |^gubbaTaN| |mumazzaqaN|
  2758. % |'aydu-hA| \arb[voc]{kAna .ganiyyaN l_akinna-hu labisa ^gubbaTaN
  2759. % mumazzaqaN 'aydu-hA} \arb[trans]{kAna .ganiyyaN l_akinna-hu labisa
  2760. % ^gubbaTaN mumazzaqaN 'aydu-hA}.
  2761. %
  2762. % \textsc{Rem.}~\emph{b.} Although the hyphen before the
  2763. % \arb[trans]{tanwIn} is optional as \package{arabluatex} always
  2764. % parses nouns with such termination, it may also be used to mark
  2765. % better the inflectional endings:---\\
  2766. % |mana`a| |'l-nAs-a| |kAffaT-aN| |min| |mu_hA.tabati-hi|
  2767. % |'a.had-uN| |bi-sayyidi-nA| \arb[voc]{mana`a 'l-nAs-a kAffaT-aN
  2768. % min mu_hA.tabati-hi 'a.had-uN bi-sayyidi-nA} \arb[trans]{mana`a
  2769. % 'l-nAs-a kAffaT-aN min mu_hA.tabati-hi 'a.had-uN bi-sayyidi-nA}.
  2770. % \end{quoting}
  2771. %
  2772. % \paragraph{Discarding the \arb[trans]{'i`rAb}}
  2773. % As said above (\vref{ref:irab-discarded}), the \arb[trans]{'i`rAb}
  2774. % may be discarded in some cases, as in transliterated proper names or
  2775. % book titles. \package{arabluatex} is able to render words ending
  2776. % with \arb[trans]{tA' marbU.taT} in different ways, depending on
  2777. % their function:---
  2778. % \begin{compactenum}[(a)]
  2779. % \item Nouns followed by an adjective in apposition: |madInaT|
  2780. % |kabIraT| \arb[trans]{madInaT kabIraT}, |al-madInaT| |al-kabIraT|
  2781. % \arb[trans]{al-madInaT al-kabIraT}.
  2782. % \item Nouns followed by another noun in the genitive (contruct
  2783. % state): |.hikmaT| |al-l_ah| \arb[trans]{.hikmaT| \uc{al-l_ah}},
  2784. % |fi.d.daT| |al-darAhim| \arb[trans]{fi.d.daT al-darAhim}.
  2785. % \end{compactenum}
  2786. % \begin{quoting}
  2787. % \textsc{Rem.} It may so happen, as in the absence of the article
  2788. % before the annexed word, that \package{arabluatex} be unable to
  2789. % determine which of the above two cases the word ending with
  2790. % \arb[trans]{tA' marbU.taT} falls into. The \enquote*{pipe}
  2791. % character (see \vref{sec:pipe}) may be appended to that word to
  2792. % indicate that what follows is in the construct state:
  2793. % |\uc{r}isAlaT| |fI| |tartIb| \verb+qirA'aT|+ |kutub|
  2794. % |\uc{^g}AlInUs| \arb[trans]{\uc{r}isAlaT fI tartIb qirA'aT|
  2795. % kutub \uc{^g}AlInUs}.
  2796. % \end{quoting}
  2797. %
  2798. %
  2799. % \paragraph{Uncertain short vowels}
  2800. % In some printed books, it may happen that more than one short vowel
  2801. % be placed on a consonant in cases where the vocalization is
  2802. % uncertain or ambiguous, like so: \arb[voc]{fa`uaila}. In
  2803. % transliteration, the uncertain vowels go between slashes and are
  2804. % separated by commas: |fa`uaila| \arb[voc]{fa`uaila}
  2805. % \arb[trans]{fa`uaila}.
  2806. %
  2807. % \subsection{Examples}
  2808. % \label{sec:examples-translit}
  2809. % Here follows in transliteration the story of
  2810. % \arb[trans]{\uc{ju.hA}} and his donkey (\arb[voc]{\uc{ju.hA
  2811. % wa-.himAru-hu}}). See the code \vpageref{ref:juha-code}:---
  2812. %
  2813. % \SetTranslitConvention{dmg}
  2814. % \begin{arab}[trans]
  2815. % \LR{\textbf{\emph{\enquote*{dmg}} standard:}} 'at_A .sadIquN 'il_A
  2816. % \uc{ju.hA} ya.tlubu min-hu .himAra-hu li-yarkaba-hu fI safraTiN
  2817. % qa.sIraTiN fa-qAla la-hu: \enquote{sawfa 'u`Idu-hu 'ilay-ka fI
  2818. % 'l-masA'-i wa-'adfa`u la-ka 'ujraTaN.} fa-qAla \uc{ju.hA}:
  2819. % \enquote{'anA 'AsifuN jiddaN 'annI lA 'asta.tI`u 'an 'u.haqqiqa
  2820. % la-ka ra.gbata-ka fa-'l-.himAr-u laysa hunA 'l-yawm-a.} wa-qabla
  2821. % 'an yutimma \uc{ju.hA} kalAma-hu bada'a 'l-.himAr-u yanhaqu fI
  2822. % 'i.s.tabli-hi. fa-qAla la-hu .sadIqu-hu: \enquote{'innI 'asma`u
  2823. % .himAra-ka yA \uc{ju.hA} yanhaqu.} fa-qAla la-hu \uc{ju.hA}:
  2824. % \enquote{.garIbuN 'amru-ka yA .sadIqI 'a-tu.saddiqu 'l-.himAr-a
  2825. % wa-tuka_d_diba-nI?}
  2826. % \end{arab}
  2827. %
  2828. % \SetTranslitConvention{loc}
  2829. % \begin{arab}[trans]
  2830. % \LR{\textbf{\emph{\enquote*{loc}} standard:}} 'at_A .sadIquN 'il_A
  2831. % \uc{ju.hA} ya.tlubu min-hu .himAra-hu li-yarkaba-hu fI safraTiN
  2832. % qa.sIraTiN fa-qAla la-hu: \enquote{sawfa 'u`Idu-hu 'ilay-ka fI
  2833. % 'l-masA'-i wa-'adfa`u la-ka 'ujraTaN.} fa-qAla \uc{ju.hA}:
  2834. % \enquote{'anA 'AsifuN jiddaN 'annI lA 'asta.tI`u 'an 'u.haqqiqa
  2835. % la-ka ra.gbata-ka fa-'l-.himAr-u laysa hunA 'l-yawm-a.} wa-qabla
  2836. % 'an yutimma \uc{ju.hA} kalAma-hu bada'a 'l-.himAr-u yanhaqu fI
  2837. % 'i.s.tabli-hi. fa-qAla la-hu .sadIqu-hu: \enquote{'innI 'asma`u
  2838. % .himAra-ka yA \uc{ju.hA} yanhaqu.} fa-qAla la-hu \uc{ju.hA}:
  2839. % \enquote{.garIbuN 'amru-ka yA .sadIqI 'a-tu.saddiqu 'l-.himAr-a
  2840. % wa-tuka_d_diba-nI?}
  2841. % \end{arab}
  2842. % \SetTranslitConvention{dmg}
  2843. %
  2844. % \SetTranslitConvention{arabica}
  2845. % \begin{arab}[trans]
  2846. % \LR{\textbf{\emph{\enquote*{arabica}} standard:}} 'at_A .sadIquN
  2847. % 'il_A \uc{ju.hA} ya.tlubu min-hu .himAra-hu li-yarkaba-hu fI
  2848. % safraTiN qa.sIraTiN fa-qAla la-hu: \enquote{sawfa 'u`Idu-hu
  2849. % 'ilay-ka fI 'l-masA'-i wa-'adfa`u la-ka 'ujraTaN.} fa-qAla
  2850. % \uc{ju.hA}: \enquote{'anA 'AsifuN jiddaN 'annI lA 'asta.tI`u 'an
  2851. % 'u.haqqiqa la-ka ra.gbata-ka fa-'l-.himAr-u laysa hunA 'l-yawm-a.}
  2852. % wa-qabla 'an yutimma \uc{ju.hA} kalAma-hu bada'a 'l-.himAr-u
  2853. % yanhaqu fI 'i.s.tabli-hi. fa-qAla la-hu .sadIqu-hu: \enquote{'innI
  2854. % 'asma`u .himAra-ka yA \uc{ju.hA} yanhaqu.} fa-qAla la-hu
  2855. % \uc{ju.hA}: \enquote{.garIbuN 'amru-ka yA .sadIqI 'a-tu.saddiqu
  2856. % 'l-.himAr-a wa-tuka_d_diba-nI?}
  2857. % \end{arab}
  2858. % \SetTranslitConvention{dmg}
  2859. %
  2860. % \section{Buckwalter input scheme}
  2861. % \label{sec:buckwalter-scheme}
  2862. % \NEWfeature{v1.4} Even though \package{arabluatex} is primarily
  2863. % designed to process the Arab\TeX\ notation, it can also process the
  2864. % Buckwalter input scheme to a large extent.\footnote{See
  2865. % \url{http://www.qamus.org/transliteration.htm}} The Buckwalter
  2866. % scheme is actually processed in two steps, as it is first converted
  2867. % into Arab\TeX. Then, once this is accomplished, the Arab\TeX\ scheme
  2868. % is processed through the above described functions. In this way, the
  2869. % Buckwalter input scheme can make the most of the
  2870. % \package{arabluatex} special features that are presented in
  2871. % \vref{sec:options}.
  2872. %
  2873. % \DescribeMacro{\SetInputScheme} The input scheme, which is set to
  2874. % |arabtex| by default, may be changed at any point of the document by
  2875. % the \cs{SetInputScheme}\marg{scheme} command, where \meta{scheme}
  2876. % may be either |arabtex| or |buckwalter|. This command is also
  2877. % accepted in the preamble should one wish to set the input scheme
  2878. % globally, like so:---
  2879. % \iffalse
  2880. %<*example>
  2881. % \fi
  2882. \begin{arabluaverbatim}
  2883. \usepackage{arabluatex}
  2884. \SetInputScheme{buckwalter}
  2885. \end{arabluaverbatim}
  2886. % \iffalse
  2887. %</example>
  2888. % \fi
  2889. %
  2890. % \paragraph{\enquote*{base}, \enquote*{\texttt{xml}} and
  2891. % \enquote*{safe} schemes}
  2892. % \package{arabluatex} can use any of the so-called Buckwalter
  2893. % \enquote*{base}, \enquote*{\texttt{xml}} or \enquote*{safe} schemes
  2894. % as they are described in \textcite[25--26]{Habash}.\footnote{I am
  2895. % grateful to Graeme Andrews who suggested that the \enquote*{safe}
  2896. % scheme be included in \package{arabluatex}.} However, the following
  2897. % limitation apply to the \enquote*{base} and \enquote*{\texttt{xml}}
  2898. % schemes: the braces |{| and |}|, which are used to encode
  2899. % \arb[novoc]{"a} and \arb[novoc]{y"'}, must be replaced with square
  2900. % brackets viz. |[| and |]| respectively.
  2901. %
  2902. % It is therefore recommended to use the Buckwalter \enquote*{safe}
  2903. % scheme.
  2904. %
  2905. % \Cref{tab:buckwalter-scheme} gives the Buckwalter equivalents that
  2906. % are currently used by \package{arabluatex}. The additional
  2907. % characters that are defined in \vref{tab:additional-arabic-codings}
  2908. % are also available.
  2909. %
  2910. % \begin{longtable}{llllll}
  2911. % \captionlistentry{Buckwalter scheme}\\[-1em]
  2912. % \toprule
  2913. % Letter & \multicolumn{3}{l}{Transliteration\footnotemark}
  2914. % & \multicolumn{2}{l}{Buckwalter notation} \\
  2915. % & \texttt{dmg} & \texttt{loc} & \texttt{arabica} & |base/xml| &
  2916. % |safe| \\ \midrule
  2917. % \endfirsthead
  2918. % \toprule
  2919. % Letter & \multicolumn{3}{l}{Transliteration}
  2920. % & \multicolumn{2}{l}{Buckwalter notation} \\
  2921. % & \texttt{dmg} & \texttt{loc} & \texttt{arabica} & |base/xml| &
  2922. % |safe| \\ \midrule
  2923. % \endhead \footnotetext{See \vref{sec:transliteration}.}
  2924. % \label{tab:buckwalter-scheme}
  2925. % \arb[novoc]{a} & \dmg{a} & \loc{a} & \brill{a} & |A| & |A| \\
  2926. % \arb[novoc]{b} & \dmg{b} & \loc{b} & \brill{b} & |b| & |b| \\
  2927. % \arb[novoc]{t} & \dmg{t} & \loc{t} & \brill{t} & |t| & |t| \\
  2928. % \arb[novoc]{_t} & \dmg{_t} & \loc{_t} & \brill{_t} & |v| & |v| \\
  2929. % \arb[novoc]{j} & \dmg{j} & \loc{j} & \brill{j} & |j| & |j| \\
  2930. % \arb[novoc]{.h} & \dmg{.h} & \loc{.h} & \brill{.h} & |H| & |H| \\
  2931. % \arb[novoc]{x} & \dmg{x} & \loc{x} & \brill{x} & |x| & |x| \\
  2932. % \arb[novoc]{d} & \dmg{d} & \loc{d} & \brill{d} & |d| & |d| \\
  2933. % \arb[novoc]{_d} & \dmg{_d} & \loc{_d} & \brill{_d} & |*| & |V| \\
  2934. % \arb[novoc]{r} & \dmg{r} & \loc{r} & \brill{r} & |r| & |r| \\
  2935. % \arb[novoc]{z} & \dmg{z} & \loc{z} & \brill{z} & |z| & |z| \\
  2936. % \arb[novoc]{s} & \dmg{s} & \loc{s} & \brill{s} & |s| & |s| \\
  2937. % \arb[novoc]{^s} & \dmg{^s} & \loc{^s} & \brill{^s} & |$| & |c| \\
  2938. % \arb[novoc]{.s} & \dmg{.s} & \loc{.s} & \brill{.s} & |S| & |S| \\
  2939. % \arb[novoc]{.d} & \dmg{.d} & \loc{.d} & \brill{.d} & |D| & |D| \\
  2940. % \arb[novoc]{.t} & \dmg{.t} & \loc{.t} & \brill{.t} & |T| & |T| \\
  2941. % \arb[novoc]{.z} & \dmg{.z} & \loc{.z} & \brill{.z} & |Z| & |Z| \\
  2942. % \arb[novoc]{`} & \dmg{`} & \loc{`} & \brill{`} & |E| & |E| \\
  2943. % \arb[novoc]{.g} & \dmg{.g} & \loc{.g} & \brill{.g} & |g| & |g| \\
  2944. % \arb[novoc]{f} & \dmg{f} & \loc{f} & \brill{f} & |f| & |f| \\
  2945. % \arb[novoc]{q} & \dmg{q} & \loc{q} & \brill{q} & |q| & |q| \\
  2946. % \arb[novoc]{k} & \dmg{k} & \loc{k} & \brill{k} & |k| & |k| \\
  2947. % \arb[novoc]{l} & \dmg{l} & \loc{l} & \brill{l} & |l| & |l| \\
  2948. % \arb[novoc]{m} & \dmg{m} & \loc{m} & \brill{m} & |m| & |m| \\
  2949. % \arb[novoc]{n} & \dmg{n} & \loc{n} & \brill{n} & |n| & |n| \\
  2950. % \arb[novoc]{h} & \dmg{h} & \loc{h} & \brill{h} & |h| & |h| \\
  2951. % \arb[novoc]{w} & \dmg{w} & \loc{w} & \brill{w} & |w| & |w| \\
  2952. % \arb[novoc]{y} & \dmg{y} & \loc{y} & \brill{y} & |y| & |y| \\
  2953. % \arb[novoc]{Y} & \dmg{Y} & \loc{Y} & \brill{Y} & |Y| & |Y| \\
  2954. % \arb[novoc]{T} & \dmg{aT} & \loc{aT} & \brill{aT} & |p| & |p| \\
  2955. % \midrule
  2956. % \arb[novoc]{|"'} & \dmg{|"'} & \loc{|"'} & \brill{|"'} & \verb|'| & |C| \\
  2957. % \arb[novoc]{A"'} & \dmg{A"'} & \loc{A"'} & \brill{A"'} & \verb+|+ & |M| \\
  2958. % \arb[novoc]{a"'} & \dmg{a"'} & \loc{a"'} & \brill{a"'} & \verb|>| & |O| \\
  2959. % \arb[novoc]{w"'} & \dmg{w"'} & \loc{w"'} & \brill{w"'} & \verb|&| & |W| \\
  2960. % \arb[novoc]{i"'} & \dmg{i"'} & \loc{i"'} & \brill{i"'} & \verb|<| & |I| \\
  2961. % \arb[novoc]{y"'} & \dmg{y"'} & \loc{y"'} & \brill{y"'} & \verb|]| & |Q| \\
  2962. % \midrule
  2963. % \arb[novoc]{BB} & --- & --- & --- & \verb|~| & |~| \\
  2964. % \arb[novoc]{"a} & ' & ' & --- & |[| & |L| \\
  2965. % \midrule
  2966. % \arb[voc]{Ba} & \dmg{Ba} & \loc{Ba} & \brill{Ba} & \verb|a| & |a| \\
  2967. % \arb[voc]{Bu} & \dmg{Bu} & \loc{Bu} & \brill{Bu} & \verb|u| & |u| \\
  2968. % \arb[voc]{Bi} & \dmg{Bi} & \loc{Bi} & \brill{Bi} & \verb|i| & |i| \\
  2969. % \arb[voc]{BaN} & \dmg{BaN} & \loc{BaN} & \brill{BaN} & \verb|F| & |F| \\
  2970. % \arb[voc]{BuN} & \dmg{BuN} & \loc{BuN} & \brill{BuN} & \verb|N| & |N| \\
  2971. % \arb[voc]{BiN} & \dmg{BiN} & \loc{BiN} & \brill{BiN} & \verb|K| & |K| \\
  2972. % \arb[voc]{B"} & --- & --- & --- & \verb|o| & |o| \\
  2973. % \midrule
  2974. % \arb[novoc]{B_a} & \dmg{B_a} & \loc{B_a} & \brill{B_a} & |`| & |e| \\
  2975. % \midrule
  2976. % \arb[novoc]{--} (\arb[trans]{ta.twIl}) & --- & --- & --- & |_| & |_| \\
  2977. % \bottomrule
  2978. % \caption*{\Cref*{tab:buckwalter-scheme}: Buckwalter scheme}
  2979. % \end{longtable}
  2980. %
  2981. % \paragraph{Transliteration}
  2982. % The Buckwalter notation can also be transliterated into any accepted
  2983. % romanization standard of Arabic. See above
  2984. % \vref{sec:transliteration} for more information. However, it should
  2985. % be pointed out again that only accurate coding produces accurate
  2986. % transliteration. It is therefore at the very least highly advisable
  2987. % to use the hyphen for tying the definite article and the inseparable
  2988. % particles (viz. prepositions, adverbs and conjunctions) to words,
  2989. % like so:--- \SetInputScheme{buckwalter}
  2990. % \begin{quote}
  2991. % |Al-EaAlamu| \arb{Al-EaAlam-u} \arb[trans]{Al-EaAlam-u},
  2992. % |Al-camsu| \arb{Al-cams-u} \arb[trans]{Al-cams-u},
  2993. % |bi-SinaAEapi| |Al-T~ib~i|, \arb{bi-SinaAEap-i Al-T~ib~-i}
  2994. % \arb[trans]{bi-SinaAEap-i Al-T~ib~-i}.
  2995. %
  2996. % |wa-Al-l~ehi| \arb{wa-Al-l~eh-i} \arb[trans]{wa-Al-l~eh-i},
  2997. % |Al-Hamdu| |li-l~ehi| \arb{Al-Hamd-u li-l~eh-i}
  2998. % \arb[trans]{Al-Hamd-u li-l~eh-i}.
  2999. % \end{quote}
  3000. % \SetInputScheme{arabtex}
  3001. %
  3002. % Similary, it is not advisable to use \verb+|+ and |[|
  3003. % (\enquote*{base} and \enquote*{\texttt{xml}} schemes) or |M| and |L|
  3004. % (\enquote*{safe} scheme) to encode the \arb[trans]{'alif-u
  3005. % 'l-mamdUdaT-i} and the \arb[trans]{'alif-u 'l-wa.sl-i} for such
  3006. % signs are supposed to be generated by \package{arabluatex} internal
  3007. % functions. Besides, as they do not \emph{per se} convey any
  3008. % morphological information on what they are derived from, they cannot
  3009. % be transliterated accurately. To take one example, %
  3010. % \SetInputScheme{buckwalter}%
  3011. % |<ilY Al-LntiqaADi| gives \arb{>ilY Al-LntiqaADi} as expected, but
  3012. % only |<ilY Al-intiqADi| can be transliterated as \arb[trans]{<ilY
  3013. % Al-intiqaADi} with the correct vowel \meta{i} in place of the %
  3014. % \SetInputScheme{arabtex}%
  3015. % \arb[trans]{'alif-u 'l-wa.sl-i}.
  3016. %
  3017. % \section{Unicode Arabic input}
  3018. % \label{sec:unicode-input}
  3019. % \NEWfeature{v1.5} As said above in \vref{sec:buckwalter-scheme}
  3020. % about the Buckwalter input scheme, even though \package{arabluatex}
  3021. % is primarily designed to process the Arab\TeX\ notation, it also
  3022. % accepts Unicode Arabic input. It should be noted that
  3023. % \package{arabluatex} does in no way interfere with Unicode Arabic
  3024. % input: none of the |voc|, |fullvoc|, |novoc| or |trans| options will
  3025. % have any effect on plain Unicode Arabic for the time being.
  3026. %
  3027. % That said, there are two ways of inserting Unicode
  3028. % Arabic:
  3029. % \begin{compactenum}[(a)]
  3030. % \item \DescribeMacro{\txarb} The \cs{txarb}\marg{Unicode Arabic}
  3031. % command for inserting Unicode Arabic text in paragraphs;
  3032. % \item The \DescribeEnv{txarab} |txarab| environment for inserting
  3033. % running paragraphs of Arabic text, like so:---\\%
  3034. % \iffalse
  3035. %<*example>
  3036. % \fi
  3037. \begin{arabluaverbatim}
  3038. \begin{txarab}
  3039. <Unicode Arabic text>
  3040. \end{txarab}
  3041. \end{arabluaverbatim}
  3042. % \iffalse
  3043. %</example>
  3044. % \fi
  3045. % \end{compactenum}
  3046. %
  3047. % \section{\LaTeX\ Commands in Arabic environments}
  3048. % \label{sec:commands-in-arb}
  3049. % \paragraph{General principle} \label{ref:cmd-inside-arabic}\LaTeX\
  3050. % commands are accepted in Arabic environments. The general principle
  3051. % which applies is that single-argument commands
  3052. % (\cs{command}\marg{arg}) such as \cs{emph}\marg{text},
  3053. % \cs{textbf}\marg{text} and the like, are assumed to have Arabic text
  3054. % as their arguments:---
  3055. % \begin{quote}
  3056. % |\abjad{45}| |kitAbu-hu| |\emph{fI| |'l-\uc{`AdAt-i}}|
  3057. % \arb[voc]{\abjad{45} kitAbu-hu \emph{fI 'l-\uc{`AdAt-i}}}
  3058. % \arb[trans]{\abjad{45} kitAbu-hu \emph{fI
  3059. % 'l-\uc{`AdAt-i}}}.\footnote{This is odd in Arabic script, but
  3060. % using such features as \cs{emph} or \cs{textbf} is a matter of
  3061. % personal taste.}
  3062. % \end{quote}
  3063. %
  3064. % The same applies to footnotes:---
  3065. % \iffalse
  3066. %<*example>
  3067. % \fi
  3068. \begin{arabluacode}
  3069. \renewcommand{\footnoterule}%
  3070. {\hfill\noindent\rule[1mm]{.4\textwidth}{.15mm}}
  3071. \begin{arab}
  3072. 'inna 'abI kAna mina 'l-muqAtilaT-i\footnote{al-muqAtilaT-i:
  3073. al-muqAtil-Ina.}, wa-kAnat 'ummI min `u.zamA'-i buyUt-i
  3074. 'l-zamAzimaT-i\footnote{al-zamAzimaT-u: .tA'ifaT-u mina
  3075. 'l-furs-i.}.
  3076. \end{arab}
  3077. \end{arabluacode}
  3078. % \iffalse
  3079. %</example>
  3080. % \fi
  3081. %
  3082. % Some commands, however, do not expect running text in their
  3083. % arguments, or one may wish to insert English text eg. in footnotes
  3084. % or in marginal notes. \package{arabluatex} provides a set of
  3085. % commands to handle such cases.
  3086. %
  3087. % \DescribeMacro{\LR} \cs{LR}\marg{arg} is designed to typeset its
  3088. % argument from left to right. It may be used in an Arabic
  3089. % environment, either \cs{arb}\marg{Arabic text} or \cs{begin}|{arab}|
  3090. % \meta{Arabic text} \cs{end}|{arab}|, for short insertions of
  3091. % left-to-right text, or to insert any \LaTeX\ command that would
  3092. % otherwise be rejected by \package{arabluatex}, such as commands the
  3093. % argument of which is expected to be a dimension or a unit of
  3094. % measurement.
  3095. %
  3096. % \DescribeMacro{\RL} \cs{RL}\marg{arg} does the same as
  3097. % \cs{LR}\marg{arg}, but typesets its argument from right to left. Even
  3098. % in an Arabic environment, this command may be useful.
  3099. %
  3100. % \DescribeMacro{\LRfootnote} \DescribeMacro{\RLfootnote}
  3101. % \cs{LRfootnote}\marg{text} and \cs{RLfootnote}\marg{text} typeset
  3102. % left-to-right and right-to-left footnotes respectively in Arabic
  3103. % environments. Unlike \cs{footnote}\marg{text}, the arguments of both
  3104. % \cs{LRfootnote} and \cs{RLfootnote} are not expected to be Arabic
  3105. % text. For example, \cs{LRfootnote} can be used to insert English
  3106. % footnotes in running Arabic text:---
  3107. % \iffalse
  3108. %<*example>
  3109. % \fi
  3110. \begin{arabluacode}
  3111. \arb[fullvoc]{\uc{z}ayd-uN\LRfootnote{%
  3112. \enquote{\arb[trans]{\uc{z}ayd} is the son of
  3113. \arb[trans]{\uc{`a}mr}}: the second
  3114. noun is not in apposition to the first, but forms
  3115. part of the predicate\ldots} "ibn-u \uc{`a}mr-iNU}
  3116. \end{arabluacode}
  3117. % \iffalse
  3118. %</example>
  3119. % \fi
  3120. %
  3121. % When footnotes are typeset from right to left, it may happen that
  3122. % the numbers of the footnotes that are at the bottom of the page be
  3123. % typeset in the wrong direction. For example, instead of an expected
  3124. % number 18, one may get 81. \package{arabluatex} is not responsible
  3125. % for that, but should it happen, it may be necessary to redefine in
  3126. % the preamble the \LaTeX\ macro \cs{thefootnote} like so:---\\
  3127. % \arabluaverb{\renewcommand*{\thefootnote}{\textsuperscript{\LR{\arabic{footnote}}}}}
  3128. % \DescribeMacro{\FixArbFtnmk} Another solution is to put in the
  3129. % preamble, below the line that loads \package{arabluatex}, the
  3130. % \cs{FixArbFtnmk} command. However, for more control over the layout
  3131. % of footnotes marks, it is advisable to use the \package{scrextend}
  3132. % package.\footnote{See \url{http://ctan.org/pkg/koma-script}; read
  3133. % the documentation of \package{KOMA-script} for details about the
  3134. % \cs{deffootnotemark} and \cs{deffootnote} commands.}
  3135. %
  3136. % \DescribeMacro{\LRmarginpar} The \cs{LRmarginpar} command does for
  3137. % marginal notes the same as \cs{LRfootnote} does for footnotes. Of
  3138. % course, it is supposed to be used in Arabic environments. Note that
  3139. % \cs{marginpar} also works in Arabic environments, but it acts as any
  3140. % other single-argument command inserted in Arabic environments. The
  3141. % general principle laid \vpageref{ref:cmd-inside-arabic} applies.
  3142. %
  3143. % \DescribeMacro{\setRL} \DescribeMacro{\setLR} \cs{setRL} and
  3144. % \cs{setLR} can be used to change the direction of paragraphs, either
  3145. % form left to right or from right to left. As an example, an
  3146. % easy way to typeset a right-to-left sectional title follows:---
  3147. % \iffalse
  3148. %<*example>
  3149. % \fi
  3150. \begin{arabluacode}
  3151. \setRL
  3152. \section*{\arb{barzawayhi li-buzurjumihra bn-i 'l-buxtikAni}}
  3153. \setLR
  3154. \begin{arab}
  3155. qAla barzawayhi bn-u 'azhar-a, ra's-u 'a.tibbA'-i fAris-a...
  3156. \end{arab}
  3157. \end{arabluacode}
  3158. % \iffalse
  3159. %</example>
  3160. % \fi
  3161. %
  3162. % \subsection{New commands}
  3163. % \label{sec:declare-new-commands}
  3164. % \NEWfeature{v1.9}%
  3165. % In some particular cases, it may be useful to define new commands to
  3166. % be inserted in Arabic environments. From the general principle laid
  3167. % \vpageref{ref:cmd-inside-arabic}, it follows that any command that
  3168. % is found inside an Arabic environment is assumed to have Arabic text
  3169. % in its argument which \package{arabluatex} will process as such
  3170. % before passing it on to the command itself for any further
  3171. % processing. As a result of this feature, such a command as:\\
  3172. % \arabluaverb{\newcommand{\fvarabic}[1]{\arb[fullvoc]{#1}}}\\
  3173. % will work as expected, but will always output non-vocalized Arabic
  3174. % if it is inserted in a |novoc| Arabic environment because its
  3175. % argument will have been processed by the |novoc| rules before the
  3176. % command |\fvarabic| itself can see it.
  3177. %
  3178. % \DescribeMacro{\MkArbBreak} The \cs{MkArbBreak}\marg{csv list of
  3179. % commands} command can be used in the preamble to give any
  3180. % \emph{single-argument} command---either new or already
  3181. % existing---the precedence over \package{arabluatex} inside Arabic
  3182. % environments. It takes as argument a comma-separated list of
  3183. % commands each of which must be stripped of its leading character
  3184. % |\|, like so:---\\
  3185. % \arabluaverb{\MkArbBreak{onecmd, anothercmd, yetanothercmd, ...}}
  3186. %
  3187. % For example, here follows a way to define a new command |\fvred| to
  3188. % distinguish words with a different color and always print them in
  3189. % fully vocalized Arabic:---\footnote{See below \vref{sec:textcolor} for
  3190. % more information on two-argument commands.} %
  3191. % \iffalse
  3192. %<*example>
  3193. % \fi
  3194. \begin{arabluacode}
  3195. \MkArbBreak{fvred}
  3196. \newcommand{\fvred}[1]{\textcolor{red}{\arb[fullvoc]{#1}}}
  3197. \begin{arab}[voc]
  3198. _tumma "intalaqa _dU 'l-qarn-ayni 'il_A 'ummaT-iN 'u_hr_A fI
  3199. \fvred{((ma.tli`-i 'l-^sams-i))} wa-lA binA'-a la-hum
  3200. yu'amminu-hum mina 'l-^sams-i.
  3201. \end{arab}
  3202. \end{arabluacode}
  3203. % \iffalse
  3204. %</example>
  3205. % \fi
  3206. %
  3207. % \subsection{Environments}
  3208. % \label{sec:environments}
  3209. % \changes{v1.5}{2016/11/14}{Environments may be nested inside the
  3210. % \texttt{arab} environment}
  3211. % \NEWfeature{v1.5} Environments such as
  3212. % \arabluaverb{\begin{quote}... \end{quote}} may be nested inside the
  3213. % |arab| environment. Up to one optional argument may be passed to
  3214. % each nested environment, like so:---
  3215. % \iffalse
  3216. %<*example>
  3217. % \fi
  3218. \begin{arabluaverbatim}
  3219. \begin{arab}
  3220. \begin{<environment>}[<options>]
  3221. <Arabic text>
  3222. \end{<environment>}
  3223. \end{arab}
  3224. \end{arabluaverbatim}
  3225. % \iffalse
  3226. %</example>
  3227. % \fi
  3228. %
  3229. % In the following example, the \package{quoting} package is used:---
  3230. % \iffalse
  3231. %<*example>
  3232. % \fi
  3233. \begin{arabluacode}
  3234. \setquotestyle{arabic}
  3235. \begin{arab}[fullvoc]
  3236. kAna \uc{'abU} \uc{'l-hu_dayli} 'ahd_A 'il_A \uc{muwaysiN}
  3237. dajAjaTaN. wa-kAnat dajAjatu-hu 'llatI 'ahdA-hA dUna mA kAna
  3238. yuttaxa_du li-\uc{muwaysiN}. wa-l_akinna-hu bi-karami-hi
  3239. wa-bi-.husni xuluqi-hi 'a.zhara 'l-ta`ajjuba min simani-hA
  3240. wa-.tIbi la.hmi-hA. wa-kAna <\uc{'abU} \uc{'l-hu_dayli}> yu`rafu
  3241. bi-'l-'imsAki 'l-^sadIdi. fa-qAla: \enquote{wa-kayfa ra'ayta yA
  3242. \uc{'abA} \uc{`imrAna} tilka 'l-dajAjaTa?} qAla:
  3243. \enquote{kAnat `ajabaN mina 'l-`ajabi!} fa-yaqUlu:
  3244. \begin{quoting}[begintext=», endtext=«]
  3245. wa-tadrI mA jinsu-hA? wa-tadrI mA sinnu-hA? fa-'inna
  3246. 'l-dajAjaTa 'inna-mA ta.tIbu bi-'l-jinsi wa-'l-sinni. wa-tadrI
  3247. bi-'ayyi ^say'iN kunnA nusamminu-hA? wa-fI 'ayyi makAniN kunnA
  3248. na`lifu-hA?
  3249. \end{quoting}
  3250. fa-lA yazAlu fI h_a_dA wa-'l-'A_haru ya.d.haku .da.hkaN na`rifu-hu
  3251. na.hnu wa-lA ya`rifu-hu \uc{'abU} \uc{'l-hu_dayli}.
  3252. \end{arab}
  3253. \end{arabluacode}
  3254. % \iffalse
  3255. %</example>
  3256. % \fi
  3257. %
  3258. % \subsubsection{Lists}
  3259. % \label{sec:lists}
  3260. % Lists environments are also accepted inside the |arab|
  3261. % environment. One may either use any of the three standard list
  3262. % environments, viz. |itemize|, |enumerate| and |description| or use a
  3263. % package that provides additional refinements such as
  3264. % \package{paralist}.
  3265. %
  3266. % To take a first example, should one wish to typeset a list of
  3267. % manuscripts, the |description| environment can be used like so:---
  3268. % \iffalse
  3269. %<*example>
  3270. % \fi
  3271. \begin{arabluacode}
  3272. \setRL\paragraph{\arb[novoc]{rumUzi 'l-kitAbi}}\setLR
  3273. \begin{arab}[novoc]
  3274. \begin{description}
  3275. \item[b] max.tU.tu 'l-maktabaTi 'l-'ahliyyaTi bi-\uc{bArIs} 2860
  3276. `arabiyyuN.
  3277. \item[s] max.tU.tu 'l-maktabaTi 'l-'ahliyyaTi bi-\uc{bArIs} 2859
  3278. `arabiyyuN.
  3279. \item[m] max.tU.tu majlisi \arb[novoc]{^sUrAY malY} .tahrAna 521.
  3280. \end{description}
  3281. \end{arab}
  3282. \end{arabluacode}
  3283. % \iffalse
  3284. %</example>
  3285. % \fi
  3286. %
  3287. % As a second example, the contents of a treatise may be typeset with
  3288. % the standard list environments, like so:---
  3289. % \iffalse
  3290. %<*example>
  3291. % \fi
  3292. \begin{arabluacode}
  3293. \setRL\centerline{\arb{\textbf{al-qAnUnu fI 'l-.tibbi}}}\setLR
  3294. \begin{arab}
  3295. \begin{itemize}
  3296. \item \textbf{al-fannu 'l-'awwalu} fI .haddi 'l-.tibbi
  3297. wa-maw.dU`Ati-hi mina 'l-'umUri 'l-.tabI`iyyaTi wa-ya^stamilu
  3298. `al_A sittaTi ta`AlImiN
  3299. \begin{itemize}
  3300. \item \textbf{al-ta`lImu 'l-'awwalu} [wa-huwa fa.slAni]
  3301. \begin{itemize}
  3302. \item \textbf{al-fa.slu 'l-'awwalu}
  3303. \end{itemize}
  3304. \end{itemize}
  3305. \end{itemize}
  3306. \end{arab}
  3307. \end{arabluacode}
  3308. % \iffalse
  3309. %</example>
  3310. % \fi
  3311. %
  3312. % \paragraph{Caveat}
  3313. % The various French definition files of the \package{babel} package
  3314. % viz. |acadian|, |canadien|, |francais|, |frenchb| or |french| all
  3315. % redefine the list environments, which breaks the standard definition
  3316. % file that is used by \package{arabluatex}. Therefore,
  3317. % \package{babel-french} must be loaded with the |StandardLists=true|
  3318. % option, like so:---%
  3319. % \iffalse
  3320. %<*example>
  3321. % \fi
  3322. \begin{arabluaverbatim}
  3323. \usepackage[french]{babel}
  3324. \frenchsetup{StandardLists=true}
  3325. \end{arabluaverbatim}
  3326. % \iffalse
  3327. %</example>
  3328. % \fi%
  3329. % This option will prevent \package{babel-french} from interfering
  3330. % with the layout of the document. Then the package \package{paralist}
  3331. % can be used to make the lists \enquote*{compact} as
  3332. % \package{babel-french} do.
  3333. %
  3334. % \subsection{\package{csquotes}}
  3335. % \label{sec:csquotes}
  3336. % The recommended way of inserting quotation marks in running Arabic
  3337. % text is to use \package{csquotes}. With the help of the
  3338. % \cs{DeclareQuoteStyle} command, one can define an Arabic style, like
  3339. % so:---
  3340. % \iffalse
  3341. %<*example>
  3342. % \fi
  3343. \begin{arabluaverbatim}
  3344. \usepackage{csquotes}
  3345. \DeclareQuoteStyle{arabic}
  3346. {\rmfamily\textquotedblright}{\rmfamily\textquotedblleft}
  3347. {\rmfamily\textquoteright}{\rmfamily\textquoteleft}
  3348. \end{arabluaverbatim}
  3349. % \iffalse
  3350. %</example>
  3351. % \fi
  3352. % Then, use this newly defined style with \cs{setquotestyle}, like so:---
  3353. % \iffalse
  3354. %<*example>
  3355. % \fi
  3356. \begin{arabluacode}
  3357. \setquotestyle{arabic}
  3358. \begin{arab}
  3359. fa-qAla la-hu ju.hA: \enquote{.garIb-uN 'amru-ka yA .sadIqI
  3360. 'a-tu.saddiqu 'l-.himAr-a wa-tuka_d_diba-nI?}
  3361. \end{arab}
  3362. \setquotestyle{english}
  3363. \end{arabluacode}
  3364. % \iffalse
  3365. %</example>
  3366. % \fi
  3367. % \begin{quoting}
  3368. % \textsc{Rem.} Do not forget to set back the quoting style to its
  3369. % initial state once the Arabic environment is closed. See the last
  3370. % line in the code above.
  3371. % \end{quoting}
  3372. %
  3373. % \subsection{Two-argument commands}
  3374. % \label{sec:two-arg-cmds}
  3375. %
  3376. % \paragraph{Color}
  3377. % \label{sec:textcolor}
  3378. % The two-argument command \cs{textcolor}\marg{color}\marg{Arabic
  3379. % text} is supported inside \cs{begin}|{arab}| \ldots\
  3380. % \cs{end}|{arab}|. One simple example follows:--- %
  3381. % \iffalse
  3382. %<*example>
  3383. % \fi
  3384. \begin{arabluacode}
  3385. \begin{arab}
  3386. \textcolor{red}{\uc{m}uha_d_dabu \uc{'l-d}Ini \uc{`a}bdu
  3387. \uc{'l-r}a.hImi bnu \uc{`a}liyyiN} huwa ^say_hu-nA 'l-'imAmu
  3388. 'l-.sadru 'l-kabIru 'l-`Alimu 'l-fA.dilu \uc{m}uha_d_dabu
  3389. \uc{'l-d}Ini \uc{'a}bU \uc{m}u.hammadiN \uc{`a}bdu
  3390. \uc{'l-r}a.hImi bnu \uc{`a}liyyi bni \uc{.h}AmidiN wa-yu`rafu
  3391. bi-\uc{'l-d}a_hwari.
  3392. \end{arab}
  3393. \begin{arab}[trans]
  3394. \textcolor{red}{\uc{m}uha_d_dabu \uc{'l-d}Ini \uc{`a}bdu
  3395. \uc{'l-r}a.hImi bnu \uc{`a}liyyiN} huwa ^say_hu-nA 'l-'imAmu
  3396. 'l-.sadru 'l-kabIru 'l-`Alimu 'l-fA.dilu \uc{m}uha_d_dabu
  3397. \uc{'l-d}Ini \uc{'a}bU \uc{m}u.hammadiN \uc{`a}bdu
  3398. \uc{'l-r}a.hImi bnu \uc{`a}liyyi bni \uc{.h}AmidiN wa-yu`rafu
  3399. bi-\uc{'l-d}a_hwari.
  3400. \end{arab}
  3401. \end{arabluacode}
  3402. % \iffalse
  3403. %</example>
  3404. % \fi
  3405. %
  3406. % \paragraph{\package{reledmac}}
  3407. % \label{sec:reledmac}
  3408. % The two-argument command \cs{edtext}\marg{lemma}\marg{commands} is
  3409. % supported inside \cs{begin}|{arab}| \ldots\ \cs{end}|{arab}|. As an
  3410. % example, one may get \package{arabluatex} and \package{reledmac} to
  3411. % work together like so:---
  3412. % \iffalse
  3413. %<*example>
  3414. % \fi
  3415. \begin{arabluaverbatim}
  3416. \beginnumbering
  3417. \pstart
  3418. \begin{arab}
  3419. wa-ya.sIru ta.hta 'l-jild-i
  3420. \edtext{\arb{.sadId-uN}}{\Afootnote{M: \arb{.sadId-aN} E1}}
  3421. \end{arab}
  3422. \pend
  3423. \endnumbering
  3424. \end{arabluaverbatim}
  3425. % \iffalse
  3426. %</example>
  3427. % \fi
  3428. %
  3429. % \subsection{\package{quran}}
  3430. % \label{sec:pkg-quran}
  3431. % \changes{v1.5}{2016/11/14}{Compatibility with the \textsf{quran}
  3432. % package} \package{arabluatex} is compatible with the \package{quran}
  3433. % package so that both can be used in conjunction with one another for
  3434. % typesetting the \arb[trans]{\uc{qur'An}}. As \package{quran} draws
  3435. % the text of the \arb[trans]{\uc{qur'An}} from a Unicode encoded
  3436. % database, its commands have to be passed as arguments to the
  3437. % \cs{txarb} command for short insertions in left-to-right paragraphs,
  3438. % or inserted inside the \index{txarab=txarab (environment)}|txarab|
  3439. % environment for typesetting running paragraphs of
  3440. % \arb[trans]{\uc{qur'An}}\emph{ic} text (see above
  3441. % \vref{sec:unicode-input} for more details). Please note that
  3442. % \package{arabluatex} takes care of formatting the Arabic: therefore,
  3443. % it is recommended to load the \package{quran} package with the
  3444. % |nopar| option, after \package{arabluatex} itself has been loaded,
  3445. % like so:--- %
  3446. % \iffalse
  3447. %<*example>
  3448. % \fi
  3449. \begin{arabluaverbatim}
  3450. \usepackage{arabluatex}
  3451. \usepackage[nopar]{quran}
  3452. \end{arabluaverbatim}
  3453. % \iffalse
  3454. %</example>
  3455. % \fi
  3456. %
  3457. % As an example, the following code will typeset the \arb[trans]{sUraT
  3458. % al-\uc{fAti.haT}}:---
  3459. % \iffalse
  3460. %<*example>
  3461. % \fi
  3462. \begin{arabluacode}
  3463. \begin{txarab}
  3464. \quransurah[1]
  3465. \end{txarab}
  3466. \end{arabluacode}
  3467. % \iffalse
  3468. %</example>
  3469. % \fi
  3470. %
  3471. % \section{Future work}
  3472. % \label{sec:future-work}
  3473. % A short, uncommented, list of what is planned in the versions of
  3474. % \package{arabluatex} to come follows:
  3475. % \begin{compactenum}[(a)]
  3476. % \item Short-term:
  3477. % \begin{compactenum}[i.]
  3478. % \item \texttt{TEI xml} support: \package{arabluatex} will
  3479. % interoperate with \texttt{TEI xml} through new global and local
  3480. % options that will output Arabic in a \texttt{TEI xml} compliant
  3481. % file in addition to the usual PDF output: see
  3482. % \vpageref{ref:tei-to-come}.
  3483. % \end{compactenum}
  3484. % \item Medium-term:
  3485. % \begin{compactenum}[i.]
  3486. % \item More languages: the list of supported languages will
  3487. % eventually be the same as \package{arabtex}: see
  3488. % \vref{fn:arabtex-languages}.
  3489. % \item Formulate propositions for extending the Arab\TeX\ notation
  3490. % and the transliteration tables. Include them in
  3491. % \package{arabluatex}. See \vref{sec:additional-characters}.
  3492. % \end{compactenum}
  3493. % \end{compactenum}
  3494. %
  3495. % \StopEventually{}
  3496. %
  3497. % \section{Implementation}
  3498. %
  3499. % \iffalse
  3500. %<*package>
  3501. % \fi
  3502. %
  3503. % The most important part of \package{arabluatex} relies on Lua
  3504. % functions and tables. Read the |.lua| files that accompany
  3505. % \package{arabluatex} for more information.
  3506. % \begin{macrocode}
  3507. \NeedsTeXFormat{LaTeX2e}
  3508. \ProvidesPackage{arabluatex}%
  3509. [2018/03/31 v1.11 An ArabTeX-like interface for LuaLaTeX]
  3510. \RequirePackage{ifluatex}
  3511. % \end{macrocode}
  3512. % \package{arabluatex} requires \LuaLaTeX\ of course. Issue a warning
  3513. % if the document is processed with another engine.
  3514. % \begin{macrocode}
  3515. \ifluatex\else
  3516. \PackageError{arabluatex}{lualatex needed}{%
  3517. Package `arabluatex' needs LuaTeX.\MessageBreak
  3518. So you should use `lualatex' to process your document.\MessageBreak
  3519. See documentation of `arabluatex' for further information.}%
  3520. \expandafter\expandafter\expandafter\csname endinput\endcsname
  3521. \fi
  3522. % \end{macrocode}
  3523. % Declare the global options, and define them:
  3524. % \begin{macrocode}
  3525. \RequirePackage{xkeyval}
  3526. \DeclareOptionX{voc}{\def\al@mode{voc}}
  3527. \DeclareOptionX{fullvoc}{\def\al@mode{fullvoc}}
  3528. \DeclareOptionX{novoc}{\def\al@mode{novoc}}
  3529. \DeclareOptionX{trans}{\def\al@mode{trans}}
  3530. \ExecuteOptionsX{voc}
  3531. \ProcessOptionsX\relax
  3532. \def\al@mode@voc{voc}
  3533. \def\al@mode@fullvoc{fullvoc}
  3534. \def\al@mode@novoc{novoc}
  3535. \def\al@mode@trans{trans}
  3536. % \end{macrocode}
  3537. % Packages that are required by \package{arabluatex}:
  3538. % \begin{macrocode}
  3539. \RequirePackage{etoolbox}
  3540. \RequirePackage{arabluatex-patch}
  3541. \RequirePackage{fontspec}
  3542. \RequirePackage{amsmath}
  3543. \RequirePackage{luacode}
  3544. \RequirePackage{xparse}
  3545. \RequirePackage{environ}
  3546. \RequirePackage{adjustbox}
  3547. % \end{macrocode}
  3548. % The following boolean will be set to |true| in |RL| mode:
  3549. % \begin{macrocode}
  3550. \newbool{al@rlmode}
  3551. % \end{macrocode}
  3552. % Here begins the real work: load |arabluatex.lua|:
  3553. % \begin{macrocode}
  3554. \luadirect{dofile(kpse.find_file("arabluatex.lua"))}
  3555. % \end{macrocode}
  3556. % This is needed by the current versions of \package{polyglossia} and
  3557. % \package{luabidi}. \package{luabidi} provides a \cs{Footnote}
  3558. % command. Use it as well if it is loaded.
  3559. % \begin{macrocode}
  3560. \luadirect{tex.enableprimitives("luatex",tex.extraprimitives("omega"))}
  3561. % \end{macrocode}
  3562. % Font setup. If no Arabic font is selected, issue a warning message
  3563. % and attempt to load the Amiri font which is included in \TeX{}live:
  3564. % \begin{macrocode}
  3565. \AtBeginDocument{\ifdefined\arabicfont\relax\else
  3566. \PackageWarning{arabluatex}{\string\arabicfont\ is not defined.^^JI
  3567. will try to load Amiri}%
  3568. \newfontfamily\arabicfont[Script=Arabic]{Amiri}\fi}%
  3569. % \end{macrocode}
  3570. % \begin{macro}{\setRL}
  3571. % This neutralizes what is defined by the same command in
  3572. % \package{luabidi}:
  3573. % \begin{macrocode}
  3574. \AtBeginDocument{\def\setRL{\booltrue{al@rlmode}\pardir TRT\textdir TRT}}
  3575. % \end{macrocode}
  3576. % \end{macro}
  3577. % \begin{macro}{\setLR}
  3578. % The same applies to \cs{setLR}:
  3579. % \begin{macrocode}
  3580. \AtBeginDocument{\def\setLR{\boolfalse{al@rlmode}\pardir TLT\textdir TLT}}
  3581. % \end{macrocode}
  3582. % \end{macro}
  3583. % \begin{macro}{\LR} This command typesets its argument from left to
  3584. % right. As \cs{LR} may be already defined, we need to redefine for
  3585. % it to suit our purpose:
  3586. % \begin{macrocode}
  3587. \AtBeginDocument{\ifdef{\LR}%
  3588. {\RenewDocumentCommand{\LR}{m}{\bgroup\textdir TLT\rmfamily#1\egroup}}
  3589. {\NewDocumentCommand{\LR}{m}{\bgroup\textdir TLT\rmfamily#1\egroup}}}
  3590. % \end{macrocode}
  3591. % \end{macro}
  3592. % \begin{macro}{\RL} This one typesets its argument from right to
  3593. % left. Same remark as above regarding the need of redefinition.
  3594. % \begin{macrocode}
  3595. \AtBeginDocument{\ifdef{\RL}%
  3596. {\RenewDocumentCommand{\RL}{m}{\bgroup\textdir TRT\rmfamily#1\egroup}}
  3597. {\NewDocumentCommand{\RL}{m}{\bgroup\textdir TRT#1\rmfamily\egroup}}}
  3598. % \end{macrocode}
  3599. % \end{macro}
  3600. % \begin{macro}{\MkArbBreak}
  3601. % \changes{v1.9}{2017/07/05}{New \cs{MkArbBreak} command for inserting
  3602. % user-defined macros in Arabic environments}
  3603. % The \cs{MkArbBreak}\marg{csv list of commands} command can be used
  3604. % to give any command---either new or already existing---the
  3605. % precedence over \package{arabluatex} inside Arabic environments. It
  3606. % is actually coded in Lua.
  3607. % \begin{macrocode}
  3608. \DeclareDocumentCommand{\MkArbBreak}{m}{%
  3609. \luadirect{mkarbbreak(\luastringN{#1})}}
  3610. % \end{macrocode}
  3611. % \end{macro}
  3612. % \begin{macro}{\aemph} Arabic emphasis. Needs to be redefined as
  3613. % well. The function is actually coded in Lua.
  3614. % \begin{macro}{\aemph*} The \enquote*{starred} version of this
  3615. % command alway puts the stroke over its argument.
  3616. % \changes{v1.9.2}{2017/10/24}{Starred version which always puts the
  3617. % stroke over its argument}
  3618. % \begin{macrocode}
  3619. \AtBeginDocument{\ifdef{\aemph}%
  3620. {\RenewDocumentCommand{\aemph}{s m}{%
  3621. \IfBooleanTF{#1}{%
  3622. $\overline{\text{#2}}$}
  3623. {\luadirect{tex.sprint(aemph(\luastringN{#2}))}}}}
  3624. {\NewDocumentCommand{\aemph}{s m}{%
  3625. \IfBooleanTF{#1}{%
  3626. $\overline{\text{#2}}$}
  3627. {\luadirect{tex.sprint(aemph(\luastringN{#2}))}}}}}
  3628. % \end{macrocode}
  3629. % \end{macro}
  3630. % \end{macro}
  3631. % \begin{macro}{\SetInputScheme}
  3632. % \changes{v1.4}{2016/07/05}{\cs{SetInputScheme} can be used to
  3633. % process other input schemes such as \enquote*{Buckwalter}}
  3634. % \package{arabluatex} is designed for processing Arab\TeX\ input
  3635. % notation. \cs{SetInputScheme} may be used in the preamble or at
  3636. % any point of the document should the user wish to use a different
  3637. % notation such as the \enquote*{Buckwalter scheme}.
  3638. % \begin{macrocode}
  3639. \def\al@input@scheme{arabtex}
  3640. \NewDocumentCommand{\SetInputScheme}{m}{\def\al@input@scheme{#1}}
  3641. % \end{macrocode}
  3642. % \end{macro}
  3643. % \begin{macro}{\SetArbEasy}
  3644. % \changes{v1.2}{2016/05/09}{New \cs{SetArbEasy}/\cs{SetArbDflt} for
  3645. % \enquote*{modern} or \enquote*{classic} Arabic styles.}
  3646. % \begin{macro}{\SetArbEasy*}
  3647. % \changes{v1.4.4}{2016/09/28}{this starred version discards the
  3648. % \arb[trans]{sukUn} in addition to what is already discarded by
  3649. % \cs{SetArbEasy}.}
  3650. % \begin{macro}{\SetArbDflt}
  3651. % By default, \package{arabluatex} applies complex rules to generate
  3652. % euphonic \arb[trans]{ta^sdId}, \arb[trans]{'alif mamdUdaT} and
  3653. % \arb[trans]{sukUn} depending on the modes which are selected,
  3654. % either |voc|, |fullvoc| or |trans|. Such refinements can be
  3655. % discarded with \cs{SetArbEasy}, either globally in the preamble or
  3656. % at any point of the document. Note that \cs{SetArbEasy} keeps the
  3657. % \arb[trans]{sukUn} that is generated, while the starred version
  3658. % \cs{SetArbEasy*} takes it away. Default complex rules can be set
  3659. % back at any point of the document with \cs{SetArbDflt}.
  3660. % \begin{macro}{\SetArbDflt*}
  3661. % \changes{v1.6}{2016/12/17}{This starred version applies the
  3662. % assimilation rules in addition to what \cs{SetArbDflt} already
  3663. % does.} As of v1.6, \package{arabluatex} does not applies any more
  3664. % the assimilation rules that are laid on \vref{ref:assimilation}; a
  3665. % new starred version \cs{SetArbDflt*} is now available to the user
  3666. % should he wish to apply them.
  3667. % \begin{macrocode}
  3668. \def\al@arb@rules{dflt}
  3669. \NewDocumentCommand{\SetArbEasy}{s}{%
  3670. \IfBooleanTF{#1}
  3671. {\def\al@arb@rules{easynosukun}}
  3672. {\def\al@arb@rules{easy}}}
  3673. \NewDocumentCommand{\SetArbDflt}{s}{%
  3674. \IfBooleanTF{#1}
  3675. {\def\al@arb@rules{idgham}}
  3676. {\def\al@arb@rules{dflt}}}
  3677. % \end{macrocode}
  3678. % \end{macro}
  3679. % \end{macro}
  3680. % \end{macro}
  3681. % \end{macro}
  3682. % \begin{macro}{\SetTranslitFont}
  3683. % \changes{v1.4}{2016/07/05}{For selecting a specific font for
  3684. % transliterated texts} By default, the font that is used for
  3685. % transliterated text is the main font of the document. Any other
  3686. % font may also be selected with the font-selecting commands of the
  3687. % \package{fontspec} package.
  3688. % \begin{macrocode}
  3689. \def\al@trans@font{\rmfamily}%
  3690. \NewDocumentCommand{\SetTranslitFont}{m}{\def\al@trans@font{#1}}
  3691. % \end{macrocode}
  3692. % \end{macro}
  3693. % \begin{macro}{\SetTranslitStyle} By default any transliterated
  3694. % Arabic text is printed in italics. This can be changed either
  3695. % globally in the preamble or at any point of the document:
  3696. % \begin{macrocode}
  3697. \def\al@trans@style{\itshape}%
  3698. \NewDocumentCommand{\SetTranslitStyle}{m}{\def\al@trans@style{#1}}
  3699. % \end{macrocode}
  3700. % \end{macro}
  3701. % \begin{macro}{\SetTranslitConvention}
  3702. % \cs{SetTranslitConvention}\marg{convention} can be used to change
  3703. % the transliteration convention, which is |dmg| by default:
  3704. % \begin{macrocode}
  3705. \def\al@trans@convention{dmg}
  3706. \NewDocumentCommand{\SetTranslitConvention}{m}{\def\al@trans@convention{#1}}
  3707. % \end{macrocode}
  3708. % \end{macro}
  3709. % \begin{macro}{\arbup}
  3710. % \changes{v1.3}{2016/05/28}{\arb[trans]{'i`rAb} is now written as
  3711. % superscript text in \texttt{dmg} mode by default.}
  3712. % \begin{macro}{\NoArbUp}
  3713. % \begin{macro}{\ArbUpDflt}
  3714. % \begin{macro}{\SetArbUp}
  3715. % By default, \cs{arbup} is set to \cs{textsuperscript}. This is how
  3716. % the \arb[trans]{tanwIn} that takes place at the end of a word
  3717. % should be displayed in |dmg| mode. \cs{NoArbUp} may be used
  3718. % either in the preamble or at any point of the document in case one
  3719. % wishes to have the \arb[trans]{tanwIn} on the line. The default
  3720. % rule can be set back with \cs{ArbUpDflt} at any point of the
  3721. % document. Finally \cs{SetArbUp} can be used to customize the way
  3722. % \arb[trans]{tanwIn} is displayed: this command takes the
  3723. % formatting directives as argument, like so:
  3724. % \cs{SetArbUp}\marg{code}.
  3725. % \begin{macrocode}
  3726. \NewDocumentCommand{\al@arbup@dflt}{m}{\textsuperscript{\thinspace#1}}%
  3727. \NewDocumentCommand{\al@arbup}{m}{\al@arbup@dflt{#1}}
  3728. \NewDocumentCommand{\arbup}{m}{\al@arbup{#1}}
  3729. \NewDocumentCommand{\ArbUpDflt}{}{\let\al@arbup=\al@arbup@dflt}
  3730. \NewDocumentCommand{\NoArbUp}{}{\RenewDocumentCommand{\al@arbup}{m}{##1}}
  3731. \NewDocumentCommand{\SetArbUp}{m}{\RenewDocumentCommand{\al@arbup}{m}{#1}}
  3732. % \end{macrocode}
  3733. % \end{macro}
  3734. % \end{macro}
  3735. % \end{macro}
  3736. % \end{macro}
  3737. % \begin{macro}{\uc} Proper Arabic names or book titles should be
  3738. % passed to the \cs{uc} command so that they have their first letters
  3739. % uppercased. \cs{uc} is actually coded in Lua.
  3740. % \begin{macrocode}
  3741. \NewDocumentCommand{\uc}{m}%
  3742. {\luadirect{tex.sprint(uc(\luastringN{#1}))}}
  3743. % \end{macrocode}
  3744. % \end{macro}
  3745. % \begin{macro}{\Uc} \cs{uc} can be used safely in all of the modes
  3746. % that are provided by \package{arabluatex} as any of the |voc|,
  3747. % |fullvoc| and |novoc| modes discard it on top of any other
  3748. % functions to be run. \cs{Uc} does the same as \cs{uc} except
  3749. % that \emph{it is never discarded}. For that reason, \cs{Uc}
  3750. % \emph{should never be used outside the} |trans|
  3751. % \emph{mode}. \package{arabluatex} uses \cs{Uc} internally so as
  3752. % to prevent \cs{uc} from being discarded in case words that are to
  3753. % be transliterated are inserted into Arabic commands or
  3754. % environments where transliteration is not required. Therefore, it
  3755. % is not documented.
  3756. % \begin{macrocode}
  3757. \let\Uc\uc
  3758. % \end{macrocode}
  3759. % \end{macro}
  3760. % \begin{macro}{\prname}\changes{v1.10}{2018/01/03}{New command for
  3761. % typesetting Arabic proper names in transliteration} \cs{prname} is
  3762. % to be used outside Arabic environments for proper names. It takes as
  3763. % argument one or more Arabic words, each of which will be rendered in
  3764. % upright roman style with its first letter uppercased.
  3765. % \begin{macrocode}
  3766. \NewDocumentCommand{\prname}{m}{%
  3767. \bgroup\SetTranslitStyle{\relax}\arb[trans]{\uc{#1}}\egroup}
  3768. % \end{macrocode}
  3769. % \end{macro}
  3770. % \begin{macro}{\txarb} \cs{txarb} sets the direction to right-to-left
  3771. % and selects the Arabic font. It is used internally by several Lua
  3772. % functions, but available to the user should he wish to insert
  3773. % |utf8| Arabic text in his document.
  3774. % \begin{macro}{\txtrans} \cs{txtrans} is used internally by several
  3775. % Lua functions to insert transliterated Arabic text. Therefore, it is
  3776. % not documented.
  3777. % \begin{macrocode}
  3778. \NewDocumentCommand{\txarb}{+m}{\bgroup\textdir
  3779. TRT\arabicfont#1\egroup}
  3780. \NewDocumentCommand{\txtrans}{+m}{\bgroup\textdir
  3781. TLT\al@trans@font#1\egroup}
  3782. % \end{macrocode}
  3783. % \end{macro}
  3784. % \end{macro}
  3785. % \begin{environment}{txarab}
  3786. % \changes{v1.5}{2016/11/14}{New \texttt{txarab} environment for
  3787. % typesetting running paragraphs in Unicode Arabic} The |txarab|
  3788. % environment does for paragraphs the same as \cs{txarb} does for
  3789. % short insertions of |utf8| Arabic text.
  3790. % \begin{macrocode}
  3791. \NewDocumentEnvironment{txarab}{}{%
  3792. \par%
  3793. \booltrue{al@rlmode}%
  3794. \pardir TRT\textdir TRT\arabicfont}{\par}
  3795. % \end{macrocode}
  3796. % \end{environment}
  3797. % \begin{macro}{\arb}
  3798. % The \cs{arb} command detects which Arabic mode is to be used,
  3799. % either globally if no option is set, or locally, then passes its
  3800. % argument to the appropriate Lua function.
  3801. % \begin{macrocode}
  3802. \NewDocumentCommand{\arb}{O{\al@mode} +m}%
  3803. {\edef\@tempa{#1}%
  3804. \ifx\@tempa\al@mode@voc%
  3805. \bgroup\textdir TRT\arabicfont%
  3806. \luadirect{tex.sprint(processvoc(\luastringN{#2},
  3807. \luastringO{\al@arb@rules}, \luastringO{\al@input@scheme}))}\egroup%
  3808. \else%
  3809. \ifx\@tempa\al@mode@fullvoc%
  3810. \bgroup\textdir TRT\arabicfont%
  3811. \luadirect{tex.sprint(processfullvoc(\luastringN{#2},
  3812. \luastringO{\al@arb@rules}, \luastringO{\al@input@scheme}))}\egroup%
  3813. \else%
  3814. \ifx\@tempa\al@mode@novoc%
  3815. \bgroup\textdir TRT\arabicfont%
  3816. \luadirect{tex.sprint(processnovoc(\luastringN{#2},
  3817. \luastringO{\al@arb@rules}, \luastringO{\al@input@scheme}))}\egroup%
  3818. \else%
  3819. \ifx\@tempa\al@mode@trans%
  3820. \bgroup\textdir TLT\al@trans@style%
  3821. \luadirect{tex.sprint(processtrans(\luastringN{#2},
  3822. \luastringO{\al@trans@convention},
  3823. \luastringO{\al@arb@rules},
  3824. \luastringO{\al@input@scheme}))}\egroup%
  3825. \else%
  3826. \fi\fi\fi\fi}
  3827. % \end{macrocode}
  3828. % \end{macro}
  3829. % \begin{macro}{\arbmark}
  3830. % \changes{v1.11}{2018/03/31}{New command for inserting additional
  3831. % marks in Arabic environments} \cs{arbmark} takes one argument from a
  3832. % list of defined elements. This command is coded in Lua.
  3833. % \begin{macrocode}
  3834. \NewDocumentCommand{\arbmark}{m}{%
  3835. \bgroup%
  3836. \SetInputScheme{arabtex}%
  3837. \luadirect{tex.sprint(processarbmarks(\luastringN{#1}))}%
  3838. \egroup}
  3839. % \end{macrocode}
  3840. % \end{macro}
  3841. % \begin{macro}{\newarbmark}
  3842. % \changes{v1.11}{2018/03/31}{Allows defining additional sets of Arabic
  3843. % marks} \cs{newarbmark} lets the user define additional Arabic
  3844. % marks. As \cs{arbmark}, this command is coded in Lua. It takes
  3845. % three arguments: the abbreviated form to be used as argument of
  3846. % \cs{arbmark}, the rendition in Arabic script and the rendition in
  3847. % romanized Arabic.
  3848. % \begin{macrocode}
  3849. \NewDocumentCommand{\newarbmark}{m m m}{%
  3850. \luadirect{newarbmark(\luastringN{#1}, \luastringN{#2}, \luastringN{#3})}}
  3851. % \end{macrocode}
  3852. % \end{macro}
  3853. % \begin{environment}{arab}
  3854. % The |arab| environment does for paragraphs the same as \cs{arb} does
  3855. % for short insertions of Arabic text.
  3856. % \begin{macrocode}
  3857. \NewEnviron{arab}[1][\al@mode]%
  3858. {\par\edef\@tempa{#1}%
  3859. \ifx\@tempa\al@mode@voc%
  3860. \booltrue{al@rlmode}%
  3861. \bgroup\pardir TRT\textdir TRT\arabicfont%
  3862. \luadirect{tex.sprint(processvoc(\luastringO{\BODY},
  3863. \luastringO{\al@arb@rules}, \luastringO{\al@input@scheme}))}\egroup%
  3864. \else%
  3865. \ifx\@tempa\al@mode@fullvoc%
  3866. \booltrue{al@rlmode}%
  3867. \bgroup\pardir TRT\textdir TRT\arabicfont%
  3868. \luadirect{tex.sprint(processfullvoc(\luastringO{\BODY},
  3869. \luastringO{\al@arb@rules}, \luastringO{\al@input@scheme}))}\egroup%
  3870. \else%
  3871. \ifx\@tempa\al@mode@novoc%
  3872. \booltrue{al@rlmode}%
  3873. \bgroup\pardir TRT\textdir TRT\arabicfont%
  3874. \luadirect{tex.sprint(processnovoc(\luastringO{\BODY},
  3875. \luastringO{\al@arb@rules}, \luastringO{\al@input@scheme}))}\egroup%
  3876. \else%
  3877. \ifx\@tempa\al@mode@trans%
  3878. \bgroup\pardir TLT\textdir TLT\al@trans@style%
  3879. \luadirect{tex.sprint(processtrans(\luastringO{\BODY},
  3880. \luastringO{\al@trans@convention},
  3881. \luastringO{\al@arb@rules},
  3882. \luastringO{\al@input@scheme}))}\egroup%
  3883. \else \fi\fi\fi\fi}[\par]
  3884. % \end{macrocode}
  3885. % \end{environment}
  3886. % \begin{environment}{arabverse}
  3887. % \changes{v1.6}{2016/12/17}{New environment \texttt{arabverse} for
  3888. % typesetting Arabic poetry} The |arabverse| environment may receive
  3889. % different options: |mode|, |width|, |gutter|, |metre|, |utf|
  3890. % and |delim|; all of them are defined here just before the
  3891. % |arabverse| environment:
  3892. % \begin{macrocode}
  3893. \newlength{\al@bayt@width}
  3894. \newlength{\al@gutter@width}
  3895. \setlength{\al@bayt@width}{.3\textwidth}
  3896. \setlength{\al@gutter@width}{.15\al@bayt@width}
  3897. \define@key[al]{verse}{width}{\setlength{\al@bayt@width}{#1}}
  3898. \define@key[al]{verse}{gutter}{\setlength{\al@gutter@width}{#1}}
  3899. \define@key[al]{verse}{metre}{\arb{#1}}
  3900. \define@boolkey[al]{verse}{utf}[true]{}
  3901. \define@boolkey[al]{verse}{delim}[true]{}
  3902. \define@choicekey[al]{verse}{mode}{fullvoc, voc, novoc,
  3903. trans}{\def\al@mode{#1}}
  3904. \presetkeys[al]{verse}{metre={}, utf=false,
  3905. delim=false}{}
  3906. % \end{macrocode}
  3907. % Then follows the environment itself:
  3908. % \begin{macrocode}
  3909. \NewDocumentEnvironment{arabverse}{O{}}%
  3910. {\par\centering\noindent\bgroup\setkeys[al]{verse}[metre]{#1}%
  3911. \ifx\al@mode\al@mode@trans%
  3912. \ifal@verse@utf\setRL\else\setLR\fi%
  3913. \else\setRL\fi}%
  3914. {\hfill\setkeys[al]{verse}[width,gutter,utf,mode]{#1}\egroup}
  3915. % \end{macrocode}
  3916. % \begin{macro}{\bayt}
  3917. % \changes{v1.6}{2016/12/17}{New macro \cs{bayt} for typesetting
  3918. % each verse inside the \texttt{arabverse} environment} Each verse
  3919. % consists of two hemistichs; therefore the \cs{bayt} command takes
  3920. % two arguments, the first receives the \arb[trans]{.sadr} and the
  3921. % second the \arb[trans]{`ajuz}. That two subsequent hemistichs
  3922. % should be connected with one another is technically named
  3923. % \arb[trans]{tadwIr}. In some of these cases, the hemistichs may be
  3924. % connected by a prominent horizontal flexible stroke which is drawn
  3925. % by the \cs{al@verse@stroke} command.
  3926. % \begin{macro}{\SetHemistichDelim}
  3927. % \changes{v1.6}{2016/12/17}{New \cs{SetHemistichDelim} command for
  3928. % changing the default delimiter between hemistichs} A hemistich
  3929. % delimiter also may be defined. By default, it is set to the
  3930. % \enquote*{star} character: |*|. The
  3931. % \cs{SetHemistichDelim}\marg{delimiter} command can be used at any
  3932. % point of the document to change this default setting.
  3933. % \end{macro}
  3934. % \begin{macrocode}
  3935. \NewDocumentCommand{\arb@utf}{m}{%
  3936. \ifal@verse@utf\txarb{#1}\else\arb{#1}\fi}
  3937. \def\al@hemistich@delim{*}
  3938. \NewDocumentCommand{\SetHemistichDelim}{m}{\def\al@hemistich@delim{#1}}
  3939. \def\al@verse@stroke{\leavevmode\xleaders\hbox{\arb{--}}\hfill\kern0pt}
  3940. \NewDocumentCommand{\bayt}{m o m}{%
  3941. \ifdefined\savenotes\savenotes\else\fi%
  3942. \edef\al@tatweel{--}%
  3943. \adjustbox{width=\al@bayt@width, height=\Height}{\arb@utf{#1}}%
  3944. \IfNoValueTF{#2}{%
  3945. \ifal@verse@delim\makebox[\al@gutter@width][c]{\al@hemistich@delim}%
  3946. \else%
  3947. \hspace{\al@gutter@width}%
  3948. \fi
  3949. }{%
  3950. \edef\@tempa{#2}%
  3951. \ifx\@tempa\al@tatweel%
  3952. \ifx\al@mode\al@mode@trans%
  3953. \hspace{\al@gutter@width}%
  3954. \else%
  3955. \makebox[\al@gutter@width][s]{\al@verse@stroke}%
  3956. \fi%
  3957. \else%
  3958. \ifx\al@mode\al@mode@trans%
  3959. \adjustbox{width=\al@gutter@width, height=\Height}{\arb@utf{#2}}%
  3960. \else%
  3961. \makebox[\al@gutter@width][s]{\arb@utf{#2}}%
  3962. \fi\fi}%
  3963. \adjustbox{width=\al@bayt@width, height=\Height}{\arb@utf{#3}}%
  3964. \ifdefined\spewnotes\spewnotes\else\fi%
  3965. }
  3966. % \end{macrocode}
  3967. % \end{macro}
  3968. % \end{environment}
  3969. % \begin{macro}{\abjad} \cs{abjad}\marg{number} expresses its argument
  3970. % in Arabic letters in accordance with the \arb[trans]{'abjad}
  3971. % arrangement of the alphabet. \meta{number} must be between 1 and
  3972. % 1999. It is now coded in Lua so that \package{polyglossia} is no
  3973. % longer needed. See |arabluatex.lua| for more information.
  3974. % \changes{v1.1}{2016/04/26}{New and more flexible \protect\cs{abjad}
  3975. % command.}
  3976. % \begin{macrocode}
  3977. \AtBeginDocument{%
  3978. \ifdefined\abjad%
  3979. \RenewDocumentCommand{\abjad}{m}%
  3980. {\luadirect{tex.sprint(abjadify(#1))}}%
  3981. \else%
  3982. \NewDocumentCommand{\abjad}{m}%
  3983. {\luadirect{tex.sprint(abjadify(#1))}}
  3984. \fi}
  3985. % \end{macrocode}
  3986. % \end{macro}
  3987. % \begin{macro}{\arbnull}
  3988. % \changes{v1.7}{2016/12/24}{New \cs{arbnull} command for putting
  3989. % back on any contextual analysis rule broken by other commands.}
  3990. % The \cs{arbnull} command does nothing by itself. It is processed
  3991. % only if it is found in Arabic context so as to put back on
  3992. % contextual analysis in case it has been broken by other commands.
  3993. % \begin{macrocode}
  3994. \NewDocumentCommand{\arbnull}{m}{\relax}
  3995. % \end{macrocode}
  3996. % \end{macro}
  3997. % \begin{macro}{\abraces}
  3998. % \cs{abraces}\marg{Arabic text} puts its argument between
  3999. % braces. This macro is written in Lua and is dependent on the
  4000. % current value of |tex.textdir|.
  4001. % \changes{v1.4.3}{2016/09/14}{New \cs{abraces} command which
  4002. % expresses its argument between braces.}
  4003. % \begin{macrocode}
  4004. \NewDocumentCommand{\abraces}{+m}{%
  4005. \luadirect{tex.sprint(abraces(\luastringN{#1}))}}
  4006. % \end{macrocode}
  4007. % \end{macro}
  4008. % \begin{macro}{\LRmarginpar} \cs{LRmarginpar} is supposed to be
  4009. % inserted in an Arabic environment. It typsets his argument in a
  4010. % marginal note from left to right.
  4011. % \begin{macrocode}
  4012. \DeclareDocumentCommand{\LRmarginpar}{m}{\marginpar{\textdir TLT #1}}
  4013. % \end{macrocode}
  4014. % \end{macro}
  4015. % \begin{macro}{\LRfootnote} \cs{LRfootnote} and \cs{RLfootnote} are
  4016. % supposed to be used in Arabic environments for insertions of non
  4017. % Arabic text. \cs{LRfootnote} typesets its argument left-to-right\ldots
  4018. % \begin{macro}{\RLfootnote} while \cs{RLfootnote} typesets its
  4019. % argument left-to-right.
  4020. % \begin{macrocode}
  4021. \DeclareDocumentCommand{\LRfootnote}{m}{\bgroup\pardir
  4022. TLT\textdir TLT\footnote{#1}\egroup}
  4023. \DeclareDocumentCommand{\RLfootnote}{m}{\bgroup\pardir
  4024. TRT\textdir TRT\footnote{#1}\egroup}
  4025. % \end{macrocode}
  4026. % \end{macro}
  4027. % \end{macro}
  4028. % \begin{macro}{\FixArbFtnmk} In the preamble, just below
  4029. % \cs{usepackage}|{arabluatex}|, \cs{FixArbFtnmk} may be of some
  4030. % help in case the footnote numbers at the bottom of the page are
  4031. % printed in the wrong direction. This quick fix uses and loads
  4032. % \package{scrextend} if it is not already loaded.
  4033. % \begin{macrocode}
  4034. \NewDocumentCommand{\FixArbFtnmk}{}{%
  4035. \@ifpackageloaded{scrextend}%
  4036. {\AtBeginDocument{\deffootnote{2em}{1.6em}{\LR{\thefootnotemark}.\enskip}}}%
  4037. {\RequirePackage{scrextend}
  4038. \AtBeginDocument{\deffootnote{2em}{1.6em}{\LR{\thefootnotemark}.\enskip}}}}
  4039. % \end{macrocode}
  4040. % \end{macro}
  4041. % That is it. Say goodbye before leaving.
  4042. %
  4043. % \iffalse
  4044. %</package>
  4045. % \fi
  4046. %
  4047. % \subsection*{Patches}
  4048. % \label{sec:patches}
  4049. %
  4050. % \iffalse
  4051. %<*patch>
  4052. % \fi
  4053. % \begin{macrocode}
  4054. \NeedsTeXFormat{LaTeX2e}
  4055. \ProvidesPackage{arabluatex-patch}%
  4056. [2016/11/14 v1.0 patches for arabluatex]
  4057. % \end{macrocode}
  4058. % I have put in a separate |.sty| file external lines of code that
  4059. % I had to patch for a good reason. I hate doing this, and hopefully,
  4060. % most of these lines will disappear as soon as they are not required
  4061. % anymore.
  4062. %
  4063. % The following is taken from |latex.ltx|. I had to make this patch
  4064. % for I could not find a way to process the list environments in
  4065. % right-to-left mode. The \LuaTeX\ primitives \cs{bodydir} and
  4066. % \cs{pagedir} will eventually allow us to get rid of this:
  4067. % \begin{macrocode}
  4068. \def\list#1#2{%
  4069. \ifnum \@listdepth >5\relax
  4070. \@toodeep
  4071. \else
  4072. \global\advance\@listdepth\@ne
  4073. \fi
  4074. \rightmargin\z@
  4075. \listparindent\z@
  4076. \itemindent\z@
  4077. \csname @list\romannumeral\the\@listdepth\endcsname
  4078. \def\@itemlabel{#1}%
  4079. \let\makelabel\@mklab
  4080. \@nmbrlistfalse
  4081. #2\relax
  4082. \@trivlist
  4083. \parskip\parsep
  4084. \parindent\listparindent
  4085. \advance\linewidth -\rightmargin
  4086. \advance\linewidth -\leftmargin
  4087. % \end{macrocode}
  4088. % patch begins:
  4089. % \begin{macrocode}
  4090. \ifbool{al@rlmode}{\advance\@totalleftmargin \rightmargin}%
  4091. {\advance\@totalleftmargin \leftmargin}
  4092. % \end{macrocode}
  4093. % patch ends.
  4094. % \begin{macrocode}
  4095. \parshape \@ne \@totalleftmargin \linewidth
  4096. \ignorespaces}
  4097. \def\@item[#1]{%
  4098. \if@noparitem
  4099. \@donoparitem
  4100. \else
  4101. \if@inlabel
  4102. \indent \par
  4103. \fi
  4104. \ifhmode
  4105. \unskip\unskip \par
  4106. \fi
  4107. \if@newlist
  4108. \if@nobreak
  4109. \@nbitem
  4110. \else
  4111. \addpenalty\@beginparpenalty
  4112. \addvspace\@topsep
  4113. \addvspace{-\parskip}%
  4114. \fi
  4115. \else
  4116. \addpenalty\@itempenalty
  4117. \addvspace\itemsep
  4118. \fi
  4119. \global\@inlabeltrue
  4120. \fi
  4121. \everypar{%
  4122. \@minipagefalse
  4123. \global\@newlistfalse
  4124. \if@inlabel
  4125. \global\@inlabelfalse
  4126. {\setbox\z@\lastbox
  4127. \ifvoid\z@
  4128. \kern-\itemindent
  4129. \fi}%
  4130. \box\@labels
  4131. \penalty\z@
  4132. \fi
  4133. \if@nobreak
  4134. \@nobreakfalse
  4135. \clubpenalty \@M
  4136. \else
  4137. \clubpenalty \@clubpenalty
  4138. \everypar{}%
  4139. \fi}%
  4140. \if@noitemarg
  4141. \@noitemargfalse
  4142. \if@nmbrlist
  4143. \refstepcounter\@listctr
  4144. \fi
  4145. \fi
  4146. % \end{macrocode}
  4147. % patch begins:
  4148. % \begin{macrocode}
  4149. \ifbool{al@rlmode}{\sRLbox\@tempboxa{\makelabel{#1}}}{%
  4150. \sbox\@tempboxa{\makelabel{#1}}}%
  4151. \ifbool{al@rlmode}{\global\setbox\@labels\hbox dir TRT}%
  4152. {\global\setbox\@labels\hbox}{%
  4153. % \end{macrocode}
  4154. % patch ends.
  4155. % \begin{macrocode}
  4156. \unhbox\@labels
  4157. \hskip \itemindent
  4158. \hskip -\labelwidth
  4159. \hskip -\labelsep
  4160. \ifdim \wd\@tempboxa >\labelwidth
  4161. \box\@tempboxa
  4162. \else
  4163. \hbox to\labelwidth {\unhbox\@tempboxa}%
  4164. \fi
  4165. \hskip \labelsep}%
  4166. \ignorespaces}
  4167. % \end{macrocode}
  4168. % This is adapted from Vafa Khalighi's \package{bidi} package. Thanks
  4169. % to him.
  4170. % \begin{macrocode}
  4171. \long\def\sRLbox#1#2{\setbox#1\hbox dir TRT{%
  4172. \color@setgroup#2\color@endgroup}}
  4173. % \end{macrocode}
  4174. %
  4175. % \iffalse
  4176. %</patch>
  4177. % \fi
  4178. %
  4179. % \Finale
  4180. \endinput