7

Is there a way to get time and date stamps, or other standard counters, to appear in Chinese? I am using xeCJK.

Package babel (with \selectlanguage{french} etc. in context) makes it simple for the major European languages.

doncherry
  • 54,637

1 Answers1

11

The package zhnumber provides many macros to convert numbers, counters, dates and times into their Chinese representation.

Unfortunately, I can only understand the macro and option names in the manual.

In Use of Chinese numers similar to \Roman and \Arabic you can find another example that uses LaTeX counters.

Code

\documentclass{article}
\usepackage{xeCJK}
\setCJKmainfont{SimSun}
\usepackage{zhnumber}
\begin{document}
Date: \zhtoday

Time: \zhcurrtime

\zhnumsetup{time=Chinese}
Date: \zhtoday

Time: \zhcurrtime

\zhnumsetup{time=Arabic}
1586/08/17: \zhdate{1586/08/17}
\end{document}

Output

enter image description here

Qrrbrbirlbel
  • 119,821