Japanese needs handling Western text does not — vertical writing, line-break rules (*kinsoku*, characters forbidden at the start or end of a line), and spacing between Japanese and Latin. TeX offers two mature routes: the long-standing pLaTeX / upLaTeX (via DVI and dvipdfmx) and the modern LuaLaTeX-ja (PDF directly, OpenType fonts). This page maps the landscape and shows how to start with each.
The Japanese TeX landscape
Japanese typesetting was founded on the pTeX engine developed at ASCII Corporation, which brought vertical writing, *kinsoku*, and Japanese–Latin spacing into TeX. LaTeX on top of it is pLaTeX. Later came upTeX / upLaTeX, whose internals are Unicode, and then LuaTeX-ja, which ports Japanese typesetting to the modern LuaTeX engine. In practice your choices are three: pLaTeX, upLaTeX, and LuaLaTeX-ja (for the engines themselves, see “The pTeX family”).
Typeset with pLaTeX / upLaTeX
First pick a Japanese document class — the widely-used jsclasses (jsarticle, jsbook, by Haruhiko Okumura) or the modern, JLReq-compliant jlreq. For upLaTeX, pass the uplatex class option. Build with uplatex → DVI → dvipdfmx (or ptex2pdf -l -u in one shot). upLaTeX handles all of Unicode, while plain pLaTeX is limited to the JIS X 0208 range.
% upLaTeX。uplatex main.tex && dvipdfmx main
\documentclass[uplatex]{jsarticle}
\begin{document}
日本語と English の混植。
\end{document}Typeset with LuaLaTeX-ja
The modern route is LuaTeX-ja: Japanese typesetting on LuaLaTeX, with native Unicode, OpenType/system fonts, and PDF output directly (no DVI step). Use a LuaTeX-ja class (ltjsarticle, or jlreq under lualatex) and set Japanese fonts with luatexja-fontspec’s \setmainjfont / \setsansjfont. Compile with lualatex.
% LuaLaTeX-ja。lualatex main.tex
\documentclass{ltjsarticle}
\usepackage{luatexja-fontspec}
\setmainjfont{Noto Serif CJK JP}
\begin{document}
日本語と English の混植。
\end{document}Japanese layout inserts subtle glue between characters: kanjiskip between Japanese characters, and xkanjiskip at Japanese–Western boundaries (the small gap around “日本語 and abc”). In LuaTeX-ja you tune these with \ltjsetparameter{...}; in pLaTeX/upLaTeX the classes set sensible defaults.
\ltjsetparameter{xkanjiskip=0.25\zw plus 1pt minus 1pt}Which to use
- Existing assets, speed, the paper standard →
upLaTeX(jsclassesorjlreq) +dvipdfmx. - Modern, OpenType fonts, direct PDF →
LuaLaTeX-ja(ltjsclassesorjlreq); increasingly the choice for new work. - Plain pLaTeX is limited to JIS X 0208, so for new documents prefer the up- or Lua-based route.
jlreqworks with pLaTeX, upLaTeX, and LuaLaTeX alike, and suits serious JLReq-compliant typesetting.