2

I would like to change months names in context, in tex \month define the month number, names of months can be redefined with \ifcase Change month names in \today command

How can I do the same in context (modify names of months appearing with \date command), appears as \month unavailable in context.

Update

Here a MWE

\setuppapersize[A4]
\mainlanguage[arabic]
\setupdirections[bidi=global]
\setupalign[r2l] 

\definefontfeature
  [arabic]
  [mode=node,language=dflt,script=arab,
    init=yes,medi=yes,fina=yes,isol=yes,
    liga=yes,dlig=yes,rlig=yes,tlig=yes,
    calt=yes,trep=yes,clig=yes,
    mark=yes,mkmk=yes,kern=yes,curs=yes]


\starttypescript [serif] [arabic]
  \definefontsynonym [Arabic-Regular] [name:Amiri] [features=arabic]
  \definefontsynonym [Arabic-Bold] [name:Amiri] [features=arabic]
\stoptypescript

\starttypescript [serif] [arabic] [name]
 \usetypescript[serif][fallback]
 \definefontsynonym [Serif]     [Arabic-Regular] [features=arabic]
 \definefontsynonym [SerifBold] [Arabic-Bold]    [features=arabic]
\stoptypescript

\starttypescript [Arabic]
 \definetypeface [Arabic] [rm] [serif] [arabic] [default]
 \definetypeface [Arabic] [mm] [math]  [palatino] [default]
\stoptypescript 

\setuplayout[
  grid=min,
  backspace=20mm, width=170mm,
  topspace=10mm, height=275mm,
  header=10mm,footer=10mm,
  headerdistance=2mm
  ]

\setupbodyfont[Arabic,18pt]
\setupinterlinespace[line=30pt]

\starttext

\date

\stoptext 
3

If you don't want to change the main language of your document (using \mainlanguage[…] then you can redefine the months using \setuplabeltext:

\setuplabeltext
  %% [en]  %% for a language specific setting
  [january=J,
   february=F]

Furthermore, if you want to change the date format used by \date, you can do so with \setuplanguage:

\setuplanguage
  %% [en]  %% for a language specific setting
  [date={year, \thinspace–\thinspace, mm, \thinspace–\thinspace, dd}]
  • Thanks @Marco in my case I need just \setuplabeltext [arabic] [january=جانفي, february=فيفري] – Salim Bou Feb 16 '16 at 16:03

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.