TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

When mixing Chinese text and non-math mode numbers together within a sentence, narrow numbers are given the same amount of space as characters:

\setCJKmainfont{Adobe Heiti Std}

In most situations, this appearance is probably ideal, however, in my case, I need to temporarily change this spacing, in a small number of instances. How can I force the characters to be printed closer to the "1" one has the same spacing it would have if it were placed among English text (with no spaces on either side)?

share|improve this question
up vote 5 down vote accepted

You can use \CJKsetecglue to set the spaces between CJK symbols and western symbols. This is documented in xeCJK.

\usepackage{ctexcap} % it will load xeCJK internally. Or just use ctexart instead of article
\setCJKmainfont{Adobe Heiti Std}
\CJKsetecglue{\hskip0.15em plus0.05em minus 0.05em}

However, you must be careful when you use a \hskip other than normal inter-word space. \CJKsetecglue only sets the space between the two different character class in XeTeX. There are still many cases xeCJK cannot add sapces automatically.

For example,

汉字\mbox{abc}汉字 % no spaces added

You should add proper spacing (but not a space) yourself these cases.

share|improve this answer
I don't want to change the spacing for the entire document, just in specific places. Is there a way to do this without changing all of the spacing everywhere? – Village Dec 15 '11 at 11:00
@Village: Just use \CJKsetecglue{...} in the group or envrionment you want. This is basic LaTeX usage like setting \rmfamily or redefining \arraystretch. – Leo Liu Dec 15 '11 at 13:44

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

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