I am new to ConTeXt and would like to know how to show the eastern numerals or Hindi numerals in ConTeXt document in terms of page numbers, footnote, and itemize environment. Please consider the MWE below:
MWE
\definefontfeature
[arabic]
[mode=node,language=dflt,script=arab,
init=yes,medi=yes,fina=yes,isol=yes,
liga=yes,dlig=yes,rlig=yes,clig=yes,
mark=yes,mkmk=yes,kern=yes,curs=yes]
\starttypescript [serif] [myfont]
\definefontsynonym [Serif] [file:/usr/share/fonts/opentype/scheherazade/Scheherazade-Regular.ttf] [features=arabic]
\stoptypescript
\starttypescript [myfont]
\definetypeface [\typescriptone] [rm] [serif] [myfont] [default]
\definetypeface [\typescriptone] [ss] [sans] [modern] [default]
\definetypeface [\typescriptone] [tt] [mono] [modern] [default]
\definetypeface [\typescriptone] [mm] [math] [modern] [default]
\stoptypescript
\setuppapersize [A4]
\mainlanguage[arabic]
\setupdirections[bidi=global]
\setupbodyfont[myfont,14pt]
\setupalign[r2l]
\setupheads[number=no]
% \setuplayout
% [grid=min]
% \showgrid
\starttext
هذا نص باللغة العربية وهذه ارقام عربية شرقية ١، ٢، ٣، ٤ ، ٥
\startitemize[n]
\item الجملة الاولى
\item الجملة الثانية
\item الجملة الثالثة
\stopitemize
This text is in Arabic\footnote{هذه هي الارقام العربية اما الارقام العربية الشرقية او الهندي فتراها في السطر الاول من الصفحة} and these are eastern numbers 1, 2, 3, 4, 5.
\stoptext
%%% Local Variables:
%%% mode: context
%%% TeX-master: t
%%% TeX-engine: luatex
%%% End:
Output
Desired Output
Is to show eastern numerals as those appearing in the first line of the compiled document in the following locations:
- page number (in the header) and hopefully will be so in TOC.
- Itemize numbers
- Footnote numbering (in the footer)
How to make that change globally as well as locally in the document?
The first five numbers in Hindi or eastern numerals are:
In Microsoft's parlance they are referred to as Hindi
numerals.
In polyglossia
's parlance they are referred to as mashriq
numerals:
% in LaTeX
\usepackage{polyglossia}
\setmainlanguage[numerals=mashriq]{arabic}
In ConTeXt's parlance they are referred to as Indic
numerals see Wiki
Note
ConTeXt ver: 2017.05.15 21:48 MKIV beta fmt: 2017.6.30
Update @Aditya
When I try \startitemize[arabicnumerals]
it shows Arabic letters, not numerals which is not the desired outcome for this post. However, this was an illuminating effect to me and would definitely use it when I want letters instead of numbers. This option should read [arabicletters]
and not [arabicnumerals]
in my humble opinion, otherwise it would be very confusing to show letters in the output when you mean numerals in your code!
When I use the second option \startitemize[devanagarinumerals]
it shows lowercase English letters as follows:
So neither one gave the desired output.
\startitemize[arabicnumerals]
or\startitemize[devanagarinumerals]
give you the numbers that you want? If so, you need to set the conversion of all numbers toarabicnumerals
.