X-Git-Url: http://git.osdn.jp/view?a=blobdiff_plain;f=doc%2Fluatexja.dtx;h=38531834b5306c39a4059482a17614af34c7068c;hb=a3e088ab9e03232e38ec4868ffd29dc3b5c58f70;hp=ac42d21a16174e97c892389e8cfc7815cb3a2314;hpb=345d41418762d68b31e0cf77a4cfb816fa7e2625;p=luatex-ja%2Fluatexja.git
diff --git a/doc/luatexja.dtx b/doc/luatexja.dtx
index ac42d21..3853183 100644
--- a/doc/luatexja.dtx
+++ b/doc/luatexja.dtx
@@ -21,23 +21,24 @@
\usepackage{metalogo,amsmath,array,tikz,pict2e,multienum,float}
\usepackage{booktabs,multicol,luatexja-ruby}
\usepackage[all]{xy}
-\usepackage{lltjext,alltt}
+\usepackage{lltjext,alltt,comment}
%%%%%%%% Lua GC
\patchcmd\@outputpage{\stepcounter{page}}{%
\directlua{%
- local k = collectgarbage("count")
- if k>900000 then
- collectgarbage("collect")
- texio.write_nl("term and log", "GC: ", math.floor(k), math.floor(collectgarbage("count")))
- end
+ if jit then
+ local k = collectgarbage("count")
+ if k>900000 then
+ collectgarbage("collect")
+ texio.write_nl("term and log", "GC: ", math.floor(k), math.floor(collectgarbage("count")))
+ end
+ end
}%
\stepcounter{page}%
}{}{}
%%%%%%%% fonts
\usepackage{luatexja-otf}
-\directlua{luatexja.otf.enable_ivs()}
\usepackage[no-math]{fontspec}
\setmainfont[Ligatures=TeX]{Linux Libertine O}
\setmonofont[Scale=MatchLowercase, ItalicFont=lmmono10-italic.otf,
@@ -56,7 +57,7 @@
\def\headfont{\normalfont\bfseries\gtfamily}\normalsize
%
%<*en>
-\frenchspacing
+\frenchspacing\sloppy
\usepackage[margin=25mm,lmargin=30mm,rmargin=30mm,footskip=6mm]{geometry}
\usepackage{luatexja-adjust}\ltjdisableadjust
\parskip=\smallskipamount
@@ -115,10 +116,12 @@
%<*en>
\title{The \LuaTeX-ja package}
\author{The \LuaTeX-ja project team}
+\date{\LuaTeXjaversion~(\today)}
%
%<*ja>
\title{\LuaTeX-jaããã±ã¼ã¸}
\author{\LuaTeX-jaããã¸ã§ã¯ããã¼ã }
+\date{\LuaTeXjaversionï¼\todayï¼}
%
\hypersetup{%
unicode,
@@ -134,6 +137,16 @@
pdftitle={LuaTeX-jaããã±ã¼ã¸}
%
}
+%<*ja>
+\def\HyRef@autoref#1#2{%
+ \begingroup
+ \Hy@safe@activestrue
+ \expandafter\HyRef@autosetref\csname r@#2\endcsname{#2}{#1}%
+ \endgroup\ltjalchar"200C %" 欧æã´ã¼ã¹ã
+}
+\def\figureautorefname{å³}
+\def\tableautorefname{表}
+%
%%%%%%%% definition env.
\usepackage{amsthm}
@@ -176,7 +189,7 @@
\def\_{\leavevmode \kern .06em\vbox {\hrule \@width .333em}}
\def\cs#1{\texttt{\upshape
- \texorpdfstring{\textbackslash\ltjsetparameter{autoxspacing=false}#1}{\textbackslash#1}}}
+ \texorpdfstring{\textbackslash\hbox{\ltjsetparameter{autoxspacing=false}#1}}{\textbackslash#1}}}
\ltjsetparameter{alxspmode={`\\,allow}}
%%%%%%%%
\makeatother
@@ -322,7 +335,7 @@ For more detailed information, see Part~\ref{part-imp} or other sections of this
%<*en>
\paragraph{Command names} \pTeX\ addes several primitives, such as \cs{kanjiskip},
-\cs{prebreakpenalty},~and,~\cs{ifydir}. They can be used as follows:
+\cs{prebreakpenalty},~and \cs{ifydir}. They can be used as follows:
%
%<*ja>
\paragraph{å½ä»¤ã®å称} ä¾ãã°\pTeX ã§è¿½å ããã次ã®ãããªããªããã£ã
@@ -446,7 +459,7 @@ on the content of the register \emph{only}. This is major difference with \pTeX.
%
%<*ja>
\paragraph{çµæ¹å}
-20150420.0çããã¯ï¼ä¸å®å®ãªããã\LuaTeX-ja ã«ããã縦çµã¿ããµãã¼ããã¦ããï¼
+ãã¼ã¸ã§ã³20150420.0ããã¯ï¼ä¸å®å®ãªããã\LuaTeX-ja ã«ããã縦çµã¿ããµãã¼ããã¦ããï¼
ãªãï¼\LuaTeX æ¬ä½ã$\Omega$æµã®çµæ¹åããµãã¼ããã¦ãããï¼ããã¨ã¯å
¨ãã®å¥ç©ã§ãããã¨
ã«æ³¨æãã¦ã»ããï¼
ç¹ã«ï¼ç°ãªã£ãçµæ¹åã®ããã¯ã¹ãæ±ãå ´åã«ã¯
@@ -489,7 +502,7 @@ without the \cs{fontspec} (and~\Pkg{luatexja-fontspec}) package.
詳ãã説æã¯\ref{ssec-setrange}ç¯ãåç
§ãã¦ã»ããï¼
ã¾ãï¼\P,~\S ã¨ãã£ãISO~8859-1ã®ä¸ä½é åã¨JIS~X~0208ã®å
±éé¨åã®æåã¯
- 20150906.0çããæ¨æºã§æ¬§ææ±ãã¨ãªã£ãï¼\LaTeXe\ 2017/01/01以éã§ã¯
+ ãã¼ã¸ã§ã³20150906.0ããæ¨æºã§æ¬§ææ±ãã¨ãªã£ãï¼\LaTeXe\ 2017/01/01以éã§ã¯
æ¨æºã§TUã¨ã³ã³ã¼ãã£ã³ã°ã®Latin Modernãã©ã³ãã使ãããã®ã§ï¼
ç¹ã«ä½ãããã½ã¼ã¹ä¸ã«ãã®ã¾ã¾è¨è¿°ãã¦ããããã®æåãåºåããã
\footnote{\LaTeXe\ 2017/01/01ããåã§ã¯ï¼ã½ã¼ã¹ä¸ã«ç´æ¥è¨è¿°ãã¦ã
@@ -559,10 +572,10 @@ and \emph{Japanese fonts} for fonts used in \textbf{JAchar}.
%
%<*en>
\item In this document, natural numbers start from~zero.
- $\omega$ denotes the set of all natural numbers.
+ $\omega$ denotes the set of all natural numbers which can be used in \TeX.
%
%<*ja>
-\item æ¬ããã¥ã¡ã³ãã§ã¯ï¼èªç¶æ°ã¯0ããå§ã¾ãï¼èªç¶æ°å
¨ä½ã®éåã¯$\omega$ã¨è¡¨è¨ããï¼
+\item æ¬ããã¥ã¡ã³ãã§ã¯ï¼èªç¶æ°ã¯0ããå§ã¾ãï¼ï¼\TeX ã§æ±ããï¼èªç¶æ°å
¨ä½ã®éåã¯$\omega$ã¨è¡¨è¨ããï¼
%
\end{itemize}
@@ -623,15 +636,15 @@ and \emph{Japanese fonts} for fonts used in \textbf{JAchar}.
\item \LuaTeX\ beta-0.85.0 (or later)
\item \Pkg{luaotfload} v2.6 (or later)
\item \Pkg{adobemapping} (Adobe cmap and pdfmapping files)
-\item \Pkg{everysel} (if you want to use \LuaTeX-ja with \LaTeXe)
-\item \Pkg{ltxcmds}, \Pkg{pdftexcmds}, \Pkg{atbegshi}
+\item \Pkg{etoolbox}, \Pkg{everysel} (if you want to use \LuaTeX-ja with \LaTeXe)
+\item \Pkg{ltxcmds}, \Pkg{pdftexcmds}, \Pkg{filehook}, \Pkg{atbegshi}
\item \Pkg{fontspec} v2.4 (or later)
%\item \emph{IPAex fonts} (\url{http://ipafont.ipa.go.jp/})
%\item \emph{IPAexãã©ã³ã(\url{http://ipafont.ipa.go.jp/})}
\end{itemize}
%In summary, \LuaTeX-ja version 20160404.0 (or~later) no longer supports \TeX~Live~2015.
%<*ja>
-è¦ç´ããã¨ï¼20160404.0ç以éã®\LuaTeX-jaã¯\TeX~Live~2015以åã§ã¯åä½ããªã\footnote{%
+è¦ç´ããã¨ï¼ãã¼ã¸ã§ã³20160404.0以éã®\LuaTeX-jaã¯\TeX~Live~2015以åã§ã¯åä½ããªã\footnote{%
ãã£ã¨ãï¼èªåã§\LuaTeX ã®ãã¤ããªãSubversionãªãã¸ããªãããã«ããã¦ããã°è©±ã¯å¥ã§ããï¼
}ï¼
%
@@ -971,7 +984,7 @@ plfonts.dtx} and \texttt{pldefs.ltx}):
\begin{itemize}
%<*en>
-\item Font encodings for Japanese fonts is \texttt{JY3}~(for horizontal direction) and
+\item Font encodings for Japanese fonts are \texttt{JY3}~(for horizontal direction) and
\texttt{JT3}~(for vertical direction).
%
%<*ja>
@@ -980,20 +993,20 @@ plfonts.dtx} and \texttt{pldefs.ltx}):
%
%<*en>
-\item Traditionally, Japanese documents use two typeface categories: \emph{mincho}~(ææä½) and
+\item Traditionally, Japanese documents use only two families: \emph{mincho}~(ææä½) and
\emph{gothic}~(\textgt{ã´ã·ãã¯ä½}). \emph{mincho} is used in the main text, while \emph{gothic}
is used in the headings or for emphasis.
\begin{center}\small
\begin{tabular}{lllc}
\toprule
-\textbf{classification}&&&\textbf{family name}\\\midrule
+\textbf{classification}&&&\textbf{commands}\\\midrule
\emph{mincho} (ææä½)&\verb+\textmc{...}+&\verb+{\mcfamily ...}+&\cs{mcdefault}\\
\emph{gothic} (\textgt{ã´ã·ãã¯ä½})&\verb+\textgt{...}+&\verb+{\gtfamily ...}+&\cs{gtdefault}\\
\bottomrule
\end{tabular}
\end{center}
\item
-By default, the following fonts are used for \emph{mincho} and \emph{gothic}:
+By default, the following fonts are used for these two families.
\begin{center}\small
\begin{tabular}{ccccc}
\toprule
@@ -1003,7 +1016,7 @@ By default, the following fonts are used for \emph{mincho} and \emph{gothic}:
\bottomrule
\end{tabular}
\end{center}
-Note that the bold series in both family are same as the medium series of \emph{gothic}
+Note that the bold series in both family are same as the medium series of gothic
family. There is no italic nor slanted shape for
these \texttt{mc}~and~\texttt{gt}.
%
@@ -1018,7 +1031,7 @@ Note that the bold series in both family are same as the medium series of \emph{
\bottomrule
\end{tabular}
\end{center}
-\item æ¨æºã§ã¯ï¼æ¬¡ã®ãã©ã³ããã¡ããªãç¨ããããï¼
+\item æ¨æºã§ã¯ï¼æ¬¡ã®ãã©ã³ããç¨ããããï¼
\begin{center}\small
\begin{tabular}{ccccc}
\toprule
@@ -1028,8 +1041,8 @@ Note that the bold series in both family are same as the medium series of \emph{
\bottomrule
\end{tabular}
\end{center}
-ã©ã¡ãã®ãã¡ããªã«ããã¦ãï¼ãã®boldã·ãªã¼ãºã§ä½¿ããããã©ã³ãã¯
-ã´ã·ãã¯ä½ã®mediumã·ãªã¼ãºã§ä½¿ããããã©ã³ãã¨åãã§ãããã¨ã«æ³¨æï¼
+ã©ã¡ãã®ãã¡ããªã«ããã¦ãï¼å¤ªå(\cs{bfseries})ã®ãã©ã³ãã¯
+ã´ã·ãã¯ä½ä¸å(\cs{gtfamily}\cs{mdseries})ã§ä½¿ããããã©ã³ãã¨åãã§ãããã¨ã«æ³¨æï¼
ã¾ãï¼ã©ã¡ãã®ãã¡ããªã§ãã¤ã¿ãªãã¯ä½ã»ã¹ã©ã³ãä½ã¯å®ç¾©ãããªãï¼
%
@@ -1044,7 +1057,7 @@ Note that the bold series in both family are same as the medium series of \emph{
These classes and packages also redefine \cs{jttdefault} to
\cs{gtdefault} (\emph{gothic}~family).
} specifies the Japanese font family in \cs{verb}~or~\texttt{verbatim} environment.
- The default value of \cs{jttdefault} is \cs{mcdefault}, so \emph{mincho} family is used.
+ The default value of \cs{jttdefault} is \cs{mcdefault}, so the mincho family is used.
%
%<*ja>
\item \cs{verb} ã \texttt{verbatim} ç°å¢ä¸ã®åææåã«ä½¿ãããåæãã©ã³ããã¡ããªã¯
@@ -1061,8 +1074,8 @@ Note that the bold series in both family are same as the medium series of \emph{
%<*en>
\item If you use the \Pkg{beamer} class with the default font theme (which uses sans serif
fonts) and with \LuaTeX-ja, you might want to change default Japanese fonts to
- \emph{gothic} family. The following line changes the default Japanese font family
- to \emph{gothic}:
+ the gothic family. The following line changes the default Japanese font family
+ to it:
%
%<*ja>
\item \Pkg{beamer}ã¯ã©ã¹ãæ¢å®ã®ãã©ã³ãè¨å®ã§ä½¿ãå ´åï¼æ¢å®æ¬§æãã©ã³ãããµã³ã»ãªããªã®
@@ -1085,9 +1098,9 @@ classes in \pLaTeX) and \Pkg{jsclasses} (classes by Haruhiko
Okumura), namely, \Pkg{ltjclasses}\footnote{%
\texttt{ltjarticle.cls},~\texttt{ltjbook.cls}, \texttt{ltjreport.cls},
\texttt{ltjtarticle.cls}, \texttt{ltjtbook.cls}, \texttt{ltjtreport.cls}.
- The latter \texttt{ltjt*.cls} are for vertically writtened Japanese documents.
+ The latter \texttt{ltjt*.cls} are for vertically written Japanese documents.
} and \Pkg{ltjsclasses}\footnote{%
- \texttt{ltjsarticle.cls},~\texttt{ltjsbook.cls},~\texttt{ltjskiyou.cls}.}.
+ \texttt{ltjsarticle.cls},~\texttt{ltjsbook.cls}, \texttt{ltjsreport.cls},~\texttt{ltjskiyou.cls}.}.
Original \Pkg{jsclasses} use \cs{mag}~primitive to set the main document font size.
However, \LuaTeX\ beta-0.87.0~or~later does not support \cs{mag} in PDF~output,
@@ -1106,7 +1119,7 @@ to set the main document font size.
縦çµç¨ã¯ \texttt{ltjtarticle.cls}, \texttt{ltjtbook.cls}, \texttt{ltjtreport.cls} ã§ããï¼
}ï¼
\Pkg{ltjsclasses}\footnote{%
- \texttt{ltjsarticle.cls},~\texttt{ltjsbook.cls},~\texttt{ltjskiyou.cls}.}%
+ \texttt{ltjsarticle.cls},~\texttt{ltjsbook.cls}, \texttt{ltjsreport.cls},~\texttt{ltjskiyou.cls}.}%
ãããããç¨æããã¦ããï¼
å
ã
ã®\Pkg{ltjsclasses}ã§ã¯ãã©ã³ããµã¤ãºãæå®ããã®ã«\cs{mag}ããªããã£ãã使ããã¦ãããï¼
@@ -1118,17 +1131,41 @@ to set the main document font size.
%<*ja>
\paragraph{è注ã¨ããã ããã¼ãã®åºåé åº}
-ãªãªã¸ãã«ã®\LaTeX ã§ã¯è注ãããã ããã¼ãã®ä¸ã«æ¥ãããã«ãªã£ã¦ããï¼
-\pLaTeX ã§ã¯è注ãããã ããã¼ãã®ä¸ã«æ¥ãããã«å¤æ´ããã¦ããï¼
+ãªãªã¸ãã«ã®\LaTeX ã§ã¯è注ã¯ããã ããã¼ãã®ä¸ã«åºåããï¼ã¾ã\cs{raggedbottom}å½ä»¤ã§ãã¼ã¸ã®é«ããä¸æãã§ãããã¨ã許ããå ´åã«ã¯
+è注ã®ä¸ç«¯ã®åç´ä½ç½®ããã¼ã¸ã«å¿ãã¦å¤ããããã«ãªã£ã¦ããï¼
+ä¸æ¹ï¼æ¥æ¬èªã®çµçã§ã¯è注ã¯ããã ããã¼ãã®ä¸ã«æ¥ãã®ãä¸è¬çã§ããã®ã§ï¼
+\pLaTeX ã§ã¯ãã®ããã«å¤æ´ããã¦ããï¼
+ããã«\cs{raggedbottom}å½ä»¤ãå®è¡ããå¾ã§ãè注ã¯å¸¸ã«ãã¼ã¸ã®ä¸ç«¯ã«åºå®ãããããã«ãªã£ã¦ããï¼
\LuaTeX-jaã§ã¯ã欧æã¯ã©ã¹ã®ä¸ã«ã¡ãã£ã¨ã ãæ¥æ¬èªãå
¥ãããã¨ããå©ç¨ãèæ
®ãï¼
-è注ã¨ããã ããã¼ãã®é åºã¯\LaTeX éãã¨ããï¼ãã\pLaTeX ã®åºåé åºã好ã¿ãªãã°ï¼
-\Pkg{stfloats}ããã±ã¼ã¸ãå©ç¨ãã¦
-\begin{lstlisting}
- \usepackage{stfloats}\fnbelowfloat
-\end{lstlisting}
-ã®ããã«ããã°ããï¼\Pkg{footmisc}ããã±ã¼ã¸ã \texttt{bottom}\ ãªãã·ã§ã³ãæå®ãã¦
-èªã¿è¾¼ãã¨ããæ¹æ³ããããï¼ããã ã¨ããã ããã¼ãã¨è注ã®éãéãã¦ãã¾ãï¼
+è注ã¨ããã ããã¼ãã®é åºï¼åã³\cs{raggedbottom}æã®è注ã®åç´ä½ç½®ã¯\LaTeX éãã¨ããï¼
+ããããå¶å¾¡ããã«ã¯ä»¥ä¸ã®æ段ãããï¼
+\begin{itemize}
+ \item \pLaTeX ã®ããã«ï¼è注ãããã ããã¼ãã®ä¸ã«çµãå ´åã«ã¯
+ \Pkg{stfloats}ããã±ã¼ã¸ãå©ç¨ãã¦
+ \begin{lstlisting}
+ \usepackage{stfloats}\fnbelowfloat
+ \end{lstlisting}
+ ã¨ããï¼ãã®ç¶æ³ãããè注ãããã ããã¼ãã®ä¸ã«çµããã¨ãã\LaTeX ã®æ¨æºã®æåã«æ»ããããã°ï¼
+ \Pkg{stfloats}ããã±ã¼ã¸ã®\cs{fnunderfloat}å½ä»¤ã使ç¨ããï¼
+ \item \cs{raggedbottom}æã®è注ã®åç´ä½ç½®ã¯ï¼\cs{iffnfixbottom}ã¨ããçå½å¤ã§å¶å¾¡ããï¼
+ \begin{description}
+ \item[å½(\cs{fnfixbottomfalse})ã®å ´å] \LaTeX æ¨æºã¨åããï¼æ¬æã¨è注ã®éã®ç©ºç½ã¯\cs{skip}\cs{footins}ã®ã¿ï¼
+ å¾ã£ã¦è注ã®åç´ä½ç½®ã¯ãã¼ã¸ã«ããå¤åããï¼
+ \item[ç(\cs{fnfixbottomtrue})ã®å ´å] \pLaTeX ã\Pkg{footmisc}ããã±ã¼ã¸ã\texttt{bottom}ãªãã·ã§ã³ã§
+ èªã¿è¾¼ãã å ´åã®ããã«ï¼è注ã¯å¸¸ã«ãã¼ã¸ã®ä¸ç«¯ã«åºå®ãããï¼
+ \end{description}
+\item ãã ãï¼\LuaTeX-jaãæä¾ãããäºæã¯ã©ã¹ã(\Pkg{ltjclasses}, \Pkg{ltjsclasses})ã§ã¯ï¼
+ \pLaTeX ã¨åãããããã«ä»¥ä¸ã®ããã«ãã¦ããï¼
+ \begin{itemize}
+ \item \cs{fnfixbottomtrue}ãèªåçã«å®è¡ããã
+ \item \Pkg{stfloats}ããã±ã¼ã¸ã\LuaTeX ããåç
§ã§ããå ´æã«ãã£ãå ´åã¯
+ èªåçã«èªã¿è¾¼ã¿ï¼\cs{fnbelowfloat}ãå®è¡ããï¼
+ \end{itemize}
+\end{itemize}
+ãªãï¼\Pkg{stfloats}ããã±ã¼ã¸ã使ã代ããã«ï¼
+\Pkg{footmisc}ããã±ã¼ã¸ã \texttt{bottom}ãªãã·ã§ã³ãæå®ãã¦èªã¿è¾¼ã
+ã¨ããã解決æ³ããããï¼
%
%%% âã¯è±è¨³ããªã
@@ -1395,22 +1432,19 @@ alphabetic fonts
%
%<*ja>
\begin{center}\small
-\begin{tabular}{cccc}
+\begin{tabular}{ccccc}
\toprule
åæ
-&\cs{jfontspec}&\cs{setmainjfont}&\cs{setsansjfont}\\
-欧æ
-&\cs{fontspec}&\cs{setmainfont}&\cs{setsansfont}\\
-\midrule
-åæ
-&\cs{newjfontfamily}&\cs{newjfontface}&\cs{defaultjfontfeatures}\\
+&\cs{jfontspec}&\cs{setmainjfont}&\cs{setsansjfont}&\cs{setmonojfont}$^*$\\
欧æ
-&\cs{newfontfamily}&\cs{newfontface}&\cs{defaultfontfeatures}\\
+&\cs{fontspec}&\cs{setmainfont}&\cs{setsansfont}&\cs{setmonofont}\\
\midrule
åæ
-&\cs{addjfontfeatures}\\
+&\cs{newjfontfamily}&\cs{newjfontface}
+&\cs{defaultjfontfeatures}&\cs{addjfontfeatures}\\
欧æ
-&\cs{addfontfeatures}\\
+&\cs{newfontfamily}&\cs{newfontface}
+&\cs{defaultfontfeatures}&\cs{addfontfeatures}\\
\bottomrule
\end{tabular}
\end{center}
@@ -1497,1787 +1531,1287 @@ JIS~X~0208:1990âè¾»
%\subsection{Presets of Japanese fonts}
%\subsection{åæãã©ã³ãã®ããªã»ããè¨å®}
-\label{ssec-preset}
+\label{ssec:preset-abst}
%<*en>
-One can load the \Pkg{luatexja-preset}
-package to use several ``presets'' of Japanese fonts.
-This package provides functions in a part of
-\Pkg{japanese-otf} package and a part of \Pkg{PXchfon} package by Takayuki Yato.
-
-One can specified other options other than listed in this subsection.
-These are simply passed to the \Pkg{luatexja-fontspec}\footnote{if \texttt{nfssonly} option is
-\emph{not} specified; in this case these options are simply ignored.}.
-For example, the line~5 in below example is eqivalent to lines 1--3.
+With \Pkg{luatexja-preset} package,
+one use one of ``preset'' to simplify Japanese font setting.
+For details of package options, and those of each presets, please see Subsecion~\ref{ssec:preset}.
+The following presets are defined:
%
%<*ja>
ãã使ããã¦ããåæãã©ã³ãè¨å®ãä¸è¡ã§æå®ã§ããããã«ããã®ã
-\Pkg{luatexja-preset}ããã±ã¼ã¸ã§ããï¼ãã®ããã±ã¼ã¸ã¯ï¼
-\Pkg{otf}ããã±ã¼ã¸ã®ä¸é¨æ©è½ã¨å
«ç»å´ä¹æ°ã«ãã\Pkg{PXchfon}ããã±ã¼ã¸ã®ä¸é¨æ©è½ã¨ã
-åããããããªæ ¼å¥½ããã¦ããï¼
-
-ãªãã·ã§ã³ã¨ãã¦ï¼æ¬ç¯ã«ãªããã®ãæå®ãããã¨ãã§ãããï¼ãããã¯
-\Pkg{luatexja-fontspec}ããã±ã¼ã¸ã«æ¸¡ããã\footnote{\texttt{nfssonly} ãªãã·ã§ã³ã
-æå®ããã¦ããå ´åã¯ï¼\Pkg{luatexja-fontspec}ããã±ã¼ã¸ã¯èªã¿è¾¼ã¾ããªãã®ã§åç´ã«ç¡è¦ãã
-ãï¼}ï¼ä¾ãã°ï¼ä¸ã®1--3è¡ç®ã¯5è¡ç®ã®ããã«ä¸è¡ã«ã¾ã¨ãããã¨ãã§ããï¼
+\Pkg{luatexja-preset}ããã±ã¼ã¸ã§ããï¼ãªãã·ã§ã³ãåããªã»ããã®è©³ç´°ã«ã¤ãã¦ã¯
+\ref{ssec:preset}ç¯ãåç
§ãã¦æ¬²ããï¼
+ç¾æç¹ã§ã¯ä»¥ä¸ã®ããªã»ãããå®ç¾©ããã¦ããï¼
%
+\begin{quote}
+ \ttfamily
+ \hyphenchar\font=-1 \exhyphenchar=-1
+ hiragino-pro, hiragino-pron, ipa, ipa-hg, ipaex, ipaex-hg,
+ kozuka-pr6, kozuka-pr6n, kozuka-pro, moga-mobo, moga-mobo-ex,
+ morisawa-pr6n, morisawa-pro, ms, ms-hg, noembed, noto-otc, noto-otf,
+ sourcehan, sourcehan-jp, ume, yu-osx, yu-win, yu-win10
+\end{quote}
+
+% ä¾ãã°ï¼æ¬ããã¥ã¡ã³ãã§ã¯\Pkg{luatexja-preset}ããã±ã¼ã¸ã
+% For example, this document loads \Pkg{luatexja-preset} package by
\begin{lstlisting}
-\usepackage[no-math]{fontspec}
-\usepackage[match]{luatexja-fontspec}
\usepackage[kozuka-pr6n]{luatexja-preset}
-%%--------
-\usepackage[no-math,match,kozuka-pr6n]{luatexja-preset}
\end{lstlisting}
+%ã¨ãã¦èªã¿è¾¼ã¿ï¼å°å¡æ¸ä½(Pr6N)ã使ããã¨ãæå®ãã¦ããï¼
+% which means that Kozuka~Pr6N fonts will be used in this document.
-%\paragraph{General options}
-%\paragraph{ä¸è¬çãªãªãã·ã§ã³}
-\begin{cslist}[before*=]
-\item[fontspec%
-%\textrm{~(enabled by default)}
-%\emph{\gtfamily ï¼æ¢å®ï¼}
-]
-%<*en>
-With this option, Japanese fonts are selected using functionality of
-the \Pkg{luatexja-fontspec} package. This means that the \Pkg{fontspec} package is
- automatically loaded by this package.
-If you need to pass some options to \Pkg{fontspec}, you can load \Pkg{fontspec} manually
-before \Pkg{luatexja-preset}:
+%<*en>
+\subsection{\cs{CID}, \cs{UTF}, and macros in \Pkg{japanese-otf} package}
+Under \pLaTeX, \Pkg{japanese-otf} package (developed by Shuzaburo Saito) is
+used for typesetting characters which is in Adobe-Japan1-6 CID but not
+in JIS~X~0208. Since this package is widely used, \LuaTeX-ja
+supports some of functions in the \Pkg{japanese-otf} package,
+as an external package \Pkg{luatexja-otf}.
%
%<*ja>
-\Pkg{luatexja-fontspec}ããã±ã¼ã¸ã®æ©è½ãç¨ãã¦åæãã©ã³ããé¸æããï¼
-ããã¯ï¼\Pkg{fontspec}ããã±ã¼ã¸ãèªåã§èªã¿è¾¼ã¾ãããã¨ãæå³ããï¼
+\subsection{\cs{CID}, \cs{UTF}ã¨\Pkg{otf}ããã±ã¼ã¸ã®ãã¯ã}
+\pLaTeX ã§ã¯ï¼JIS~X~0208ã«ãªãAdobe-Japan1-6ã®æåãåºåããããã«ï¼
+é½è¤ä¿®ä¸éæ°ã«ãã\Pkg{otf}ããã±ã¼ã¸ãç¨ãããã¦ããï¼ãã®ããã±ã¼ã¸ã¯
+åºãç¨ãããã¦ããããï¼\LuaTeX-jaã«ããã¦ã\Pkg{otf}ããã±ã¼ã¸ã®æ©è½ã®
+ä¸é¨ãï¼\Pkg{luatexja-otf}ã¨ããå¥ã®ããã±ã¼ã¸ã¨ãã¦ï¼å®è£
ããï¼
+%
-ãã\Pkg{fontspec}ããã±ã¼ã¸ã«ä½ããã®ãªãã·ã§ã³ã渡ãå¿
è¦ããã
-\footnote{ä¾ãã°ï¼æ°å¼ãã©ã³ãã¾ã§ç½®æããã¦ãã¾ãï¼\cs{mathit}ã«ãã£ã¦ã®ãªã·ã£æåã®
-æä½å¤§æåãåºãªããªãï¼ãªã©ï¼}å ´åã¯ï¼
-次ã®ããã«\Pkg{luatexja-preset}ã®åã«\Pkg{fontspec}ãæåã§èªã¿ããã°è¯ãï¼
+\begin{LTXexample}
+\jfontspec{KozMinPr6N-Regular.otf}
+森\UTF{9DD7}å¤ã¨å
ç°ç¾\UTF{9592}ã¨ã\UTF{9AD9}島å±ã«è¡ãã
+
+\CID{7652}飾åºã®\CID{13706}é家ï¼
+\CID{1481}åå¸ï¼è西é§
ï¼
+é«å´ã¨\CID{8705}\UTF{FA11}
+
+\ajåè§{ã¯ãããã«ã¿ã«ã}
+\end{LTXexample}
+
+%<*ja>
+\Pkg{otf}ããã±ã¼ã¸ã§ã¯ï¼ãããã次ã®ãããªãªãã·ã§ã³ãåå¨ããï¼
+\begin{cslist}
+\item[deluxe] ææä½ã»ã´ã·ãã¯ä½å3ã¦ã§ã¤ãã¨ï¼ä¸¸ã´ã·ãã¯ä½ãæ±ããããã«ãªãï¼
+\item[expert] ä»®åã横çµã»ç¸¦çµå°ç¨ã®ãã®ã«åãæ¿ããï¼ã«ãç¨ä»®åã
+\ \cs{rubyfamily}\ ã«ãã£ã¦æ±ããããã«ãªãï¼
+\item[bold] ã´ã·ãã¯ä½ãæ¨æºã§å¤ªãã¦ã§ã¤ãã®ãã®ã«è¨å®ããï¼
+\end{cslist}
+ããããããã®ãªãã·ã§ã³ã¯\Pkg{luatexja-otf}ããã±ã¼ã¸ã«ã¯åå¨ããªãï¼
+\Pkg{otf}ããã±ã¼ã¸ãææ¸ä¸ã§ä½¿ç¨ããåæç¨TFMãèªåã®ç©ã«ç½®ãæãã¦ããã®ã«å¯¾ãï¼
+\Pkg{luatexja-otf}ããã±ã¼ã¸ã§ã¯ï¼ãã®ãããªãã¨ã¯è¡ããªãããã§ããï¼
+
+ããã3ãªãã·ã§ã³ã«ã¤ãã¦ã¯ï¼
+\Pkg{luatexja-preset} ããã±ã¼ã¸ã«ããªã»ããã使ãæã«ä¸ç·ã«æå®ãããï¼
+ãããã¯å¯¾å¿ããå
容ã\ref{ssec-chgfnt}ç¯ï¼\ref{ssec-nfsspat}ç¯ (NFSS2) ã
+\ref{ssec-fontspec}ç¯ (\Pkg{fontspec}) ã®æ¹æ³ã§æåã§æå®ããå¿
è¦ãããï¼
%
-\begin{lstlisting}
-\usepackage[no-math]{fontspec}
-\usepackage[...]{luatexja-preset}
-\end{lstlisting}
-\item[nfssonly]
+%\subsection{Changing default Japanese fonts}
+%\subsection{æ¨æºåæãã©ã³ãã®å¤æ´}
+\label{ssec-cfg}
%<*en>
-With this option, selecting Japanese fonts won't be performed using the functionality of
- the \Pkg{fontspec} package, but only standard NFSS2 (hence without
- \cs{addjfontfeatures} etc.).
-This option is ignored when \Pkg{luatexja-fontspec} package is loaded.
+If \texttt{luatexja.cfg} can be seen from \LuaTeX, \LuaTeX-ja automatically reads it.
+The main use of \texttt{luatexja.cfg} is for changing default Japanese fonts,
+when IPAex fonts cannot be installed in \TeX~system.
+One should not overuse this \texttt{luatexja.cfg}; fonts which will be used in
+a document should be specified in its source.
-When this option is specified, \Pkg{fontspec}~and~\Pkg{luatexja-fontspec} are
-\emph{not} loaded by default. Nevertheless,
-the package\Pkg{fontspec} can coexist with the option, as the following:
+For example,
\begin{lstlisting}
-\usepackage{fontspec}
-\usepackage[hiragino-pron,nfssonly]{luatexja-preset}
+\def\ltj@stdmcfont{IPAMincho}
+\def\ltj@stdgtfont{IPAGothic}
+\end{lstlisting}
+makes that IPA~Mincho and IPA~Gothic will be used as default Japanese fonts, instead of
+IPAex~Mincho and IPAex~Gothic.
+
+For another example, the following two lines makes that
+non-embedded fonts Ryumin-Light~and~GothicBBB-Medium as default Japanese fonts
+(as the earlier version of \LuaTeX-ja):
+\begin{lstlisting}
+\def\ltj@stdmcfont{psft:Ryumin-Light}
+\def\ltj@stdgtfont{psft:GothicBBB-Medium}
\end{lstlisting}
-In this case, one can use \cs{setmainfont} etc.\ to select \emph{alphabetic} fonts.
%
%<*ja>
-\LaTeX æ¨æºã®ãã©ã³ãé¸ææ©æ§(NFSS2)ãç¨ãã¦
-\texttt{ltjpm}ï¼ææï¼ï¼\texttt{ltjpg}ï¼ã´ã·ãã¯ï¼ï¼ããã«å¾ã«è¿°ã¹ã \texttt{deluxe} ãªã
- ã·ã§ã³ãæå®ãããå ´åã«ã¯ \texttt{ltjpmg}ï¼ä¸¸ã´ã·ãã¯ï¼ã¨ãã
-3ã¤ã®åæãã©ã³ããã¡ããªãå®ç¾©ãï¼ããããç¨ããï¼
+\LuaTeX ããè¦ããä½ç½®ã« \texttt{luatexja.cfg} ãããã°ï¼\LuaTeX-jaã¯ãããèªã¿è¾¼ãï¼
+ãã®ãã¡ã¤ã«ãç¨ããã¨plain~\TeX, \LaTeXe ã«ãããæ¨æºåæãã©ã³ãã
+IPAexææã»IPAexã´ã·ãã¯ããå¤æ´ãããã¨ãã§ããï¼
+ãããï¼åºæ¬çã«ã¯\emph{æç« ä¸ã§ç¨ãããã©ã³ãã¯ï¼ä¾ãã° \Pkg{luatexja-preset} ãªã©ã§ï¼
+ææ¸ã½ã¼ã¹å
ã§æå®ããã¹ã}ã§ããï¼ãã® \texttt{luatexja.cfg} ã¯ï¼
+ãIPAexãã©ã³ããã¤ã³ã¹ãã¼ã«ã§ããªãããªã©ï¼IPAexãã©ã³ãã使ç¨ã§ããªãå ´åã«ã®ã¿
+å¿æ¥å¦ç½®çã«ç¨ããã¹ãã§ããï¼
-æ¬ãªãã·ã§ã³æå®æã«ã¯\Pkg{fontspec}ã»\Pkg{luatexja-fontspec}ããã±ã¼ã¸ã¯
-èªåã§ã¯èªã¿è¾¼ã¾ããªãï¼ãããï¼
+ä¾ãã°
\begin{lstlisting}
-\usepackage{fontspec}
-\usepackage[hiragino-pron,nfssonly]{luatexja-preset}
+\def\ltj@stdmcfont{IPAMincho}
+\def\ltj@stdgtfont{IPAGothic}
\end{lstlisting}
-ã®ããã«ããã°ï¼ãã®ãªãã·ã§ã³ãæå®ããã°
-欧æãã©ã³ãã\Pkg{fontspec}ããã±ã¼ã¸ã®æ©è½ã使ã£ã¦æå®ãããã¨ãã§ããï¼
-ä¸æ¹ï¼
-ããã±ã¼ã¸èªã¿è¾¼ã¿æã«æ¢ã«\Pkg{luatexja-fontspec}ããã±ã¼ã¸ãèªã¿è¾¼ã¾ãã¦
- ããå ´å㯠\texttt{nfssonly} ãªãã·ã§ã³ã¯ç¡è¦ãããï¼
+ã¨è¨è¿°ãã¦ããã°ï¼æ¨æºåæãã©ã³ããIPAææã»IPAã´ã·ãã¯ã¸ã¨å¤
+æ´ãããï¼
+
+
+ãªãï¼20140906.0以åã®ãã¼ã¸ã§ã³ã®ããã«ï¼
+Ryumin-Light, GothicBBB-Mediumã¨ããååã®éåè¾¼ãã©ã³ããç¨ããå ´åã¯
+\begin{lstlisting}
+\def\ltj@stdmcfont{psft:Ryumin-Light}
+\def\ltj@stdgtfont{psft:GothicBBB-Medium}
+\end{lstlisting}
+ã¨è¨è¿°ããã°ããï¼
%
-\item[match]
+
+%\section{Changing Internal Parameters}
+%\section{ãã©ã¡ã¼ã¿ã®å¤æ´}
+
%<*en>
-If this option is specified, usual family-changing commands such as
-\cs{rmfamily},~\cs{textrm}, \cs{sffamily},~\dots\ also change Japanese font family.
-This option is passed to \Pkg{luatexja-fontspec}, if \texttt{fontspec}
-option is specifed.
+There are many internal parameters in \LuaTeX-ja. And due to the behavior of \LuaTeX,
+most of them are not stored as internal register of \TeX, but as an
+original storage system in \LuaTeX-ja. Hence, to assign or acquire those
+parameters, you have to use commands \cs{ltjsetparameter} and
+\cs{ltjgetparameter}.
%
-
%<*ja>
-ãã®ãªãã·ã§ã³ãæå®ãããã¨ï¼ã\pLaTeXe æ°ããã¥ã¡ã³ãã¯ã©ã¹ãã®ããã«\
-\cs{rmfamily}, \verb+\textrm{...}+, \cs{sffamily} çã
-欧æãã©ã³ãã ãã§ãªãåæãã©ã³ããå¤æ´ããããã«ãªãï¼
-\ \texttt{fontspec}\
-ãªãã·ã§ã³ãæå¹ã«ãªã£ã¦ããå ´åã¯ï¼ãã®ãªãã·ã§ã³ã¯ \Pkg{luatexja-fontspec} ããã±ã¼ã¸ã¸ã¨æ¸¡ãããï¼
+\LuaTeX-jaã«ã¯å¤ãã®ãã©ã¡ã¼ã¿ãåå¨ããï¼ããã¦\LuaTeX ã®ä»æ§ã®ããã«ï¼
+ãã®å¤ãã¯\TeX ã®ã¬ã¸ã¹ã¿ã«ã§ã¯ãªãï¼\LuaTeX-jaç¬èªã®æ¹æ³ã§ä¿æããã¦ããï¼
+ãããã®ãã©ã¡ã¼ã¿ãè¨å®ã»åå¾ããããã«ã¯ \cs{ltjsetparameter} 㨠\cs{ltjgetparameter} ã
+ç¨ããï¼
%
+%\subsection{Range of \textbf{JAchar}s}
+%\subsection{\textbf{JAchar}ã®ç¯å²}
+\label{ssec-setrange}
-\item[nodeluxe%
-%\textrm{~(enabled by default)}
-%\emph{\gtfamily ï¼æ¢å®ï¼}
-]
%<*en>
-The nagation of \texttt{deluxe} option.
-Use one-weighted \textit{mincho} and \textit{gothic} font families.
-This means that \verb+\mcfamily\bfseries+, \verb+\gtfamily\bfseries+ and
-\verb+\gtfamily\mdseries+ use the same font.
+\LuaTeX-ja divides the Unicode codespace \texttt{U+0080}--\texttt{U+10FFFF}
+into \emph{character ranges},
+numbered 1 to 217. The grouping can be (globally) customized by \cs{ltjdefcharrange}.
+The next line adds whole characters in Supplementary Ideographic Plane
+and the character ``æ¼¢'' to the character range~100.
%
%<*ja>
-\texttt{deluxe}ãªãã·ã§ã³ã®å¦å®ï¼
-\LaTeXe ç°å¢ä¸ã®æ¨æºè¨å®ã®ããã«ï¼ææä½ã»ã´ã·ãã¯ä½ãå1ã¦ã§ã¤ãã§ä½¿ç¨ããï¼
-ããå
·ä½çã«è¨ãã¨ï¼ãã®è¨å®ã®ä¸ã§ã¯
-\ \verb+\mcfamily\bfseries+, \verb+\gtfamily\bfseries+,
-\verb+\gtfamily\mdseries+ã¯ã¿ãªåããã©ã³ãã¨ãªãï¼
+\LuaTeX-jaã¯ï¼Unicodeã® \texttt{U+0080}--\texttt{U+10FFFF} ã®ç©ºéã
+1çªãã217çªã¾ã§ã®\emph{æåç¯å²}ã«åå²ãã¦ããï¼
+åºåã㯠\cs{ltjdefcharrange} ãç¨ãããã¨ã§ï¼ã°ãã¼ãã«ã«ï¼å¤æ´ãããã¨ãã§ãï¼
+ä¾ãã°ï¼æ¬¡ã¯è¿½å æ¼¢åé¢(SIP)ã«ããå
¨ã¦ã®æåã¨ãæ¼¢ããã100çªã®æåç¯å²ãã«è¿½å ããï¼
%
-\item[deluxe]
+\begin{lstlisting}
+\ltjdefcharrange{100}{"20000-"2FFFF,`æ¼¢}
+\end{lstlisting}
+
%<*en>
-Use \textit{mincho} with two weights (medium~and~bold),
-\textit{gothic} with three weights (medium, bold~and~heavy), and \textit{rounded gothic}%
-\footnote{Provided by \cs{mgfamily} and \cs{textmg},
-because \textit{rounded gothic} is called \textit{maru gothic} (丸ã´ã·ãã¯) in Japanese.}.
-The heavy weight of \textit{gothic} can be used by ``changing the family'' \cs{gtebfamily},
-or \verb+\textgteb{...}+.
-This is because the \Pkg{fontspec} package can handle only medium (\cs{mdseries}) and
-bold (\cs{bfseries}).
+A character can belong to only one character range.
+For example, whole SIP belong to the range~4 in the default setting of \LuaTeX-ja,
+and if one executes the above line, then SIP will belong to the range~100 and be
+removed from the range~4.
%
%<*ja>
-ææä½2ã¦ã§ã¤ãã»ã´ã·ãã¯ä½3ã¦ã§ã¤ãã¨ï¼
-丸ã´ã·ãã¯ä½ (\cs{mgfamily}, \verb+\textmg{...}+) ã使ç¨å¯è½ã¨ããï¼
-ã´ã·ãã¯ä½ã¯ä¸åã»å¤ªåã»æ¥µå¤ªã®3ã¦ã§ã¤ãããããï¼
-極太ã´ã·ãã¯ä½ã使ãå ´åï¼
-\begin{itemize}
- \item \cs{gtebfamily}, \verb+\textgteb{...}+
- \item \cs{ebseries} ï¼å¨å²ãã´ã·ãã¯ä½ã®ã¨ãï¼\texttt{nfssonly} ãªãã·ã§ã³æå®æã®ã¿ï¼
-\end{itemize}
-ã®ãããããç¨ããï¼æ¨æºã§ \cs{ebseries} ãæºåããã¦ããªãã®ã¯ï¼ãã¼ã¸ã§ã³ãå¤ã
-\Pkg{fontspec}ã§ã¯ä¸å(\cs{mdseries})ã¨å¤ªå(\cs{bfseries})ããæ±ããªãã£ãåæ®ã§ããï¼
+åæåã¯ãã ä¸ã¤ã®æåç¯å²ã«æå±ãããã¨ãã§ããï¼
+ä¾ãã°ï¼SIPå
ã®æåã¯å
¨ã¦\LuaTeX-jaã®ããã©ã«ãã§ã¯4çªã®æåç¯å²ã«
+å±ãã¦ãããï¼ä¸è¨ã®æå®ãè¡ãã°SIPå
ã®æåã¯100çªã«å±ãããã«ãªãï¼4çªããã¯é¤ãããï¼
%
-\item[expert]
+
%<*en>
-Use horizontal/vertical kana alternates, and define a command \cs{rubyfamily} to use kana
-characters designed for ruby.
+The distinction between \textbf{ALchar} and \textbf{JAchar} is performed by character ranges.
+This can be edited by setting the \textsf{jacharrange} parameter.
+For example, the code below is just the default setting of \LuaTeX-ja, and
+it sets
+\begin{itemize}
+ \item a character which belongs character ranges 1,~4, 5, and~8 is \textbf{ALchar},
+ \item a character which belongs character ranges 2,~3, 6, and~7 is \textbf{JAchar}.
+\end{itemize}
%
%<*ja>
-横çµã»ç¸¦çµå°ç¨ä»®åãç¨ããï¼ã¾ãï¼\cs{rubyfamily} ã§ã«ãç¨ä»®åã使ç¨å¯è½ã¨ãªã\footnote{%
- \cs{rubyfamily}ã¨ã¯ããã¤ã¤ï¼å®éã«ã¯ãã©ã³ããã¡ããªãåãæ¿ããã®ã§ã¯ãªãï¼é常ã§ã¯
- font featureã®è¿½å ï¼\texttt{nfssonly} æå®æã«ã¯ã·ã§ã¤ãã \texttt{rb} ã«åãæ¿ãï¼ï¼
-}ï¼
+\textbf{ALchar}ã¨\textbf{JAchar}ã®åºå¥ã¯æåç¯å²ãã¨ã«è¡ãããï¼
+ããã¯\textsf{jacharrange}ãã©ã¡ã¼ã¿ã«ãã£ã¦ç·¨éã§ããï¼
+ä¾ãã°ï¼ä»¥ä¸ã¯\LuaTeX-jaã®åæè¨å®ã§ããï¼æ¬¡ã®å
容ãè¨å®ãã¦ããï¼
+\begin{itemize}
+ \item 1çªï¼4çªï¼5çªï¼8çªã®æåç¯å²ã«å±ããæåã¯\textbf{ALchar}ï¼
+ \item 2çªï¼3çªï¼6çªï¼7çªã®æåç¯å²ã«å±ããæåã¯\textbf{JAchar}ï¼
+\end{itemize}
%
-\item[bold]
+\begin{lstlisting}
+\ltjsetparameter{jacharrange={-1, +2, +3, -4, -5, +6, +7, -8}}
+\end{lstlisting}
%<*en>
-Substitute bold series of \textit{gothic} for bold series of \textit{mincho}.
-If \texttt{nodeluxe} option is enabled, medium series of \textit{gothic} is also changed,
-since we use same font for both series of \textit{gothic}.
-%
-%<*ja>
-ãææã®å¤ªåããã´ã·ãã¯ä½ã®å¤ªåã«ãã£ã¦ä»£æ¿ããï¼
-ãã\texttt{nodeluxe}ãªãã·ã§ã³ãæå®ããã¦ããå ´åã¯ï¼ã´ã·ãã¯ä½ã¯1ã¦ã§ã¤ããã使ç¨ãããª
- ãããï¼
-ãã´ã·ãã¯ä½ã®ä¸åããåæã«å¤æ´ããããã¨ã«ãªãï¼
+The argument to \textsf{jacharrange} parameter is a list of non-zero integer.
+Negative integer $-n$ in the list means that ``each character in the range~$n$ is an
+\textbf{ALchar}'',
+and positive integer $+n$ means that ``\dots\ is a \textbf{JAchar}''.
+%
+%<*ja>
+\textsf{jacharrange}ãã©ã¡ã¼ã¿ã®å¼æ°ã¯éé¶ã®æ´æ°ã®ãªã¹ãã§ããï¼
+ãªã¹ãä¸ã®è² ã®æ´æ°$-n$ã¯ãæåç¯å²$n$ã«å±ããæåã¯\textbf{ALchar}ã¨ãã¦
+æ±ãããã¨ãæå³ãï¼æ£ã®æ´æ°$+n$ã¯ã\textbf{JAchar}ã¨ãã¦æ±ãããã¨ãæå³ããï¼
%
-\item[90jis]
-%Use 90JIS glyph variants if possible.
-%åºæ¥ãéã90JISã®åå½¢ã使ãï¼
-\item[jis2004]
-%Use JIS2004 glyph variants if possible.
-%åºæ¥ãéãJIS2004ã®åå½¢ã使ãï¼
-\item[jis]
+
%<*en>
-Use the JFM \texttt{jfm-jis.lua}, instead of \texttt{jfm-ujis.lua}, which is the default JFM of
-\LuaTeX-ja.
+Note that characters \texttt{U+0000}--\texttt{U+007F} are always treated as an
+\textbf{ALchar} (this cannot be customized).
%
%<*ja>
-ç¨ããJFMãï¼JISãã©ã³ãã¡ããªãã¯é¡ä¼¼ã®ï¼\texttt{jfm-jis.lua}ã«ããï¼ãã®ãªãã·ã§ã³ããªãæã¯
-\LuaTeX-jaæ¨æºã®\texttt{jfm-ujis.lua}ãç¨ããããï¼
+ãªãï¼\texttt{U+0000}--\texttt{U+007F} ã¯å¸¸ã«\textbf{ALchar}ã¨ãã¦æ±ãããï¼å©ç¨è
ãå¤æ´ã
+ããã¨ã¯åºæ¥ãªãï¼ï¼
%
-\end{cslist}
%<*en>
-Note that \texttt{90jis} and \texttt{jis2004} only affect with \textit{mincho},
-\textit{gothic} (and possibly \textit{rounded gothic}) defined by this package.
-We didn't taken account of when both \texttt{90jis} and \texttt{jis2004} are specified.
+\paragraph{Default character ranges}
+\LuaTeX-ja predefines eight character ranges for convenience. They are
+determined from the following data:
%
%<*ja>
-\texttt{90jis}ã¨\texttt{jis2004}ã«ã¤ãã¦ã¯æ¬ããã±ã¼ã¸ã§å®ç¾©ããã
-ææä½ã»ã´ã·ãã¯ä½ï¼ã»ä¸¸ã´ã·ãã¯ä½ï¼ã«ã®ã¿æå¹ã§ããï¼
-両ãªãã·ã§ã³ãåæã«æå®ãããå ´åã®åä½ã«ã¤ãã¦ã¯å
¨ãèæ
®ãã¦ããªãï¼
+\paragraph{æåç¯å²ã®åæå¤}
+\LuaTeX-jaã§ã¯8ã¤ã®æåç¯å²ãäºãå®ç¾©ãã¦ããï¼
+ãããã¯ä»¥ä¸ã®ãã¼ã¿ã«åºã¥ãã¦æ±ºå®ãã¦ããï¼
%
+\begin{itemize}
+%\item Blocks in Unicode~6.0.
+%\item Unicode~6.0ã®ãããã¯ï¼
+%\item The \texttt{Adobe-Japan1-UCS2} mapping between a CID Adobe-Japan1-6 and Unicode.
+%\item Adobe-Japan1-6ã®CIDã¨Unicodeã®éã®å¯¾å¿è¡¨\texttt{Adobe-Japan1-UCS2}ï¼
+%\item The \Pkg{PXbase} bundle for \upTeX\ by Takayuki Yato.
+%\item å
«ç»å´ä¹æ°ã«ãã\upTeX ç¨ã®\Pkg{PXbase}ãã³ãã«ï¼
+\end{itemize}
-%\paragraph{Presets for multi weight}
-%\paragraph{å¤ã¦ã§ã¤ãç¨ããªã»ããã®ä¸è¦§}
%<*en>
-Besides \texttt{morisawa-pro}~and~\texttt{morisawa-pr6n} presets,
-fonts are specified by font name, not by file name.
-In following tables, starred fonts (e.g.~KozGo\dots-Regular) are used for medium series of \textit{gothic},
-\emph{if and only if \texttt{deluxe} option is specified}.
+Now we describe these eight ranges. The superscript ``J'' or ``A'' after the
+number shows whether each character in the range is treated as
+\textbf{JAchar}s or not by default. These settings are similar to the
+\texttt{prefercjk} settings defined in \texttt{PXbase} bundle.
+Any characters equal to or above \texttt{U+0080} which does not belong to
+these eight ranges belongs to the character range~217.
%
%<*ja>
-\texttt{morisawa-pro}, \texttt{morisawa-pr6n}以å¤ã¯ãã©ã³ãã®æå®ã¯
-ï¼ãã¡ã¤ã«åã§ãªãï¼ãã©ã³ãåã§è¡ãããï¼
-以ä¸ã®è¡¨ã«ããã¦ï¼*\,ã¤ãã®ãã©ã³ã(e,g,~KozGo\dots-Regular)ã¯ï¼\emph{\texttt{deluxe}ãªãã·ã§ã³æå®æã«}
-ã´ã·ãã¯ä½ä¸åã¨ãã¦ç¨ãããããã®ã示ãã¦ããï¼
+以ä¸ã§ã¯ããã8ã¤ã®æåç¯å²ã«ã¤ãã¦è¨è¿°ããï¼æ·»åã®ã¢ã«ãã¡ããããJããAã
+ã¯ï¼ãã®æåç¯å²å
ã®æåã\textbf{JAchar}ã\textbf{ALchar}ãã表ãã¦ããï¼ãããã®åæè¨å®ã¯
+\texttt{PXbase}ãã³ãã«ã§å®ç¾©ããã¦ãã\texttt{prefercjk}ã¨é¡ä¼¼ã®ãã®ã§ãããï¼
+8ããããã©ã³ã使ç¨æã®ãã©ãã«ãé²ãããã« \texttt{U+0080}--\texttt{U+00FF} ã®æåã¯å
¨é¨
+\textbf{ALchar}ã¨ãã¦ããï¼
+ãªãï¼\texttt{U+0080} 以éã§ããã8ã¤ã®æåç¯å²ã«å±ããªãæåã¯ï¼217çªã®æåç¯å²ã«å±ãããã¨ã«ãªã£ã¦ããï¼
%
-\begin{cslist}[style=standard]
- \item[kozuka-pro] Kozuka Pro (Adobe-Japan1-4) fonts.
-% \\*[-\dimexpr\medskipamount+\baselineskip\relax]
- \item[kozuka-pr6] Kozuka Pr6 (Adobe-Japan1-6) fonts.
-% \\*[-\dimexpr\medskipamount+\baselineskip\relax]
- \item[kozuka-pr6n] Kozuka Pr6N (Adobe-Japan1-6, JIS04-savvy) fonts.
+\begin{description}
+%<*en>
+
+\item[Range~8${}^{\text{A}}$] The intersection of the upper half of ISO~8859-1
+ (Latin-1 Supplement) and JIS~X~0208 (a basic character set for Japanese). This character range
+ consists of the following characters:
+%
+%<*ja>
+\item[ç¯å²8${}^{\text{A}}$] ISO~8859-1ã®ä¸ä½é åï¼ã©ãã³1è£å©ï¼ã¨
+ JIS~X~0208ã®å
±éé¨åï¼ãã®æåç¯å²ã¯
+ 以ä¸ã®æåã§æ§æãããï¼
+%
+\begin{multicols}{2}
+\begin{itemize}
+\def\ch#1#2{\item \char"#1\ (\texttt{U+00#1}, #2)}%"
+\ch{A7}{Section Sign}
+\ch{A8}{Diaeresis}
+\ch{B0}{Degree sign}
+\ch{B1}{Plus-minus sign}
+\ch{B4}{Spacing acute}
+\ch{B6}{Paragraph sign}
+\ch{D7}{Multiplication sign}
+\ch{F7}{Division Sign}
+\end{itemize}
+\end{multicols}
%<*en>
-Kozuka Pro/Pr6N fonts are bundled with Adobe's software, such as Adobe~InDesign.
-There is not rounded gothic family in Kozuka fonts.
+\item[Range~1${}^{\text{A}}$] Latin characters that some of them are included in Adobe-Japan1-6.
+This range consists of the following Unicode ranges, \emph{except characters in the range~8 above}:
%
%<*ja>
-å°å¡Proæ¸ä½ã»Pr6Næ¸ä½ã¯Adobe InDesignçã®Adobe製åã«ãã³ãã«ããã¦ããï¼
-ãå°å¡ä¸¸ã´ã·ãã¯ãã¯åå¨ããªãã®ã§ï¼ä¾¿å®çã«å°å¡ã´ã·ãã¯Hã«ãã£ã¦ä»£ç¨ãã¦ããï¼
+\item[ç¯å²1${}^{\text{A}}$] ã©ãã³æåã®ãã¡ï¼Adobe-Japan1-6ã¨ã®å
±éé¨åããããã®ï¼
+ ãã®ç¯å²ã¯ä»¥ä¸ã®Unicodeã®ãããã¯ã®ãã¡
+ \emph{ç¯å²8ãé¤ãã}é¨åã§æ§æããã¦ããï¼
%
-\begin{center}\small
-\begin{tabular}{cllll}
-\toprule
-\bfseries family&\bfseries series&\ttfamily kozuka-pro&\ttfamily kozuka-pr6&\ttfamily kozuka-pr6n\\
-\midrule
- &medium&KozMinPro-Regular&KozMinProVI-Regular&KozMinPr6N-Regular\\
-%\smash{\raisebox{1.5ex}{\textit{mincho}}}%
-%\smash{\raisebox{1.5ex}{\gt ææ}}%
- &bold&KozMinPro-Bold&KozMinProVI-Bold&KozMinPr6N-Bold\\
-\midrule
- &&KozGoPro-Regular*&KozGoProVI-Regular*&KozGoPr6N-Regular*\\
- &\smash{\raisebox{1.5ex}{medium}}
- &KozGoPro-Medium&KozGoProVI-Medium&KozGoPr6N-Medium\\
-\cmidrule(l){2-5}
-%\smash{\raisebox{2ex}{\textit{gothic}}}%
-%\smash{\raisebox{2ex}{\gt ã´ã·ãã¯}}%
- &bold&KozGoPro-Bold&KozGoProVI-Bold&KozGoPr6N-Bold\\
- &heavy&KozGoPro-Heavy&KozGoProVI-Heavy&KozGoPr6N-Heavy\\
-\midrule
-%\textit{rounded gothic}
-%\gt 丸ã´ã·ãã¯
-&&KozGoPro-Heavy&KozGoProVI-Heavy&KozGoPr6N-Heavy\\
-\bottomrule
+\begin{multicols}{2}
+\begin{itemize}
+\item \texttt{U+0080}--\texttt{U+00FF}: Latin-1 Supplement
+\item \texttt{U+0100}--\texttt{U+017F}: Latin Extended-A
+\item \texttt{U+0180}--\texttt{U+024F}: Latin Extended-B
+\item \texttt{U+0250}--\texttt{U+02AF}: IPA Extensions
+\item \texttt{U+02B0}--\texttt{U+02FF}: Spacing Modifier Letters
+%\par\
+\item \texttt{U+0300}--\texttt{U+036F}: \\*\null\hfill Combining Diacritical Marks
+\item \texttt{U+1E00}--\texttt{U+1EFF}: \\*\null\hfill Latin Extended Additional
+%\par\
+\end{itemize}
+\end{multicols}
+%<*en>
+\item[Range~2${}^{\text{\kern.1emJ}}$] Greek and Cyrillic letters. JIS~X~0208 (hence most of Japanese
+ fonts) has some of these characters.
+%
+%<*ja>
+\item[ç¯å²2${}^{\text{\kern.1emJ}}$] ã®ãªã·ã£æåã¨ããªã«æåï¼JIS~X~0208ï¼ãããã£ã¦ã»ã¨ãã©ã®
+ åæãã©ã³ãï¼ã«ã¯ï¼ãããã®æåã®ä¸é¨ãå«ã¾ãã¦ããï¼
+%
+\begin{multicols}{2}
+\begin{itemize}
+\item \texttt{U+0370}--\texttt{U+03FF}: Greek and Coptic
+\item \texttt{U+0400}--\texttt{U+04FF}: Cyrillic
+\item \texttt{U+1F00}--\texttt{U+1FFF}: Greek Extended
+\\\
+\end{itemize}
+\end{multicols}
+%<*en>
+\item[Range~3${}^{\text{\kern.1emJ}}$] Punctuations and Miscellaneous symbols. The block list is
+ indicated in \autoref{tab:rng3}.
+%
+%<*ja>
+\item[ç¯å²3${}^{\text{\kern.1emJ}}$] å¥èªç¹ã¨è¨å·é¡ï¼ãããã¯ã®ãªã¹ãã¯\autoref{tab:rng3}%
+ ã«ç¤ºãã¦ããï¼
+%
+\begin{table}[!tb]
+%\caption{Unicode blocks in predefined character range~3.}\medskip
+%\caption{æåç¯å²3ã«æå®ããã¦ããUnicodeãããã¯ï¼}
+\label{tab:rng3}
+\catcode`\"=13\def"#1#2#3#4{\texttt{U+#1#2#3#4}}%"
+\centering\small
+\begin{tabular}{llll}
+"2000--"206F&General Punctuation&
+"2070--"209F&Superscripts and Subscripts\\
+"20A0--"20CF&Currency Symbols&
+"20D0--"20FF&Comb.\ Diacritical Marks for Symbols\\
+"2100--"214F&Letterlike Symbols&
+"2150--"218F&Number Forms\\
+"2190--"21FF&Arrows&
+"2200--"22FF&Mathematical Operators\\
+"2300--"23FF&Miscellaneous Technical&
+"2400--"243F&Control Pictures\\
+"2500--"257F&Box Drawing&
+"2580--"259F&Block Elements\\
+"25A0--"25FF&Geometric Shapes&
+"2600--"26FF&Miscellaneous Symbols\\
+"2700--"27BF&Dingbats&
+"2900--"297F&Supplemental Arrows-B\\
+"2980--"29FF&Misc.\ Mathematical Symbols-B&
+"2B00--"2BFF&Miscellaneous Symbols and Arrows
\end{tabular}
-\end{center}
-
-%\newpage
- \item[hiragino-pro] Hiragino Pro (Adobe-Japan1-5) fonts.
-% \\*[-\dimexpr\medskipamount+\baselineskip\relax]
- \item[hiragino-pron] Hiragino ProN (Adobe-Japan1-5, JIS04-savvy) fonts.
-
+\end{table}
%<*en>
-Hiragino fonts are bundled with Mac OS~X 10.5 or later.
-Some editions of a Japanese word-processor ``ä¸å¤ªé2012'' includes Hiragino ProN fonts.
-Note that the heavy weight of \textit{gothic} family only supports
-Adobe-Japan1-3 character collection (Std/StdN).
+\item[Range~4${}^{\text{A}}$] Characters usually not in Japanese fonts. This range consists
+ of almost all Unicode blocks which are not in other
+ predefined ranges. Hence, instead of showing the block list,
+ we put the definition of this range itself:
%
%<*ja>
-ãã©ã®ããã©ã³ãã¯ï¼Mac OS~X以å¤ã«ãï¼ä¸å¤ªé2012ã®ä¸ä½ã¨ãã£ã·ã§ã³ã«ããã³ãã«ããã¦ããï¼
-極太ã´ã·ãã¯ã¨ãã¦ç¨ãããã©ã®ãè§ã´W8ã¯ï¼Adobe-Japan1-3ã®ç¯å²ããã«ãã¼ãã¦ããªã
-Std/StdNãã©ã³ãã§ããï¼ãã®ä»ã¯Adobe-Japan1-5対å¿ã§ããï¼
+\item[ç¯å²4${}^{\text{A}}$] é常åæãã©ã³ãã«ã¯å«ã¾ãã¦ããªãæåï¼
+ ãã®ç¯å²ã¯ä»ã®ç¯å²ã«ãªãã»ã¨ãã©å
¨ã¦ã®Unicodeãããã¯
+ ã§æ§æããã¦ããï¼ãããã£ã¦ï¼ãããã¯ã®ãªã¹ãã示ã
+ 代ããã«ï¼ç¯å²ã®å®ç¾©ãã®ãã®ã示ãï¼
%
-\begin{center}\small
-\begin{tabular}{clll}
-\toprule
-\bf family&\bf series&\tt hiragino-pro&\tt hiragino-pron\\
-\midrule
- &medium&Hiragino~Mincho~Pro~W3&Hiragino~Mincho~ProN~W3\\
-%\smash{\raisebox{1.5ex}{\textit{mincho}}}%
-%\smash{\raisebox{1.5ex}{\gt ææ}}%
- &bold&Hiragino~Mincho~Pro~W6&Hiragino~Mincho~ProN~W6\\
-\midrule
- &&Hiragino~Kaku~Gothic~Pro~W3*&Hiragino~Kaku~Gothic~ProN~W3*\\
- &\smash{\raisebox{1.5ex}{medium}}
- &Hiragino~Kaku~Gothic~Pro~W6&Hiragino~Kaku~Gothic~ProN~W6\\
-\cmidrule(l){2-4}
-%\smash{\raisebox{2ex}{\textit{gothic}}}%
-%\smash{\raisebox{2ex}{\gt ã´ã·ãã¯}}%
- &bold&Hiragino~Kaku~Gothic~Pro~W6&Hiragino~Kaku~Gothic~ProN~W6\\
- &heavy&Hiragino~Kaku~Gothic~Std~W8&Hiragino~Kaku~Gothic~StdN~W8\\
-\midrule
-%\textit{rounded gothic}
-%\gt 丸ã´ã·ãã¯
-&&Hiragino~Maru~Gothic~Pro~W4&Hiragino~Maru~Gothic~ProN~W4\\
-\bottomrule
+\begin{lstlisting}
+\ltjdefcharrange{4}{%
+ "500-"10FF, "1200-"1DFF, "2440-"245F, "27C0-"28FF, "2A00-"2AFF,
+ "2C00-"2E7F, "4DC0-"4DFF, "A4D0-"A82F, "A840-"ABFF, "FB00-"FE0F,
+ "FE20-"FE2F, "FE70-"FEFF, "10000-"1FFFF, "E000-"F8FF} % non-Japanese
+\end{lstlisting}
+%\item[Range~5${}^{\text{A}}$] Surrogates and Supplementary Private Use Areas.
+%\item[ç¯å²5${}^{\text{A}}$] 代ç¨ç¬¦å·ã¨è£å©ç§ç¨é åï¼
+%\item[Range~6${}^{\text{\kern.1emJ}}$] Characters used in Japanese. The block list is indicated in \autoref{tab:rng6}.
+%\item[ç¯å²6${}^{\text{\kern.1emJ}}$] æ¥æ¬èªã§ç¨ããããæåï¼ãããã¯ã®ãªã¹ãã¯\autoref{tab:rng6}ã«ç¤ºãï¼
+\begin{table}[!tb]
+%\caption{Unicode blocks in predefined character range~6.}\medskip
+%\caption{æåç¯å²6ã«æå®ããã¦ããUnicodeãããã¯ï¼}
+\label{tab:rng6}
+\catcode`\"=13\def"#1#2#3#4{\texttt{U+#1#2#3#4}}%"
+\centering\small
+\begin{tabular}{llll}
+"2460--"24FF&Enclosed Alphanumerics&
+"2E80--"2EFF&CJK Radicals Supplement\\
+"3000--"303F&CJK Symbols and Punctuation&
+"3040--"309F&Hiragana\\
+"30A0--"30FF&Katakana&
+"3190--"319F&Kanbun\\
+"31F0--"31FF&Katakana Phonetic Extensions&
+"3200--"32FF&Enclosed CJK Letters and Months\\
+"3300--"33FF&CJK Compatibility&
+"3400--"4DBF&CJK Unified Ideographs Extension A\\
+"4E00--"9FFF&CJK Unified Ideographs&
+"F900--"FAFF&CJK Compatibility Ideographs\\
+"FE10--"FE1F&Vertical Forms&
+"FE30--"FE4F&CJK Compatibility Forms\\
+"FE50--"FE6F&Small Form Variants&
+"{20}000--"{2F}FFF&(Supplementary Ideographic Plane)\\
+"{E0}100--"{E0}1EF&Variation Selectors Supplement
\end{tabular}
-\end{center}
-
- \item[morisawa-pro] Morisawa Pro (Adobe-Japan1-4) fonts.
-% \\*[-\dimexpr\medskipamount+\baselineskip\relax]
- \item[morisawa-pr6n] Morisawa Pr6N (Adobe-Japan1-6, JIS04-savvy) fonts.
-\begin{center}\small
-\begin{tabular}{cl>{\tt}l>{\tt}l}
-\toprule
-\bf family&\bf series&morisawa-pro&morisawa-pr6n\\
-\midrule
- &medium&A-OTF-RyuminPro-Light.otf&A-OTF-RyuminPr6N-Light.otf\\
-%\smash{\raisebox{1.5ex}{\textit{mincho}}}%
-%\smash{\raisebox{1.5ex}{\gt ææ}}%
- &bold&A-OTF-FutoMinA101Pro-Bold.otf&A-OTF-FutoMinA101Pr6N-Bold.otf\\
-\midrule
- &medium
- &A-OTF-GothicBBBPro-Medium.otf&A-OTF-GothicBBBPr6N-Medium.otf\\
-%\textit{gothic}%
-%\gt ã´ã·ãã¯
- &bold&A-OTF-FutoGoB101Pro-Bold.otf&A-OTF-FutoGoB101Pr6N-Bold.otf\\
- &heavy&A-OTF-MidashiGoPro-MB31.otf&A-OTF-MidashiGoPr6N-MB31.otf\\
-\midrule
-%\textit{rounded gothic}
-%\gt 丸ã´ã·ãã¯
-&&A-OTF-Jun101Pro-Light.otf&A-OTF-ShinMGoPr6N-Light.otf\\
-\bottomrule
+\end{table}
+%<*en>
+\item[Range~7${}^{\text{\kern.1emJ}}$] Characters used in CJK languages, but not included in Adobe-Japan1-6.
+The block list is indicated in \autoref{tab:rng7}.
+%
+%<*ja>
+\item[ç¯å²7${}^{\text{\kern.1emJ}}$] CJKè¨èªã§ç¨ããããæåã®ãã¡ï¼Adobe-Japan1-6ã«
+ å«ã¾ãã¦ããªããã®ï¼
+ ãããã¯ã®ãªã¹ãã¯\autoref{tab:rng7}ã«ç¤ºãï¼
+%
+\begin{table}[!tb]
+%\caption{Unicode blocks in predefined character range~7.}\medskip
+%\caption{æåç¯å²7ã«æå®ããã¦ããUnicodeãããã¯ï¼}
+\label{tab:rng7}
+\catcode`\"=13\def"#1#2#3#4{\texttt{U+#1#2#3#4}}%"
+\centering\small
+\begin{tabular}{llll}
+"1100--"11FF&Hangul Jamo&
+"2F00--"2FDF&Kangxi Radicals\\
+"2FF0--"2FFF&Ideographic Description Characters&
+"3100--"312F&Bopomofo\\
+"3130--"318F&Hangul Compatibility Jamo&
+"31A0--"31BF&Bopomofo Extended\\
+"31C0--"31EF&CJK Strokes&
+"A000--"A48F&Yi Syllables\\
+"A490--"A4CF&Yi Radicals&
+"A830--"A83F&Common Indic Number Forms\\
+"AC00--"D7AF&Hangul Syllables&
+"D7B0--"D7FF&Hangul Jamo Extended-B
\end{tabular}
-\end{center}
+\end{table}
+\end{description}
-%\newpage
- \item[yu-win] Yu fonts bundled with Windows~8.1.
-% \\*[-\dimexpr\medskipamount+\baselineskip\relax]
- \item[yu-win10] Yu fonts bundled with Windows~10.
-% \\*[-\dimexpr\medskipamount+\baselineskip\relax]
- \item[yu-osx] Yu fonts bundled with OSX~Mavericks.
-\begin{center}\small
-\begin{tabular}{cllll}
-\toprule
-\bf family&\bf series&\texttt{yu-win}&\texttt{yu-win10}&\texttt{yu-osx}\\
-\midrule
- &medium&YuMincho-Regular&YuMincho-Regular&YuMincho~Medium\\
-%\smash{\raisebox{1.5ex}{\textit{mincho}}}%
-%\smash{\raisebox{1.5ex}{\gt ææ}}%
- &bold&YuMincho-Demibold&YuMincho-Demibold&YuMincho~Demibold\\
-\midrule
- &&YuGothic-Regular*&YuGothic-Regular*&YuGothic~Medium*\\
- &\smash{\raisebox{1.5ex}{medium}}%
- &YuGothic-Regular&YuGothic-Medium&YuGothic~Medium\\
-\cmidrule(l){2-5}
-%\textit{gothic}%
-%\gt ã´ã·ãã¯
- &bold&YuGothic-Bold&YuGothic-Bold&YuGothic~Bold\\
- &heavy&YuGothic-Bold&YuGothic-Bold&YuGothic~Bold\\
-\midrule
-%\textit{rounded gothic}
-%\gt 丸ã´ã·ãã¯
-&&YuGothic-Bold&YuGothic-Bold&YuGothic~Bold\\
-\bottomrule
-\end{tabular}
-\end{center}
+%<*en>
+\paragraph{Notes on \texttt{U+0080}--\texttt{U+00FF}}
+You should treat characters in \\texttt{U+0080}--\texttt{U+00FF} as \textbf{ALchar},
+when you use traditional 8-bit fonts, such as the \Pkg{marvosym} package.
-%\newpage
-\item[moga-mobo] MogaMincho, MogaGothic, and MoboGothic.
-\item[moga-mobo-ex] MogaExMincho, MogaExGothic, and MoboExGothic.
-%These fonts can be downloaded from\\\hfill \url{http://yozvox.web.fc2.com/}.
-%ãããã®ãã©ã³ã㯠\url{http://yozvox.web.fc2.com/} ãããã¦ã³ãã¼ãã§ããï¼
-\begin{center}\small
-\begin{tabular}{clll}
-\toprule
-\bf family&\bf series&\bf default, \texttt{90jis}~option&\bf \texttt{jis2004} option\\
-\midrule
- &medium&Moga90Mincho&MogaMincho\\
-%\smash{\raisebox{1.5ex}{\textit{mincho}}}%
-%\smash{\raisebox{1.5ex}{\gt ææ}}%
- &bold&Moga90Mincho Bold&MogaMincho Bold\\
-\midrule
- &medium&Moga90Gothic&MogaGothic\\
-%\textit{gothic}%
-%\gt ã´ã·ãã¯
- &bold&Moga90Gothic Bold&MogaGothic Bold\\
- &heavy&Moga90Gothic Bold&MogaGothic Bold\\
-\midrule
-%\textit{rounded gothic}
-%\gt 丸ã´ã·ãã¯
-&&Mobo90Gothic&MoboGothic\\
-\bottomrule
-\end{tabular}
-\end{center}
-%When \texttt{moga-mobo-ex} is specified, the font ``MogaEx90Mincho'' etc.\ are used.
-%\texttt{moga-mobo-ex}ãªãã·ã§ã³æå®æã«ã¯MogaEx90Minchoãªã©ã®Exãååã«ã¤ãããã©ã³ãã使ãããï¼
+For example, \cs{Frowny} which is provided by the \Pkg{marvosym} package has
+the same codepoint as \S\ (\text{U+00A7}).
+Hence, as previous versions of \LuaTeX-ja, if these characters are treated as
+\text{JAchar}s, then \cs{Frowny} produces ``\ltjjachar`§'' (in a Japanese font).
-\item[ume] Ume Mincho and Ume Gothic.
-%These fonts can be downloaded from\\\hfill \url{https://ja.osdn.net/projects/ume-font/wiki/FrontPage}.
-%ãããã®ãã©ã³ã㯠\url{https://ja.osdn.net/projects/ume-font/wiki/FrontPage} ãããã¦ã³ãã¼ãã§ããï¼
-\begin{center}\small
-\begin{tabular}{cll}
-\toprule
-\bf family&\bf series&\bf default\\
-\midrule
- &medium&Ume Mincho\\
-%\smash{\raisebox{1.5ex}{\textit{mincho}}}%
-%\smash{\raisebox{1.5ex}{\gt ææ}}%
- &bold&Ume Mincho\\
-\midrule
- &&Ume Gothic*\\
- &\smash{\raisebox{1.5ex}{medium}}&Ume Gothic O5\\
-\cmidrule(l){2-3}
-%\textit{gothic}%
-%\gt ã´ã·ãã¯
- &bold&Ume Gothic O5\\
- &heavy&Ume Gothic O5\\
-\midrule
-%\textit{rounded gothic}
-%\gt 丸ã´ã·ãã¯
-&&Ume Gothic O5\\
-\bottomrule
-\end{tabular}
-\end{center}
+To avoid such situations, the default setting of \LuaTeX-ja is changed in version~20150906.0
+so that all characters \texttt{U+0080}--\texttt{U+00FF} are treated as \textbf{ALchar}.
-\end{cslist}
-%\paragraph{Presets for single weight}
-%\paragraph{åã¦ã§ã¤ãç¨ããªã»ããä¸è¦§}
-%<*en>
-Next, we describe settings for using only single weight.
+If you want to output a character as \textbf{ALchar} and \textbf{JAchar} regardless the range
+setting, you can use \cs{ltjalchar} and \cs{ltjjachar} respectively, as the following example.
+\begin{LTXexample}[width=0.3\textwidth]
+\gtfamily\large % default, ALchar, JAchar
+¶, \ltjalchar`¶, \ltjjachar`¶\\ % default: ALchar
+α, \ltjalchar`α, \ltjjachar`α % default: JAchar
+\end{LTXexample}
%
%<*ja>
-次ã«ï¼åã¦ã§ã¤ãç¨ã®è¨å®ãè¿°ã¹ãï¼ãã®4è¨å®ã§ã¯
-ææä½å¤ªåã»ä¸¸ã´ã·ãã¯ä½ã¯ã´ã·ãã¯ä½ã¨åããã©ã³ããç¨ããããï¼
+\paragraph{\texttt{U+0080}--\texttt{U+00FF}ã«ã¤ãã¦ã®æ³¨æ}
+\LuaTeX-jaã§ï¼\Pkg{marvosym}ããã±ã¼ã¸çï¼Unicodeãã©ã³ãã§ãªã
+ä¼çµ±çãª8ããããã©ã³ããç¨ããå ´åã«ã¯æ³¨æãå¿
è¦ã§ããï¼
+
+ä¾ãã°ï¼\Pkg{marvosym}ããã±ã¼ã¸ã®æä¾ãã \cs{Frowny} ãï¼ç¬¦å·ä½ç½®ã¯167ï¼ã¤ã¾ãUnicodeã«ããã
+\S\ (\text{U+00A7}) ã¨åã符å·ä½ç½®ã«ããï¼
+å³ã¡ï¼ä»¥åã®ãã¼ã¸ã§ã³ã®ããã«ï¼ãåç¯ã®æåç¯å²8å
ã®æåã¯\textbf{JAchar}ãã¨ããè¨å®ã§
+ãã£ãã¨ããã¨ï¼ä¸è¨ã® \cs{Frowny} ã¯åæãã©ã³ãã§ã\ltjjachar`§ããåºåãããã¨ã«ãªãï¼
+
+ãã®ãããªäºæ
ãé¿ããããã«ï¼ãã¼ã¸ã§ã³20150906.0ãã㯠\texttt{U+0080}--\texttt{U+00FF} ã®ç¯å²ã®
+æåã¯å
¨ã¦\textbf{ALchar}ã¨ãªãããã«åæè¨å®ãå¤æ´ãã¦ããï¼
+
+ãªãï¼æåç¯å²ã®è¨å®ã«é¢ããã1ã¤ã®æåã\textbf{ALchar}, \textbf{JAchar}ã§åºåãããå ´åã«ã¯ï¼
+以ä¸ã®ä¾ã®ããã«ãããã \cs{ltjalchar},~\cs{ltjjachar} ã«è©²å½æåã®æåã³ã¼ãã渡ãã°ããï¼
+\begin{LTXexample}[width=0.3\textwidth]
+\gtfamily\large % default, ALchar, JAchar
+¶, \ltjalchar`¶, \ltjjachar`¶\\ % default: ALchar
+α, \ltjalchar`α, \ltjjachar`α % default: JAchar
+\end{LTXexample}
%
-\par\nobreak\medskip
-{\centering\small
-\begin{tabular}{lllll}
-\toprule
-&\tt noembed&\tt ipa&\tt ipaex&\tt ms\\
-\midrule
+
+
+%\subsection{\Param{kanjiskip} and \Param{xkanjiskip}}
+%\subsection{\Param{kanjiskip}ã¨\Param{xkanjiskip}}
+\label{subs-kskip}
+
+%\textbf{JAglue} is divided into the following three categories:
+%\textbf{JAglue}ã¯ä»¥ä¸ã®3ã¤ã®ã«ãã´ãªã«åé¡ãããï¼
+\begin{itemize}
%<*en>
-\it mincho&Ryumin-Light (non-embedded)
-&IPA Mincho&IPAex Mincho&MS Mincho\\
-\it gothic&GothicBBB-Medium (non-embedded)
-&IPA Gothic&IPAex Gothic&MS Gothic\\
+\item Glues/kerns specified in JFM. If \cs{inhibitglue} is issued
+ around a \textbf{JAchar}, this glue will not be inserted at the
+ place.
%
%<*ja>
-\gtfamily ææä½&Ryumin-Lightï¼éåè¾¼ï¼
-&IPAææ&IPAexææ&MSææ\\
-\gtfamily ã´ã·ãã¯ä½&GothicBBB-Mediumï¼éåè¾¼ï¼
-&IPAã´ã·ãã¯&IPAexã´ã·ãã¯&MSã´ã·ãã¯\\
+\item JFMã§æå®ãããã°ã«ã¼ï¼ã«ã¼ã³ï¼ãã \cs{inhibitglue} ã\textbf{JAchar}ã®å¨ãã§
+ çºè¡ããã¦ããã°ï¼ãã®ã°ã«ã¼ã¯æ¿å
¥ãããªãï¼
%
-\bottomrule
-\end{tabular}\par\medskip}
-
-%\paragraph{Using HG fonts}
-%\paragraph{HGãã©ã³ãã®å©ç¨}
%<*en>
-We can use HG~fonts bundled with Microsoft~Office for realizing multiple weights.
+\item The default glue which inserted between two \textbf{JAchar}s (\Param{%
+ kanjiskip}).
%
%<*ja>
-ããåã«æ¸ããåã¦ã§ã¤ãç¨è¨å®ãï¼Microsoft Officeçã«ä»å±ããHGãã©ã³ãã使ã£ã¦
-å¤ã¦ã§ã¤ãåããè¨å®ãããï¼
+\item ããã©ã«ãã§2ã¤ã®\textbf{JAchar}ã®éã«æ¿å
¥ãããã°ã«ã¼(\Param{kanjiskip})ï¼
%
-\par\nobreak\medskip
-{\centering\small
-\begin{tabular}{llll}
-\toprule
-&\tt ipa-hg&\tt ipaex-hg&\tt ms-hg\\
-\midrule
%<*en>
-\bf mincho medium
-&IPA Mincho&IPAex Mincho&MS Mincho\\\midrule
-\bf mincho bold&
-\multicolumn{3}{c}{HG Mincho E}\\\midrule
-\bf Gothic medium\\
-~~without \texttt{deluxe}
-&IPA Gothic&IPAex Gothic&MS Gothic\\
-~~with {\tt jis2004}
-&IPA Gothic&IPAex Gothic&MS Gothic\\
-\cmidrule(lr){1-4}
-~~otherwise&
-\multicolumn{3}{c}{HG Gothic M}\\\midrule
-\bf gothic bold&
-\multicolumn{3}{c}{HG Gothic E}\\\midrule
-\bf gothic heavy&
-\multicolumn{3}{c}{HG Soei Kaku Gothic UB}\\\midrule
-\bf rounded gothic&
-\multicolumn{3}{c}{HG Maru Gothic PRO}\\
-%
-%<*ja>
-\gtfamily ææä½ä¸å
-&IPAææ&IPAexææ&MSææ\\\midrule
-\gtfamily ææä½å¤ªå&
-\multicolumn{3}{c}{HGææE}\\\midrule
-\gtfamily ã´ã·ãã¯ä½ä¸å\\
-ãåã¦ã§ã¤ãæ
-&IPAã´ã·ãã¯&IPAexã´ã·ãã¯&MSã´ã·ãã¯\\
-ã{\tt jis2004}æå®æ
-&IPAã´ã·ãã¯&IPAexã´ã·ãã¯&MSã´ã·ãã¯\\
-\cmidrule(lr){1-4}
-ããã以å¤ã®æ&
-\multicolumn{3}{c}{HGã´ã·ãã¯M}\\\midrule
-\gtfamily ã´ã·ãã¯ä½å¤ªå&
-\multicolumn{3}{c}{HGã´ã·ãã¯E}\\\midrule
-\gtfamily ã´ã·ãã¯ä½æ¥µå¤ª&
-\multicolumn{3}{c}{HGåµè±è§ã´ã·ãã¯UB}\\\midrule
-\gtfamily 丸ã´ã·ãã¯ä½&
-\multicolumn{3}{c}{HG丸ã´ã·ãã¯ä½PRO}\\
+\item The default glue which inserted between a \textbf{JAchar} and an
+ \textbf{ALchar} (\Param{xkanjiskip}).
+%
+%<*ja>
+\item ããã©ã«ãã§\textbf{JAchar}ã¨\textbf{ALchar}ã®éã«æ¿å
¥ãããã°ã«ã¼(\Param{xkanjiskip})ï¼
%
-\bottomrule
-\end{tabular}\par\medskip}
-
+\end{itemize}
%<*en>
-Note that HG~Mincho~E, HG~Gothic~E, HG Soei Kaku Gothic UB, and HG Maru Gothic PRO
-are internally specified by:
-\begin{description}
-\item[default] by font name (\texttt{HGMinchoE}, etc.).
-\item[{\tt 90jis}] by file name (\texttt{hgrme.ttc}, \texttt{hgrge.ttc}, \texttt{hgrsgu.ttc}, \texttt{hgrsmp.ttf}).
-\item[{\tt jis2004}] by file name (\texttt{hgrme04.ttc}, \texttt{hgrge04.ttc}, \texttt{hgrsgu04.ttc}, \texttt{hgrsmp04.ttf}).
-\end{description}
+The value (a skip) of \Param{kanjiskip} or
+\Param{xkanjiskip} can be changed as the following.
+Note that only their values \emph{at the end of a paragraph or a hbox are
+adopted in the whole paragraph or the whole hbox.
+}
%
%<*ja>
-ãªãï¼HGææEã»HGã´ã·ãã¯Eã»HGåµè±è§ã´ã·ãã¯UBã»HG丸ã´ã·ãã¯ä½PROã®4ã¤ã«ã¤ãã¦ã¯ï¼å
é¨ã§
-\begin{description}
-\item[æ¨æº] ãã©ã³ãåï¼\texttt{HGMinchoE} ãªã©ï¼
-\item[{\tt 90jis}æå®æ] ãã¡ã¤ã«å (%
-\texttt{hgrme.ttc}, \texttt{hgrge.ttc}, \texttt{hgrsgu.ttc}, \texttt{hgrsmp.ttf})
-\item[{\tt jis2004}æå®æ] ãã¡ã¤ã«å (%
-\texttt{hgrme04.ttc}, \texttt{hgrge04.ttc}, \texttt{hgrsgu04.ttc}, \texttt{hgrsmp04.ttf})
-\end{description}
-ã¨ãã¦æå®ãè¡ã£ã¦ããã®ã§æ³¨æãããã¨ï¼
+\Param{kanjiskip}ã\Param{xkanjiskip}ã®å¤
+ã¯ä»¥ä¸ã®ããã«ãã¦å¤æ´å¯è½ã§ããï¼
%
-
-
+\begin{lstlisting}
+\ltjsetparameter{kanjiskip={0pt plus 0.4pt minus 0.4pt},
+ xkanjiskip={0.25\zw plus 1pt minus 1pt}}
+\end{lstlisting}
%<*en>
-\subsection{\cs{CID}, \cs{UTF}, and macros in \Pkg{japanese-otf} package}
-Under \pLaTeX, \Pkg{japanese-otf} package (developed by Shuzaburo Saito) is
-used for typesetting characters which is in Adobe-Japan1-6 CID but not
-in JIS~X~0208. Since this package is widely used, \LuaTeX-ja
-supports some of functions in the \Pkg{japanese-otf} package,
-as an external package \Pkg{luatexja-otf}.
+Here \cs{zw} is a internal dimension
+which stores fullwidth of the current Japanese font.
+This \cs{zw} can be used as the unit \texttt{zw} in \pTeX.
+
+The value of these parameter can be get by \cs{ltjgetparameter}.
+Note that the result by \cs{ltjgetparameter} is \emph{not} the internal quantities,
+but \emph{a string} (hence \cs{the} cannot be prefixed).
%
%<*ja>
-\subsection{\cs{CID}, \cs{UTF}ã¨\Pkg{otf}ããã±ã¼ã¸ã®ãã¯ã}
-\pLaTeX ã§ã¯ï¼JIS~X~0208ã«ãªãAdobe-Japan1-6ã®æåãåºåããããã«ï¼
-é½è¤ä¿®ä¸éæ°ã«ãã\Pkg{otf}ããã±ã¼ã¸ãç¨ãããã¦ããï¼ãã®ããã±ã¼ã¸ã¯
-åºãç¨ãããã¦ããããï¼\LuaTeX-jaã«ããã¦ã\Pkg{otf}ããã±ã¼ã¸ã®æ©è½ã®
-ä¸é¨ãï¼\Pkg{luatexja-otf}ã¨ããå¥ã®ããã±ã¼ã¸ã¨ãã¦ï¼å®è£
ããï¼
-%
+ããã§ï¼\cs{zw} ã¯ç¾å¨ã®åæãã©ã³ãã®å
¨è§å¹
ã表ãé·ãã§ããï¼
+\pTeX ã«ãããé·ãåä½ \texttt{zw} ã¨åãããã«ä½¿ç¨ã§ããï¼
+ãããã®ãã©ã¡ã¼ã¿ã®å¤ã¯ä»¥ä¸ã®ããã«åå¾ã§ããï¼
+æ»ãå¤ã¯å
é¨å¤ã§ã¯ãªã\emph{æåå}ã§ããï¼\cs{the} ã¯åç½®ã§ããªãï¼ãã¨ã«æ³¨æãã¦ã»ããï¼
+%
\begin{LTXexample}
-\jfontspec{KozMinPr6N-Regular.otf}
-森\UTF{9DD7}å¤ã¨å
ç°ç¾\UTF{9592}ã¨ã\UTF{9AD9}島å±ã«è¡ãã
-
-\CID{7652}飾åºã®\CID{13706}é家ï¼
-\CID{1481}åå¸ï¼è西é§
ï¼
-é«å´ã¨\CID{8705}\UTF{FA11}
-
-\ajåè§{ã¯ãããã«ã¿ã«ã}
+kanjiskip: \ltjgetparameter{kanjiskip},\\
+xkanjiskip: \ltjgetparameter{xkanjiskip}
\end{LTXexample}
+%<*en>
+It may occur that JFM contains the data of ``ideal width of
+\Param{kanjiskip}''
+and/or ``ideal width of \Param{xkanjiskip}''.
+To use these data from JFM, set the value of \Param{kanjiskip} or
+\Param{xkanjiskip} to \cs{maxdimen}
+(these ``ideal width'' cannot be retrived by \cs{ltjgetparameter}).
+%
%<*ja>
-\Pkg{otf}ããã±ã¼ã¸ã§ã¯ï¼ãããã次ã®ãããªãªãã·ã§ã³ãåå¨ããï¼
-\begin{cslist}
-\item[deluxe] ææä½ã»ã´ã·ãã¯ä½å3ã¦ã§ã¤ãã¨ï¼ä¸¸ã´ã·ãã¯ä½ãæ±ããããã«ãªãï¼
-\item[expert] ä»®åã横çµã»ç¸¦çµå°ç¨ã®ãã®ã«åãæ¿ããï¼ã«ãç¨ä»®åã
-\ \cs{rubyfamily}\ ã«ãã£ã¦æ±ããããã«ãªãï¼
-\item[bold] ã´ã·ãã¯ä½ãæ¨æºã§å¤ªãã¦ã§ã¤ãã®ãã®ã«è¨å®ããï¼
-\end{cslist}
-ããããããã®ãªãã·ã§ã³ã¯\Pkg{luatexja-otf}ããã±ã¼ã¸ã«ã¯åå¨ããªãï¼
-\Pkg{otf}ããã±ã¼ã¸ãææ¸ä¸ã§ä½¿ç¨ããåæç¨TFMãèªåã®ç©ã«ç½®ãæãã¦ããã®ã«å¯¾ãï¼
-\Pkg{luatexja-otf}ããã±ã¼ã¸ã§ã¯ï¼ãã®ãããªãã¨ã¯è¡ããªãããã§ããï¼
-
-ããã3ãªãã·ã§ã³ã«ã¤ãã¦ã¯ï¼
-\Pkg{luatexja-preset} ããã±ã¼ã¸ã«ããªã»ããã使ãæã«ä¸ç·ã«æå®ãããï¼
-ãããã¯å¯¾å¿ããå
容ã\ref{ssec-chgfnt}ç¯ï¼\ref{ssec-nfsspat}ç¯ (NFSS2) ã
-\ref{ssec-fontspec}ç¯ (\Pkg{fontspec}) ã®æ¹æ³ã§æåã§æå®ããå¿
è¦ãããï¼
+JFMã¯ãæã¾ãã\Param{kanjiskip}ã®å¤ãã
+ãæã¾ãã\Param{xkanjiskip}ã®å¤ããæã£ã¦ãããã¨ãããï¼
+ãããã®ãã¼ã¿ã使ãããã«ã¯ï¼\Param{kanjiskip}ã%
+\Param{xkanjiskip}ã®å¤ã \cs{maxdimen} ã®å¤ã«è¨å®ããã°ãããï¼
+\cs{ltjgetparameter} ã«ãã£ã¦åå¾ãããã¨ã¯ã§ããªãã®ã§æ³¨æãå¿
è¦ã§ããï¼
%
-%\subsection{Changing default Japanese fonts}
-%\subsection{æ¨æºåæãã©ã³ãã®å¤æ´}
-\label{ssec-cfg}
-%<*en>
-If \texttt{luatexja.cfg} can be seen from \LuaTeX, \LuaTeX-ja automatically reads it.
-The main use of \texttt{luatexja.cfg} is for changing default Japanese fonts,
-when IPAex fonts cannot be installed in \TeX~system.
-One should not overuse this \texttt{luatexja.cfg}; fonts which will be used in
-a document should be specified in its source.
-
-For example,
-\begin{lstlisting}
-\def\ltj@stdmcfont{IPAMincho}
-\def\ltj@stdgtfont{IPAGothic}
-\end{lstlisting}
-makes that IPA~Mincho and IPA~Gothic will be used as default Japanese fonts, instead of
-IPAex~Mincho and IPAex~Gothic.
+%\subsection{Insertion setting of \Param{xkanjiskip}}
+%\subsection{\Param{xkanjiskip} ã®æ¿å
¥è¨å®}
-For another example, the following two lines makes that
-non-embedded fonts Ryumin-Light~and~GothicBBB-Medium as default Japanese fonts
-(as the earlier version of \LuaTeX-ja):
-\begin{lstlisting}
-\def\ltj@stdmcfont{psft:Ryumin-Light}
-\def\ltj@stdgtfont{psft:GothicBBB-Medium}
-\end{lstlisting}
+%<*en>
+It is not desirable that \Param{xkanjiskip} is inserted into every
+boundary between \textbf{JAchar}s and \textbf{ALchar}s. For example,
+\Param{xkanjiskip} should not be inserted after opening parenthesis
+(\textit{e.g.}, compare ``(ã'' and ``(\hskip\ltjgetparameter{xkanjiskip}ã'').
+\LuaTeX-ja can control whether \Param{xkanjiskip} can be inserted
+before/after a character, by changing \Param{jaxspmode} for \textbf{JAchar}s and
+\Param{alxspmode} parameters \textbf{ALchar}s respectively.
%
%<*ja>
-\LuaTeX ããè¦ããä½ç½®ã« \texttt{luatexja.cfg} ãããã°ï¼\LuaTeX-jaã¯ãããèªã¿è¾¼ãï¼
-ãã®ãã¡ã¤ã«ãç¨ããã¨plain~\TeX, \LaTeXe ã«ãããæ¨æºåæãã©ã³ãã
-IPAexææã»IPAexã´ã·ãã¯ããå¤æ´ãããã¨ãã§ããï¼
-ãããï¼åºæ¬çã«ã¯\emph{æç« ä¸ã§ç¨ãããã©ã³ãã¯ï¼ä¾ãã° \Pkg{luatexja-preset} ãªã©ã§ï¼
-ææ¸ã½ã¼ã¹å
ã§æå®ããã¹ã}ã§ããï¼ãã® \texttt{luatexja.cfg} ã¯ï¼
-ãIPAexãã©ã³ããã¤ã³ã¹ãã¼ã«ã§ããªãããªã©ï¼IPAexãã©ã³ãã使ç¨ã§ããªãå ´åã«ã®ã¿
-å¿æ¥å¦ç½®çã«ç¨ããã¹ãã§ããï¼
-
-ä¾ãã°
-\begin{lstlisting}
-\def\ltj@stdmcfont{IPAMincho}
-\def\ltj@stdgtfont{IPAGothic}
-\end{lstlisting}
-ã¨è¨è¿°ãã¦ããã°ï¼æ¨æºåæãã©ã³ããIPAææã»IPAã´ã·ãã¯ã¸ã¨å¤
-æ´ãããï¼
-
-
-ãªãï¼20140906.0以åã®ãã¼ã¸ã§ã³ã®ããã«ï¼
-Ryumin-Light, GothicBBB-Mediumã¨ããååã®éåè¾¼ãã©ã³ããç¨ããå ´åã¯
-\begin{lstlisting}
-\def\ltj@stdmcfont{psft:Ryumin-Light}
-\def\ltj@stdgtfont{psft:GothicBBB-Medium}
-\end{lstlisting}
-ã¨è¨è¿°ããã°ããï¼
+\Param{xkanjiskip}ããã¹ã¦ã®\textbf{JAchar}ã¨\textbf{ALchar}ã®å¢çã«
+æ¿å
¥ãããã®ã¯æã¾ãããã¨ã§ã¯ãªãï¼ä¾ãã°ï¼\Param{xkanjiskip}ã¯éãæ¬å¼§ã®
+å¾ã«ã¯æ¿å
¥ãããã¹ãã§ã¯ãªãï¼ã(ããã¨ã(\hskip\ltjgetparameter{xkanjiskip}ããã
+æ¯ã¹ã¦ã¿ãï¼ï¼
+\LuaTeX-jaã§ã¯\Param{xkanjiskip}ãããæåã®åï¼å¾ã«æ¿å
¥ãããã©ãããï¼
+\textbf{JAchar}ã«å¯¾ãã¦ã¯\Param{jaxspmode}ãï¼\textbf{ALchar}ã«å¯¾ãã¦ã¯
+\Param{alxspmode}ãããããå¤ãããã¨ã§å¶å¾¡ãããã¨ãã§ããï¼
%
-
-
-%\section{Changing Internal Parameters}
-%\section{ãã©ã¡ã¼ã¿ã®å¤æ´}
+\begin{LTXexample}
+\ltjsetparameter{jaxspmode={`ã,preonly}, alxspmode={`\!,postonly}}
+pãq ã!ã
+\end{LTXexample}
%<*en>
-There are many internal parameters in \LuaTeX-ja. And due to the behavior of \LuaTeX,
-most of them are not stored as internal register of \TeX, but as an
-original storage system in \LuaTeX-ja. Hence, to assign or acquire those
-parameters, you have to use commands \cs{ltjsetparameter} and
-\cs{ltjgetparameter}.
+The second argument \texttt{preonly} means that the insertion of
+\Param{xkanjiskip} is allowed before this character, but not after.
+the other possible values are \texttt{postonly}, \texttt{allow}, and \texttt{inhibit}.
%
%<*ja>
-\LuaTeX-jaã«ã¯å¤ãã®ãã©ã¡ã¼ã¿ãåå¨ããï¼ããã¦\LuaTeX ã®ä»æ§ã®ããã«ï¼
-ãã®å¤ãã¯\TeX ã®ã¬ã¸ã¹ã¿ã«ã§ã¯ãªãï¼\LuaTeX-jaç¬èªã®æ¹æ³ã§ä¿æããã¦ããï¼
-ãããã®ãã©ã¡ã¼ã¿ãè¨å®ã»åå¾ããããã«ã¯ \cs{ltjsetparameter} 㨠\cs{ltjgetparameter} ã
-ç¨ããï¼
+2ã¤ç®ã®å¼æ°ã® \texttt{preonly}ã¯ã\Param{xkanjiskip}ã®æ¿å
¥ã¯ãã®æåã®
+åã§ã®ã¿è¨±ããï¼å¾ã§ã¯è¨±ããªãããã¨ãæå³ããï¼ä»ã«æå®å¯è½ãªå¤ã¯
+\texttt{postonly}, \texttt{allow}, \texttt{inhibit}ã§ããï¼
%
-%\subsection{Range of \textbf{JAchar}s}
-%\subsection{\textbf{JAchar}ã®ç¯å²}
-\label{ssec-setrange}
-
%<*en>
-\LuaTeX-ja divides the Unicode codespace \texttt{U+0080}--\texttt{U+10FFFF}
-into \emph{character ranges},
-numbered 1 to 217. The grouping can be (globally) customized by \cs{ltjdefcharrange}.
-The next line adds whole characters in Supplementary Ideographic Plane
-and the character ``æ¼¢'' to the character range~100.
+\Param{jaxspmode} and \Param{alxspmode} use a same table to store the parameters
+on the current version. Therefore, line~1 in the code above can be rewritten
+as follows:
%
%<*ja>
-\LuaTeX-jaã¯ï¼Unicodeã® \texttt{U+0080}--\texttt{U+10FFFF} ã®ç©ºéã
-1çªãã217çªã¾ã§ã®\emph{æåç¯å²}ã«åå²ãã¦ããï¼
-åºåã㯠\cs{ltjdefcharrange} ãç¨ãããã¨ã§ï¼ã°ãã¼ãã«ã«ï¼å¤æ´ãããã¨ãã§ãï¼
-ä¾ãã°ï¼æ¬¡ã¯è¿½å æ¼¢åé¢(SIP)ã«ããå
¨ã¦ã®æåã¨ãæ¼¢ããã100çªã®æåç¯å²ãã«è¿½å ããï¼
+ãªãï¼ç¾è¡ã®
+ä»æ§ã§ã¯ï¼\Param{jaxspmode}, \Param{alxspmode}ã¯ãã¼ãã«ãå
±æãã¦ããï¼
+ä¸ã®ã³ã¼ãã®1è¡ç®ã次ã®ããã«å¤ãã¦ãåããã¨ã«ãªãï¼
%
\begin{lstlisting}
-\ltjdefcharrange{100}{"20000-"2FFFF,`æ¼¢}
+\ltjsetparameter{alxspmode={`ã,preonly}, jaxspmode={`\!,postonly}}
\end{lstlisting}
-
%<*en>
-A character can belong to only one character range.
-For example, whole SIP belong to the range~4 in the default setting of \LuaTeX-ja,
-and if you execute the above line, then SIP will belong to the range~100 and be
-removed from the range~4.
+One can use also numbers to specify these two parameters (see Subsection~\ref{ssec-param}).
%
%<*ja>
-åæåã¯ãã ä¸ã¤ã®æåç¯å²ã«æå±ãããã¨ãã§ããï¼
-ä¾ãã°ï¼SIPå
ã®æåã¯å
¨ã¦\LuaTeX-jaã®ããã©ã«ãã§ã¯4çªã®æåç¯å²ã«
-å±ãã¦ãããï¼ä¸è¨ã®æå®ãè¡ãã°SIPå
ã®æåã¯100çªã«å±ãããã«ãªãï¼4çªããã¯é¤ãããï¼
+ã¾ãï¼ããã2ãã©ã¡ã¼ã¿ã«ã¯æ°å¤ã§å¤ãæå®ãããã¨ãã§ããï¼\ref{ssec-param}ç¯ãåç
§ï¼ï¼
%
%<*en>
-The distinction between \textbf{ALchar} and \textbf{JAchar} is performed by character ranges.
-This can be edited by setting the \textsf{jacharrange} parameter.
-For example, the code below is just the default setting of \LuaTeX-ja, and
-it sets
-\begin{itemize}
- \item a character which belongs character ranges 1,~4, 5, and~8 is \textbf{ALchar},
- \item a character which belongs character ranges 2,~3, 6, and~7 is \textbf{JAchar}.
-\end{itemize}
+If you want to enable/disable all insertions of \Param{kanjiskip} and
+\Param{xkanjiskip}, set \Param{autospacing} and \Param{autoxspacing}
+parameters to \texttt{true}/\texttt{false}, respectively.
%
%<*ja>
-\textbf{ALchar}ã¨\textbf{JAchar}ã®åºå¥ã¯æåç¯å²ãã¨ã«è¡ãããï¼
-ããã¯\textsf{jacharrange}ãã©ã¡ã¼ã¿ã«ãã£ã¦ç·¨éã§ããï¼
-ä¾ãã°ï¼ä»¥ä¸ã¯\LuaTeX-jaã®åæè¨å®ã§ããï¼æ¬¡ã®å
容ãè¨å®ãã¦ããï¼
-\begin{itemize}
- \item 1çªï¼4çªï¼5çªï¼8çªã®æåç¯å²ã«å±ããæåã¯\textbf{ALchar}ï¼
- \item 2çªï¼3çªï¼6çªï¼7çªã®æåç¯å²ã«å±ããæåã¯\textbf{JAchar}ï¼
-\end{itemize}
+ããå
¨ã¦ã®\Param{kanjiskip}ã¨\Param{xkanjiskip}ã®æ¿å
¥ãæå¹åï¼ç¡å¹å
+ããããã°ï¼ãããã\Param{autospacing}ã¨\Param{autoxspacing}ã
+\texttt{true}/\texttt{false}ã«è¨å®ããã°ããï¼
%
-\begin{lstlisting}
-\ltjsetparameter{jacharrange={-1, +2, +3, -4, -5, +6, +7, -8}}
-\end{lstlisting}
+
+%\subsection{Shifting the baseline}
+%\subsection{ãã¼ã¹ã©ã¤ã³ã®ç§»å}
%<*en>
-The argument to \textsf{jacharrange} parameter is a list of non-zero integer.
-Negative integer $-n$ in the list means that ``each character in the range~$n$ is an
-\textbf{ALchar}'',
-and positive integer $+n$ means that ``\dots\ is a \textbf{JAchar}''.
+To make a match between a Japanese font and an alphabetic font, sometimes
+shifting of the baseline of one of the pair is needed. In \pTeX, this is achieved
+by setting \cs{ybaselineshift} (or \cs{tbaselineshift}) to a non-zero length (the
+baseline of \textbf{ALchar} is shifted below). However, for documents
+whose main language is not Japanese, it is good to shift the baseline of
+Japanese fonts, but not that of alphabetic fonts.
+Because of this, \LuaTeX-ja can independently set the shifting amount
+of the baseline of alphabetic fonts and that of Japanese fonts.
+\begin{center}
+ \small
+\begin{tabular}{>{\bfseries}lcc}
+\toprule
+&\bfseries Horizontal writing (\emph{yoko} direction) etc.
+&\bfseries Vertical writing(\emph{tate} direction)\\
+\midrule
+Alphabetic fonts&\Param{yalbaselineshift}
+ parameter&\Param{talbaselineshift} parameter\\
+Japanese fonts&\Param{yjabaselineshift}
+ parameter&\Param{tjabaselineshift} parameter\\
+\bottomrule
+\end{tabular}
+\end{center}
%
%<*ja>
-\textsf{jacharrange}ãã©ã¡ã¼ã¿ã®å¼æ°ã¯éé¶ã®æ´æ°ã®ãªã¹ãã§ããï¼
-ãªã¹ãä¸ã®è² ã®æ´æ°$-n$ã¯ãæåç¯å²$n$ã«å±ããæåã¯\textbf{ALchar}ã¨ãã¦
-æ±ãããã¨ãæå³ãï¼æ£ã®æ´æ°$+n$ã¯ã\textbf{JAchar}ã¨ãã¦æ±ãããã¨ãæå³ããï¼
+åæãã©ã³ãã¨æ¬§æãã©ã³ããåãããããã«ã¯ï¼æã
ã©ã¡ããã®ãã¼ã¹ã©ã¤ã³ã®ç§»åã
+å¿
è¦ã«ãªãï¼\pTeX ã§ã¯ãã㯠\cs{ybaselineshift}ï¼ã¾ãã¯\cs{tbaselineshift}ï¼ãè¨å®ãããã¨ã§
+ãªããã¦ããï¼\textbf{ALchar}ã®ãã¼ã¹ã©ã¤ã³ããã®åã ãä¸ããï¼ï¼ãããï¼æ¥æ¬èªã主ã§ã¯ãªã
+ææ¸ã«å¯¾ãã¦ã¯ï¼æ¬§æãã©ã³ãã§ã¯ãªãåæãã©ã³ãã®ãã¼ã¹ã©ã¤ã³ã移åããæ¹ãããï¼
+ãã®ããï¼\LuaTeX-jaã§ã¯æ¬§æãã©ã³ãã®ãã¼ã¹ã©ã¤ã³ã®ã·ããé
+ã¨åæãã©ã³ãã®ãã¼ã¹ã©ã¤ã³ã®ã·ããéãç¬ç«ã«è¨å®ã§ããããã«ãªã£ã¦ããï¼
+\begin{center}
+ \small
+\begin{tabular}{>{\bfseries}lcc}
+\toprule
+&\bfseries 横çµãªã©&\bfseries 縦çµ\\
+\midrule
+欧æãã©ã³ãã®ã·ããé&\Param{yalbaselineshift}
+ parameter&\Param{talbaselineshift} parameter\\
+åæãã©ã³ãã®ã·ããé&\Param{yjabaselineshift}
+ parameter&\Param{tjabaselineshift} parameter\\
+\bottomrule
+\end{tabular}
+\end{center}
%
%<*en>
-Note that characters \texttt{U+0000}--\texttt{U+007F} are always treated as an
-\textbf{ALchar} (this cannot be customized).
+Here the horizontal line in the below example is the baseline of a line.
%
%<*ja>
-ãªãï¼\texttt{U+0000}--\texttt{U+007F} ã¯å¸¸ã«\textbf{ALchar}ã¨ãã¦æ±ãããï¼å©ç¨è
ãå¤æ´ã
-ããã¨ã¯åºæ¥ãªãï¼ï¼
+ä¸ã®ä¾ã«ããã¦å¼ããã¦ããæ°´å¹³ç·ããã¼ã¹ã©ã¤ã³ã§ããï¼
%
+\begin{LTXexample}
+\vrule width 150pt height 0.2pt depth 0.2pt \hskip-120pt
+\ltjsetparameter{yjabaselineshift=0pt, yalbaselineshift=0pt}abcããã
+\ltjsetparameter{yjabaselineshift=5pt, yalbaselineshift=2pt}abcããã
+\end{LTXexample}
%<*en>
-\paragraph{Default character ranges}
-\LuaTeX-ja predefines eight character ranges for convenience. They are
-determined from the following data:
-%
+There is an interesting side-effect: characters in different size can be
+vertically aligned center in a line, by setting two parameters appropriately.
+The following is an example (beware the value is not well tuned):
+%
%<*ja>
-\paragraph{æåç¯å²ã®åæå¤}
-\LuaTeX-jaã§ã¯8ã¤ã®æåç¯å²ãäºãå®ç¾©ãã¦ããï¼
-ãããã¯ä»¥ä¸ã®ãã¼ã¿ã«åºã¥ãã¦æ±ºå®ãã¦ããï¼
+ãã®æ©è½ã«ã¯é¢ç½ã使ãæ¹ãããï¼2ã¤ã®ãã©ã¡ã¼ã¿ãé©åã«è¨å®ãããã¨ã§ï¼ãµã¤ãºã®
+ç°ãªãæåãä¸å¿ç·ã«æãããã¨ãã§ããï¼
+以ä¸ã¯ä¸ã¤ã®ä¾ã§ããï¼å¤ã¯ãã¾ã調æ´ããã¦ããªããã¨ã«æ³¨æï¼ï¼
%
+\begin{LTXexample}[width=0.4\textwidth]
+\vrule width 150pt height4.417pt depth-4.217pt%
+\kern-150pt
+\large xyzæ¼¢å
+{\scriptsize
+ \ltjsetparameter{yjabaselineshift=-1.757pt,
+ yalbaselineshift=-1.757pt}
+ æ¼¢åxyzããã
+}ãããabc
+\end{LTXexample}
+
+%<*en>
+Note that setting positive \Param{yalbaselineshift}~or~\Param{talbaselineshift}
+parameters does not increase the depth of one-letter \emph{syllable} $p$ of \textbf{Alchar}, if
+its left-protrusion~(\cs{lpcode}) and right-protrusion~(\cs{rpcode}) are both non-zero.
+This is because
\begin{itemize}
-%\item Blocks in Unicode~6.0.
-%\item Unicode~6.0ã®ãããã¯ï¼
-%\item The \texttt{Adobe-Japan1-UCS2} mapping between a CID Adobe-Japan1-6 and Unicode.
-%\item Adobe-Japan1-6ã®CIDã¨Unicodeã®éã®å¯¾å¿è¡¨\texttt{Adobe-Japan1-UCS2}ï¼
-%\item The \Pkg{PXbase} bundle for \upTeX\ by Takayuki Yato.
-%\item å
«ç»å´ä¹æ°ã«ãã\upTeX ç¨ã®\Pkg{PXbase}ãã³ãã«ï¼
+\item These two parameters are implemented by setting \texttt{yoffset} field of a
+glyph node, and this does not increase the depth of the glyph.
+\item To cope with the above situation, \LuaTeX-ja automatically supplies
+a rule in every syllable.
+\item However, we cannot use this ``supplying a rule'' method if a syllable comprises just
+ one letter whose \cs{lpcode}~and~\cs{rpcode} are both non-zero.
\end{itemize}
-%<*en>
-Now we describe these eight ranges. The superscript ``J'' or ``A'' after the
-number shows whether each character in the range is treated as
-\textbf{JAchar}s or not by default. These settings are similar to the
-\texttt{prefercjk} settings defined in \texttt{PXbase} bundle.
-Any characters equal to or above \texttt{U+0080} which does not belong to
-these eight ranges belongs to the character range~217.
+This problem does not apply for \Param{yjabaselineshift}~nor~\Param{tjabaselineshift},
+becuse a \emph{JAchar} is encapsulated by a horizontal box if needed.
%
%<*ja>
-以ä¸ã§ã¯ããã8ã¤ã®æåç¯å²ã«ã¤ãã¦è¨è¿°ããï¼æ·»åã®ã¢ã«ãã¡ããããJããAã
-ã¯ï¼ãã®æåç¯å²å
ã®æåã\textbf{JAchar}ã\textbf{ALchar}ãã表ãã¦ããï¼ãããã®åæè¨å®ã¯
-\texttt{PXbase}ãã³ãã«ã§å®ç¾©ããã¦ãã\texttt{prefercjk}ã¨é¡ä¼¼ã®ãã®ã§ãããï¼
-8ããããã©ã³ã使ç¨æã®ãã©ãã«ãé²ãããã« \texttt{U+0080}--\texttt{U+00FF} ã®æåã¯å
¨é¨
-\textbf{ALchar}ã¨ãã¦ããï¼
-ãªãï¼\texttt{U+0080} 以éã§ããã8ã¤ã®æåç¯å²ã«å±ããªãæåã¯ï¼217çªã®æåç¯å²ã«å±ãããã¨ã«ãªã£ã¦ããï¼
+ãªãï¼ä»¥ä¸ã®å ´åã«ã¯1æåã®\textbf{ALchar}ãããªããé³ç¯ãã®æ·±ãã¯å¢å ããªããã¨ã«æ³¨æï¼
+\begin{itemize}
+ \item \Param{yalbaselineshift},~\Param{talbaselineshift}ãã©ã¡ã¼ã¿ãæ£ã«ãªã£ã¦ããï¼
+ \item ãé³ç¯ããæ§æããå¯ä¸ã®æå$p$ã®
+å·¦ä½ç½ã¸ã®çªåºé(\cs{lpcode})ï¼å³ä½ç½ã¸ã®çªåºé(\cs{rpcode})ãã©ã¡ããéé¶ã§ããï¼
+\end{itemize}
+\emph{JAchar}ã¯å¿
è¦ã«å¿ãã¦1æåãã¤ããã¯ã¹ã«ã«ãã»ã«åãããããï¼
+\Param{yjabaselineshift},~\Param{tjabaselineshift}ãã©ã¡ã¼ã¿ã«ã¤ãã¦ã¯ãã®ãããªåé¡ã¯èµ·ãããªãï¼
%
-\begin{description}
-%<*en>
-\item[Range~8${}^{\text{A}}$] The intersection of the upper half of ISO~8859-1
- (Latin-1 Supplement) and JIS~X~0208 (a basic character set for Japanese). This character range
- consists of the following characters:
-%
%<*ja>
-\item[ç¯å²8${}^{\text{A}}$] ISO~8859-1ã®ä¸ä½é åï¼ã©ãã³1è£å©ï¼ã¨
- JIS~X~0208ã®å
±éé¨åï¼ãã®æåç¯å²ã¯
- 以ä¸ã®æåã§æ§æãããï¼
-%
-\begin{multicols}{2}
+\paragraph{æ°å¼ã«ãããæåï¼\pTeX ã¨ã®éã}
+\textbf{ALchar}ã®ãã¼ã¹ã©ã¤ã³ãè£æ£ãã\Param{yalbaselineshift}, \Param{talbaselineshift}ãã©ã¡ã¼ã¿ã¯
+ã»ã¼\pTeX ã«ããã \cs{ybaselineshift}, \cs{tbaselineshift} ã«å¯¾å¿ãã¦ãããã®ã§ãããï¼
+æ°å¼ä¸ã®æåã¯ç°ãªã£ã¦ããã®ã§æ³¨æãå¿
è¦ã§ããï¼
+ä¾ãã°ï¼\autoref{tab:math_bsa}ã®ããã«ï¼æ°å¼ä¸ã«æ示çã«ç¾ãã \cs{hbox},~\cs{vbox} ã¯ï¼æ¨ªçµã«ããã¦
\begin{itemize}
-\def\ch#1#2{\item \char"#1\ (\texttt{U+00#1}, #2)}%"
-\ch{A7}{Section Sign}
-\ch{A8}{Diaeresis}
-\ch{B0}{Degree sign}
-\ch{B1}{Plus-minus sign}
-\ch{B4}{Spacing acute}
-\ch{B6}{Paragraph sign}
-\ch{D7}{Multiplication sign}
-\ch{F7}{Division Sign}
+ \item 2015年以åã®\pTeX ã§ã¯ï¼ããã¯ã¹å
¨ä½ã \cs{ybaselineshift} ã ã¨ã·ãããããã®ã§ï¼
+ \autoref{tab:math_bsa}ä¸ã®``ã''ã®ããã«ï¼ããã¯ã¹ä¸ã®åææåã¯
+ \ \cs{ybaselineshift} ã ãã·ããããï¼ä¸æ¹ï¼``for all''ã®ããã«ï¼
+ ããã¯ã¹å
ã®æ¬§ææåã¯2éã«ã·ããããããã¨ã«ãªãï¼
+ \item ä¸æ¹ï¼\LuaTeX-jaã§ã¯ãã®ãããªãã¨ã¯ããããï¼
+ æ°å¼ä¸ã«æ示çã«ç¾ãã \cs{hbox},~\cs{vbox} ã¯ã·ããããªãï¼ãã®ããï¼
+ \autoref{tab:math_bsa}ä¸ã®``ã''ã``for all''ãï¼ããããæ¬æä¸ã«
+ æ¸ãããã¨ãã¨åãä¸ä¸ä½ç½®ã«çµã¾ããï¼
+
+ ãªãï¼\TeX~Live~2016以éã®\pTeX ã§ã¯æ¹ä¿®ããªããï¼\LuaTeX-jaã¨
+ è¿ãæåã«ãªãããã«ãã¦ãããï¼æ°å¼ä¸ã«ç´ã«æ¸ããã``ã''ã®ãã¼ã¹ã©ã¤ã³ã«ã¤ãã¦ã¯
+ ã¾ã éããè¦ãããï¼
\end{itemize}
-\end{multicols}
+
+ãªãï¼ãã¼ã¸ã§ã³20170401.0以éã®\LuaTeX-jaã§ã¯ï¼\cs{vcenter} ã«ããããã¯ã¹ã«ã¯
+å
¨ä½ã\Param{yalbaselineshift}, \Param{talbaselineshift} ãã©ã¡ã¼ã¿ãåæ ãããããã«ãã¦ããï¼
+ãã®æ¹ãçµæãèªç¶ã§ãããã¨ã«ããå¤æ´ãªã®ã ãï¼çµæçã«\cs{vcenter} ã«ã¤ãã¦ã¯\pTeX ã¨åãæåã¨ãªã£ãï¼
+
+\begin{table}
+\small\centering
+\caption{æ°å¼é¢ä¿ã®ãã¼ã¹ã©ã¤ã³è£æ£($\Param{yalbaselineshift}=10\,\textrm{pt}$)}
+\label{tab:math_bsa}
+\newdimen\origbaselineskip
+\origbaselineskip=\baselineskip
+\begin{tabular}{lp{30\zw}}
+\toprule
+\emph{å
¥å}&\vspace*{\dimexpr-\origbaselineskip-\smallskipamount}
+\begin{lstlisting}
+æ°å¼abc: $ãa\hbox{ã}$, $\int_0^x t\,dt=x^2/2$,
+$\Phi\vdash F(x)\ \hbox{for all}\ x\in A$
+\end{lstlisting}\\
+\noalign{\vskip-\origbaselineskip}
+\midrule
+\emph{\pTeX~(--2015)}&
+{\ltjsetparameter{yalbaselineshift=10pt}%
+æ°å¼abc: $\lower10pt\hbox{ã}a\lower10pt\hbox{ã}$, $\int_0^x t\,dt=x^2/2$,
+$\Phi\vdash F(x)\ \lower10pt\hbox{for all}\ x\in A$
+\par}\\\noalign{\vskip-\origbaselineskip}\midrule
+\emph{\pTeX~(2016--)}&
+{\ltjsetparameter{yalbaselineshift=10pt}%
+æ°å¼abc: $\lower10pt\hbox{ã}a\hbox{ã}$, $\int_0^x t\,dt=x^2/2$,
+$\Phi\vdash F(x)\ \hbox{for all}\ x\in A$
+\par}\\\noalign{\vskip-\origbaselineskip}\midrule
+\emph{\LuaTeX-ja}&
+{\ltjsetparameter{yalbaselineshift=10pt}%
+æ°å¼abc: $ãa\hbox{ã}$, $\int_0^x t\,dt=x^2/2$,
+$\Phi\vdash F(x)\ \hbox{for all}\ x\in A$
+\par}\\
+\noalign{\vskip-\origbaselineskip}
+\bottomrule
+\end{tabular}
+\end{table}
+%
%<*en>
-\item[Range~1${}^{\text{A}}$] Latin characters that some of them are included in Adobe-Japan1-6.
-This range consists of the following Unicode ranges, \emph{except characters in the range~8 above}:
+\subsection{\emph{kinsoku} parameters and OpenType features}
+Among parameters which related to Japanese word-wrapping process (\emph{kinsoku shori}),
+\begin{quote}
+ \Param{jaxspmode},~\Param{alxspmode}, \Param{prebreakpenalty},
+ \Param{postbreakpenalty}~and~\Param{kcatcode}
+\end{quote}
+are stored by each character codes.
+
+OpenType font features are ignored in these parameters.
+For example, a fullwidth katakana ``ã¢'' on line~10 in the below input is replaced to
+its halfwidth variant ``ï½±'', by \verb+hwid+ feature.
+However, the penalty inserted after it is 10 which is the \Param{postbreakpenalty} of
+``ã¢'', not 20.
%
%<*ja>
-\item[ç¯å²1${}^{\text{A}}$] ã©ãã³æåã®ãã¡ï¼Adobe-Japan1-6ã¨ã®å
±éé¨åããããã®ï¼
- ãã®ç¯å²ã¯ä»¥ä¸ã®Unicodeã®ãããã¯ã®ãã¡
- \emph{ç¯å²8ãé¤ãã}é¨åã§æ§æããã¦ããï¼
+\newpage
+\subsection{ç¦åå¦çé¢é£ãã©ã¡ã¼ã¿ã¨OpenTypeã®font feature}
+ç¦åå¦çã \Param{kanjiskip}, \Param{xkanjiskip} ã®æ¿å
¥ã«é¢é£ãããã©ã¡ã¼ã¿ã®ãã¡
+\begin{quote}
+ \Param{jaxspmode},~\Param{alxspmode}, \Param{prebreakpenalty},
+ \Param{postbreakpenalty}, \Param{kcatcode}
+\end{quote}
+ã¯ï¼æåã³ã¼ããã¨ã«è¨å®ããéã§ããï¼
+
+\Pkg{fontspec}ããã±ã¼ã¸ã使ãï¼\ref{ssec-fontspec}ç¯ï¼å ´åãªã©ï¼
+å種ã®OpenType featureãé©ç¨ãããã¨ãããã¨æããï¼å段è½ã«è¿°ã¹ããã©ã¡ã¼ã¿é¡ã¯ï¼
+\emph{OpenType featureã®é©ç¨åã®æåã³ã¼ãã«ãã£ã¦é©ç¨ãããï¼}
+ä¾ãã°ï¼ä»¥ä¸ã®ä¾ã«ããã¦10è¡ç®ã®ãã¢ãã¯ï¼\verb+hwid+ featureã®é©ç¨ã«ããåè§ã«ã¿ã«ãã®ãï½±ã
+ã«ç½®ãæããï¼ãããï¼ãã®ç´å¾ã«æ¿å
¥ããã \Param{postbreakpenalty}ã¯ï¼ç½®æåã®ãã¢ãã«å¯¾ããå¤10ã§ããï¼
%
-\begin{multicols}{2}
-\begin{itemize}
-\item \texttt{U+0080}--\texttt{U+00FF}: Latin-1 Supplement
-\item \texttt{U+0100}--\texttt{U+017F}: Latin Extended-A
-\item \texttt{U+0180}--\texttt{U+024F}: Latin Extended-B
-\item \texttt{U+0250}--\texttt{U+02AF}: IPA Extensions
-\item \texttt{U+02B0}--\texttt{U+02FF}: Spacing Modifier Letters
-%\par\
-\item \texttt{U+0300}--\texttt{U+036F}: \\*\null\hfill Combining Diacritical Marks
-\item \texttt{U+1E00}--\texttt{U+1EFF}: \\*\null\hfill Latin Extended Additional
-%\par\
-\end{itemize}
-\end{multicols}
-%<*en>
-\item[Range~2${}^{\text{\kern.1emJ}}$] Greek and Cyrillic letters. JIS~X~0208 (hence most of Japanese
- fonts) has some of these characters.
-%
+
+\begin{LTXexample}[width=0.2\textwidth]
+\ltjsetparameter{postbreakpenalty={`ã¢, 10}}
+\ltjsetparameter{postbreakpenalty={`ï½±, 20}}
+
+\newcommand\showpostpena[1]{%
+ \leavevmode\setbox0=\hbox{#1\hbox{}}%
+ \unhbox0\setbox0=\lastbox\the\lastpenalty}
+
+\showpostpena{ã¢},
+\showpostpena{ï½±},
+{\addjfontfeatures{CharacterWidth=Half}\showpostpena{ã¢}}
+\end{LTXexample}
+
+\clearpage
+%\part{Reference}
+%\part{ãªãã¡ã¬ã³ã¹}
+\label{part-ref}
+\suppressfloats[t]
%<*ja>
-\item[ç¯å²2${}^{\text{\kern.1emJ}}$] ã®ãªã·ã£æåã¨ããªã«æåï¼JIS~X~0208ï¼ãããã£ã¦ã»ã¨ãã©ã®
- åæãã©ã³ãï¼ã«ã¯ï¼ãããã®æåã®ä¸é¨ãå«ã¾ãã¦ããï¼
+\section{\LuaTeX-jaã«ããã \cs{catcode}}
+\label{sec-catcode}
+\subsection{äºåç¥èï¼\pTeX ã¨\upTeX ã«ããã \cs{kcatcode}}
+\pTeXï¼\upTeX ã«ããã¦ã¯ï¼åææåãå¶å¾¡ç¶´å
ã§å©ç¨ã§ãããã©ãã
+㯠\cs{kcatcode} ã®å¤ã«ãã£ã¦æ±ºå®ãããã®ã§ãã£ãï¼
+詳細ã¯\autoref{tab:kcat}ãåç
§ããããï¼
%
-\begin{multicols}{2}
-\begin{itemize}
-\item \texttt{U+0370}--\texttt{U+03FF}: Greek and Coptic
-\item \texttt{U+0400}--\texttt{U+04FF}: Cyrillic
-\item \texttt{U+1F00}--\texttt{U+1FFF}: Greek Extended
-\\\
-\end{itemize}
-\end{multicols}
%<*en>
-\item[Range~3${}^{\text{\kern.1emJ}}$] Punctuations and Miscellaneous symbols. The block list is
- indicated in Table~\ref{table-rng3}.
+\section{\cs{catcode} in \LuaTeX-ja}
+\label{sec-catcode}
+\subsection{Preliminaries: \cs{kcatcode} in \pTeX\ and \upTeX}
+In \pTeX~and~\upTeX, the value of \cs{kcatcode} determines
+whether a Japanese character can be used in a control word.
+For the detail, see \autoref{tab:kcat}.
+%
+
+\begin{table}[t]
+\small
+\caption{\cs{kcatcode} in \upTeX}
+\label{tab:kcat}
+%\medskip
+
+\noindent\hfill
+\begin{tabular}{ccccc}
+\toprule
+\bfseries \cs{kcatcode}&
+%<*en>
+\bfseries meaning&
+\bfseries control word&
+\bfseries widow penalty&
+\bfseries linebreak\\
%
%<*ja>
-\item[ç¯å²3${}^{\text{\kern.1emJ}}$] å¥èªç¹ã¨è¨å·é¡ï¼ãããã¯ã®ãªã¹ãã¯è¡¨\ref{table-rng3}%
- ã«ç¤ºãã¦ããï¼
+\bfseries æå³&
+\bfseries å¶å¾¡ç¶´ä¸ã«ä½¿ç¨&
+\bfseries æåã¦ã£ãã¦å¦ç&
+\bfseries ç´å¾ã§ã®æ¹è¡\\
%
-\begin{table}[!tb]
-%\caption{Unicode blocks in predefined character range~3.}\medskip
-%\caption{æåç¯å²3ã«æå®ããã¦ããUnicodeãããã¯ï¼}
-\label{table-rng3}
-\catcode`\"=13\def"#1#2#3#4{\texttt{U+#1#2#3#4}}%"
-\centering\small
-\begin{tabular}{llll}
-"2000--"206F&General Punctuation&
-"2070--"209F&Superscripts and Subscripts\\
-"20A0--"20CF&Currency Symbols&
-"20D0--"20FF&Comb.\ Diacritical Marks for Symbols\\
-"2100--"214F&Letterlike Symbols&
-"2150--"218F&Number Forms\\
-"2190--"21FF&Arrows&
-"2200--"22FF&Mathematical Operators\\
-"2300--"23FF&Miscellaneous Technical&
-"2400--"243F&Control Pictures\\
-"2500--"257F&Box Drawing&
-"2580--"259F&Block Elements\\
-"25A0--"25FF&Geometric Shapes&
-"2600--"26FF&Miscellaneous Symbols\\
-"2700--"27BF&Dingbats&
-"2900--"297F&Supplemental Arrows-B\\
-"2980--"29FF&Misc.\ Mathematical Symbols-B&
-"2B00--"2BFF&Miscellaneous Symbols and Arrows
-\end{tabular}
-\end{table}
-%<*en>
-\item[Range~4${}^{\text{A}}$] Characters usually not in Japanese fonts. This range consists
- of almost all Unicode blocks which are not in other
- predefined ranges. Hence, instead of showing the block list,
- we put the definition of this range itself:
-%
-%<*ja>
-\item[ç¯å²4${}^{\text{A}}$] é常åæãã©ã³ãã«ã¯å«ã¾ãã¦ããªãæåï¼
- ãã®ç¯å²ã¯ä»ã®ç¯å²ã«ãªãã»ã¨ãã©å
¨ã¦ã®Unicodeãããã¯
- ã§æ§æããã¦ããï¼ãããã£ã¦ï¼ãããã¯ã®ãªã¹ãã示ã
- 代ããã«ï¼ç¯å²ã®å®ç¾©ãã®ãã®ã示ãï¼
-%
-\begin{lstlisting}
-\ltjdefcharrange{4}{%
- "500-"10FF, "1200-"1DFF, "2440-"245F, "27C0-"28FF, "2A00-"2AFF,
- "2C00-"2E7F, "4DC0-"4DFF, "A4D0-"A82F, "A840-"ABFF, "FB00-"FE0F,
- "FE20-"FE2F, "FE70-"FEFF, "10000-"1FFFF, "E000-"F8FF} % non-Japanese
-\end{lstlisting}
-%\item[Range~5${}^{\text{A}}$] Surrogates and Supplementary Private Use Areas.
-%\item[ç¯å²5${}^{\text{A}}$] 代ç¨ç¬¦å·ã¨è£å©ç§ç¨é åï¼
-%\item[Range~6${}^{\text{\kern.1emJ}}$] Characters used in Japanese. The block list is indicated in Table~\ref{table-rng6}.
-%\item[ç¯å²6${}^{\text{\kern.1emJ}}$] æ¥æ¬èªã§ç¨ããããæåï¼ãããã¯ã®ãªã¹ãã¯è¡¨\ref{table-rng6}ã«ç¤ºãï¼
-\begin{table}[!tb]
-%\caption{Unicode blocks in predefined character range~6.}\medskip
-%\caption{æåç¯å²6ã«æå®ããã¦ããUnicodeãããã¯ï¼}
-\label{table-rng6}
-\catcode`\"=13\def"#1#2#3#4{\texttt{U+#1#2#3#4}}%"
-\centering\small
-\begin{tabular}{llll}
-"2460--"24FF&Enclosed Alphanumerics&
-"2E80--"2EFF&CJK Radicals Supplement\\
-"3000--"303F&CJK Symbols and Punctuation&
-"3040--"309F&Hiragana\\
-"30A0--"30FF&Katakana&
-"3190--"319F&Kanbun\\
-"31F0--"31FF&Katakana Phonetic Extensions&
-"3200--"32FF&Enclosed CJK Letters and Months\\
-"3300--"33FF&CJK Compatibility&
-"3400--"4DBF&CJK Unified Ideographs Extension A\\
-"4E00--"9FFF&CJK Unified Ideographs&
-"F900--"FAFF&CJK Compatibility Ideographs\\
-"FE10--"FE1F&Vertical Forms&
-"FE30--"FE4F&CJK Compatibility Forms\\
-"FE50--"FE6F&Small Form Variants&
-"{20}000--"{2F}FFF&(Supplementary Ideographic Plane)\\
-"{E0}100--"{E0}1EF&Variation Selectors Supplement
-\end{tabular}
-\end{table}
-%<*en>
-\item[Range~7${}^{\text{\kern.1emJ}}$] Characters used in CJK languages, but not included in Adobe-Japan1-6.
-The block list is indicated in Table~\ref{table-rng7}.
-%
-%<*ja>
-\item[ç¯å²7${}^{\text{\kern.1emJ}}$] CJKè¨èªã§ç¨ããããæåã®ãã¡ï¼Adobe-Japan1-6ã«
- å«ã¾ãã¦ããªããã®ï¼
- ãããã¯ã®ãªã¹ãã¯è¡¨\ref{table-rng7}ã«ç¤ºãï¼
-%
-\begin{table}[!tb]
-%\caption{Unicode blocks in predefined character range~7.}\medskip
-%\caption{æåç¯å²7ã«æå®ããã¦ããUnicodeãããã¯ï¼}
-\label{table-rng7}
-\catcode`\"=13\def"#1#2#3#4{\texttt{U+#1#2#3#4}}%"
-\centering\small
-\begin{tabular}{llll}
-"1100--"11FF&Hangul Jamo&
-"2F00--"2FDF&Kangxi Radicals\\
-"2FF0--"2FFF&Ideographic Description Characters&
-"3100--"312F&Bopomofo\\
-"3130--"318F&Hangul Compatibility Jamo&
-"31A0--"31BF&Bopomofo Extended\\
-"31C0--"31EF&CJK Strokes&
-"A000--"A48F&Yi Syllables\\
-"A490--"A4CF&Yi Radicals&
-"A830--"A83F&Common Indic Number Forms\\
-"AC00--"D7AF&Hangul Syllables&
-"D7B0--"D7FF&Hangul Jamo Extended-B
-\end{tabular}
-\end{table}
-\end{description}
-
-%<*en>
-\paragraph{Notes on \texttt{U+0080}--\texttt{U+00FF}}
-You should treat characters in \\texttt{U+0080}--\texttt{U+00FF} as \textbf{ALchar},
-when you use traditional 8-bit fonts, such as the \Pkg{textcomp} package or the
-\Pkg{marvosym} package.
-
-For example, the codepoint \cs{textparagraph} which is provided by the \Pkg{textcomp}
-package is 182. This codepoint corresponds \P\ (\text{U+00B6}) in Unicode.
-Similarly, \cs{Frowny} which is provided by the \Pkg{marvosym} package has
-the same codepoint as \S\ (\text{U+00A7}).
-Hence, as previous versions of \LuaTeX-ja, if these characters are treated as
-\text{JAchar}s, then \cs{textparagraph} produces ``ltjjachar`¶'' (in a Japanese font),
-and \cs{Frowny} produces ``\ltjjachar`§'' (in a Japanese font).
+\midrule
+15&non-cjk&\multicolumn{3}{c}{(treated as usual \LaTeX)}\\
+16&kanji&Y&Y&ignored\\
+17&kana&Y&Y&ignored\\
+18&other&N&N&ignored\\
+19&hangul&Y&Y&space\\
+\bottomrule
+\end{tabular}\hfill\null
-To avoid such situations, the default setting of \LuaTeX-ja is changed in this release
-so that all characters \texttt{U+0080}--\texttt{U+00FF} are treated as \textbf{ALchar}.
+\medskip
-If you want to output a character as \textbf{ALchar} and \textbf{JAchar} regardless the range
-setting, you can use \cs{ltjalchar} and \cs{ltjjachar} respectively, as the following example.
-\begin{LTXexample}[width=0.3\textwidth]
-\gtfamily\large % default, ALchar, JAchar
-¶, \ltjalchar`¶, \ltjjachar`¶\\ % default: ALchar
-α, \ltjalchar`α, \ltjjachar`α % default: JAchar
-\end{LTXexample}
-%
%<*ja>
-\paragraph{\texttt{U+0080}--\texttt{U+00FF}ã«ã¤ãã¦ã®æ³¨æ}
-\LuaTeX-jaã§ï¼\Pkg{textcomp}ããã±ã¼ã¸ã\Pkg{marvosym}ããã±ã¼ã¸çï¼Unicodeãã©ã³ãã§ãªã
-ä¼çµ±çãª8ããããã©ã³ããç¨ããå ´åã«ã¯æ³¨æãå¿
è¦ã§ããï¼
-
-ä¾ãã°ï¼\Pkg{textcomp}ããã±ã¼ã¸ã®æä¾ãã \cs{textparagraph} ã¯ï¼
-符å·ä½ç½®ã182ï¼ã¤ã¾ã \texttt{0xB6} ã§ããï¼Unicodeã§ã¯ãã®ç¬¦å·ä½ç½®ã§ã¯\P\ (\text{U+00B6}) ã«å¯¾å¿ããï¼
-ã¾ãï¼\Pkg{marvosym}ããã±ã¼ã¸ã®æä¾ãã \cs{Frowny} ãï¼ç¬¦å·ä½ç½®ã¯167ï¼ã¤ã¾ãUnicodeã«ããã
-\S\ (\text{U+00A7}) ã¨åã符å·ä½ç½®ã«ããï¼
-å³ã¡ï¼ä»¥åã®ãã¼ã¸ã§ã³ã®ããã«ï¼ãåç¯ã®æåç¯å²8å
ã®æåã¯\textbf{JAchar}ãã¨ããè¨å®ã§
-ãã£ãã¨ããã¨ï¼ä¸è¨ã® \cs{textparagraph} ã¯åæãã©ã³ãã§ã\ltjjachar`¶ããåºåãï¼
-ã¾ã \cs{Frowny} ã¯åæãã©ã³ãã§ã\ltjjachar`§ããåºåãããã¨ã«ãªãï¼
-
-ãã®ãããªäºæ
ãé¿ããããã«ï¼æ¬ãã¼ã¸ã§ã³ãã㯠\texttt{U+0080}--\texttt{U+00FF} ã®ç¯å²ã®
-æåã¯å
¨ã¦\textbf{ALchar}ã¨ãªãããã«åæè¨å®ãå¤æ´ãã¦ããï¼
-ç¹ã«å½±é¿ãåããã®ãï¼JIS~X~0208ã®ä¸é¨åã§ããæåç¯å²8å
ã®æåã§ããï¼
-\emph{\Pkg{fontspec}ããã±ã¼ã¸ãèªã¿è¾¼ãã ããã¦æ¬§æè¨å·ã¨ãã¦ãããã®æåã®åºåç°å¢ãæ´ã
-ãªãã¨ï¼ã½ã¼ã¹ä¸ã«ç´æ¥è¨è¿°ãã¦ãåºåãããªã}ãã¨ã«ãªãï¼
-
-ãªãï¼æåç¯å²ã®è¨å®ã«é¢ããã1ã¤ã®æåã\textbf{ALchar}, \textbf{JAchar}ã§åºåãããå ´åã«ã¯ï¼
-以ä¸ã®ä¾ã®ããã«ãããã \cs{ltjalchar},~\cs{ltjjachar} ã«è©²å½æåã®æåã³ã¼ãã渡ãã°ããï¼
-\begin{LTXexample}[width=0.3\textwidth]
-\gtfamily\large % default, ALchar, JAchar
-¶, \ltjalchar`¶, \ltjjachar`¶\\ % default: ALchar
-α, \ltjalchar`α, \ltjjachar`α % default: JAchar
-\end{LTXexample}
+æåã¦ã£ãã¦å¦çï¼ãæ¼¢åãä¸æåã ã次ã®è¡ã«è¡ãã®ãé²ãã
+\cs{jcharwidowpenalty} ãï¼
+ãã®æåã®ç´åã«æ¿å
¥ãããããå¦ãï¼ã示ãï¼
%
+\end{table}
-%\subsection{\Param{kanjiskip} and \Param{xkanjiskip}}
-%\subsection{\Param{kanjiskip}ã¨\Param{xkanjiskip}}
-\label{subs-kskip}
-
-%\textbf{JAglue} is divided into the following three categories:
-%\textbf{JAglue}ã¯ä»¥ä¸ã®3ã¤ã®ã«ãã´ãªã«åé¡ãããï¼
-\begin{itemize}
-%<*en>
-\item Glues/kerns specified in JFM. If \cs{inhibitglue} is issued
- around a \textbf{JAchar}, this glue will not be inserted at the
- place.
-%
-%<*ja>
-\item JFMã§æå®ãããã°ã«ã¼ï¼ã«ã¼ã³ï¼ãã \cs{inhibitglue} ã\textbf{JAchar}ã®å¨ãã§
- çºè¡ããã¦ããã°ï¼ãã®ã°ã«ã¼ã¯æ¿å
¥ãããªãï¼
-%
%<*en>
-\item The default glue which inserted between two \textbf{JAchar}s (\Param{%
- kanjiskip}).
+\cs{kcatcode} can be set by a row of JIS~X~0208 in \pTeX,
+and generally by a Unicode block\footnote{%
+ \upTeX\ divides \texttt{U+FF00}--\texttt{U+FFEF} (Halfwidth and Fullwidth Forms)
+ into three subblocks, and \cs{kcatcode} can be set by a subblock.
+}
+in \upTeX. So characters which can be used in a control word
+slightly differ between \pTeX~and~\upTeX.
%
%<*ja>
-\item ããã©ã«ãã§2ã¤ã®\textbf{JAchar}ã®éã«æ¿å
¥ãããã°ã«ã¼(\Param{kanjiskip})ï¼
+\pTeX ã§ã¯ \cs{kcatcode} ã¯JIS~X~0208ã®åºåä½ï¼
+\upTeX ã§ã¯æ¦ãUnicodeãããã¯åä½\footnote{%
+ \texttt{U+FF00}--\texttt{U+FFEF} (Halfwidth and Fullwidth Forms)ã¯
+ ãå
¨è§è±æ°åããåè§ã«ããããã®ä»ãã¨3ã¤ã«åå²ããã¦ããï¼
+ ããããå¥ã
ã« \cs{kcatcode} ãæå®ã§ããããã«ãªã£ã¦ããï¼
+}ã§è¨å®å¯è½ã«ãªã£ã¦ããï¼ãã®ããï¼\pTeX ã¨\upTeX ã®åæç¶æ
ã§ã¯
+å¶å¾¡ç¶´å
ã§ä½¿ç¨å¯è½ãªæåãå¾®å¦ã«ç°ãªã£ã¦ããï¼
%
+
%<*en>
-\item The default glue which inserted between a \textbf{JAchar} and an
- \textbf{ALchar} (\Param{xkanjiskip}).
-%
-%<*ja>
-\item ããã©ã«ãã§\textbf{JAchar}ã¨\textbf{ALchar}ã®éã«æ¿å
¥ãããã°ã«ã¼(\Param{xkanjiskip})ï¼
-%
+\subsection{Case of \LuaTeX-ja}
+The role of \cs{kcatcode} in \pTeX~and~\upTeX\ can be
+divided into the following four kinds,
+and \LuaTeX-ja can control these four kinds separately:
+\begin{itemize}
+ \item
+\emph{Distinction between \textbf{JAchar} or \textbf{ALchar}}
+is controlled by the character range, see Subsection~\ref{ssec-setrange}.
+ \item
+\emph{Whether the character can be used in a control word}
+is controlled by setting \cs{catcode} to 11~(enabled) or 12~(disabled), as usual.
+ \item
+\emph{Whether \Param{jcharwidowpenalty} can be inserted before the character}
+is controlled by the lowermost bit of the \Param{kcatcode} parameter.
+ \item
+\emph{Linebreak after a \textbf{JAchar}} does not produce a space.
\end{itemize}
-%<*en>
-The value (a skip) of \Param{kanjiskip} or
-\Param{xkanjiskip} can be changed as the following.
-Note that only their values \emph{at the end of a paragraph or a hbox are
-adopted in the whole paragraph or the whole hbox.
-}
%
%<*ja>
-\Param{kanjiskip}ã\Param{xkanjiskip}ã®å¤
-ã¯ä»¥ä¸ã®ããã«ãã¦å¤æ´å¯è½ã§ããï¼
+\subsection{\LuaTeX-jaã®å ´å}
+\LuaTeX-jaã§ã¯ï¼å¾æ¥ã®\pTeXã»\upTeX ã«ããã \cs{kcatcode} ã®å½¹å²ã
+åå²ãã¦ããï¼
+\begin{description}
+ \item[欧æ/åæã®åºå¥ (\upTeX)]
+\cs{ltjdefcharrange} ã¨\textsf{jacharrange}ãã©ã¡ã¼ã¿ï¼\ref{ssec-setrange}ç¯ï¼
+ \item[å¶å¾¡ç¶´ä¸ã«ä½¿ç¨å¯ã]
+\LuaTeX èªèº«ã® \cs{catcode} ã§ãã
+ \item[\Param{jcharwidowpenalty}ãæ¿å
¥å¯ã]
+\Param{kcatcode}ãã©ã¡ã¼ã¿ã®æä¸ä½ããã
+ \item[ç´å¾ã®æ¹è¡]
+æ¥æ¬èªããæ³å®ãã¦ããªãã®ã§ï¼\textbf{JAchar}ç´å¾ã®æ¹è¡ã§åè§ã¹ãã¼ã¹ãæ¿å
¥ããããã¨ã¯ãªãï¼
+\end{description}
%
-\begin{lstlisting}
-\ltjsetparameter{kanjiskip={0pt plus 0.4pt minus 0.4pt},
- xkanjiskip={0.25\zw plus 1pt minus 1pt}}
-\end{lstlisting}
+
%<*en>
-Here \cs{zw} is a internal dimension
-which stores fullwidth of the current Japanese font.
-This \cs{zw} can be used as the unit \texttt{zw} in \pTeX.
+Default setting of \cs{catcode} of Unicode characters are located in
+\begin{description}
+ \item[plain \LuaTeX] \texttt{luatex-unicode-letters.tex}, which is based on \texttt{unicode-letters.tex}
+(for \XeTeX).
+ \item[\LuaLaTeX] now included in \LaTeX\ kernel as~\texttt{unicode-letters.def}.
+\end{description}
+However, the default setting of \cs{catcode} differs
+between \XeTeX\ and \LuaTeX, by the following reasons:
+\begin{itemize}
+ \item (plain format) \texttt{luatex-unicode-letters.tex} is based on old \texttt{unicode-letters.tex}.
+ \item The latter half of \texttt{unicode-letters.tex}~and~\texttt{unicode-letters.def}
+sets\cs{catcode} of several characters to 11, via setting \cs{XeTeXcharclass}.
+However, this latter half does not exist (plain case), or not executed (\LaTeX~case) in \LuaTeX.
+\end{itemize}
+In other words,
+\begin{description}
+\item[plain \LuaTeX]
+Kanji nor kana characters cannot be used in
+a control word, in the default setting of plain \LuaTeX.
+\item[\LuaLaTeX]
+In recent (2015-10-01 or later) \LuaLaTeX, Kanji and kana characters in a control word is supported (these catcode are 11),
+but not fullwidth alphanumerics and several other characters.
+\end{description}
-The value of these parameter can be get by \cs{ltjgetparameter}.
-Note that the result by \cs{ltjgetparameter} is \emph{not} the internal quantities,
-but \emph{a string} (hence \cs{the} cannot be prefixed).
+This would be inconvenient for \pTeX~users to shifting to \LuaTeX-ja,
+since several control words containing Kanji or other fullwidth characters, such as
+\verb+\西æ¦+~or~\verb+\ï¼å¹´ç®è¥¿æ¦+ are used in \pTeX.
+Hence, \LuaTeX-ja have a counterpart of \texttt{unicode-letters.tex}
+for \LuaTeX, \emph{to match the \cs{catcode} setting with that of \XeTeX.}
%
%<*ja>
-ããã§ï¼\cs{zw} ã¯ç¾å¨ã®åæãã©ã³ãã®å
¨è§å¹
ã表ãé·ãã§ããï¼
-\pTeX ã«ãããé·ãåä½ \texttt{zw} ã¨åãããã«ä½¿ç¨ã§ããï¼
+ãã¤ãã£ãã«Unicodeå
¨é¨ã®æåãæ±ãã\XeTeX ã\LuaTeX ã§ã¯ï¼
+æåãå¶å¾¡ç¶´å
ã§ä½¿ç¨ã§ãããã¯é常ã®æ¬§ææåã¨åãã \cs{catcode}
+ã§æå®ãããã¨ã¨ãªãï¼plain \XeTeX ã«ããã \cs{catcode} ã®åæè¨å®ã¯\
+\texttt{unicode-letters.tex} ä¸ã«è¨è¿°ããã¦ããï¼plain \LuaTeX ã§ã¯ããã
+å
ã«ãã \texttt{luatex-unicode-letters.tex} ãç¨ãã¦ããï¼
+\LaTeX ã§ã¯ \cs{catcode} ã®è¨å®ã¯ã«ã¼ãã«ã« \texttt{unicode-letters.def} ã¨ãã¦çµ±åããï¼
+ãã®ãã¡ã¤ã«ã\XeLaTeX, \LuaLaTeX ã®ä¸¡æ¹ãç¨ãã¦ããï¼
-ãããã®ãã©ã¡ã¼ã¿ã®å¤ã¯ä»¥ä¸ã®ããã«åå¾ã§ããï¼
-æ»ãå¤ã¯å
é¨å¤ã§ã¯ãªã\emph{æåå}ã§ããï¼\cs{the} ã¯åç½®ã§ããªãï¼ãã¨ã«æ³¨æãã¦ã»ããï¼
-%
-\begin{LTXexample}
-kanjiskip: \ltjgetparameter{kanjiskip},\\
-xkanjiskip: \ltjgetparameter{xkanjiskip}
-\end{LTXexample}
-
-%<*en>
-It may occur that JFM contains the data of ``ideal width of
-\Param{kanjiskip}''
-and/or ``ideal width of \Param{xkanjiskip}''.
-To use these data from JFM, set the value of \Param{kanjiskip} or
-\Param{xkanjiskip} to \cs{maxdimen}
-(these ``ideal width'' cannot be retrived by \cs{ltjgetparameter}).
-%
-%<*ja>
-JFMã¯ãæã¾ãã\Param{kanjiskip}ã®å¤ãã
-ãæã¾ãã\Param{xkanjiskip}ã®å¤ããæã£ã¦ãããã¨ãããï¼
-ãããã®ãã¼ã¿ã使ãããã«ã¯ï¼\Param{kanjiskip}ã%
-\Param{xkanjiskip}ã®å¤ã \cs{maxdimen} ã®å¤ã«è¨å®ããã°ãããï¼
-\cs{ltjgetparameter} ã«ãã£ã¦åå¾ãããã¨ã¯ã§ããªãã®ã§æ³¨æãå¿
è¦ã§ããï¼
+ã ãï¼\XeTeX ã«ããã \cs{catcode} ã®åæè¨å®ã¨
+\LuaTeX ã«ãããããã¯ä¸è´ãã¦ããªãï¼
+\begin{itemize}
+ \item \texttt{luatex-unicode-letters.tex} ã®å
ã«ãªã£ã\
+\texttt{unicode-letters.tex} ãå¤ã
+ \item \texttt{unicode-letters.tex} å¾åé¨ã \texttt{unicode-letters.def} å¾åé¨ã§ã¯
+\cs{XeTeXcharclass} ã®è¨å®ãè¡ãªã£ã¦ããï¼
+ããã«ãã£ã¦æ¼¢åãä»®åï¼ããã³å
¨è§è±æ°åã® \cs{catcode} ã11ã«è¨å®ããã¦ããï¼
+ãããï¼\texttt{luatex-unicode-letters.tex} ã§ã¯ãã®ãå¾åé¨ãã
+ã¾ããã¨çç¥ããã¦ããï¼ã¾ã\LuaLaTeX ã§ã \texttt{unicode-letters.def} å¾åé¨ã¯å®è¡ãããª
+ ãï¼
+\end{itemize}
+è¨ãæããã¨ï¼
+\begin{description}
+ \item[plain \LuaTeX] æ¼¢åãä»®åãå¶å¾¡ç¶´å
ã«
+使ç¨ãããã¨ã¯ã§ããªãï¼
+ \item[\LuaLaTeX] æè¿ã®ï¼2015-10-01以éã®ï¼
+\LuaLaTeX ã§ã¯æ¼¢åãä»®åãå¶å¾¡ç¶´å
ã«
+使ç¨ãããã¨ãå¯è½ã«ãªã£ããï¼å
¨è§è±æ°åã¯ç¸å¤ããã使ç¨ã§ããªãï¼
+\end{description}
+ããã§ã¯ \pTeX ã§ä½¿ç¨ã§ãã \verb+\ï¼å¹´ç®è¥¿æ¦+\footnote{ç§ç è²»\LaTeX ã§ä½¿ç¨ããã¦ããããã§ãï¼}ãªã©ã使ããªããã¨ã¨ãªãï¼
+\LuaTeX-jaã¸ã®ç§»è¡ã§æéãçããï¼ãã®ããï¼\LuaTeX-jaã§ã¯
+\texttt{unicode-letters.tex} ã®å¾åé¨ã«ãããå
容ãèªåã§ããããï¼
+çµæã¨ãã¦\textbf{\XeTeX ã«ãããåæè¨å®ã¨åãã«ãªãããã«ãã¦ããï¼}
%
-%\subsection{Insertion setting of \Param{xkanjiskip}}
-%\subsection{\Param{xkanjiskip} ã®æ¿å
¥è¨å®}
+\begin{table}
+ \centering\small
+%\caption{Difference of the set of non-kanji JIS~X~0208 characters which can be used in a control word}
+%\caption{å¶å¾¡ç¶´ä¸ã«ä½¿ç¨åºæ¥ãJIS~X~0208éæ¼¢åã®éã}
+%\medskip
+\label{tab:kcat-diff}
+\def\D#1#2#3#4{%
+ {\fboxsep0pt\fcolorbox{cyan}{white}%
+ {\large\char"#1#2#3#4}}\ (\texttt{U+#1#2#3#4})} %"
+\leavevmode\hbox to 0pt{\hss\begin{tabular}{cccccc}
+\toprule
+%&\bf row&\bf col.&\bf \pTeX&\bf \upTeX&\bf\LuaTeX-ja\\
+%&\bf åº&\bf ç¹&\bf \pTeX&\bf \upTeX&\fontseries{b}\selectfont\LuaTeX-ja\\
+\midrule
+%\D 3000&1&1&N&N&Y\\
+\D 30FB&1&6&N&Y&N\\
+\D 309B&1&11&N&Y&N\\
+\D 309C&1&12&N&Y&N\\
+\D FF40&1&14&N&N&Y\\
+\D FF3E&1&16&N&N&Y\\
+\D FFE3&1&17&N&N&Y\\
+\D FF3F&1&18&N&N&Y\\
+%\D 30FD&1&19&N&Y&Y\\
+%\D 30FE&1&20&N&Y&Y\\
+%\D 309D&1&21&N&Y&Y\\
+%\D 309E&1&22&N&Y&Y\\
+\D 3003&1&23&N&N&Y\\
+\D 4EDD&1&24&N&Y&Y\\
+\D 3005&1&25&N&N&Y\\
+\D 3006&1&26&N&N&Y\\
+\D 3007&1&27&N&N&Y\\
+\D 30FC&1&28&N&Y&Y\\
+\D FF0F&1&31&N&N&Y\\
+\D FF3C&1&32&N&N&Y\\
+\bottomrule
+\end{tabular}\qquad
+\begin{tabular}{cccccc}
+\toprule
+%&\bf row&\bf col.&\bf \pTeX&\bf \upTeX&\bf\LuaTeX-ja\\
+%&\bf åº&\bf ç¹&\bf \pTeX&\bf \upTeX&\fontseries{b}\selectfont\LuaTeX-ja\\
+\midrule
+\D FF5C&1&35&N&N&Y\\
+\D FF0B&1&60&N&N&Y\\
+\D FF1D&1&65&N&N&Y\\
+\D FF1C&1&67&N&N&Y\\
+\D FF1E&1&68&N&N&Y\\
+\D FF03&1&84&N&N&Y\\
+\D FF06&1&85&N&N&Y\\
+\D FF0A&1&86&N&N&Y\\
+\D FF20&1&87&N&N&Y\\
+\D 3012&2&9&N&N&Y\\
+\D 3013&2&14&N&N&Y\\
+\D FFE2&2&44&N&N&Y\\
+\D 212B&2&82&N&N&Y\\
+%\multicolumn{3}{c}{$\vphantom{\D 3000}$\hbox{}Greek letters (row 6)}&Y&N&Y\\
+%\multicolumn{3}{c}{$\vphantom{\D 3000}$\hbox{}Cyrillic letters (row 7)}&N&N&Y\\
+%\multicolumn{3}{c}{$\vphantom{\D 3000}$\hbox{}ã®ãªã·ã£æåï¼6åºï¼}&Y&N&Y\\
+%\multicolumn{3}{c}{$\vphantom{\D 3000}$\hbox{}ããªã«æåï¼7åºï¼}&N&N&Y\\
+\bottomrule
+\end{tabular}\hss}\par
+\end{table}
%<*en>
-It is not desirable that \Param{xkanjiskip} is inserted into every
-boundary between \textbf{JAchar}s and \textbf{ALchar}s. For example,
-\Param{xkanjiskip} should not be inserted after opening parenthesis
-(\textit{e.g.}, compare ``(ã'' and ``(\hskip\ltjgetparameter{xkanjiskip}ã'').
-\LuaTeX-ja can control whether \Param{xkanjiskip} can be inserted
-before/after a character, by changing \Param{jaxspmode} for \textbf{JAchar}s and
-\Param{alxspmode} parameters \textbf{ALchar}s respectively.
-%
-%<*ja>
-\Param{xkanjiskip}ããã¹ã¦ã®\textbf{JAchar}ã¨\textbf{ALchar}ã®å¢çã«
-æ¿å
¥ãããã®ã¯æã¾ãããã¨ã§ã¯ãªãï¼ä¾ãã°ï¼\Param{xkanjiskip}ã¯éãæ¬å¼§ã®
-å¾ã«ã¯æ¿å
¥ãããã¹ãã§ã¯ãªãï¼ã(ããã¨ã(\hskip\ltjgetparameter{xkanjiskip}ããã
-æ¯ã¹ã¦ã¿ãï¼ï¼
-\LuaTeX-jaã§ã¯\Param{xkanjiskip}ãããæåã®åï¼å¾ã«æ¿å
¥ãããã©ãããï¼
-\textbf{JAchar}ã«å¯¾ãã¦ã¯\Param{jaxspmode}ãï¼\textbf{ALchar}ã«å¯¾ãã¦ã¯
-\Param{alxspmode}ãããããå¤ãããã¨ã§å¶å¾¡ãããã¨ãã§ããï¼
-%
-\begin{LTXexample}
-\ltjsetparameter{jaxspmode={`ã,preonly}, alxspmode={`\!,postonly}}
-pãq ã!ã
-\end{LTXexample}
+\subsection{Non-kanji characters in a control word}
+Because the engine differ, so non-kanji JIS~X~0208 characters
+which can be used in a control word differ in \pTeX, in \upTeX,~and~in \LuaTeX-ja.
+\autoref{tab:kcat-diff} shows the difference.
+Except for four characters ``ã»'',~``ã'', ``ã'',~``ã '',
+\LuaTeX-ja admits more characters in a control word than \upTeX.
-%<*en>
-The second argument \texttt{preonly} means that the insertion of
-\Param{xkanjiskip} is allowed before this character, but not after.
-the other possible values are \texttt{postonly}, \texttt{allow}, and \texttt{inhibit}.
+Difference becomes larger, if we consider
+non-kanji JIS~X~0213 characters.
+For the detail, see \url{https://github.com/h-kitagawa/kct}.
%
%<*ja>
-2ã¤ç®ã®å¼æ°ã® \texttt{preonly}ã¯ã\Param{xkanjiskip}ã®æ¿å
¥ã¯ãã®æåã®
-åã§ã®ã¿è¨±ããï¼å¾ã§ã¯è¨±ããªãããã¨ãæå³ããï¼ä»ã«æå®å¯è½ãªå¤ã¯
-\texttt{postonly}, \texttt{allow}, \texttt{inhibit}ã§ããï¼
-%
+\subsection{å¶å¾¡ç¶´ä¸ã«ä½¿ç¨åºæ¥ãJISéæ¼¢åã®éã}
-%<*en>
-\Param{jaxspmode} and \Param{alxspmode} use a same table to store the parameters
-on the current version. Therefore, line~1 in the code above can be rewritten
-as follows:
-%
-%<*ja>
-ãªãï¼ç¾è¡ã®
-ä»æ§ã§ã¯ï¼\Param{jaxspmode}, \Param{alxspmode}ã¯ãã¼ãã«ãå
±æãã¦ããï¼
-ä¸ã®ã³ã¼ãã®1è¡ç®ã次ã®ããã«å¤ãã¦ãåããã¨ã«ãªãï¼
-%
-\begin{lstlisting}
-\ltjsetparameter{alxspmode={`ã,preonly}, jaxspmode={`\!,postonly}}
-\end{lstlisting}
-%<*en>
-One can use also numbers to specify these two parameters (see Subsection~\ref{ssec-param}).
-%
-%<*ja>
-ã¾ãï¼ããã2ãã©ã¡ã¼ã¿ã«ã¯æ°å¤ã§å¤ãæå®ãããã¨ãã§ããï¼\ref{ssec-param}ç¯ãåç
§ï¼ï¼
+ã¨ã³ã¸ã³ãç°ãªãã®ã§ï¼\pTeX, \upTeX, \LuaTeX-ja
+ã«ããã¦å¶å¾¡ç¶´ä¸ã«ä½¿ç¨å¯è½ãªJIS~X~0208ã®æåã¯ç°ãªãï¼
+ç°ãªã£ã¦ããã¨ããã ããè¼ããã¨ï¼\autoref{tab:kcat-diff}ã®ããã«ãªãï¼
+ãã»ããããããããã ããé¤ãã°ï¼\LuaTeX-jaã§ã¯\upTeX ããå¤ãã®æåã
+å¶å¾¡ç¶´ã«ä½¿ç¨å¯è½ã«ãªã£ã¦ããï¼
+
+JIS~X~0213ã®ç¯å²ã«åºããã¨ï¼å·®ç°ã¯ããã«å¤§ãããªãï¼
+詳細ã«ã¤ãã¦ã¯ä¾ãã° \url{https://github.com/h-kitagawa/kct} ä¸ã®\
+\texttt{kct-out.pdf} ãªã©ãåç
§ãããã¨ï¼
%
+
%<*en>
-If you want to enable/disable all insertions of \Param{kanjiskip} and
-\Param{xkanjiskip}, set \Param{autospacing} and \Param{autoxspacing}
-parameters to \texttt{true}/\texttt{false}, respectively.
+\section{Directions}
+\LuaTeX\ supports four $\Omega$-style directions: \texttt{TLT},~\texttt{TRT}, \texttt{RTT}
+and \texttt{LTL}.
+However, neither directions are not well-suited for typesetting Japanese vertically, hence we
+implemented vertical writing by rotating \texttt{TLT}-box by 90~degrees.
%
%<*ja>
-ããå
¨ã¦ã®\Param{kanjiskip}ã¨\Param{xkanjiskip}ã®æ¿å
¥ãæå¹åï¼ç¡å¹å
-ããããã°ï¼ãããã\Param{autospacing}ã¨\Param{autoxspacing}ã
-\texttt{true}/\texttt{false}ã«è¨å®ããã°ããï¼
+\section{縦çµ}
+\label{sec-direction}
+\LuaTeX æ¬ä½ã§ãï¼$\Omega$ã»$\aleph$ç±æ¥ã®æ©è½ã¨ãã¦ï¼è¤æ°ã®çµæ¹åããµãã¼ããã¦ããï¼
+ãããï¼\LuaTeX ããµãã¼ãããã®ã¯ \texttt{TLT},~\texttt{TRT}, \texttt{RTT},~\texttt{LTL}\
+ã®ã¿ã§ããï¼æ¥æ¬èªã®ç¸¦çµã«ä½¿ãã®ã¯æã¾ãããªã\footnote{%
+åææåã ããªãã° \texttt{RTT} ã使ãã°ãªãã¨ããªãã¨æããï¼
+欧ææåãå
¥ã£ã¦ããå ´åã¯ãã¾ããããï¼\texttt{RTR} ã¨ããçµæ¹åãå¿
è¦ã«ãªãï¼
+}ï¼ãã®ããï¼\LuaTeX-jaã§ã¯æ¨ªçµ(\texttt{TLT})ã§çµãã ããã¯ã¹ãå転ãããæ¹å¼ã§
+縦çµãå®è£
ããï¼
%
-%\subsection{Shifting the baseline}
-%\subsection{ãã¼ã¹ã©ã¤ã³ã®ç§»å}
-%<*en>
-To make a match between a Japanese font and an alphabetic font, sometimes
-shifting of the baseline of one of the pair is needed. In \pTeX, this is achieved
-by setting \cs{ybaselineshift} (or \cs{tbaselineshift}) to a non-zero length (the
-baseline of \textbf{ALchar} is shifted below). However, for documents
-whose main language is not Japanese, it is good to shift the baseline of
-Japanese fonts, but not that of alphabetic fonts.
-Because of this, \LuaTeX-ja can independently set the shifting amount
-of the baseline of alphabetic fonts and that of Japanese fonts.
-\begin{center}
- \small
-\begin{tabular}{>{\bfseries}lcc}
-\toprule
-&\bfseries Horizontal writing (\emph{yoko} direction) etc.
-&\bfseries Vertical writing(\emph{tate} direction)\\
-\midrule
-Alphabetic fonts&\Param{yalbaselineshift}
- parameter&\Param{talbaselineshift} parameter\\
-Japanese fonts&\Param{yjabaselineshift}
- parameter&\Param{tjabaselineshift} parameter\\
-\bottomrule
-\end{tabular}
-\end{center}
-%
+%\subsection{ãµãã¼ãããçµæ¹å}
+\begin{table}[t]
+%\caption{\LuaTeX-ja ã®ãµãã¼ãããçµæ¹å}
+%\caption{Directions supported by \LuaTeX-ja}
+%\medskip
+\label{tab-dir}
+\centering\small
+\def\obox#1{%
+ \setbox0=\hbox{\yoko\hbox{#1%
+ \large\ltjsetparameter{talbaselineshift=0pt}%
+ \vrule height 25pt width 0.4pt depth 15pt\kern-.2pt%
+ \raise25pt\hbox to 0pt{\hss\composite{*r^@{>>}}\hss}%
+ \raise-15pt\hbox to 0pt{\hss\composite{*l^@{>|}}\hss}\kern.2pt%
+ \vrule height.2pt depth.2pt width 60pt\hbox to 0pt{\hss\composite{*d^@{>}}\hss}\kern-60pt
+ \hbox to 60pt{\,éã¯ãAg\hss}}}%
+ \raise\dimexpr 0.5\ltjgetdp0-0.5\ltjgetht0\box0%
+}
%<*ja>
-åæãã©ã³ãã¨æ¬§æãã©ã³ããåãããããã«ã¯ï¼æã
ã©ã¡ããã®ãã¼ã¹ã©ã¤ã³ã®ç§»åã
-å¿
è¦ã«ãªãï¼\pTeX ã§ã¯ãã㯠\cs{ybaselineshift}ï¼ã¾ãã¯\cs{tbaselineshift}ï¼ãè¨å®ãããã¨ã§
-ãªããã¦ããï¼\textbf{ALchar}ã®ãã¼ã¹ã©ã¤ã³ããã®åã ãä¸ããï¼ï¼ãããï¼æ¥æ¬èªã主ã§ã¯ãªã
-ææ¸ã«å¯¾ãã¦ã¯ï¼æ¬§æãã©ã³ãã§ã¯ãªãåæãã©ã³ãã®ãã¼ã¹ã©ã¤ã³ã移åããæ¹ãããï¼
-ãã®ããï¼\LuaTeX-jaã§ã¯æ¬§æãã©ã³ãã®ãã¼ã¹ã©ã¤ã³ã®ã·ããé
-ã¨åæãã©ã³ãã®ãã¼ã¹ã©ã¤ã³ã®ã·ããéãç¬ç«ã«è¨å®ã§ããããã«ãªã£ã¦ããï¼
-\begin{center}
- \small
-\begin{tabular}{>{\bfseries}lcc}
+\begin{tabular}{>{\bfseries}lcccc}
\toprule
-&\bfseries 横çµãªã©&\bfseries 縦çµ\\
+&横çµ&ç¸¦çµ &ãdtouæ¹åã&ãutodæ¹åã\\
\midrule
-欧æãã©ã³ãã®ã·ããé&\Param{yalbaselineshift}
- parameter&\Param{talbaselineshift} parameter\\
-åæãã©ã³ãã®ã·ããé&\Param{yjabaselineshift}
- parameter&\Param{tjabaselineshift} parameter\\
+å½ä»¤&\cs{yoko}&\cs{tate}&\cs{dtou}&\cs{utod}\\
+åéãæ¹å&æ°´å¹³å³åãï¼âï¼&åç´ä¸åãï¼âï¼&åç´ä¸åãï¼âï¼&åç´ä¸åãï¼âï¼\\
+è¡éãæ¹å&åç´ä¸åãï¼âï¼&水平左åãï¼âï¼&æ°´å¹³å³åãï¼âï¼&水平左åãï¼âï¼\\
+使ç¨ããåæãã©ã³ã&横çµç¨(\cs{jfont})&縦çµç¨(\cs{tfont})&
+\multicolumn{2}{c}{%
+ 横çµç¨(\cs{jfont})ã®$90^\circ$å転}\\[\smallskipamount]
+çµçä¾\null $^*$ &\obox{\yoko}&\obox{\tate}&\obox{\dtou}&\obox{\utod}\\
+\noalign{\medskip}
\bottomrule
\end{tabular}
-\end{center}
-%
-
-%<*en>
-Here the horizontal line in the below example is the baseline of a line.
-%
-%<*ja>
-ä¸ã®ä¾ã«ããã¦å¼ããã¦ããæ°´å¹³ç·ããã¼ã¹ã©ã¤ã³ã§ããï¼
-%
-\begin{LTXexample}
-\vrule width 150pt height 0.2pt depth 0.2pt \hskip-120pt
-\ltjsetparameter{yjabaselineshift=0pt, yalbaselineshift=0pt}abcããã
-\ltjsetparameter{yjabaselineshift=5pt, yalbaselineshift=2pt}abcããã
-\end{LTXexample}
-%<*en>
-There is an interesting side-effect: characters in different size can be
-vertically aligned center in a line, by setting two parameters appropriately.
-The following is an example (beware the value is not well tuned):
-%
-%<*ja>
-ãã®æ©è½ã«ã¯é¢ç½ã使ãæ¹ãããï¼2ã¤ã®ãã©ã¡ã¼ã¿ãé©åã«è¨å®ãããã¨ã§ï¼ãµã¤ãºã®
-ç°ãªãæåãä¸å¿ç·ã«æãããã¨ãã§ããï¼
-以ä¸ã¯ä¸ã¤ã®ä¾ã§ããï¼å¤ã¯ãã¾ã調æ´ããã¦ããªããã¨ã«æ³¨æï¼ï¼
+\medskip\raggedright
+\def\R#1{%
+ \raise0.38\zw\hbox{%
+ \vrule height.2pt depth.2pt width2\zw%
+ \hbox to 0pt{\hss\composite{*d^@{#1}}\hss}%
+ }%
+}
+$^*$\ å¹
(width)ï¼é«ã(height)ï¼æ·±ã(depth)ã®å¢å æ¹åãï¼
+ããããã\R{>}ãï¼ã\R{>>}ãï¼ã\R{>|}ãã§è¡¨ãã¦ããï¼
+\raggedright
%
-\begin{LTXexample}[width=0.4\textwidth]
-\vrule width 150pt height4.417pt depth-4.217pt%
-\kern-150pt
-\large xyzæ¼¢å
-{\scriptsize
- \ltjsetparameter{yjabaselineshift=-1.757pt,
- yalbaselineshift=-1.757pt}
- æ¼¢åxyzããã
-}ãããabc
-\end{LTXexample}
%<*en>
-Note that setting positive \Param{yalbaselineshift}~or~\Param{talbaselineshift}
-parameters does not increase the depth of one-letter \emph{syllable} $p$ of \textbf{Alchar}, if
-its left-protrusion~(\cs{lpcode}) and right-protrusion~(\cs{rpcode}) are both non-zero.
-This is because
-\begin{itemize}
-\item These two parameters are implemented by setting \texttt{yoffset} field of a
-glyph node, and this does not increase the depth of the glyph.
-\item To cope with the above situation, \LuaTeX-ja automatically supplies
-a rule in every syllable.
-\item However, we cannot use this ``supplying a rule'' method if a syllable comprises just
- one letter whose \cs{lpcode}~and~\cs{rpcode} are both non-zero.
-\end{itemize}
-
-This problem does not apply for \Param{yjabaselineshift}~nor~\Param{tjabaselineshift},
-becuse a \emph{JAchar} is encapsulated by a horizontal box if needed.
-%
-%<*ja>
-ãªãï¼ä»¥ä¸ã®å ´åã«ã¯1æåã®\textbf{ALchar}ãããªããé³ç¯ãã®æ·±ãã¯å¢å ããªããã¨ã«æ³¨æï¼
-\begin{itemize}
- \item \Param{yalbaselineshift},~\Param{talbaselineshift}ãã©ã¡ã¼ã¿ãæ£ã«ãªã£ã¦ããï¼
- \item ãé³ç¯ããæ§æããå¯ä¸ã®æå$p$ã®
-å·¦ä½ç½ã¸ã®çªåºé(\cs{lpcode})ï¼å³ä½ç½ã¸ã®çªåºé(\cs{rpcode})ãã©ã¡ããéé¶ã§ããï¼
-\end{itemize}
-\emph{JAchar}ã¯å¿
è¦ã«å¿ãã¦1æåãã¤ããã¯ã¹ã«ã«ãã»ã«åãããããï¼
-\Param{yjabaselineshift},~\Param{tjabaselineshift}ãã©ã¡ã¼ã¿ã«ã¤ãã¦ã¯ãã®ãããªåé¡ã¯èµ·ãããªãï¼
-%
-
-%<*ja>
-\paragraph{æ°å¼ã«ãããæåï¼\pTeX ã¨ã®éã}
-\textbf{ALchar}ã®ãã¼ã¹ã©ã¤ã³ãè£æ£ãã \Param{yalbaselineshift} ãã©ã¡ã¼ã¿ã¯
-ã»ã¼\pTeX ã«ããã \cs{ybaselineshift} ã«å¯¾å¿ãã¦ãããã®ã§ãããï¼
-æ°å¼ä¸ã®æåã¯ç°ãªã£ã¦ããã®ã§æ³¨æãå¿
è¦ã§ããï¼
-ä¾ãã°ï¼è¡¨\ref{tab:math_bsa}ã®ããã«ï¼æ°å¼ä¸ã«æ示çã«ç¾ãã \cs{hbox} ã¯ï¼
-\begin{itemize}
- \item 2015年以åã®\pTeX ã§ã¯ï¼ããã¯ã¹å
¨ä½ã \cs{ybaselineshift} ã ã¨ã·ãããããã®ã§ï¼
- 表\ref{tab:math_bsa}ä¸ã®``ã''ã®ããã«ï¼ããã¯ã¹ä¸ã®åææåã¯
- \ \cs{ybaselineshift} ã ãã·ããããï¼ä¸æ¹ï¼``for all''ã®ããã«ï¼
- ããã¯ã¹å
ã®æ¬§ææåã¯2éã«ã·ããããããã¨ã«ãªãï¼
- \item ä¸æ¹ï¼\LuaTeX-jaã§ã¯ãã®ãããªãã¨ã¯ããããï¼
- æ°å¼ä¸ã«æ示çã«ç¾ãã \cs{hbox} ã¯ã·ããããªãï¼ãã®ããï¼
- 表\ref{tab:math_bsa}ä¸ã®``ã''ã``for all''ãï¼ããããæ¬æä¸ã«
- æ¸ãããã¨ãã¨åãä¸ä¸ä½ç½®ã«çµã¾ããï¼
-
- ãªãï¼\TeX~Live~2016以éã®\pTeX ã§ã¯æ¹ä¿®ããªããï¼\LuaTeX-jaã¨
- è¿ãæåã«ãªãããã«ãã¦ãããï¼æ°å¼ä¸ã«ç´ã«æ¸ããã``ã''ã®ãã¼ã¹ã©ã¤ã³ã«ã¤ãã¦ã¯
- ã¾ã éããè¦ãããï¼
-\end{itemize}
-\begin{table}
-\small\centering
-\caption{æ°å¼é¢ä¿ã®ãã¼ã¹ã©ã¤ã³è£æ£($\Param{yalbaselineshift}=10\,\textrm{pt}$)}
-\label{tab:math_bsa}
-\newdimen\origbaselineskip
-\origbaselineskip=\baselineskip
-\begin{tabular}{lp{30\zw}}
+\begin{tabular}{>{\bfseries}lcccc}
\toprule
-\emph{å
¥å}&\vspace*{\dimexpr-\origbaselineskip-\smallskipamount}
-\begin{lstlisting}
-æ°å¼abc: $ãa\hbox{ã}$, $\int_0^x t\,dt=x^2/2$,
-$\Phi\vdash F(x)\ \hbox{for all}\ x\in A$
-\end{lstlisting}\\
-\noalign{\vskip-\origbaselineskip}
+&horizontal (\emph{yoko}~direction)&vertical (\emph{tate}~direction)&%
+ \emph{dtou} direction&\emph{utod} direction\\
\midrule
-\emph{\pTeX~(--2015)}&
-{\ltjsetparameter{yalbaselineshift=10pt}%
-æ°å¼abc: $\lower10pt\hbox{ã}a\lower10pt\hbox{ã}$, $\int_0^x t\,dt=x^2/2$,
-$\Phi\vdash F(x)\ \lower10pt\hbox{for all}\ x\in A$
-\par}\\\noalign{\vskip-\origbaselineskip}\midrule
-\emph{\pTeX~(2016--)}&
-{\ltjsetparameter{yalbaselineshift=10pt}%
-æ°å¼abc: $\lower10pt\hbox{ã}a\hbox{ã}$, $\int_0^x t\,dt=x^2/2$,
-$\Phi\vdash F(x)\ \hbox{for all}\ x\in A$
-\par}\\\noalign{\vskip-\origbaselineskip}\midrule
-\emph{\LuaTeX-ja}&
-{\ltjsetparameter{yalbaselineshift=10pt}%
-æ°å¼abc: $ãa\hbox{ã}$, $\int_0^x t\,dt=x^2/2$,
-$\Phi\vdash F(x)\ \hbox{for all}\ x\in A$
-\par}\\
-\noalign{\vskip-\origbaselineskip}
+Commands&\cs{yoko}&\cs{tate}&\cs{dtou}&\cs{utod}\\
+Beginning of the page&Top&Right&Left&Right\\
+Beginning of the line&Left&Top&Bottom&Top\\
+Used Japanese font&horizontal (\cs{jfont})&vertical (\cs{tfont})&
+\multicolumn{2}{c}{%
+ horizontal ($90^\circ$ rotated)}\\[\smallskipamount]
+Example&\obox{\yoko}&\obox{\tate}&\obox{\dtou}&\obox{\utod}\\
+\noalign{\medskip}
+(Notation used in $\Omega$)&TLT&RTR, RTT&LBL&RTR\\
\bottomrule
\end{tabular}
+
+\medskip\raggedright
+\def\R#1{%
+ \raise0.38\zw\hbox{%
+ \vrule height.2pt depth.2pt width2\zw%
+ \hbox to 0pt{\hss\composite{*d^@{#1}}\hss}%
+ }%
+}
+\raggedright
+%
\end{table}
-%
%<*en>
-\subsection{\emph{kinsoku} parameters and OpenType features}
-Among parameters which related to Japanese word-wrapping process (\emph{kinsoku shori}),
-\begin{quote}
- \Param{jaxspmode},~\Param{alxspmode}, \Param{prebreakpenalty},
- \Param{postbreakpenalty}~and~\Param{kcatcode}
-\end{quote}
-are stored by each character codes.
+\LuaTeX-ja supports four directions, as shown in \autoref{tab-dir}.
+The second column (\emph{yoko} direction) is just horizontal writing,
+and the third column (\emph{tate} direction) is vertical writing.
+The fourth column (\emph{dtou} direction) is actually a hidden feature of \pTeX.
+We implemented this for debugging purpose.
+The fifth column (\emph{utod} direction) corresponds the ``\texttt{tate (math) direction}'' of \pTeX.
-OpenType font features are ignored in these parameters.
-For example, a fullwidth katakana ``ã¢'' on line~10 in the below input is replaced to
-its halfwidth variant ``ï½±'', by \verb+hwid+ feature.
-However, the penalty inserted after it is 10 which is the \Param{postbreakpenalty} of
-``ã¢'', not 20.
+Directions can be changed by \cs{yoko},~\cs{tate}, \cs{dtou},~\cs{utod},
+only when the current list is null. Also, the direction of a math formula is changed to
+\emph{utod}, when the direction outside the math formula is \emph{tate} (vertical writing).
%
+
%<*ja>
-\subsection{ç¦åå¦çé¢é£ãã©ã¡ã¼ã¿ã¨OpenTypeã®font feature}
-ç¦åå¦çã \Param{kanjiskip}, \Param{xkanjiskip} ã®æ¿å
¥ã«é¢é£ãããã©ã¡ã¼ã¿ã®ãã¡
-\begin{quote}
- \Param{jaxspmode},~\Param{alxspmode}, \Param{prebreakpenalty},
- \Param{postbreakpenalty}, \Param{kcatcode}
-\end{quote}
-ã¯ï¼æåã³ã¼ããã¨ã«è¨å®ããéã§ããï¼
+\LuaTeX-jaããµãã¼ãããçµæ¹åã¯\autoref{tab-dir}ã«ç¤ºã4ã¤ã§ããï¼
+4åç®ã® \cs{dtou} ã¯èãæ
£ããªãå½ä»¤ã ã¨æããï¼
+å®ã¯\pTeX ã«ååã®å½ä»¤ãï¼ããã¥ã¡ã³ãã«ã¯æ¸ããã¦ããªããï¼åå¨ããï¼
+Down-TO-Upã®æå³ãªã®ã ããï¼\cs{dtou} ã使ç¨ããæ©ä¼ã¯ãªãã ãããï¼
+\LuaTeX-jaã§ã¯ãããã°ç¨ã«å®è£
ãã¦ããï¼
+5åç®ã® \cs{utod} ã¯ï¼\pTeX ã§è¨ãã縦æ°å¼ãã£ã¬ã¯ã·ã§ã³ãã«ç¸å½ãããã®ã§ããï¼
-\Pkg{fontspec}ããã±ã¼ã¸ã使ãï¼\ref{ssec-fontspec}ç¯ï¼å ´åãªã©ï¼
-å種ã®OpenType featureãé©ç¨ãããã¨ãããã¨æããï¼å段è½ã«è¿°ã¹ããã©ã¡ã¼ã¿é¡ã¯ï¼
-\emph{OpenType featureã®é©ç¨åã®æåã³ã¼ãã«ãã£ã¦é©ç¨ãããï¼}
-ä¾ãã°ï¼ä»¥ä¸ã®ä¾ã«ããã¦10è¡ç®ã®ãã¢ãã¯ï¼\verb+hwid+ featureã®é©ç¨ã«ããåè§ã«ã¿ã«ãã®ãï½±ã
-ã«ç½®ãæããï¼ãããï¼ãã®ç´å¾ã«æ¿å
¥ããã \Param{postbreakpenalty}ã¯ï¼ç½®æåã®ãã¢ãã«å¯¾ããå¤10ã§ããï¼
+çµæ¹åã¯ï¼\cs{yoko},~\cs{tate}, \cs{dtou},~\cs{utod} ããããã使ç¨ãããã¨ã§ï¼
+ç¾å¨ä½æä¸ã®ãªã¹ããããã¯ã¹ã空ã®æã«ã®ã¿å¤æ´å¯è½ã§ããï¼
+ã¾ãï¼ç¸¦çµä¸ã®æ°å¼å
ã®ããã¯ã¹ã¯\pTeX ã¨åãããã«çµæ¹åã \cs{utod} ã¨ãªãï¼
%
-\begin{LTXexample}[width=0.2\textwidth]
-\ltjsetparameter{postbreakpenalty={`ã¢, 10}}
-\ltjsetparameter{postbreakpenalty={`ï½±, 20}}
-
-\newcommand\showpostpena[1]{%
- \leavevmode\setbox0=\hbox{#1\hbox{}}%
- \unhbox0\setbox0=\lastbox\the\lastpenalty}
+%<*en>
+\subsection{Boxes in different direction}
-\showpostpena{ã¢},
-\showpostpena{ï½±},
-{\addjfontfeatures{CharacterWidth=Half}\showpostpena{ã¢}}
+As in \pTeX, one can use boxes of different direction in one document.
+The below is an example.
+\begin{LTXexample}
+ããã¯æ¨ªçµ% yoko
+\hbox{\tate % tate
+ \hbox{縦çµ}% tate
+ ã®ä¸ã«
+ \hbox{\yoko 横çµã®å
容}% yoko
+ ãæ¿å
¥ãã
+}
+ã¾ã横çµã«æ»ã% yoko
\end{LTXexample}
-\clearpage
-%\part{Reference}
-%\part{ãªãã¡ã¬ã³ã¹}
-\label{part-ref}
-\suppressfloats[t]
+\autoref{tab-diffdir} shows how a box is arranged when
+the direction inside the box and that outside the box differ.
+%
%<*ja>
-\section{\LuaTeX-jaã«ããã \cs{catcode}}
-\label{sec-catcode}
-\subsection{äºåç¥èï¼\pTeX ã¨\upTeX ã«ããã \cs{kcatcode}}
-\pTeXï¼\upTeX ã«ããã¦ã¯ï¼åææåãå¶å¾¡ç¶´å
ã§å©ç¨ã§ãããã©ãã
-㯠\cs{kcatcode} ã®å¤ã«ãã£ã¦æ±ºå®ãããã®ã§ãã£ãï¼
-詳細ã¯è¡¨\ref{table-kcat}ãåç
§ããããï¼
+\subsection{ç°æ¹åã®ããã¯ã¹}
+
+縦çµã®ä¸ã«ã42ããªã©ã®2æ¡ä»¥ä¸ã®ç®ç¨æ°åã横çµã§çµããªã©ï¼
+ç°ãªãçµæ¹åãæ··å¨ããããã¨ããã°ãã°è¡ãããï¼
+çµæ¹åã®æ··å¨ã\pTeX ã¨åãããã«ã§ããï¼
+\begin{LTXexample}
+ããã¯æ¨ªçµ% yoko
+\hbox{\tate % tate
+ \hbox{縦çµ}% tate
+ ã®ä¸ã«
+ \hbox{\yoko 横çµã®å
容}% yoko
+ ãæ¿å
¥ãã
+}
+ã¾ã横çµã«æ»ã% yoko
+\end{LTXexample}
+
+ç°ãªãçµæ¹åã®ããã¯ã¹ãé
ç½®ããå ´åã«ã©ãçµã¾ãããã®ä»æ§ãï¼\pTeX ã
+è¸è¥²ãã¦ããï¼\autoref{tab-diffdir}ã«ç¤ºãï¼
%
-%<*en>
-\section{\cs{catcode} in \LuaTeX-ja}
-\label{sec-catcode}
-\subsection{Preliminaries: \cs{kcatcode} in \pTeX\ and \upTeX}
-In \pTeX~and~\upTeX, the value of \cs{kcatcode} determines
-whether a Japanese character can be used in a control word.
-For the detail, see Table~\ref{table-kcat}.
-%
\begin{table}[t]
-\small
-\caption{\cs{kcatcode} in \upTeX}
-\label{table-kcat}
-%\medskip
-
-\noindent\hfill
-\begin{tabular}{ccccc}
-\toprule
-\bfseries \cs{kcatcode}&
-%<*en>
-\bfseries meaning&
-\bfseries control word&
-\bfseries widow penalty&
-\bfseries linebreak\\
-%
-%<*ja>
-\bfseries æå³&
-\bfseries å¶å¾¡ç¶´ä¸ã«ä½¿ç¨&
-\bfseries æåã¦ã£ãã¦å¦ç&
-\bfseries ç´å¾ã§ã®æ¹è¡\\
-%
-\midrule
-15&non-cjk&\multicolumn{3}{c}{(treated as usual \LaTeX)}\\
-16&kanji&Y&Y&ignored\\
-17&kana&Y&Y&ignored\\
-18&other&N&N&ignored\\
-19&hangul&Y&Y&space\\
-\bottomrule
-\end{tabular}\hfill\null
-
-\medskip
-
-%<*ja>
-æåã¦ã£ãã¦å¦çï¼ãæ¼¢åãä¸æåã ã次ã®è¡ã«è¡ãã®ãé²ãã
-\cs{jcharwidowpenalty} ãï¼
-ãã®æåã®ç´åã«æ¿å
¥ãããããå¦ãï¼ã示ãï¼
-%
-\end{table}
-
-%<*en>
-\cs{kcatcode} can be set by a row of JIS~X~0208 in \pTeX,
-and generally by a Unicode block\footnote{%
- \upTeX\ divides \texttt{U+FF00}--\texttt{U+FFEF} (Halfwidth and Fullwidth Forms)
- into three subblocks, and \cs{kcatcode} can be set by a subblock.
-}
-in \upTeX. So characters which can be used in a control word
-slightly differ between \pTeX~and~\upTeX.
-%
-%<*ja>
-\pTeX ã§ã¯ \cs{kcatcode} ã¯JIS~X~0208ã®åºåä½ï¼
-\upTeX ã§ã¯æ¦ãUnicodeãããã¯åä½\footnote{%
- \texttt{U+FF00}--\texttt{U+FFEF} (Halfwidth and Fullwidth Forms)ã¯
- ãå
¨è§è±æ°åããåè§ã«ããããã®ä»ãã¨3ã¤ã«åå²ããã¦ããï¼
- ããããå¥ã
ã« \cs{kcatcode} ãæå®ã§ããããã«ãªã£ã¦ããï¼
-}ã§è¨å®å¯è½ã«ãªã£ã¦ããï¼ãã®ããï¼\pTeX ã¨\upTeX ã®åæç¶æ
ã§ã¯
-å¶å¾¡ç¶´å
ã§ä½¿ç¨å¯è½ãªæåãå¾®å¦ã«ç°ãªã£ã¦ããï¼
-%
-
-%<*en>
-\subsection{Case of \LuaTeX-ja}
-The role of \cs{kcatcode} in \pTeX~and~\upTeX\ can be
-divided into the following four kinds,
-and \LuaTeX-ja can control these four kinds separately:
-\begin{itemize}
- \item
-\emph{Distinction between \textbf{JAchar} or \textbf{ALchar}}
-is controlled by the character range, see Subsection~\ref{ssec-setrange}.
- \item
-\emph{Whether the character can be used in a control word}
-is controlled by setting \cs{catcode} to 11~(enabled) or 12~(disabled), as usual.
- \item
-\emph{Whether \Param{jcharwidowpenalty} can be inserted before the character}
-is controlled by the lowermost bit of the \Param{kcatcode} parameter.
- \item
-\emph{Linebreak after a \textbf{JAchar}} does not produce a space.
-\end{itemize}
-%
-%<*ja>
-\subsection{\LuaTeX-jaã®å ´å}
-\LuaTeX-jaã§ã¯ï¼å¾æ¥ã®\pTeXã»\upTeX ã«ããã \cs{kcatcode} ã®å½¹å²ã
-åå²ãã¦ããï¼
-\begin{description}
- \item[欧æ/åæã®åºå¥ (\upTeX)]
-\cs{ltjdefcharrange} ã¨\textsf{jacharrange}ãã©ã¡ã¼ã¿ï¼\ref{ssec-setrange}ç¯ï¼
- \item[å¶å¾¡ç¶´ä¸ã«ä½¿ç¨å¯ã]
-\LuaTeX èªèº«ã® \cs{catcode} ã§ãã
- \item[\Param{jcharwidowpenalty}ãæ¿å
¥å¯ã]
-\Param{kcatcode}ãã©ã¡ã¼ã¿ã®æä¸ä½ããã
- \item[ç´å¾ã®æ¹è¡]
-æ¥æ¬èªããæ³å®ãã¦ããªãã®ã§ï¼\textbf{JAchar}ç´å¾ã®æ¹è¡ã§åè§ã¹ãã¼ã¹ãæ¿å
¥ããããã¨ã¯ãªãï¼
-\end{description}
-%
-
-%<*en>
-Default setting of \cs{catcode} of Unicode characters are located in
-\begin{description}
- \item[plain \LuaTeX] \texttt{luatex-unicode-letters.tex}, which is based on \texttt{unicode-letters.tex}
-(for \XeTeX).
- \item[\LuaLaTeX] now included in \LaTeX\ kernel as~\texttt{unicode-letters.def}.
-\end{description}
-However, the default setting of \cs{catcode} differs
-between \XeTeX\ and \LuaTeX, by the following reasons:
-\begin{itemize}
- \item (plain format) \texttt{luatex-unicode-letters.tex} is based on old \texttt{unicode-letters.tex}.
- \item The latter half of \texttt{unicode-letters.tex}~and~\texttt{unicode-letters.def}
-sets\cs{catcode} of several characters to 11, via setting \cs{XeTeXcharclass}.
-However, this latter half does not exist (plain case), or not executed (\LaTeX~case) in \LuaTeX.
-\end{itemize}
-In other words,
-\begin{description}
-\item[plain \LuaTeX]
-Kanji nor kana characters cannot be used in
-a control word, in the default setting of plain \LuaTeX.
-\item[\LuaLaTeX]
-In recent (2015-10-01 or later) \LuaLaTeX, Kanji and kana characters in a control word is supported (these catcode are 11),
-but not fullwidth alphanumerics and several other characters.
-\end{description}
-
-This would be inconvenient for \pTeX~users to shifting to \LuaTeX-ja,
-since several control words containing Kanji or other fullwidth characters, such as
-\verb+\西æ¦+~or~\verb+\ï¼å¹´ç®è¥¿æ¦+ are used in \pTeX.
-Hence, \LuaTeX-ja have a counterpart of \texttt{unicode-letters.tex}
-for \LuaTeX, \emph{to match the \cs{catcode} setting with that of \XeTeX.}
-%
-%<*ja>
-ãã¤ãã£ãã«Unicodeå
¨é¨ã®æåãæ±ãã\XeTeX ã\LuaTeX ã§ã¯ï¼
-æåãå¶å¾¡ç¶´å
ã§ä½¿ç¨ã§ãããã¯é常ã®æ¬§ææåã¨åãã \cs{catcode}
-ã§æå®ãããã¨ã¨ãªãï¼plain \XeTeX ã«ããã \cs{catcode} ã®åæè¨å®ã¯\
-\texttt{unicode-letters.tex} ä¸ã«è¨è¿°ããã¦ããï¼plain \LuaTeX ã§ã¯ããã
-å
ã«ãã \texttt{luatex-unicode-letters.tex} ãç¨ãã¦ããï¼
-\LaTeX ã§ã¯ \cs{catcode} ã®è¨å®ã¯ã«ã¼ãã«ã« \texttt{unicode-letters.def} ã¨ãã¦çµ±åããï¼
-ãã®ãã¡ã¤ã«ã\XeLaTeX, \LuaLaTeX ã®ä¸¡æ¹ãç¨ãã¦ããï¼
-
-ã ãï¼\XeTeX ã«ããã \cs{catcode} ã®åæè¨å®ã¨
-\LuaTeX ã«ãããããã¯ä¸è´ãã¦ããªãï¼
-\begin{itemize}
- \item \texttt{luatex-unicode-letters.tex} ã®å
ã«ãªã£ã\
-\texttt{unicode-letters.tex} ãå¤ã
- \item \texttt{unicode-letters.tex} å¾åé¨ã \texttt{unicode-letters.def} å¾åé¨ã§ã¯
-\cs{XeTeXcharclass} ã®è¨å®ãè¡ãªã£ã¦ããï¼
-ããã«ãã£ã¦æ¼¢åãä»®åï¼ããã³å
¨è§è±æ°åã® \cs{catcode} ã11ã«è¨å®ããã¦ããï¼
-ãããï¼\texttt{luatex-unicode-letters.tex} ã§ã¯ãã®ãå¾åé¨ãã
-ã¾ããã¨çç¥ããã¦ããï¼ã¾ã\LuaLaTeX ã§ã \texttt{unicode-letters.def} å¾åé¨ã¯å®è¡ãããª
- ãï¼
-\end{itemize}
-è¨ãæããã¨ï¼
-\begin{description}
- \item[plain \LuaTeX] æ¼¢åãä»®åãå¶å¾¡ç¶´å
ã«
-使ç¨ãããã¨ã¯ã§ããªãï¼
- \item[\LuaLaTeX] æè¿ã®ï¼2015-10-01以éã®ï¼
-\LuaLaTeX ã§ã¯æ¼¢åãä»®åãå¶å¾¡ç¶´å
ã«
-使ç¨ãããã¨ãå¯è½ã«ãªã£ããï¼å
¨è§è±æ°åã¯ç¸å¤ããã使ç¨ã§ããªãï¼
-\end{description}
-ããã§ã¯ \pTeX ã§ä½¿ç¨ã§ãã \verb+\ï¼å¹´ç®è¥¿æ¦+\footnote{ç§ç è²»\LaTeX ã§ä½¿ç¨ããã¦ããããã§ãï¼}ãªã©ã使ããªããã¨ã¨ãªãï¼
-\LuaTeX-jaã¸ã®ç§»è¡ã§æéãçããï¼ãã®ããï¼\LuaTeX-jaã§ã¯
-\texttt{unicode-letters.tex} ã®å¾åé¨ã«ãããå
容ãèªåã§ããããï¼
-çµæã¨ãã¦\textbf{\XeTeX ã«ãããåæè¨å®ã¨åãã«ãªãããã«ãã¦ããï¼}
-%
-
-\begin{table}
- \centering\small
-%\caption{Difference of the set of non-kanji JIS~X~0208 characters which can be used in a control word}
-%\caption{å¶å¾¡ç¶´ä¸ã«ä½¿ç¨åºæ¥ãJIS~X~0208éæ¼¢åã®éã}
-%\medskip
-\label{table-kcat-diff}
-\def\D#1#2#3#4{%
- {\fboxsep0pt\fcolorbox{cyan}{white}%
- {\large\char"#1#2#3#4}}\ (\texttt{U+#1#2#3#4})} %"
-\leavevmode\hbox to 0pt{\hss\begin{tabular}{cccccc}
-\toprule
-%&\bf row&\bf col.&\bf \pTeX&\bf \upTeX&\bf\LuaTeX-ja\\
-%&\bf åº&\bf ç¹&\bf \pTeX&\bf \upTeX&\fontseries{b}\selectfont\LuaTeX-ja\\
-\midrule
-%\D 3000&1&1&N&N&Y\\
-\D 30FB&1&6&N&Y&N\\
-\D 309B&1&11&N&Y&N\\
-\D 309C&1&12&N&Y&N\\
-\D FF40&1&14&N&N&Y\\
-\D FF3E&1&16&N&N&Y\\
-\D FFE3&1&17&N&N&Y\\
-\D FF3F&1&18&N&N&Y\\
-%\D 30FD&1&19&N&Y&Y\\
-%\D 30FE&1&20&N&Y&Y\\
-%\D 309D&1&21&N&Y&Y\\
-%\D 309E&1&22&N&Y&Y\\
-\D 3003&1&23&N&N&Y\\
-\D 4EDD&1&24&N&Y&Y\\
-\D 3005&1&25&N&N&Y\\
-\D 3006&1&26&N&N&Y\\
-\D 3007&1&27&N&N&Y\\
-\D 30FC&1&28&N&Y&Y\\
-\D FF0F&1&31&N&N&Y\\
-\D FF3C&1&32&N&N&Y\\
-\bottomrule
-\end{tabular}\qquad
-\begin{tabular}{cccccc}
-\toprule
-%&\bf row&\bf col.&\bf \pTeX&\bf \upTeX&\bf\LuaTeX-ja\\
-%&\bf åº&\bf ç¹&\bf \pTeX&\bf \upTeX&\fontseries{b}\selectfont\LuaTeX-ja\\
-\midrule
-\D FF5C&1&35&N&N&Y\\
-\D FF0B&1&60&N&N&Y\\
-\D FF1D&1&65&N&N&Y\\
-\D FF1C&1&67&N&N&Y\\
-\D FF1E&1&68&N&N&Y\\
-\D FF03&1&84&N&N&Y\\
-\D FF06&1&85&N&N&Y\\
-\D FF0A&1&86&N&N&Y\\
-\D FF20&1&87&N&N&Y\\
-\D 3012&2&9&N&N&Y\\
-\D 3013&2&14&N&N&Y\\
-\D FFE2&2&44&N&N&Y\\
-\D 212B&2&82&N&N&Y\\
-%\multicolumn{3}{c}{$\vphantom{\D 3000}$\hbox{}Greek letters (row 6)}&Y&N&Y\\
-%\multicolumn{3}{c}{$\vphantom{\D 3000}$\hbox{}Cyrillic letters (row 7)}&N&N&Y\\
-%\multicolumn{3}{c}{$\vphantom{\D 3000}$\hbox{}ã®ãªã·ã£æåï¼6åºï¼}&Y&N&Y\\
-%\multicolumn{3}{c}{$\vphantom{\D 3000}$\hbox{}ããªã«æåï¼7åºï¼}&N&N&Y\\
-\bottomrule
-\end{tabular}\hss}\par
-\end{table}
-
-%<*en>
-\subsection{Non-kanji characters in a control word}
-Because the engine differ, so non-kanji JIS~X~0208 characters
-which can be used in a control word differ in \pTeX, in \upTeX,~and~in \LuaTeX-ja.
-Table~\ref{table-kcat-diff} shows the difference.
-Except for four characters ``ã»'',~``ã'', ``ã'',~``ã '',
-\LuaTeX-ja admits more characters in a control word than \upTeX.
-
-Difference becomes larger, if we consider
-non-kanji JIS~X~0213 characters.
-For the detail, see \url{https://github.com/h-kitagawa/kct}.
-%
-%<*ja>
-\subsection{å¶å¾¡ç¶´ä¸ã«ä½¿ç¨åºæ¥ãJISéæ¼¢åã®éã}
-
-ã¨ã³ã¸ã³ãç°ãªãã®ã§ï¼\pTeX, \upTeX, \LuaTeX-ja
-ã«ããã¦å¶å¾¡ç¶´ä¸ã«ä½¿ç¨å¯è½ãªJIS~X~0208ã®æåã¯ç°ãªãï¼
-ç°ãªã£ã¦ããã¨ããã ããè¼ããã¨ï¼è¡¨\ref{table-kcat-diff}ã®ããã«ãªãï¼
-ãã»ããããããããã ããé¤ãã°ï¼\LuaTeX-jaã§ã¯\upTeX ããå¤ãã®æåã
-å¶å¾¡ç¶´ã«ä½¿ç¨å¯è½ã«ãªã£ã¦ããï¼
-
-JIS~X~0213ã®ç¯å²ã«åºããã¨ï¼å·®ç°ã¯ããã«å¤§ãããªãï¼
-詳細ã«ã¤ãã¦ã¯ä¾ãã° \url{https://github.com/h-kitagawa/kct} ä¸ã®\
-\texttt{kct-out.pdf} ãªã©ãåç
§ãããã¨ï¼
-%
-
-
-%<*en>
-\section{Directions}
-\LuaTeX\ supports four $\Omega$-style directions: \texttt{TLT},~\texttt{TRT}, \texttt{RTT}
-and \texttt{LTL}.
-However, neither directions are not well-suited for typesetting Japanese vertically, hence we
-implemented vertical writing by rotating \texttt{TLT}-box by 90~degrees.
-%
-%<*ja>
-\section{縦çµ}
-\label{sec-direction}
-\LuaTeX æ¬ä½ã§ãï¼$\Omega$ã»$\aleph$ç±æ¥ã®æ©è½ã¨ãã¦ï¼è¤æ°ã®çµæ¹åããµãã¼ããã¦ããï¼
-ãããï¼\LuaTeX ããµãã¼ãããã®ã¯ \texttt{TLT},~\texttt{TRT}, \texttt{RTT},~\texttt{LTL}\
-ã®ã¿ã§ããï¼æ¥æ¬èªã®ç¸¦çµã«ä½¿ãã®ã¯æã¾ãããªã\footnote{%
-åææåã ããªãã° \texttt{RTT} ã使ãã°ãªãã¨ããªãã¨æããï¼
-欧ææåãå
¥ã£ã¦ããå ´åã¯ãã¾ããããï¼\texttt{RTR} ã¨ããçµæ¹åãå¿
è¦ã«ãªãï¼
-}ï¼ãã®ããï¼\LuaTeX-jaã§ã¯æ¨ªçµ(\texttt{TLT})ã§çµãã ããã¯ã¹ãå転ãããæ¹å¼ã§
-縦çµãå®è£
ããï¼
-%
-
-%\subsection{ãµãã¼ãããçµæ¹å}
-\begin{table}[t]
-%\caption{\LuaTeX-ja ã®ãµãã¼ãããçµæ¹å}
-%\caption{Directions supported by \LuaTeX-ja}
-%\medskip
-\label{tab-dir}
-\centering\small
-\def\obox#1{%
- \setbox0=\hbox{\yoko\hbox{#1%
- \large\ltjsetparameter{talbaselineshift=0pt}%
- \vrule height 25pt width 0.4pt depth 15pt\kern-.2pt%
- \raise25pt\hbox to 0pt{\hss\composite{*r^@{>>}}\hss}%
- \raise-15pt\hbox to 0pt{\hss\composite{*l^@{>|}}\hss}\kern.2pt%
- \vrule height.2pt depth.2pt width 60pt\hbox to 0pt{\hss\composite{*d^@{>}}\hss}\kern-60pt
- \hbox to 60pt{\,éã¯ãAg\hss}}}%
- \raise\dimexpr 0.5\ltjgetdp0-0.5\ltjgetht0\box0%
-}
-%<*ja>
-\begin{tabular}{>{\bfseries}lcccc}
-\toprule
-&横çµ&ç¸¦çµ &ãdtouæ¹åã&ãutodæ¹åã\\
-\midrule
-å½ä»¤&\cs{yoko}&\cs{tate}&\cs{dtou}&\cs{utod}\\
-åéãæ¹å&æ°´å¹³å³åãï¼âï¼&åç´ä¸åãï¼âï¼&åç´ä¸åãï¼âï¼&åç´ä¸åãï¼âï¼\\
-è¡éãæ¹å&åç´ä¸åãï¼âï¼&水平左åãï¼âï¼&æ°´å¹³å³åãï¼âï¼&水平左åãï¼âï¼\\
-使ç¨ããåæãã©ã³ã&横çµç¨(\cs{jfont})&縦çµç¨(\cs{tfont})&
-\multicolumn{2}{c}{%
- 横çµç¨(\cs{jfont})ã®$90^\circ$å転}\\[\smallskipamount]
-çµçä¾\null $^*$ &\obox{\yoko}&\obox{\tate}&\obox{\dtou}&\obox{\utod}\\
-\noalign{\medskip}
-\bottomrule
-\end{tabular}
-
-\medskip\raggedright
-\def\R#1{%
- \raise0.38\zw\hbox{%
- \vrule height.2pt depth.2pt width2\zw%
- \hbox to 0pt{\hss\composite{*d^@{#1}}\hss}%
- }%
-}
-$^*$\ å¹
(width)ï¼é«ã(height)ï¼æ·±ã(depth)ã®å¢å æ¹åãï¼
-ããããã\R{>}ãï¼ã\R{>>}ãï¼ã\R{>|}ãã§è¡¨ãã¦ããï¼
-\raggedright
-%
-
-%<*en>
-\begin{tabular}{>{\bfseries}lcccc}
-\toprule
-&horizontal (\emph{yoko}~direction)&vertical (\emph{tate}~direction)&%
- \emph{dtou} direction&\emph{utod} direction\\
-\midrule
-Commands&\cs{yoko}&\cs{tate}&\cs{dtou}&\cs{utod}\\
-Beginning of the page&Top&Right&Left&Right\\
-Beginning of the line&Left&Top&Bottom&Top\\
-Used Japanese font&horizontal (\cs{jfont})&vertical (\cs{tfont})&
-\multicolumn{2}{c}{%
- horizontal ($90^\circ$ rotated)}\\[\smallskipamount]
-Example&\obox{\yoko}&\obox{\tate}&\obox{\dtou}&\obox{\utod}\\
-\noalign{\medskip}
-(Notation used in $\Omega$)&TLT&RTR, RTT&LBL&RTR\\
-\bottomrule
-\end{tabular}
-
-\medskip\raggedright
-\def\R#1{%
- \raise0.38\zw\hbox{%
- \vrule height.2pt depth.2pt width2\zw%
- \hbox to 0pt{\hss\composite{*d^@{#1}}\hss}%
- }%
-}
-\raggedright
-%
-\end{table}
-
-%<*en>
-\LuaTeX-ja supports four directions, as shown in Table~\ref{tab-dir}.
-The second column (\emph{yoko} direction) is just horizontal writing,
-and the third column (\emph{tate} direction) is vertical writing.
-The fourth column (\emph{dtou} direction) is actually a hidden feature of \pTeX.
-We implemented this for debugging purpose.
-The fifth column (\emph{utod} direction) corresponds the ``\texttt{tate (math) direction}'' of \pTeX.
-
-Directions can be changed by \cs{yoko},~\cs{tate}, \cs{dtou},~\cs{utod},
-only when the current list is null. Also, the direction of a math formula is changed to
-\emph{utod}, when the direction outside the math formula is \emph{tate} (vertical writing).
-%
-
-%<*ja>
-\LuaTeX-jaããµãã¼ãããçµæ¹åã¯è¡¨\ref{tab-dir}ã«ç¤ºã4ã¤ã§ããï¼
-4åç®ã® \cs{dtou} ã¯èãæ
£ããªãå½ä»¤ã ã¨æããï¼
-å®ã¯\pTeX ã«ååã®å½ä»¤ãï¼ããã¥ã¡ã³ãã«ã¯æ¸ããã¦ããªããï¼åå¨ããï¼
-Down-TO-Upã®æå³ãªã®ã ããï¼\cs{dtou} ã使ç¨ããæ©ä¼ã¯ãªãã ãããï¼
-\LuaTeX-jaã§ã¯ãããã°ç¨ã«å®è£
ãã¦ããï¼
-5åç®ã® \cs{utod} ã¯ï¼\pTeX ã§è¨ãã縦æ°å¼ãã£ã¬ã¯ã·ã§ã³ãã«ç¸å½ãããã®ã§ããï¼
-
-çµæ¹åã¯ï¼\cs{yoko},~\cs{tate}, \cs{dtou},~\cs{utod} ããããã使ç¨ãããã¨ã§ï¼
-ç¾å¨ä½æä¸ã®ãªã¹ããããã¯ã¹ã空ã®æã«ã®ã¿å¤æ´å¯è½ã§ããï¼
-ã¾ãï¼ç¸¦çµä¸ã®æ°å¼å
ã®ããã¯ã¹ã¯\pTeX ã¨åãããã«çµæ¹åã \cs{utod} ã¨ãªãï¼
-%
-
-%<*en>
-\subsection{Boxes in different direction}
-
-As in \pTeX, one can use boxes of different direction in one document.
-The below is an example.
-\begin{LTXexample}
-ããã¯æ¨ªçµ% yoko
-\hbox{\tate % tate
- \hbox{縦çµ}% tate
- ã®ä¸ã«
- \hbox{\yoko 横çµã®å
容}% yoko
- ãæ¿å
¥ãã
-}
-ã¾ã横çµã«æ»ã% yoko
-\end{LTXexample}
-
-Table~\ref{tab-diffdir} shows how a box is arranged when
-the direction inside the box and that outside the box differ.
-%
-%<*ja>
-\subsection{ç°æ¹åã®ããã¯ã¹}
-
-縦çµã®ä¸ã«ã42ããªã©ã®2æ¡ä»¥ä¸ã®ç®ç¨æ°åã横çµã§çµããªã©ï¼
-ç°ãªãçµæ¹åãæ··å¨ããããã¨ããã°ãã°è¡ãããï¼
-çµæ¹åã®æ··å¨ã\pTeX ã¨åãããã«ã§ããï¼
-\begin{LTXexample}
-ããã¯æ¨ªçµ% yoko
-\hbox{\tate % tate
- \hbox{縦çµ}% tate
- ã®ä¸ã«
- \hbox{\yoko 横çµã®å
容}% yoko
- ãæ¿å
¥ãã
-}
-ã¾ã横çµã«æ»ã% yoko
-\end{LTXexample}
-
-ç°ãªãçµæ¹åã®ããã¯ã¹ãé
ç½®ããå ´åã«ã©ãçµã¾ãããã®ä»æ§ãï¼\pTeX ã
-è¸è¥²ãã¦ããï¼è¡¨\ref{tab-diffdir}ã«ç¤ºãï¼
-%
-
-\begin{table}[t]
-%\caption{ç°æ¹åã®ããã¯ã¹ã®é
ç½®}
-%\caption{Boxes in different direction}
+%\caption{ç°æ¹åã®ããã¯ã¹ã®é
ç½®}
+%\caption{Boxes in different direction}
%\medskip
\label{tab-diffdir}
\centering\small\unitlength3mm
@@ -3585,7 +3119,7 @@ These commands set the dimension of \cs{box}. One does not need
\ltjsetwd42 20pt, \ltjsetwd42=20pt, \ltjsetwd=42 20pt, \ltjsetwd=42=20pt
\end{lstlisting}
-è¨å®å¤ã¯ã横çµãã縦çµåã³ \cs{utod} æ¹åãã\cs{dtou} æ¹åã
+è¨å®å¤ã¯ã横çµãã縦çµåã³utodæ¹åããdtouæ¹åã
ã®3種ãã¨ã«ç¬ç«ãã¦è¨é²ãããï¼åèã¨ãã¦ï¼Gitãªãã¸ããªå
ã®
\verb+test/test55-boxdim_diffdir.{tex,pdf}+ ãæãã¦ããï¼
@@ -3816,7 +3350,7 @@ Specify the name of (horizontal) JFM.
If specified JFM has not been loaded, \LuaTeX-ja search and load
a file named \texttt{jfm-.lua}.
-The following JFMs are shipped with \LuaTeX-ja:
+The following horizontal JFMs are shipped with \LuaTeX-ja:
%
%<*ja>
ç¨ããï¼æ¨ªçµç¨ï¼JFMã®ååãæå®ããï¼ãã以åã«æå®ãããJFMãèªã¿è¾¼ã¾ãã¦ããªããã°ï¼
@@ -3824,7 +3358,7 @@ The following JFMs are shipped with \LuaTeX-ja:
%
\begin{description}
%<*en>
-\item[\tt jfm-ujis.lua] A standard JFM in \LuaTeX-ja. This JFM is
+\item[\tt jfm-ujis.lua] A standard horizontal JFM in \LuaTeX-ja. This JFM is
based on \verb+upnmlminr-h.tfm+, a metric for UTF/OTF package that
is used in \upTeX. When you use the \Pkg{luatexja-otf} package, you should use this JFM.
%
@@ -3859,10 +3393,10 @@ The following JFMs are shipped with \LuaTeX-ja:
%
\end{description}
%<*en>
-The difference among these three~JFMs is shown in Table~\ref{tab-difjfm}.
+The difference among these three~JFMs is shown in \autoref{tab-difjfm}.
%
%<*ja>
-ããã3ã¤ã®JFMã®éãã¯è¡¨\ref{tab-difjfm}ã«ç¤ºããï¼è¡¨ä¸ã®æä¾ã®ä¸é¨ã«ã¯ï¼
+ããã3ã¤ã®JFMã®éãã¯\autoref{tab-difjfm}ã«ç¤ºããï¼è¡¨ä¸ã®æä¾ã®ä¸é¨ã«ã¯ï¼
\cite{min10}ã®å³3,~4ã®ãã®ãç¨ããï¼
%
@@ -3892,11 +3426,11 @@ Sometimes there is a need that \ldots.
\item[jfmvar=]
æ¨æºã§ã¯ï¼JFMã¨ãµã¤ãºãåãã§ï¼
å®ãã©ã³ãã ããç°ãªã2ã¤ã®åæãã©ã³ãã¯ãåºå¥ãããªããï¼ä¾ãã°
-å³\ref{fig:jfmvar}ã«ããã¦ï¼æåã®ãï¼ãã¨ãããã®å®ãã©ã³ãã¯ç°ãªããï¼
+\autoref{fig:jfmvar}ã«ããã¦ï¼æåã®ãï¼ãã¨ãããã®å®ãã©ã³ãã¯ç°ãªããï¼
JFMããµã¤ãºãåããªã®ã§ï¼æ®éã«ãï¼ããã¨å
¥åããæã¨åãããã«åè§ç©ºãã¨ãªãï¼
ãããï¼JFMã¨ãµã¤ãºãåãã§ãã£ã¦ãï¼\texttt{jfmvar} ãã¼ã®ç°ãªã
-2ã¤ã®åæãã©ã³ãï¼ä¾ãã°å³\ref{fig:jfmvar}ã§è¨ã \cs{F} 㨠\cs{H}ï¼
+2ã¤ã®åæãã©ã³ãï¼ä¾ãã°\autoref{fig:jfmvar}ã§è¨ã \cs{F} 㨠\cs{H}ï¼
ã¯ãåºå¥ããããï¼ç°ãªãåæãã©ã³ãã«ç°ãªã \texttt{jfmvar} ãã¼ãå²ãå½ã¦ï¼
ãã¤\Param{differentjfm}ãã©ã¡ã¼ã¿ã \texttt{both} ã«è¨å®ããã°ï¼
\pTeX ã¨ä¼¼ãç¶æ³ã§çµçããããã¨ã«ãªãï¼
@@ -3927,9 +3461,9 @@ JFMããµã¤ãºãåããªã®ã§ï¼æ®éã«ãï¼ããã¨å
¥åããæã¨
\label{para-kern}
%<*en>
Some fonts have information for inter-glyph spacing.
-This version of \LuaTeX-ja treats kerning spaces like an italic correction;
+\LuaTeX-ja 20140324.0 or later treats kerning spaces like an italic correction;
any glue and/or kern from the JFM and a kerning space can coexist.
-See Figure~\ref{fig:kern-jfm} for detail.
+See \autoref{fig:kern-jfm} for detail.
Note that in \cs{setmainjfont} etc.\ which are provided by \Pkg{luatexja-fontspec}
package, kerning option is set \emph{off} (\texttt{Kerning=Off}) by default,
@@ -3938,9 +3472,9 @@ because of the compatibility with previous versions of \LuaTeX-ja.
%<*ja>
ããã¤ãã®ãã©ã³ãã¯ã°ãªãéã®ã¹ãã¼ã¹ã«ã¤ãã¦ã®æ
å ±ãæã£ã¦ããï¼
ãã®ã«ã¼ãã³ã°æ
å ±ã¯ä»¥åã®\LuaTeX-ja ã¨ã¯ãã¾ãç¸æ§ãè¯ããªãã£ããï¼
-æ¬ãã¼ã¸ã§ã³ã§ã¯ã«ã¼ãã³ã°ã«ãã空ç½ã¯ã¤ã¿ãªãã¯è£æ£ã¨åæ§ã«æ±ããã¨ã«ãªã£ã¦ããï¼
+ãã¼ã¸ã§ã³20140324.0以éã§ã¯ã«ã¼ãã³ã°ã«ãã空ç½ã¯ã¤ã¿ãªãã¯è£æ£ã¨åæ§ã«æ±ããã¨ã«ãªã£ã¦ããï¼
ã¤ã¾ãï¼ã«ã¼ãã³ã°ç±æ¥ã®ç©ºç½ã¨JFMç±æ¥ã®ã°ã«ã¼ã»ã«ã¼ã³ã¯åæã«å
¥ãããï¼
-å³\ref{fig:kern-jfm}ãåç
§ï¼
+\autoref{fig:kern-jfm}ãåç
§ï¼
\begin{itemize}
\item \emph{\cs{jfont} ãï¼
NFSS2ç¨ã®å½ä»¤ï¼\ref{ssec-chgfnt}ç¯ï¼\ref{ssec-nfsspat}ç¯ï¼ã«ãããæå®ã§ã¯
@@ -3999,7 +3533,7 @@ JFMä¸ã«ããã \texttt{kanjiskip\_natural}, \texttt{kanjiskip\_stretch},\
\texttt{kanjiskip\_shrink}ãã¼ï¼\pageref{pg:ksp_nat}ãã¼ã¸ï¼ã®ä½¿ç¨ã«ãã£ã¦ï¼
ãJFMç±æ¥ã®ã°ã«ã¼ã®ä»ã«ï¼\Param{kanjiskip}ã®èªç¶é·/伸ã³é/縮ã¿éã®ä¸é¨ã
åãå ´æã«æ¿å
¥ããããã¨ããç¶æ³ãèµ·ããããï¼
-ãã®æ©è½ãç¡å¹åãï¼20150922.0ç以åã¨åããããªçµçãå¾ãããã«ã¯
+ãã®æ©è½ãç¡å¹åãï¼ãã¼ã¸ã§ã³20150922.0以åã¨åããããªçµçãå¾ãããã«ã¯
ä»ã®OpenTypeæ©è½ã¨åãããã«\ \texttt{-ltjksp}\ æå®ãè¡ãã°è¯ãï¼
\begin{LTXexample}[width=16\zw]
\leavevmode
@@ -4025,12 +3559,13 @@ JFMä¸ã«ããã \texttt{kanjiskip\_natural}, \texttt{kanjiskip\_stretch},\
%\subsection{\cs{tfont} å½ä»¤}
+\begin{comment}
+ {\catcode`\<=12\catcode`\>=12
\begin{table}[t]
%\caption{Differences between vertical JFMs shipped with \LuaTeX-ja}
%\caption{\LuaTeX-ja ã«å梱ããã¦ãã縦çµç¨ JFM ã®éã}
%\medskip
\label{tab-difjfm-tate}
-\catcode`\<=12\catcode`\>=12
\ltjsetparameter{jacharrange={+3}}
\small
\def\r#1#2{%
@@ -4067,9 +3602,32 @@ JFMä¸ã«ããã \texttt{kanjiskip\_natural}, \texttt{kanjiskip\_stretch},\
\end{minipage}
\ltjsetparameter{jacharrange={-3}}
\end{table}
+}
+\end{comment}
%<*en>
-...
+\cs{tfont} loads a font as a Japanese font for vertical direction.
+This command admits the same syntax used in \cs{font}~and~\cs{jfont}.
+A font defined by~\cs{tfont} differs the following points from that by~\cs{jfont}:
+\begin{itemize}
+ \item Both \texttt{vert}~and~\texttt{vrt2} Opentype features are activated,
+ unless they are explicitly activated or deactivated (as the third line in the example below).
+\begin{lstlisting}
+\tfont\S=file:KozMinPr6N-Regular.otf:jfm=ujisv
+ % vert and vrt2 are automatically activated
+\tfont\T=file:KozMinPr6N-Regular.otf:jfm=ujisv;-vert % vert and vrt2 are not activated
+\end{lstlisting}
+ \item ...
+ \item One have to specify the name of vertical JFM in \texttt{jfm=}.
+\LuaTeX-ja ships following vertical JFMs:
+\begin{description}
+\item[\tt jfm-ujisv.lua] A standard vertical JFM in \LuaTeX-ja. This JFM is
+ based on \verb+upnmlminr-v.tfm+, a metric for UTF/OTF package that
+ is used in \upTeX.
+\item[\tt jfm-tmin.lua] A counterpart for \verb+tmin10.tfm+, which is one
+ of the default Japanese font metric shipped with \pTeX.
+\end{description}
+\end{itemize}
%
%<*ja>
\cs{tfont} ã¯ãã©ã³ãã縦çµç¨ã®åæãã©ã³ãã¨ãã¦èªã¿è¾¼ãå½ä»¤ã§ããï¼
@@ -4087,7 +3645,7 @@ JFMä¸ã«ããã \texttt{kanjiskip\_natural}, \texttt{kanjiskip\_stretch},\
\end{lstlisting}
\item \ref{ssec-math}ç¯ã§è¿°ã¹ãï¼æ°å¼ä¸ã®åæãã©ã³ãã«ã¯ç¸¦çµç¨åæãã©ã³ãã¯æå®ã§ããªãï¼
\item \texttt{jfm=}\ ã®é¨åã«ã¯ç¸¦çµç¨JFMãæå®ããï¼
-以ä¸ã®ç¸¦çµç¨JFMã\LuaTeX-jaã«ã¯å梱ããã¦ããï¼éãã表\ref{tab-difjfm-tate}ã«ç¤ºããï¼
+以ä¸ã®ç¸¦çµç¨JFMã\LuaTeX-jaã«ã¯å梱ããã¦ããï¼%ããï¼éãã\autoref{tab-difjfm-tate}ã«ç¤ºããï¼
\begin{description}
\item[\tt jfm-ujisv.lua] \LuaTeX-jaã®æ¨æºç¸¦çµç¨JFMã§ããï¼ãã®JFMã¯\upTeX ã§
ç¨ããããUTF/OTFããã±ã¼ã¸ç¨ã®åæç¨TFMã§ãã \verb+upnmlminr-v.tfm+ ã
@@ -4228,15 +3786,15 @@ floating-point numbers in design-size unit.
\begin{cslist}[style=standard]
-\item[version=$1\mathrel{\textrm{or}}2$]
+\item[version=]
%(optional, default value is~1)
%ï¼ä»»æï¼æ¢å®å¤ã¯1ï¼
%<*en>
-The version JFM. Currently 1~and~2 are supported
+The version JFM. Currently 1,~2,~and,~3 are supported
%
%<*ja>
-JFMã®ãã¼ã¸ã§ã³ï¼1ã¾ãã¯2ããµãã¼ããããï¼
+JFMã®ãã¼ã¸ã§ã³ï¼1,~2,~3ããµãã¼ããããï¼
%
\item[dir=]
@@ -4378,7 +3936,7 @@ Direction of JFM&\textbf{\texttt{'yoko'} (horizontal)}&\multicolumn{1}{l}{\textb
\end{table}
Specify the width of characters in character class~$i$, the height, the depth and
the amount of italic correction. All characters in character class~$i$ are regarded that its width, height, and depth are
-as values of these fields. The default values are shown in Table~\ref{tab-wid}.
+as values of these fields. The default values are shown in \autoref{tab-wid}.
%
%<*ja>
\begin{table}[t]
@@ -4415,7 +3973,7 @@ These fields are for adjusting the position of the ``real'' glyph. Legal
treated as~0, and \texttt{align} field is treated as
\texttt{'left'}.
The effects of these 3~fields are indicated in
-Figures \ref{fig-pos}~and~\ref{fig-pos-tate}.
+\autoref{fig:pos}~and~\autoref{fig:pos-tate}.
%
%<*ja>
ãããã®ãã£ã¼ã«ãã¯å®éã®ã°ãªãã®ä½ç½®ã調æ´ããããã«ããï¼
@@ -4423,8 +3981,8 @@ Figures \ref{fig-pos}~and~\ref{fig-pos-tate}.
\texttt{'right'} ã®ããããã§ããï¼ããããã3ã¤ã®ãã£ã¼ã«ãã®ãã¡ã®1ã¤ãçããã
å ´åï¼\texttt{left} 㨠\texttt{down} ã¯0ï¼\texttt{align} ãã£ã¼ã«ãã¯
\ \texttt{'left'} ã§ãããã®ã¨ãã¦æ±ãããï¼
-ããã3ã¤ã®ãã£ã¼ã«ãã®æå³ã«ã¤ãã¦ã¯å³\ref{fig-pos}ï¼æ¨ªçµç¨åæãã©ã³ãï¼ï¼
-å³\ref{fig-pos-tate}ï¼ç¸¦çµç¨åæãã©ã³ãï¼ã§èª¬æããï¼
+ããã3ã¤ã®ãã£ã¼ã«ãã®æå³ã«ã¤ãã¦ã¯\autoref{fig:pos}ï¼æ¨ªçµç¨åæãã©ã³ãï¼ï¼
+\autoref{fig:pos-tate}ï¼ç¸¦çµç¨åæãã©ã³ãï¼ã§èª¬æããï¼
%
%<*en>
@@ -4541,7 +4099,7 @@ Furthermore, the glyph is shifted according to values of fields
%The position of the real glyph (horizontal Japanese fonts)
%横çµåæãã©ã³ãã«ããããå®éã®ãã°ãªãã®ä½ç½®
}
-\label{fig-pos}
+\label{fig:pos}
\end{figure}
\begin{figure}[!tb]
\begin{minipage}{0.4\textwidth}%
@@ -4622,7 +4180,7 @@ Furthermore, the glyph is shifted according to values of fields
%The position of the real glyph (vertical Japanese fonts)
%縦çµåæãã©ã³ãã«ããããå®éã®ãã°ãªãã®ä½ç½®
}
-\label{fig-pos-tate}
+\label{fig:pos-tate}
\end{figure}
\item[kern={\{[$j$]=, [$j'$]=\{, [ratio=]\}, ...\}}]
@@ -4667,8 +4225,8 @@ we specify to $0.25/(0.5+0.25)=1/3$.
\Pkg{luatexja-adjust}ã«ããåªå
é ä½ä»ã
è¡é·èª¿æ´ï¼\ref{ssec-adj}ç¯ï¼ã«ããã¦ï¼ãã®ã°ã«ã¼ã®åªå
度ãæå®ããï¼è¨±ãããå¤ã¯ä»¥ä¸ã®éãï¼
\begin{description}
- \item[ãã¼ã¸ã§ã³1ã®ã¨ã] $-4$ãã$+3$ã®éã®æ´æ°
- \item[ãã¼ã¸ã§ã³2ã®ã¨ã] $-4$ãã$+3$ã®éã®æ´æ°ã®2ã¤çµ\texttt{\{, \}}ãï¼
+ \item[ãã¼ã¸ã§ã³1] $-4$ãã$+3$ã®éã®æ´æ°
+ \item[ãã¼ã¸ã§ã³2以é] $-4$ãã$+3$ã®éã®æ´æ°ã®2ã¤çµ\texttt{\{, \}}ãï¼
ã¾ãã¯$-4$ãã$+3$ã®éã®æ´æ°ï¼, ã¯ãããããã®ã°ã«ã¼ã伸ã³ãã¨ãã®åªå
度ï¼ç¸®ãã¨ãã®
åªå
度ã§ããï¼åã«æ´æ°$i$ãæå®ãããå ´åã¯\texttt{\{$i$, $i$\}}ã§ããã¨è§£éãããï¼
\end{description}
@@ -4711,7 +4269,7 @@ In case of glue, one can specify following additional keys in each \texttt{[$j$]
\begin{cslist}[style=standard]
\item[priority=]
An integer in $[-4,3]$ (treated as 0 if omitted), or
-a pair of these integers \texttt{\{, \}} (version~2 only).
+a pair of these integers \texttt{\{, \}} (version 2~or~later).
This is
used only in line adjustment with priority by \Pkg{luatexja-adjust}
(see Subsection~\ref{ssec-adj}). Higher value means the glue is easy to stretch,
@@ -4900,8 +4458,31 @@ The following is the list of imaginary characters:
%é常ã®ï¼\cs{noindent} ã§éå§ããã¦ããªãï¼æ®µè½ã®å
é ï¼
\item['jcharbdd']
-%A boundary between \textbf{JAchar} and anything else (such as \textbf{ALchar}, kern, glue,\,\ldots).
-%\textbf{JAchar}ã¨ããã®ä»ã®ãã®ãï¼æ¬§ææåï¼glueï¼kernçï¼ã¨ã®å¢çï¼
+%A boundary between \textbf{JAchar} and anything else.
+%<*ja>
+\textbf{JAchar}ã¨ããã®ä»ã®ãã®ãã¨ã®å¢çï¼
+
+ãã¼ã¸ã§ã³2以åã§ã¯\textbf{ALchar}ï¼ç®±ï¼ç½«ç·(rule)ï¼glue,~kernãªã©ãããããªãã®ã¨\textbf{JAchar}ã®å¢çã«å¯¾ãã¦
+æ¬ç¹æ®æåãç¨ãããã¦ãããï¼
+ãã¼ã¸ã§ã³3以éã§ã¯\ \texttt{'jcharbdd'}, \texttt{'alchar'}, \texttt{'nox\_alchar'},
+\texttt{'glue'} ã¨ç´°ååããï¼
+\texttt{'jcharbdd'} ã¯ä¸»ã«\textbf{JAchar}ã¨ããã¯ã¹ã罫ç·(rule)ã¨ã®å¢çã«ä½¿ãããããã«ãªã£ãï¼
+%
+
+\item['alchar', 'nox\_alchar']
+%<*en>
+(version 3~or~later) A boundary between \textbf{JAchar} and \textbf{ALchar}.
+%
+%<*ja>
+ï¼ãã¼ã¸ã§ã³3以éï¼\textbf{JAchar}ã¨\textbf{ALchar}ã¨ã®å¢çï¼
+\textbf{JAchar}ã¨\textbf{ALchar}ã®éã«\Param{xkanjiskip}ãå
¥ããã¨ãå¯è½ãªå ´åã¯
+\ \texttt{'alchar'}\ ãï¼ããã§ãªãå ´åã¯\ \texttt{'nox\_alchar'}\ ãç¨ãããã
+ï¼ãã®åºå¥ã¯\textbf{ALchar}å´ã®\Param{alxspmode}ã®å¤ã«ãã£ã¦ã®ã¿è¡ãããï¼ï¼
+%
+
+\item['glue']
+%(version 3~or~later) A boundary between \textbf{JAchar}, and, a glue or kern.
+%ï¼ãã¼ã¸ã§ã³3以éï¼ï¼\textbf{JAchar}ã¨glueï¼kernã¨ã®å¢çï¼
\item[$-1$]
%The left/right boundary of an inline math formula.
@@ -4988,7 +4569,7 @@ an external package is needed to support this in plain \TeX\ and
%<*en>
\LuaTeX-ja's handling of Japanese fonts in math formulas is similar;
-Table~\ref{tab-math} shows counterparts to \TeX's primitives for math
+\autoref{tab-math} shows counterparts to \TeX's primitives for math
font families. There is no relation between the value of
\cs{fam} and that of \cs{jfam}; with appropriate settings,
you can set both \cs{fam} and \cs{jfam} to the same value.
@@ -4998,7 +4579,7 @@ a \emph{horizontal} Japanese font.
%
%<*ja>
\LuaTeX-jaã®æ°å¼ä¸ã§ã®åæãã©ã³ãã®æ±ããåæ§ã§ããï¼
-表\ref{tab-math}ã¯æ°å¼ãã©ã³ããã¡ããªã«å¯¾ãã \TeX ã®ããªããã£ãã¨å¯¾å¿ãã
+\autoref{tab-math}ã¯æ°å¼ãã©ã³ããã¡ããªã«å¯¾ãã \TeX ã®ããªããã£ãã¨å¯¾å¿ãã
ãã®ã示ãã¦ããï¼\cs{fam} 㨠\cs{jfam} ã®å¤ã®éã«ã¯é¢ä¿ã¯ãªãï¼
é©åãªè¨å®ã®ä¸ã§ã¯ \cs{fam} 㨠\cs{jfam} ã®ä¸¡æ¹ã«åãå¤ãè¨å®ãããã¨ãã§ããï¼
\Param{jatextfont} ä»ã®ç¬¬2å¼æ°ã¯ï¼\cs{jfont} ã§å®ç¾©ããã
@@ -5124,16 +4705,9 @@ For $i\in\omega$, \texttt{char\_type[$i$]} is information of characters whose cl
0&\text{\texttt{'left'} (default)}\\0.5&\text{\tt 'middle'}\\1&\text{\tt 'right'}
\end{cases}
\]
-\item For $j\in \omega$, \texttt{[$j$]} stores a kern or a glue which will be inserted
-between character class~$i$ and class~$j$.
-
-If a kern will be inserted, the value of this field is \texttt{[$j$]=\{false, , \}},
-where is a node\footnote{%
- This version of \LuaTeX-ja uses ``direct access
- model'' for accessing nodes, if possible. }.
-If a glue will be inserted, we have \texttt{[$j$]=\{false, , , \}},
-where is also a node, and $\text{}=\textit{from\_jfm}+\text{}$.
\end{itemize}
+For $i$,~$j\in \omega$, \texttt{char\_type[$i$][$j$]} stores a kern or a glue which will be inserted
+between character class~$i$ and class~$j$.
\end{description}
%
%<*ja>
@@ -5166,23 +4740,34 @@ JFMã§æå®ããã¦ããããããã®å¤ãã¹ã±ã¼ãªã³ã°ãããã®
\end{cases}
\]
ã®ããããã®å¤ãã¨ãï¼
-\item $j\in \omega$ã«å¯¾ãã¦ï¼\texttt{[$j$]} ã¯æåã¯ã©ã¹$i$ã®æåã¨$j$ã®æåã®éã«æ¿å
¥ãããkern
- ãglueãæ ¼ç´ãã¦ããï¼
-éã«å
¥ããã®ãkernã§ããã°ï¼ãã®ãã£ã¼ã«ãã®å¤ã¯\
-\texttt{[$j$]=\{false, , \}} ã§ããï¼
-ã¯kernã表ããã¼ããã®ãã®ã§ãã\footnote{%
-æ¬ãã¼ã¸ã§ã³ã§ã¯ãã¼ãã®ã¢ã¯ã»ã¹ææ³ã«direct access
+\end{itemize}
+$i$,~$j\in \omega$ã«å¯¾ãã¦ï¼\texttt{char\_type[$i$][$j$]} ã¯
+æåã¯ã©ã¹$i$ã®æåã¨$j$ã®æåã®éã«æ¿å
¥ãããã°ã«ã¼ãã«ã¼ã³ãæ ¼ç´ãã¦ããï¼
+\begin{itemize}
+ \item éã«å
¥ããã®ãã«ã¼ã³ã§ããã°ï¼ãã®å¤ã¯\
+\texttt{[$j$]=\{[1]=, ratio=\}} ã§ããï¼
+ã¯ã«ã¼ã³ã表ããã¼ããã®ãã®ã§ãã\footnote{%
+ãã¼ã¸ã§ã³20150420.0以éã§ã¯ãã¼ãã®ã¢ã¯ã»ã¹ææ³ã«direct access
modelãç¨ãã¦ããï¼ãã®ããï¼ä¾ãã°\LuaTeX\ beta-0.78.2ã§ã¯ï¼åãªãèªç¶æ°ã®ããã«ã
ãè¦ããªããã¨ã«æ³¨æï¼
}ï¼
-glueã§ããã°ï¼\texttt{[$j$]=\{false, , , \}} ã§ããï¼
-ã¯glueã®é·ãã表ããã¼ããã®ãã®ã§ããï¼
- $\text{}=\textit{from\_jfm}+\text{}$ã§ããï¼
+ \item ã°ã«ã¼ã§ããã°ï¼ãã®å¤ã¯ä»¥ä¸ã®ãã¼ãæã¤ãã¼ãã«ã§ããï¼
+ \begin{description}
+ \item[\texttt{width}, \texttt{stretch}, \texttt{shrink}]
+ ã°ã«ã¼ã®ããããèªç¶é·ï¼ä¼¸ã³éï¼ç¸®ã¿éãspåä½ã§è¡¨ãããã®ï¼
+ \item[\texttt{priority}] ãï¼ã¼ã¸ã§ã³2以éã®ï¼JFMã§ã®æå® \texttt{\{,\}} ã
+ \[
+ (\text{}+4)\cdot 8+\text{}+4
+ \]
+ ã¨ãã¦0--63ã®æ´æ°ã«ããã¯ãããã®ï¼
+ \item[\texttt{ratio}, \texttt{kanjiskip\_natural}, \texttt{kanjiskip\_stretch}, \texttt{kanjiskip\_shrink}]
+ JFMä¸ã®ååã®ãã£ã¼ã«ãã®å¤ããã®ã¾ã¾ä½¿ããã¦ããï¼
+ \end{description}
\end{itemize}
\item[ascent\textrm{, }descent]
â¦â¦
\item[chars\_cbcache]
-â¦â¦
+æåã¯ã©ã¹æ±ºå®ã®å¦çã§ï¼ãã£ãã·ã¥ã¨ãã¦ä½¿ãããï¼
\end{cslist}
%
@@ -5391,13 +4976,13 @@ Penalty value for suppressing orphans. This penalty is inserted just
%<*en>
An additional attributes which each character whose character code is has.
-At the present version, the lowermost bit of indicates
+At version~20120506.0 or later, the lowermost bit of indicates
whether the character is considered as a punctuation mark
(see the description of \Param{jcharwidowpenalty} above).
%
%<*ja>
æåã³ã¼ããã®æåãæã¤ä»å çãªå±æ§å¤ï¼
-ç¾å¨ã®ãã¼ã¸ã§ã³ã§ã¯ï¼ã®æä¸ä½ããããï¼ãã®æåãå¥èªç¹ã¨
+ãã¼ã¸ã§ã³20120506.0以éã§ã¯ï¼ã®æä¸ä½ããããï¼ãã®æåãå¥èªç¹ã¨
ã¿ãªããããã©ããã表ãã¦ããï¼ä¸ã®\Param{jcharwidowpenalty}ã®è¨è¿°ãåç
§ï¼ï¼
%
@@ -5470,1849 +5055,2764 @@ to prevent a line ends with this character.
\item[\DParam{jaxspmode}\,=\{,\}$^\ast$]\
%<*en>
-Set whether inserting \Param{xkanjiskip} is allowed before/after a \textbf{JAchar} whose character code is .
-The followings are allowed for :
+Set whether inserting \Param{xkanjiskip} is allowed before/after a \textbf{JAchar} whose character code is .
+The followings are allowed for :
+%
+%<*ja>
+æåã³ã¼ããã®\textbf{JAchar}ã®åï¼å¾ãã«\Param{xkanjiskip}ã®
+æ¿å
¥ã許ããã©ããã®è¨å®ï¼
+以ä¸ã®ã許ãããï¼
+%
+\begin{description}
+%\item[0, \texttt{inhibit}] Insertion of \Param{xkanjiskip} is inhibited before the character, nor after the character.
+%\item[0, \texttt{inhibit}] \Param{xkanjiskip}ã®æ¿å
¥ã¯æåã®åï¼å¾ãã®ãããã§ãç¦æ¢ãããï¼
+%\item[1, \texttt{preonly}] Insertion of \Param{xkanjiskip} is allowed before the character, but not after.
+%\item[1, \texttt{preonly}] \Param{xkanjiskip}ã®æ¿å
¥ã¯æåã®åã§ã¯è¨±ããããï¼å¾ãã§ã¯è¨±ãããªãï¼
+%\item[2, \texttt{postonly}] Insertion of \Param{xkanjiskip} is allowed after the character, but not before.
+%\item[2, \texttt{postonly}] \Param{xkanjiskip}ã®æ¿å
¥ã¯æåã®å¾ãã§ã¯è¨±ããããï¼åã§ã¯è¨±ãããªãï¼
+%\item[3, \texttt{allow}] Insertion of \Param{xkanjiskip} is allowed both before the character and after the character. This is the default value.
+%\item[3, \texttt{allow}] \Param{xkanjiskip}ã®æ¿å
¥ã¯æåã®åï¼å¾ãã®ãããã§ã許ãããï¼ãããããã©ã«ãã®å¤ã§ããï¼
+\end{description}
+%<*en>
+This parameter is similar to the \cs{inhibitxspcode} primitive of \pTeX, but not compatible with \cs{inhibitxspcode}.
+%
+%<*ja>
+ãã®ãã©ã¡ã¼ã¿ã¯\pTeX ã® \cs{inhibitxspcode} ããªããã£ãã¨ä¼¼ã¦ãããï¼
+äºææ§ã¯ãªãï¼
+%
+\item[\DParam{alxspmode}\,=\{,\}$^\ast$] [\cs{xspcode}]\
+
+%<*en>
+Set whether inserting \Param{xkanjiskip} is allowed before/after a
+ \textbf{ALchar} whose character code is .
+ The followings are allowed for :
+%
+%<*ja>
+æåã³ã¼ããã®\textbf{ALchar}ã®åï¼å¾ãã«\Param{xkanjiskip}ã®
+æ¿å
¥ã許ããã©ããã®è¨å®ï¼
+以ä¸ã®ã許ãããï¼
+%
+\begin{description}
+%\item[0, \texttt{inhibit}] Insertion of \Param{xkanjiskip} is inhibited before the character, nor after the character.
+%\item[0, \texttt{inhibit}] \Param{xkanjiskip}ã®æ¿å
¥ã¯æåã®åï¼å¾ãã®ãããã§ãç¦æ¢ãããï¼
+%\item[1, \texttt{preonly}] Insertion of \Param{xkanjiskip} is allowed before the character, but not after.
+%\item[1, \texttt{preonly}] \Param{xkanjiskip}ã®æ¿å
¥ã¯æåã®åã§ã¯è¨±ããããï¼å¾ãã§ã¯è¨±ãããªãï¼
+%\item[2, \texttt{postonly}] Insertion of \Param{xkanjiskip} is allowed after the character, but not before.
+%\item[2, \texttt{postonly}] \Param{xkanjiskip}ã®æ¿å
¥ã¯æåã®å¾ãã§ã¯è¨±ããããï¼åã§ã¯è¨±ãããªãï¼
+%\item[3, \texttt{allow}] Insertion of \Param{xkanjiskip} is allowed before the character and after the character. This is the default value.
+%\item[3, \texttt{allow}] \Param{xkanjiskip}ã®æ¿å
¥ã¯æåã®åï¼å¾ãã®ãããã§ã許ãããï¼ãããããã©ã«ãã®å¤ã§ããï¼
+\end{description}
+%<*en>
+Note that parameters \Param{jaxspmode} and \Param{alxspmode} share a common table, hence these two parameters are synonyms of each other.
+%
+%<*ja>
+\Param{jaxspmode}ã¨\Param{alxspmode}ã¯å
±éã®ãã¼ãã«ãç¨ãã¦ããããï¼
+ããã2ã¤ã®ãã©ã¡ã¼ã¿ã¯äºãã®å¥åã¨ãªã£ã¦ãããã¨ã«æ³¨æããï¼
+%
+
+\item[\DParam{autospacing}\,=] [\cs{autospacing}]
+\item[\DParam{autoxspacing}\,=] [\cs{autoxspacing}]
+\item[\DParam{kanjiskip}\,=$^\ast$] [\cs{kanjiskip}]\
+
+%<*ja>
+ããã©ã«ãã§2ã¤ã®\textbf{JAchar}ã®éã«æ¿å
¥ãããã°ã«ã¼ã§ããï¼
+é常ã§ã¯ï¼\pTeX ã¨åãããã«ãã©ã³ããµã¤ãºã«æ¯ä¾ãã¦å¤ãããã¨ã¯ãªãï¼
+ãããï¼èªç¶é·ã \cs{maxdimen} ã®å ´åã¯ï¼ä¾å¤çã«åæãã©ã³ãã®JFMå´ã§æå®ããã¦ãã
+å¤ãæ¡ç¨ï¼ãã¡ãã¯ãã©ã³ããµã¤ãºã«æ¯ä¾ï¼ãããã¨ã«ãªã£ã¦ããï¼
+%
+%<*en>
+The default glue which inserted between two \textbf{JAchar}s.
+Changing current Japanese font does not alter this parameter, as \pTeX.
+
+If the natural width of this parameter is \cs{maxdimen}, \LuaTeX-ja uses
+the value which is specified in the JFM for current Japanese font (See Subsection~\ref{ssec-jfm-str}).
+%
+
+\item[\DParam{xkanjiskip}\,=$^\ast$] [\cs{xkanjiskip}]\
+
+%<*ja>
+ããã©ã«ãã§\textbf{JAchar}ã¨\textbf{ALchar}ã®éã«æ¿å
¥ãããã°ã«ã¼ã§ããï¼
+\Param{kanjiskip}ã¨åãããã«ï¼é常ã§ã¯ãã©ã³ããµã¤ãºã«æ¯ä¾ãã¦å¤ãããã¨ã¯ãªããï¼
+èªç¶é·ã \cs{maxdimen} ã®å ´åãä¾å¤ã§ããï¼
+%
+%<*en>
+The default glue which inserted between a \textbf{JAchar} and an
+ \textbf{ALchar}.
+Changing current font does not alter this parameter, as \pTeX.
+
+As \Param{kanjiskip}, if the natural width of this parameter is \cs{maxdimen}, \LuaTeX-ja uses
+the value which is specified in the JFM for current Japanese font (See Subsection~\ref{ssec-jfm-str}).
+%
+
+
+\item[\DParam{differentjfm}\,=$^\dagger$]\
+
+%<*en>
+Specify how glues/kerns between two \textbf{JAchar}s whose JFM (or size) are different.
+The allowed arguments are the followings:
+%
+%<*ja>
+JFMï¼ãããã¯ãµã¤ãºï¼ãç°ãªã2ã¤ã®\textbf{JAchar}ã®éã«ã°ã«ã¼ï¼ã«ã¼ã³ãã©ã®ããã«
+å
¥ããããæå®ããï¼
+許ãããå¤ã¯ä»¥ä¸ã®éãï¼
+%
+\begin{quote}
+\texttt{average},
+\texttt{both},
+\texttt{large},
+\texttt{small},
+\texttt{pleft},
+\texttt{pright},
+\texttt{paverage}
+\end{quote}
+%<*en>
+The default value is \texttt{paverage}. \dots
+%
+%<*ja>
+ããã©ã«ãå¤ã¯ \texttt{paverage} ã§ããï¼
+åã
ã®å¤ã«ããå·®ç°ã®è©³ç´°ã¯\ref{ssec-cluster-wa}ç¯ã®ããå³ç©ºç½ãã®ç®åºããåç
§ãã¦ã»ããï¼
+%
+
+\item[\DParam{jacharrange}\,=]
+\item[\DParam{kansujichar}\,=\{, \}$^\ast$] [\cs{kansujichar}]
+
+\item[\DParam{direction}\,=\ \hbox{\rm (always local)}]\
+
+%<*en>
+Assigning to this parameter has the same effect as
+\cs{yoko}~(if $\hbox{}=4$), \cs{tate}~(if $\hbox{}=3$),
+\cs{dtou}~(if $\hbox{}=1$) or \cs{utod}~(if $\hbox{}=11$).
+If the argument is not one of 4,~3, 1~nor~11,
+the behavior of this assignment is undefined.
+%
+%<*ja>
+çµæ¹åãå¤æ´ãã \cs{yoko}~(if $\hbox{}=4$), \cs{tate}~(if $\hbox{}=3$),
+\cs{dtou}~(if $\hbox{}=1$), \cs{utod}~(if $\hbox{}=11$) ã¨åãå½¹å²ãæã¤ï¼
+å©ç¨å¯è½ãªç¶æ³ãããã4å½ä»¤ã¨åä¸ã§ããï¼å¼æ°ã4,~3, 1,~11ã®ãããã§ãç¡ãã¨ãã®
+åä½ã¯æªå®ç¾©ã§ããï¼
+%
+
+\end{cslist}
+
+
+\subsection{\cs{ltjgetparameter}}
+\label{ssec-getpar}
+%<*en>
+\cs{ltjgetparameter} is a control sequence for acquiring parameters. It
+always takes a parameter name as first argument.
+%
+%<*ja>
+\cs{ltjgetparameter} ã¯ãã©ã¡ã¼ã¿ã®å¤ãåå¾ããããã®å½ä»¤ã§ããï¼
+常ã«ãã©ã¡ã¼ã¿ã®ååã第ä¸å¼æ°ã«ã¨ãï¼
+%
+\begin{LTXexample}
+\ltjgetparameter{differentjfm},
+\ltjgetparameter{autospacing},
+\ltjgetparameter{kanjiskip},
+\ltjgetparameter{prebreakpenalty}{`ï¼}.
+\end{LTXexample}
+
+%<*en>
+\emph{The return value of\/ \cs{ltjgetparameter} is
+always a string}, which is outputted by \texttt{tex.write()}.
+Hence any character other than space~``\texttt{\char32}''~(\texttt{U+0020}) has the category code
+12~(other), while the space has 10~(space).
+%
+%<*ja>
+\emph{\cs{ltjgetparameter} ã®æ»ãå¤ã¯å¸¸ã«æååã§ããï¼}
+ããã¯\texttt{tex.write()}ã«ãã£ã¦åºåãã¦ããããã§ï¼ç©ºç½ã\texttt{\char32}ã
+(\texttt{U+0020})ãé¤ããæåã®ã«ãã´ãªã¼ã³ã¼ãã¯å
¨ã¦12~(other)ã¨ãªãï¼
+ä¸æ¹ï¼ç©ºç½ã®ã«ãã´ãªã¼ã³ã¼ãã¯10~(space)ã§ããï¼
+%
+
+\begin{itemize}
+\item
+%<*en>
+If first argument is one of the
+following, no additional argument is needed.
+%
+%<*ja>
+第1å¼æ°ã次ã®ããããã®å ´åã«ã¯ï¼è¿½å ã®å¼æ°ã¯å¿
è¦ãªãï¼
+%
+\begin{quote}
+\sffamily
+jcharwidowpenalty, yjabaselineshift, yalbaselineshift, autospacing, autoxspacing,\\
+kanjiskip, xkanjiskip, differentjfm, direction
+\end{quote}
+%<*en>
+Note that \verb+\ltjgetparameter{autospacing}+~and~\verb+\ltjgetparameter{autoxspacing}+
+returns 1 or 0, not
+\texttt{true}~nor~\texttt{false}.
+%
+%<*ja>
+\verb+\ltjgetparameter{autospacing}+ 㨠\verb+\ltjgetparameter{autoxspacing}+ ã¯ï¼
+\texttt{true}ã\texttt{false}ãè¿ãã®\emph{ã§ã¯ãªã}ï¼
+1ã0ã®ãããããè¿ããã¨ã«æ³¨æï¼
+%
+
+\item
+%<*en>
+If first argument is one of the
+following, an additional argument---a character code, for example---is needed.
+%
+%<*ja>
+第1å¼æ°ã次ã®ããããã®å ´åã«ã¯ï¼ããã«æåã³ã¼ãã第2å¼æ°ã¨ãã¦ã¨ãï¼
+%
+\begin{quote}
+\sffamily
+kcatcode, prebreakpenalty, postbreakpenalty, jaxspmode, alxspmode
+\end{quote}
+%<*en>
+\verb+\ltjgetparameter{jaxspmode}{...}+~and~\verb+\ltjgetparameter{alxspmode}{...}+
+returns 0,~1, 2,~or~3, instead of \texttt{preonly} etc.
+%
+%<*ja>
+\verb+\ltjgetparameter{jaxspmode}{...}+ ã \verb+\ltjgetparameter{alxspmode}{...}+\
+ã¯ï¼\texttt{preonly} ãªã©ã¨ãã£ãæååã§ã¯ãªãï¼0ãã3ã¾ã§ã®å¤ãè¿ãï¼
+%
+
+\item
+%<*en>
+\verb+\ltjgetparameter{jacharrange}{+\verb+}+ returns \texttt{0}
+if ``characters which belong to the character range~ are \textbf{JAchar}'',
+\texttt{1} if ``\dots~are \textbf{ALchar}''.
+Although there is no character range~$-1$, specifying $-1$ to does not cause an
+ error (returns 1).
%
%<*ja>
-æåã³ã¼ããã®\textbf{JAchar}ã®åï¼å¾ãã«\Param{xkanjiskip}ã®
-æ¿å
¥ã許ããã©ããã®è¨å®ï¼
-以ä¸ã®ã許ãããï¼
+\verb+\ltjgetparameter{jacharrange}{+\verb+}+ ã¯ï¼ã\textbf{JAchar}éã®
+ç¯å²ãªãã°0ãï¼ããã§ãªããã°1ãè¿ãï¼ã$-1$çªã®æåç¯å²ãã¯åå¨ããªããï¼ã«$-1$ã
+æå®ãã¦ãã¨ã©ã¼ã¯çºçããªãï¼1ãè¿ãï¼ï¼
%
-\begin{description}
-%\item[0, \texttt{inhibit}] Insertion of \Param{xkanjiskip} is inhibited before the character, nor after the character.
-%\item[0, \texttt{inhibit}] \Param{xkanjiskip}ã®æ¿å
¥ã¯æåã®åï¼å¾ãã®ãããã§ãç¦æ¢ãããï¼
-%\item[1, \texttt{preonly}] Insertion of \Param{xkanjiskip} is allowed before the character, but not after.
-%\item[1, \texttt{preonly}] \Param{xkanjiskip}ã®æ¿å
¥ã¯æåã®åã§ã¯è¨±ããããï¼å¾ãã§ã¯è¨±ãããªãï¼
-%\item[2, \texttt{postonly}] Insertion of \Param{xkanjiskip} is allowed after the character, but not before.
-%\item[2, \texttt{postonly}] \Param{xkanjiskip}ã®æ¿å
¥ã¯æåã®å¾ãã§ã¯è¨±ããããï¼åã§ã¯è¨±ãããªãï¼
-%\item[3, \texttt{allow}] Insertion of \Param{xkanjiskip} is allowed both before the character and after the character. This is the default value.
-%\item[3, \texttt{allow}] \Param{xkanjiskip}ã®æ¿å
¥ã¯æåã®åï¼å¾ãã®ãããã§ã許ãããï¼ãããããã©ã«ãã®å¤ã§ããï¼
-\end{description}
+
+\item
%<*en>
-This parameter is similar to the \cs{inhibitxspcode} primitive of \pTeX, but not compatible with \cs{inhibitxspcode}.
+For an integer~ between 0~and~9,
+ \verb+\ltjgetparameter{kansujichar}{+\verb+}+ returns the character code
+of the result of \cs{kansuji}.
%
%<*ja>
-ãã®ãã©ã¡ã¼ã¿ã¯\pTeX ã® \cs{inhibitxspcode} ããªããã£ãã¨ä¼¼ã¦ãããï¼
-äºææ§ã¯ãªãï¼
+0--9ã®æ°ã«å¯¾ãã¦ï¼
+\verb+\ltjgetparameter{kansujichar}{+\verb+}+ ã¯ï¼\cs{kansuji}ã§åºåãã
+ ãæåã®æåã³ã¼ããè¿ãï¼
%
-\item[\DParam{alxspmode}\,=\{,\}$^\ast$] [\cs{xspcode}]\
+\item
%<*en>
-Set whether inserting \Param{xkanjiskip} is allowed before/after a
- \textbf{ALchar} whose character code is .
- The followings are allowed for :
+\verb+\ltjgetparameter{adjustdir}+ returns a integer which represents
+the direction of the surrounding vertical list.
+As \Param{direction}, the return value 1 means \emph{down-to-up} direction,
+3 means \emph{tate} direction (vertical typesetting),
+and 4 means \emph{yoko} direction (horizontal typesetting).
%
%<*ja>
-æåã³ã¼ããã®\textbf{ALchar}ã®åï¼å¾ãã«\Param{xkanjiskip}ã®
-æ¿å
¥ã許ããã©ããã®è¨å®ï¼
-以ä¸ã®ã許ãããï¼
+\verb+\ltjgetparameter{adjustdir}+ ã¯ï¼å¨å²ã®vboxã®çµæ¹åï¼è¨ãæããã°ï¼
+\cs{vadjust} ã§ç¨ããããçµæ¹åï¼ã表ãæ°å¤ãè¿ãï¼
+\Param{direction}ã¨åæ§ã«ï¼1㯠\cs{dtou} æ¹åãï¼
+3ã¯ç¸¦çµã¿ãï¼4ã¯æ¨ªçµã¿ã表ãï¼
%
-\begin{description}
-%\item[0, \texttt{inhibit}] Insertion of \Param{xkanjiskip} is inhibited before the character, nor after the character.
-%\item[0, \texttt{inhibit}] \Param{xkanjiskip}ã®æ¿å
¥ã¯æåã®åï¼å¾ãã®ãããã§ãç¦æ¢ãããï¼
-%\item[1, \texttt{preonly}] Insertion of \Param{xkanjiskip} is allowed before the character, but not after.
-%\item[1, \texttt{preonly}] \Param{xkanjiskip}ã®æ¿å
¥ã¯æåã®åã§ã¯è¨±ããããï¼å¾ãã§ã¯è¨±ãããªãï¼
-%\item[2, \texttt{postonly}] Insertion of \Param{xkanjiskip} is allowed after the character, but not before.
-%\item[2, \texttt{postonly}] \Param{xkanjiskip}ã®æ¿å
¥ã¯æåã®å¾ãã§ã¯è¨±ããããï¼åã§ã¯è¨±ãããªãï¼
-%\item[3, \texttt{allow}] Insertion of \Param{xkanjiskip} is allowed before the character and after the character. This is the default value.
-%\item[3, \texttt{allow}] \Param{xkanjiskip}ã®æ¿å
¥ã¯æåã®åï¼å¾ãã®ãããã§ã許ãããï¼ãããããã©ã«ãã®å¤ã§ããï¼
-\end{description}
+
+\item
%<*en>
-Note that parameters \Param{jaxspmode} and \Param{alxspmode} share a common table, hence these two parameters are synonyms of each other.
+For an integer~ between 0~and~65535,
+\verb+\ltjgetparameter{boxdim}{+\verb+}+ returns the direction of
+\cs{box}. If this box register is void, the returned value is zero.
%
%<*ja>
-\Param{jaxspmode}ã¨\Param{alxspmode}ã¯å
±éã®ãã¼ãã«ãç¨ãã¦ããããï¼
-ããã2ã¤ã®ãã©ã¡ã¼ã¿ã¯äºãã®å¥åã¨ãªã£ã¦ãããã¨ã«æ³¨æããï¼
+0--65535ã®æ°ã«å¯¾ãã¦ï¼
+\verb+\ltjgetparameter{boxdim}{+\verb+}+ ã¯ï¼\cs{box}ã«
+æ ¼ç´ããã¦ããããã¯ã¹ã®çµæ¹åã表ãï¼ãããã®ã¬ã¸ã¹ã¿ã空ã®å ´åã¯ï¼0ãè¿ãããï¼
%
-\item[\DParam{autospacing}\,=] [\cs{autospacing}]
-\item[\DParam{autoxspacing}\,=] [\cs{autoxspacing}]
-\item[\DParam{kanjiskip}\,=$^\ast$] [\cs{kanjiskip}]\
-
+\item
+%<*en>
+The following parameter names \emph{cannot be specified} in \cs{ltjgetparameter}.
+%
%<*ja>
-ããã©ã«ãã§2ã¤ã®\textbf{JAchar}ã®éã«æ¿å
¥ãããã°ã«ã¼ã§ããï¼
-é常ã§ã¯ï¼\pTeX ã¨åãããã«ãã©ã³ããµã¤ãºã«æ¯ä¾ãã¦å¤ãããã¨ã¯ãªãï¼
-ãããï¼èªç¶é·ã \cs{maxdimen} ã®å ´åã¯ï¼ä¾å¤çã«åæãã©ã³ãã®JFMå´ã§æå®ããã¦ãã
-å¤ãæ¡ç¨ï¼ãã¡ãã¯ãã©ã³ããµã¤ãºã«æ¯ä¾ï¼ãããã¨ã«ãªã£ã¦ããï¼
+次ã®ãã©ã¡ã¼ã¿åã \cs{ltjgetparameter} ã«æå®ãããã¨ã¯ã§ããªãï¼
%
+\begin{quote}
+\sffamily
+jatextfont, jascriptfont, jascriptscriptfont, jacharrange
+\end{quote}
+
+\item
%<*en>
-The default glue which inserted between two \textbf{JAchar}s.
-Changing current Japanese font does not alter this parameter, as \pTeX.
+\verb+\ltjgetparameter{chartorange}{+\verb+}+ returns
+the range number which belongs to
+(although there is no parameter named ``chartorange'').
-If the natural width of this parameter is \cs{maxdimen}, \LuaTeX-ja uses
-the value which is specified in the JFM for current Japanese font (See Subsection~\ref{ssec-jfm-str}).
+If is between 0 and 127, this does not belong to
+any character range. In this case,
+ \verb+\ltjgetparameter{chartorange}{+\verb+}+
+returns $-1$.
+
+Hence, one can know whether is \textbf{JAchar} or not
+by the following:
%
+%<*ja>
+\verb+\ltjgetparameter{chartorange}{+\verb+}+ ã«ãã£ã¦
+ã®å±ããæåç¯å²ã®çªå·ãç¥ããã¨ãã§ããï¼
-\item[\DParam{xkanjiskip}\,=$^\ast$] [\cs{xkanjiskip}]\
+ã«0--127ã®å¤ãæå®ããå ´åï¼ãã®ã¨ãï¼ãå±ãã
+æåç¯å²ã¯åå¨ããªãï¼ã¯$-1$ãè¿ãï¼
-%<*ja>
-ããã©ã«ãã§\textbf{JAchar}ã¨\textbf{ALchar}ã®éã«æ¿å
¥ãããã°ã«ã¼ã§ããï¼
-\Param{kanjiskip}ã¨åãããã«ï¼é常ã§ã¯ãã©ã³ããµã¤ãºã«æ¯ä¾ãã¦å¤ãããã¨ã¯ãªããï¼
-èªç¶é·ã \cs{maxdimen} ã®å ´åãä¾å¤ã§ããï¼
+ãã®ããï¼ã\textbf{JAchar}ã\textbf{ALchar}ãã¯
+次ã§ç¥ããã¨ãã§ããï¼
%
-%<*en>
-The default glue which inserted between a \textbf{JAchar} and an
- \textbf{ALchar}.
-Changing current font does not alter this parameter, as \pTeX.
+\begin{quote}
+\ttfamily \verb+\ltjgetparameter{jacharrange}{\ltjgetparameter{chartorange}{+%
+ \verb+}}+\\\null\hfill\verb+% 0 if JAchar, 1 if ALchar+
+\end{quote}
-As \Param{kanjiskip}, if the natural width of this parameter is \cs{maxdimen}, \LuaTeX-ja uses
-the value which is specified in the JFM for current Japanese font (See Subsection~\ref{ssec-jfm-str}).
+%<*en>
+\item Because the returned value is string, the following conditionals do not work
+if \Param{kanjiskip} (or~\Param{xkanjiskip}) has the stretch part or the shrink part.
+\begin{lstlisting}
+\ifdim\ltjgetparameter{kanjiskip}>\z@ ... \fi
+\ifdim\ltjgetparameter{xkanjiskip}>\z@ ... \fi
+\end{lstlisting}
+The correct way is using a temporary register.
+\begin{lstlisting}
+\@tempskipa=\ltjgetparameter{kanjiskip} \ifdim\@tempskipa>\z@ ... \fi
+\@tempskipa=\ltjgetparameter{xkanjiskip}\ifdim\@tempskipa>\z@ ... \fi
+\end{lstlisting}
%
+%<*ja>
+\item è¿ãå¤ãæååã§ãããã¨ããï¼\Param{kanjiskip}ã\Param{xkanjiskip}ãç´æ¥
+\ \cs{ifdim} ã使ã£ã¦æ¯è¼ãããã¨ã¯æã¾ãããªãï¼ä¼¸ã³éã縮ã¿éãæã£ã¦ããæã«ã¯ï¼
+次ã¯ã¨ã©ã¼ãçºçãããï¼
+\begin{lstlisting}
+\ifdim\ltjgetparameter{kanjiskip}>\z@ ... \fi
+\ifdim\ltjgetparameter{xkanjiskip}>\z@ ... \fi
+\end{lstlisting}
+ã¬ã¸ã¹ã¿ã«ä¸æ¦ä»£å
¥ããã®ãè¯ãï¼
+\begin{lstlisting}
+\@tempskipa=\ltjgetparameter{kanjiskip} \ifdim\@tempskipa>\z@ ... \fi
+\@tempskipa=\ltjgetparameter{xkanjiskip}\ifdim\@tempskipa>\z@ ... \fi
+\end{lstlisting}
+%
+
+\end{itemize}
+
+%<*ja>
+\subsection{\cs{ltjsetparameter} ã®ä»£æ¿}
+ååã¨ãã¦å種å
é¨ãã©ã¡ã¼ã¿ã®è¨å®ã«ã¯ \cs{ltjsetparameter} ãããã¯
+\ \cs{ltjglobalsetparameter}\ ãç¨ãããã¨ã«ãªããï¼
+\cs{ltjsetparameter} ã®å®è¡ã«ã¯æéããããã¨ããé£ç¹ãããï¼
+\LuaTeX-ja ã®å
é¨ã§ã¯ããé«éã«å®è¡ã§ããå¥ã®å½¢å¼ãç¨ãã¦ããï¼
+\emph{æ¬ç¯ã¯ä¸è¬å©ç¨è
ããã®å
容ã§ã¯ãªãï¼}
+
+\paragraph{\Param{kanjiskip}, \Param{xkanjiskip} ã®è¨å®}
+\pLaTeXe æ°ããã¥ã¡ã³ãã¯ã©ã¹ã§ã¯ï¼
+\begin{lstlisting}
+\def\@setfontsize#1#2#3{%
+ ...
+ \kanjiskip=0zw plus .1zw minus .01zw
+ \ifdim\xkanjiskip>\z@
+ \if@slide \xkanjiskip=0.1em \else
+ \xkanjiskip=0.25em plus 0.15em minus 0.06em
+ \fi
+ \fi}
+\end{lstlisting}
+ã¨ï¼ãã©ã³ããµã¤ãºãå¤æ´ãããã¨ã« \cs{kanjiskip}, \cs{xkanjiskip} ãå¤æ´ãã¦ããï¼
+ãã® \cs{@setfontsize} ã¯ææ¸ã®ä¸ã§å¤æ°åå®è¡ãããã®ã§ï¼
+\LuaTeX-ja ç¨ã«ç´ ç´ã«æ¸ãæãã
+\begin{lstlisting}
+ \ltjsetparameter{kanjiskip=0\zw plus .1\zw minus .01\zw}
+ \@tempskipa=\ltjgetparameter{xkanjiskip}
+ \ifdim\@tempskipa>\z@
+ \if@slide
+ \ltjsetparameter{xkanjiskip=0.1em}
+ \else
+ \ltjsetparameter{xkanjiskip=0.25em plus 0.15em minus 0.06em}
+ \fi
+ \fi
+\end{lstlisting}
+ã¨ããã®ã§ã¯ã¿ã¤ãã»ãããé
ããªã£ã¦ãã¾ãï¼
+ããã§ï¼\cs{ltjsetparameter} ã®ä¸ã§
+\begin{itemize}
+\item \cs{globaldefs} ã®å¤ãèªã¿åã \cs{ltj@setpar@global}
+\item \Param{kanjiskip} ã®è¨å®ãè¡ã \cs{ltjsetkanjiskip}
+\item \Param{xkanjiskip} ã®è¨å®ãè¡ã \cs{ltjsetxkanjiskip}
+\end{itemize}
+ãç¬ç«ããï¼\Pkg{ltjsclasses}ã§ã¯ï¼
+\begin{lstlisting}
+ \ltj@setpar@global
+ \ltjsetkanjiskip{\z@ plus .1\zw minus .01\zw}
+ \@tempskipa=\ltjgetparameter{xkanjiskip}
+ \ifdim\@tempskipa>\z@
+ \if@slide
+ \ltjsetxkanjiskip.1em
+ \else
+ \ltjsetxkanjiskip.25em plus .15em minus .06em
+ \fi
+ \fi
+\end{lstlisting}
+ã¨ãã¦ããï¼
+\cs{ltj@setpar@global}ãç´åã«å®è¡ããï¼åç¬ã§
+\cs{ltjsetkanjiskip}, \cs{ltjsetxkanjiskip}ãå®è¡ãããã¨ã¯æ³å®ããã¦ããªãã®ã§æ³¨æï¼
+
+
+
+\paragraph{ãã¼ã¹ã©ã¤ã³è£æ£éã®è¨å®}
+\pLaTeX ã®\Pkg{ascmac}ããã±ã¼ã¸ã§ã¯ï¼ç¸¦çµã®æ¬§æãã¼ã¹ã©ã¤ã³è£æ£éã®ä¸æå¾
é¿ã»å¾©å¸°å¦çã«
+\ \cs{@saveybaselineshift}\ ã¨ãã寸æ³ã¬ã¸ã¹ã¿ãç¨ã
+\begin{lstlisting}
+\@savetbaselineshift\tbaselineshift\tbaselineshift\z@
+...
+\tbaselineshift\@savetbaselineshift
+\end{lstlisting}
+ã¨ããå¦çãè¡ã£ã¦ããï¼
+
+ããã\LuaTeX-ja ç¨ã« \cs{ltjsetparameter} ã使ã£ã¦æ¸ãç´ãã¨ï¼
+\begin{lstlisting}
+\@savetbaselineshift\ltjgetparameter{talbaselineshift}
+\ltjsetparameter{talbaselineshift=\z@}
+...
+\ltjsetparameter{talbaselineshift=\@savetbaselineshift}
+\end{lstlisting}
+ã¨ãªãï¼
+
+ãã¦ï¼ç¸¦çµã®æ¬§æãã¼ã¹ã©ã¤ã³è£æ£é\Param{talbaselineshift}ã¯ï¼
+å®éã«ã¯ \cs{ltj@tablshift} ã¨ããå±æ§ã¬ã¸ã¹ã¿ã«æ ¼ç´ããã¦ãã
+ï¼\ref{sec-para}\nobreak ç¯åç
§ï¼ï¼å±æ§ã¬ã¸ã¹ã¿ã¯é·ãã§ã¯ãªãæ´æ°å¤ãæ ¼ç´ãã\footnote{%
+ å¾ã£ã¦ï¼\texttt{\textbackslash @savetbaselineshift=\textbackslash ltj@tablshift}\
+ ã®ããã«è¨è¿°ãããã¨ã¯ã§ããªãï¼å±æ§ã¬ã¸ã¹ã¿ã \cs{tbaselineshift} ã¨ããå称ã«ããªãã£
+ ãã®ã¯ãã®ããã§ããï¼
+}ãã®ã§ããï¼\cs{ltj@tablshift} ã¯è£æ£éã sp åä½ã§ä¿æãããã¨ããï¼
+ä¸è¨ã®ã³ã¼ãã¨åãå
容ãããéã以ä¸ã®ã³ã¼ãã§å®ç¾ãããã¨ãã§ããï¼
+\begin{lstlisting}
+\@savetbaselineshift\ltj@tablshift sp%
+\ltj@tablshift\z@
+...
+\ltj@tablshift\@savetbaselineshift
+\end{lstlisting}
+ãã®ææ³ã¯ \Pkg{ascmac} ããã±ã¼ã¸ã®\LuaTeX-ja対å¿ããã \Pkg{lltjp-tascmac.sty} ã§
+å®éã«ç¨ãããã¦ããï¼\Pkg{lltjp-tascmac.sty} ã¯èªåçã«èªã¿è¾¼ã¾ããã®ã§ï¼
+ã¦ã¼ã¶ã¯ä½ãæ°ã«ããæ®éã« \Pkg{ascmac} ããã±ã¼ã¸ã \cs{usepackage} ã§èªã¿ããã°è¯ãï¼
+%
-\item[\DParam{differentjfm}\,=$^\dagger$]\
+%\section{Other Commands for plain \TeX\ and \LaTeXe}
+%\section{plainã§ã\LaTeX ã§ãå©ç¨å¯è½ãªãã®ä»ã®å½ä»¤}
+%\subsection{Commands for compatibility with \pTeX}
+%\subsection{\pTeX äºæç¨å½ä»¤}
%<*en>
-Specify how glues/kerns between two \textbf{JAchar}s whose JFM (or size) are different.
-The allowed arguments are the followings:
+The following commands are implemented for compatibility with \pTeX.
+Note that the former five commands don't support JIS~X~0213, but only JIS~X~0208.
+The last \cs{kansuji} converts an integer into its Chinese numerals.
%
%<*ja>
-JFMï¼ãããã¯ãµã¤ãºï¼ãç°ãªã2ã¤ã®\textbf{JAchar}ã®éã«ã°ã«ã¼ï¼ã«ã¼ã³ãã©ã®ããã«
-å
¥ããããæå®ããï¼
-許ãããå¤ã¯ä»¥ä¸ã®éãï¼
+以ä¸ã®å½ä»¤ã¯\pTeX ã¨ã®äºææ§ã®ããã«å®è£
ããã¦ããï¼ãã®ããï¼JIS~X~0213ã«ã¯å¯¾å¿ããï¼
+\pTeX ã¨åãããã«JIS~X~0208ã®ç¯å²ãããµãã¼ããã¦ããªãï¼
%
-\begin{quote}
-\texttt{average},
-\texttt{both},
-\texttt{large},
-\texttt{small},
-\texttt{pleft},
-\texttt{pright},
-\texttt{paverage}
-\end{quote}
+\begin{center}
+\cs{kuten}, \cs{jis}, \cs{euc}, \cs{sjis}, \cs{ucs}, \cs{kansuji}
+\end{center}
%<*en>
-The default value is \texttt{paverage}. \dots
+These six commands takes an internal integer, and returns a \emph{string}.
%
%<*ja>
-ããã©ã«ãå¤ã¯ \texttt{paverage} ã§ããï¼
-åã
ã®å¤ã«ããå·®ç°ã®è©³ç´°ã¯\ref{ssec-cluster-wa}ç¯ã®ããå³ç©ºç½ãã®ç®åºããåç
§ãã¦ã»ããï¼
+ããã6å½ä»¤ã¯å
é¨æ´æ°ãå¼æ°ã¨ãããï¼å®è¡çµæã¯\textbf{æåå}ã§ãããã¨ã«æ³¨æï¼
%
-
-\item[\DParam{jacharrange}\,=]
-\item[\DParam{kansujichar}\,=\{, \}$^\ast$] [\cs{kansujichar}]
-
-\item[\DParam{direction}\,=\ \hbox{\rm (always local)}]\
+\begin{LTXexample}
+\newcount\hoge
+\hoge="2423 %"
+\the\hoge, \kansuji\hoge\\
+\jis\hoge, \char\jis\hoge\\
+\kansuji1701
+\end{LTXexample}
%<*en>
-Assigning to this parameter has the same effect as
-\cs{yoko}~(if $\hbox{}=4$), \cs{tate}~(if $\hbox{}=3$),
-\cs{dtou}~(if $\hbox{}=1$) or \cs{utod}~(if $\hbox{}=11$).
-If the argument is not one of 4,~3, 1~nor~11,
-the behavior of this assignment is undefined.
+To change characters of Chinese numerals for each digit, set \Param{kansujichar} parameter:
+\begin{LTXexample}
+\ltjsetparameter{kansujichar={1,`壹}}
+\ltjsetparameter{kansujichar={7,`æ¼}}
+\ltjsetparameter{kansujichar={0,`é¶}}
+\kansuji1701
+\end{LTXexample}
%
-%<*ja>
-çµæ¹åãå¤æ´ãã \cs{yoko}~(if $\hbox{}=4$), \cs{tate}~(if $\hbox{}=3$),
-\cs{dtou}~(if $\hbox{}=1$), \cs{utod}~(if $\hbox{}=11$) ã¨åãå½¹å²ãæã¤ï¼
-å©ç¨å¯è½ãªç¶æ³ãããã4å½ä»¤ã¨åä¸ã§ããï¼å¼æ°ã4,~3, 1,~11ã®ãããã§ãç¡ãã¨ãã®
-åä½ã¯æªå®ç¾©ã§ããï¼
-%
-
-\end{cslist}
-\subsection{\cs{ltjgetparameter}}
-\label{ssec-getpar}
+\subsection{\cs{inhibitglue}}
%<*en>
-\cs{ltjgetparameter} is a control sequence for acquiring parameters. It
-always takes a parameter name as first argument.
+\cs{inhibitglue} suppresses the insertion of \textbf{JAglue}.
+The following is an example, using a special JFM that there will be a glue between
+the beginning of a box and ``ã'', and also between ``ã''~and~``ã¦''.
%
%<*ja>
-\cs{ltjgetparameter} ã¯ãã©ã¡ã¼ã¿ã®å¤ãåå¾ããããã®å½ä»¤ã§ããï¼
-常ã«ãã©ã¡ã¼ã¿ã®ååã第ä¸å¼æ°ã«ã¨ãï¼
+\cs{inhibitglue} ã¯\textbf{JAglue}ã®æ¿å
¥ãæå¶ããï¼
+以ä¸ã¯ï¼ããã¯ã¹ã®å§ãã¨ãããã®éï¼ããããã¦ãã®éã«ã°ã«ã¼ãå
¥ãç¹å¥ãªJFMãç¨ããä¾ã§
+ããï¼
%
-\begin{LTXexample}
-\ltjgetparameter{differentjfm},
-\ltjgetparameter{autospacing},
-\ltjgetparameter{kanjiskip},
-\ltjgetparameter{prebreakpenalty}{`ï¼}.
+
+\begin{LTXexample}[width=0.4\textwidth]
+\jfont\g=file:KozMinPr6N-Regular.otf:jfm=test \g
+\fbox{\hbox{ãã¦ã\inhibitglue ã¦}}
+\inhibitglue\par\noindent ã1
+\par\inhibitglue\noindent ã2
+\par\noindent\inhibitglue ã3
+\par\hrule\noindent ãoff\inhibitglue ice
\end{LTXexample}
%<*en>
-\emph{The return value of\/ \cs{ltjgetparameter} is
-always a string}, which is outputted by \texttt{tex.write()}.
-Hence any character other than space~``\texttt{\char32}''~(\texttt{U+0020}) has the category code
-12~(other), while the space has 10~(space).
+With the help of this example, we remark the specification of \cs{inhibitglue}:
%
%<*ja>
-\emph{\cs{ltjgetparameter} ã®æ»ãå¤ã¯å¸¸ã«æååã§ããï¼}
-ããã¯\texttt{tex.write()}ã«ãã£ã¦åºåãã¦ããããã§ï¼ç©ºç½ã\texttt{\char32}ã
-(\texttt{U+0020})ãé¤ããæåã®ã«ãã´ãªã¼ã³ã¼ãã¯å
¨ã¦12~(other)ã¨ãªãï¼
-ä¸æ¹ï¼ç©ºç½ã®ã«ãã´ãªã¼ã³ã¼ãã¯10~(space)ã§ããï¼
+ãã®ä¾ãæ´ç¨ãã¦ï¼\cs{inhibitglue} ã®ä»æ§ã«ã¤ãã¦è¿°ã¹ãï¼
%
-
\begin{itemize}
-\item
-%<*en>
-If first argument is one of the
-following, no additional argument is needed.
-%
-%<*ja>
-第1å¼æ°ã次ã®ããããã®å ´åã«ã¯ï¼è¿½å ã®å¼æ°ã¯å¿
è¦ãªãï¼
-%
-\begin{quote}
-\sffamily
-jcharwidowpenalty, yjabaselineshift, yalbaselineshift, autospacing, autoxspacing,\\
-kanjiskip, xkanjiskip, differentjfm, direction
-\end{quote}
%<*en>
-Note that \verb+\ltjgetparameter{autospacing}+~and~\verb+\ltjgetparameter{autoxspacing}+
-returns 1 or 0, not
-\texttt{true}~nor~\texttt{false}.
+\item The call of \cs{inhibitglue} in the (internal) vertical mode is
+ simply ignored.
%
%<*ja>
-\verb+\ltjgetparameter{autospacing}+ 㨠\verb+\ltjgetparameter{autoxspacing}+ ã¯ï¼
-\texttt{true}ã\texttt{false}ãè¿ãã®\emph{ã§ã¯ãªã}ï¼
-1ã0ã®ãããããè¿ããã¨ã«æ³¨æï¼
+\item \emph{\cs{inhibitglue} ã®åç´ã¢ã¼ãä¸ã§ã®å¼ã³åºãã¯æå³ãæããªã}\footnote{%
+ ãã®ç¹ã¯\TeX~Live~2014ã§ã®\pTeX ã«ããã \cs{inhibitglue} ã®ä»æ§å¤æ´ã¨åãã§ããï¼
+}ï¼
+4è¡ç®ã®å
¥åã§æå¹ã«ãªããªãã®ã¯ï¼\cs{inhibitglue} ã®æç¹ã§ã¯åç´ã¢ã¼ãã§ããï¼
+\cs{noindent} ã®æç¹ã§æ°´å¹³ã¢ã¼ãã«ãªãããã§ããï¼
%
-\item
-%<*en>
-If first argument is one of the
-following, an additional argument---a character code, for example---is needed.
-%
-%<*ja>
-第1å¼æ°ã次ã®ããããã®å ´åã«ã¯ï¼ããã«æåã³ã¼ãã第2å¼æ°ã¨ãã¦ã¨ãï¼
-%
-\begin{quote}
-\sffamily
-kcatcode, prebreakpenalty, postbreakpenalty, jaxspmode, alxspmode
-\end{quote}
%<*en>
-\verb+\ltjgetparameter{jaxspmode}{...}+~and~\verb+\ltjgetparameter{alxspmode}{...}+
-returns 0,~1, 2,~or~3, instead of \texttt{preonly} etc.
+\item The call of \cs{inhibitglue} in the (restricted) horizontal
+ mode is only effective on the spot; does not get over boundary of
+ paragraphs. Moreover, \cs{inhibitglue} cancels ligatures and
+ kernings, as shown in the last line of above example.
%
%<*ja>
-\verb+\ltjgetparameter{jaxspmode}{...}+ ã \verb+\ltjgetparameter{alxspmode}{...}+\
-ã¯ï¼\texttt{preonly} ãªã©ã¨ãã£ãæååã§ã¯ãªãï¼0ãã3ã¾ã§ã®å¤ãè¿ãï¼
+\item \cs{inhibitglue} ã®ï¼å¶éãããï¼æ°´å¹³ã¢ã¼ãä¸ã§ã®å¼ã³åºãã¯ãã®å ´ã§ã®ã¿
+ æå¹ã§ããï¼æ®µè½ã®å¢çãä¹ãè¶ããªãï¼
+ ããã«ï¼\cs{inhibitglue} ã¯ä¸ã®ä¾ã®æçµè¡ã®ããã«ï¼æ¬§æã«ãããï¼ãªã¬ãã£ã¨ã«ã¼ãã³ã°ã
+ æã¡æ¶ãï¼ããã¯ï¼\cs{inhibitglue} ãå
é¨çã«ã¯ãç¾å¨ã®ãªã¹ãä¸ã«whatsitãã¼ãã
+ 追å ããããã¨ãè¡ãªã£ã¦ããããã§ããï¼
%
-\item
%<*en>
-\verb+\ltjgetparameter{jacharrange}{+\verb+}+ returns \texttt{0}
-if ``characters which belong to the character range~ are \textbf{JAchar}'',
-\texttt{1} if ``\dots~are \textbf{ALchar}''.
-Although there is no character range~$-1$, specifying $-1$ to does not cause an
- error (returns 1).
+\item The call of \cs{inhibitglue} in math mode is just ignored.
%
%<*ja>
-\verb+\ltjgetparameter{jacharrange}{+\verb+}+ ã¯ï¼ã\textbf{JAchar}éã®
-ç¯å²ãªãã°0ãï¼ããã§ãªããã°1ãè¿ãï¼ã$-1$çªã®æåç¯å²ãã¯åå¨ããªããï¼ã«$-1$ã
-æå®ãã¦ãã¨ã©ã¼ã¯çºçããªãï¼1ãè¿ãï¼ï¼
+\item \cs{inhibitglue} ãæ°å¼ã¢ã¼ãä¸ã§å¼ã³åºããå ´åã¯ãã ç¡è¦ãããï¼
%
-\item
-%<*en>
-For an integer~ between 0~and~9,
- \verb+\ltjgetparameter{kansujichar}{+\verb+}+ returns the character code
-of the result of \cs{kansuji}.
-%
%<*ja>
-0--9ã®æ°ã«å¯¾ãã¦ï¼
-\verb+\ltjgetparameter{kansujichar}{+\verb+}+ ã¯ï¼\cs{kansuji}ã§åºåãã
- ãæåã®æåã³ã¼ããè¿ãï¼
+\item \LaTeX ã§\LuaTeX-ja ã使ç¨ããå ´åã¯ï¼
+\cs{inhibitglue} ã®ä»£ããã¨ã㦠\verb+\<+ ã使ããã¨ãã§ããï¼
+æ¢ã« \verb+\<+ ãå®ç¾©ããã¦ããå ´åã¯ï¼\LuaTeX-ja ã®èªã¿è¾¼ã¿ã§å¼·å¶çã«ä¸æ¸ããããã®ã§
+注æãããã¨ï¼
%
+\end{itemize}
-\item
+
+\subsection{\cs{ltjfakeboxbdd}, \cs{ltjfakeparbegin}}
%<*en>
-\verb+\ltjgetparameter{adjustdir}+ returns a integer which represents
-the direction of the surrounding vertical list.
-As \Param{direction}, the return value 1 means \emph{down-to-up} direction,
-3 means \emph{tate} direction (vertical typesetting),
-and 4 means \emph{yoko} direction (horizontal typesetting).
+Sometimes \texttt{'parbdd'}~and~\texttt{'boxbdd'} specifications~look like ``fail'',
+especially in paragraphs inside list environments.
+This is because \cs{everypar} inserts some nodes such as boxes and kerns, so
+the ``first letter'' in a paragraph is in fact not the first letter.
%
%<*ja>
-\verb+\ltjgetparameter{adjustdir}+ ã¯ï¼å¨å²ã®vboxã®çµæ¹åï¼è¨ãæããã°ï¼
-\cs{vadjust} ã§ç¨ããããçµæ¹åï¼ã表ãæ°å¤ãè¿ãï¼
-\Param{direction}ã¨åæ§ã«ï¼1㯠\cs{dtou} æ¹åãï¼
-3ã¯ç¸¦çµã¿ãï¼4ã¯æ¨ªçµã¿ã表ãï¼
+ãªã¹ãç°å¢å
ã§ã®\cs{item}ã§å§ã¾ãåé
ç®ãªã©ã§ã¯ï¼
+ã段è½æåã®éµæ¬å¼§ãä½è¨ã«åè§åä¸ããããããªã©ï¼
+JFMã«ãã\texttt{'parbdd'}, \texttt{'boxbdd'}ã®æå®ãè¦ããä¸ç ´ç¶»ãã¦ãããã¨ãããï¼
+
+ããã¯\TeX ã\cs{everypar}ãç¨ãã¦æ®µè½éå§æã«è¨å·é¡ã空ç½ãªã©ãæ¿å
¥ãã¦ãã¾ã£ã¦ããããï¼
+段è½æåã®éµæ¬å¼§ãå®éã«ã¯æ®µè½æåã®ãã¼ãã§ã¯ãªããã¨ã«èµ·å ããï¼ä»¥ä¸ã«ä¾ã示ããï¼
%
+\begin{LTXexample}[width=0.3\textwidth]
+\parindent1\zw
+\noindent ãããããããã\par % for comparison
+ããããããã \par % normal paragraph
-\item
+\everypar{\null}
+ããããããã \par % ???
+\end{LTXexample}
%<*en>
-For an integer~ between 0~and~65535,
-\verb+\ltjgetparameter{boxdim}{+\verb+}+ returns the direction of
-\cs{box}. If this box register is void, the returned value is zero.
+\cs{ltjfakeboxbdd}~and~\cs{ltjfakeparbegin} primitives resolve this situation.
+\begin{itemize}
+ \item \cs{ltjfakeparbegin} creates a node which indicates
+ ``beginning of an indented paragraph'' to the insertion process of \textbf{JAglue}.
+ \item \cs{ltjfakeboxbdd} creates a node which indicates
+ ``beginning/ending of a box'' to the insertion process of \textbf{JAglue}.
+\end{itemize}
+As an example, the example above can be improved as follows:
%
%<*ja>
-0--65535ã®æ°ã«å¯¾ãã¦ï¼
-\verb+\ltjgetparameter{boxdim}{+\verb+}+ ã¯ï¼\cs{box}ã«
-æ ¼ç´ããã¦ããããã¯ã¹ã®çµæ¹åã表ãï¼ãããã®ã¬ã¸ã¹ã¿ã空ã®å ´åã¯ï¼0ãè¿ãããï¼
+\cs{ltjfakeboxbdd}, \cs{ltjfakeparbegin}ã¯ãã®ç¶æ³ãæ¹åããå½ä»¤ã§ããï¼
+å®éã«ã¯\cs{everypar}ã®æ«å°¾ã«ãããã追å ããã¨ãã使ãæ¹ãã»ã¨ãã©ã«ãªãã ããï¼
+\begin{itemize}
+ \item \cs{ltjfakeparbegin}ã¯ï¼å®è¡ãããç®æããã¤ã³ãã³ããã段è½ã®éå§ãã§ããã¨\LuaTeX-jaã®
+ åæå¦çã°ã«ã¼æ¿å
¥å¦çã«èªèãããï¼ãã®å½ä»¤ã®ç´åã«\textbf{JAchar}ããã£ãå ´åï¼
+ ãã®æåã®å¾ãã«å
¥ãã°ã«ã¼çã®å¦çã«ã¤ãã¦ã¯æªå®ç¾©ã§ãã
+ \footnote{%
+ ãã®å½ä»¤ã¨åçã®å
容ã¯ï¼\cs{dirrctlua}ã®å½¢ã§\Pkg{ltjsclasses}å
ã§ä»¥åãã使ããã¦ããï¼
+ ä¸è¬ã¦ã¼ã¶ã§ãå©ç¨ããããããããï¼ãã¼ã¸ã§ã³20170505.0ã§æ°ãã«å½ä»¤ã¨ãã¦å®ç¾©ããï¼
+ }ï¼
+ \item \cs{ltjfakeboxbdd}ã¯ï¼å®è¡ãããç®æããããã¯ã¹ã®å
é ã¨æ«å°¾ãã§ããã¨\LuaTeX-jaã®
+ åæå¦çã°ã«ã¼æ¿å
¥å¦çã«èªèãããï¼
+\end{itemize}
+ä¾ãã°ï¼å
ã»ã©ã®ä¾ã«å¯¾ãã¦é©ç¨ããã¨ï¼æ¬¡ã®ããã«ãªãï¼
%
+\begin{LTXexample}[width=0.3\textwidth]
+\parindent1\zw
+\noindent ãããããããã\par % for comparison
+ããããããã \par % normal paragraph
-\item
+\everypar{\null\ltjfakeparbegin}
+ããããããã \par
+\end{LTXexample}
+
+
+\subsection{\cs{ltjdeclarealtfont}}
+\label{ssec-altfont}
%<*en>
-The following parameter names \emph{cannot be specified} in \cs{ltjgetparameter}.
-%
-%<*ja>
-次ã®ãã©ã¡ã¼ã¿åã \cs{ltjgetparameter} ã«æå®ãããã¨ã¯ã§ããªãï¼
-%
+Using \cs{ltjdeclarealtfont}, one can ``compose'' more than one Japanese fonts.
+This \cs{ltjdeclarealtfont} uses in the following form:
\begin{quote}
-\sffamily
-jatextfont, jascriptfont, jascriptscriptfont, jacharrange
+\ttfamily \textbackslash ltjdeclarealtfont\{\}
\end{quote}
+where ~and~ are defined by \cs{jfont}.
+Its meaning is
+\begin{quote}
+If the current Japanese font is , characters which belong to
+is typeset by another Japanese font , instead of .
+\end{quote}
+Here is a comma-separated list of character codes, but also accepts negative integers:
+$-n$~($nâ¥1$) means that all characters of character classes~$n$, with respect to JFM used
+by . Note that characters which do not exist in are
+ignored.
-\item
-%<*en>
-\verb+\ltjgetparameter{chartorange}{+\verb+}+ returns
-the range number which belongs to
-(although there is no parameter named ``chartorange'').
-
-If is between 0 and 127, this does not belong to
-any character range. In this case,
- \verb+\ltjgetparameter{chartorange}{+\verb+}+
-returns $-1$.
-
-Hence, one can know whether is \textbf{JAchar} or not
-by the following:
+For example, if \cs{hoge} uses \texttt{jfm-ujis.lua}, the standard JFM of \LuaTeX-ja,
+then
+\begin{lstlisting}
+\ltjdeclarealtfont\hoge\piyo{"3000-"30FF, {-1}-{-1}}
+\end{lstlisting}
+does
+\begin{quote}
+If the current Japanese font is \cs{hoge}, \texttt{U+3000}--\texttt{U+30FF}
+and characters in class~1 (ideographic opening brackets)
+are typeset by \cs{piyo}.
+\end{quote}
%
%<*ja>
-\verb+\ltjgetparameter{chartorange}{+\verb+}+ ã«ãã£ã¦
-ã®å±ããæåç¯å²ã®çªå·ãç¥ããã¨ãã§ããï¼
-
-ã«0--127ã®å¤ãæå®ããå ´åï¼ãã®ã¨ãï¼ãå±ãã
-æåç¯å²ã¯åå¨ããªãï¼ã¯$-1$ãè¿ãï¼
+\cs{jfont} ã®æ¸å¼ãè¦ãã°ãããããã«ï¼åºæ¬çã«ã¯\LuaTeX-jaã«ããã1ã¤ã®åæãã©ã³ãã«
+使ç¨åºæ¥ããå®éã®ãã©ã³ããã¯1ã¤ã§ããï¼
+ãããï¼\cs{ltjdeclarealtfont} ãç¨ããã¨ï¼ãã®ååããå¤ãããã¨ãã§ããï¼
-ãã®ããï¼ã\textbf{JAchar}ã\textbf{ALchar}ãã¯
-次ã§ç¥ããã¨ãã§ããï¼
-%
+\cs{ltjdeclarealtfont} ã¯ä»¥ä¸ã®æ¸å¼ã§ä½¿ç¨ããï¼
\begin{quote}
-\ttfamily \verb+\ltjgetparameter{jacharrange}{\ltjgetparameter{chartorange}{+%
- \verb+}}+\\\null\hfill\verb+% 0 if JAchar, 1 if ALchar+
+\ttfamily \textbackslash ltjdeclarealtfont\{\}
\end{quote}
+ããã¯ãç¾å¨ã®åæãã©ã³ãããã§ããã¨ãï¼
+ã«å±ããæåã¯ãç¨ãã¦çµçãããï¼ã¨ããæå³ã§ããï¼
+\begin{itemize}
+ \item , ã¯
+\cs{jfont} ã«ãã£ã¦å®ç¾©ãããåæãã©ã³ãã§ããï¼
+ \item ã¯æåã³ã¼ãã®ç¯å²ã表ãã³ã³ãåºåãã®ãªã¹ãã§ãããï¼
+ ä¾å¤ã¨ãã¦è² æ°$-n$ã¯ãã®JFMã®æåã¯ã©ã¹$n$ã«å±ããå
¨ã¦ã®æåã
+ ãæå³ããï¼
-%<*en>
-\item Because the returned value is string, the following conditionals do not work
-if \Param{kanjiskip} (or~\Param{xkanjiskip}) has the stretch part or the shrink part.
-\begin{lstlisting}
-\ifdim\ltjgetparameter{kanjiskip}>\z@ ... \fi
-\ifdim\ltjgetparameter{xkanjiskip}>\z@ ... \fi
-\end{lstlisting}
-The correct way is using a temporary register.
-\begin{lstlisting}
-\@tempskipa=\ltjgetparameter{kanjiskip} \ifdim\@tempskipa>\z@ ... \fi
-\@tempskipa=\ltjgetparameter{xkanjiskip}\ifdim\@tempskipa>\z@ ... \fi
-\end{lstlisting}
-%
-%<*ja>
-\item è¿ãå¤ãæååã§ãããã¨ããï¼\Param{kanjiskip}ã\Param{xkanjiskip}ãç´æ¥
-\ \cs{ifdim} ã使ã£ã¦æ¯è¼ãããã¨ã¯æã¾ãããªãï¼ä¼¸ã³éã縮ã¿éãæã£ã¦ããæã«ã¯ï¼
-次ã¯ã¨ã©ã¼ãçºçãããï¼
-\begin{lstlisting}
-\ifdim\ltjgetparameter{kanjiskip}>\z@ ... \fi
-\ifdim\ltjgetparameter{xkanjiskip}>\z@ ... \fi
-\end{lstlisting}
-ã¬ã¸ã¹ã¿ã«ä¸æ¦ä»£å
¥ããã®ãè¯ãï¼
+ä¸ã«ä¸ã«å®éã«ã¯åå¨ããªãæåãæå®ãããå ´åã¯ï¼
+ãã®æåã«å¯¾ããè¨å®ã¯ç¡è¦ãããï¼
+\end{itemize}
+
+ä¾ãã°ï¼\cs{hoge} ã®JFMã\LuaTeX-jaæ¨æºã®
+\ \texttt{jfm-ujis.lua} ã§ãã£ãå ´åï¼
\begin{lstlisting}
-\@tempskipa=\ltjgetparameter{kanjiskip} \ifdim\@tempskipa>\z@ ... \fi
-\@tempskipa=\ltjgetparameter{xkanjiskip}\ifdim\@tempskipa>\z@ ... \fi
+\ltjdeclarealtfont\hoge\piyo{"3000-"30FF, {-1}-{-1}}
\end{lstlisting}
+ã¯ã\cs{hoge} ãå©ç¨ãã¦ããã¨ãï¼
+\texttt{U+3000}--\texttt{U+30FF}ã¨
+æåã¯ã©ã¹1ï¼éãæ¬å¼§é¡ï¼ä¸ã®æåã ã㯠\cs{piyo} ãç¨ããã
+ãã¨ãè¨å®ããï¼\verb+{-1}-{-1}+ ã¨ããå¤ãã£ãæå®ã®ä»æ¹ããã¦ããã®ã¯ï¼
+æ®éã« \texttt{-1} ã¨æå®ããã®ã§ã¯æ£ãã$-1$ã¨èªã¿åãããªãã¨ãã
+ãã¯ãã®é½åã«ããï¼
%
-\end{itemize}
-
%<*ja>
-\subsection{\cs{ltjsetparameter} ã®ä»£æ¿}
-ååã¨ãã¦å種å
é¨ãã©ã¡ã¼ã¿ã®è¨å®ã«ã¯ \cs{ltjsetparameter} ãããã¯
-\ \cs{ltjglobalsetparameter}\ ãç¨ãããã¨ã«ãªããï¼
-\cs{ltjsetparameter} ã®å®è¡ã«ã¯æéããããã¨ããé£ç¹ãããï¼
-\LuaTeX-ja ã®å
é¨ã§ã¯ããé«éã«å®è¡ã§ããå¥ã®å½¢å¼ãç¨ãã¦ããï¼
-\emph{æ¬ç¯ã¯ä¸è¬å©ç¨è
ããã®å
容ã§ã¯ãªãï¼}
+\subsection{\cs{ltjalchar} 㨠\cs{ltjjachar}}
+æåã³ã¼ãã$\text{}~(\geq 128=\mathtt{0x80})$ã®æåã
+\ \cs{char} ããªããã£ãã使ã \cs{char} ã¨ãã¦åºåãããã¨ï¼
+ãã®æåã®å±ããæåç¯å²ï¼\ref{ssec-setrange}ç¯åç
§ï¼ã«ãã£ã¦
+\textbf{ALchar}ã\textbf{JAchar}ãï¼ã¤ã¾ã欧æãã©ã³ãã§åºåããããåæãã©ã³ãã§åºåãã
+ããã決ã¾ãï¼
-\paragraph{\Param{kanjiskip}, \Param{xkanjiskip} ã®è¨å®}
-\pLaTeXe æ°ããã¥ã¡ã³ãã¯ã©ã¹ã§ã¯ï¼
-\begin{lstlisting}
-\def\@setfontsize#1#2#3{%
- ...
- \kanjiskip=0zw plus .1zw minus .01zw
- \ifdim\xkanjiskip>\z@
- \if@slide \xkanjiskip=0.1em \else
- \xkanjiskip=0.25em plus 0.15em minus 0.06em
- \fi
- \fi}
-\end{lstlisting}
-ã¨ï¼ãã©ã³ããµã¤ãºãå¤æ´ãããã¨ã« \cs{kanjiskip}, \cs{xkanjiskip} ãå¤æ´ãã¦ããï¼
-ãã® \cs{@setfontsize} ã¯ææ¸ã®ä¸ã§å¤æ°åå®è¡ãããã®ã§ï¼
-\LuaTeX-ja ç¨ã«ç´ ç´ã«æ¸ãæãã
-\begin{lstlisting}
- \ltjsetparameter{kanjiskip=0\zw plus .1\zw minus .01\zw}
- \@tempskipa=\ltjgetparameter{xkanjiskip}
- \ifdim\@tempskipa>\z@
- \if@slide
- \ltjsetparameter{xkanjiskip=0.1em}
- \else
- \ltjsetparameter{xkanjiskip=0.25em plus 0.15em minus 0.06em}
- \fi
- \fi
-\end{lstlisting}
-ã¨ããã®ã§ã¯ã¿ã¤ãã»ãããé
ããªã£ã¦ãã¾ãï¼
-ããã§ï¼\cs{ltjsetparameter} ã®ä¸ã§
-\begin{itemize}
-\item \cs{globaldefs} ã®å¤ãèªã¿åã \cs{ltj@setpar@global}
-\item \Param{kanjiskip} ã®è¨å®ãè¡ã \cs{ltjsetkanjiskip}
-\item \Param{xkanjiskip} ã®è¨å®ãè¡ã \cs{ltjsetxkanjiskip}
-\end{itemize}
-ãç¬ç«ããï¼\Pkg{ltjsclasses}ã§ã¯ï¼
-\begin{lstlisting}
- \ltj@setpar@global
- \ltjsetkanjiskip{\z@ plus .1\zw minus .01\zw}
- \@tempskipa=\ltjgetparameter{xkanjiskip}
- \ifdim\@tempskipa>\z@
- \if@slide
- \ltjsetxkanjiskip.1em
- \else
- \ltjsetxkanjiskip.25em plus .15em minus .06em
- \fi
- \fi
-\end{lstlisting}
-ã¨ãã¦ããï¼
-\cs{ltj@setpar@global}ãç´åã«å®è¡ããï¼åç¬ã§
-\cs{ltjsetkanjiskip}, \cs{ltjsetxkanjiskip}ãå®è¡ãããã¨ã¯æ³å®ããã¦ããªãã®ã§æ³¨æï¼
+æåç¯å²ã®è¨å®ãç¡è¦ãï¼æåã³ã¼ãã$\text{}~(\geq 128=\mathtt{0x80})$ã®æåãå¼·å¶çã«
+\textbf{ALchar}, \textbf{JAchar}ã§åºåããå½ä»¤ããããã
+\ \cs{ltjalchar},~\cs{ltjjachar} ã§ããï¼ä½¿ç¨æ¹æ³ã¯ \cs{char} ã¨åãã
+\ \cs{ltjalchar}, \cs{ltjjachar}ã¨ããã°ããï¼
+ã127以ä¸ã®å ´åã¯ï¼\cs{ltjjachar} ã§ãã£ã¦ã\textbf{ALchar}ã¨ãã¦åºåããããã¨
+ã«æ³¨æï¼
+以ä¸ã¯\ref{ssec-setrange}ç¯ã«è¼ããä¾ã«ï¼\cs{char} ã®åä½ã追å ãããã®ã§ããï¼
+\begin{LTXexample}[width=0.25\textwidth]
+\gtfamily\large % default, ALchar, JAchar
+¶, \char`¶, \ltjalchar`¶, \ltjjachar`¶\\ % default: ALchar
+α, \char`α, \ltjalchar`α, \ltjjachar`α % default: JAchar
+\end{LTXexample}
+%
+%\section{Commands for \LaTeXe}
+%\section{\LaTeXe ç¨ã®å½ä»¤}
-\paragraph{ãã¼ã¹ã©ã¤ã³è£æ£éã®è¨å®}
-\pLaTeX ã®\Pkg{ascmac}ããã±ã¼ã¸ã§ã¯ï¼ç¸¦çµã®æ¬§æãã¼ã¹ã©ã¤ã³è£æ£éã®ä¸æå¾
é¿ã»å¾©å¸°å¦çã«
-\ \cs{@saveybaselineshift}\ ã¨ãã寸æ³ã¬ã¸ã¹ã¿ãç¨ã
-\begin{lstlisting}
-\@savetbaselineshift\tbaselineshift\tbaselineshift\z@
-...
-\tbaselineshift\@savetbaselineshift
-\end{lstlisting}
-ã¨ããå¦çãè¡ã£ã¦ããï¼
+%\subsection{Patch for NFSS2}
+%\subsection{NFSS2ã¸ã®ããã}
+\label{ssec-nfsspat}
-ããã\LuaTeX-ja ç¨ã« \cs{ltjsetparameter} ã使ã£ã¦æ¸ãç´ãã¨ï¼
-\begin{lstlisting}
-\@savetbaselineshift\ltjgetparameter{talbaselineshift}
-\ltjsetparameter{talbaselineshift=\z@}
-...
-\ltjsetparameter{talbaselineshift=\@savetbaselineshift}
-\end{lstlisting}
-ã¨ãªãï¼
+%<*en>
+Japanese patch for NFSS2 in \LuaTeX-ja
+is based on \texttt{plfonts.dtx} which plays the same role in \pLaTeXe.
+We will describe
+commands which are not described in Subsection~\ref{ssec-chgfnt}.
+%
+%<*ja>
+\LuaTeX-jaã®NFSS2ã¸ã®æ¥æ¬èªãããã¯
+\pLaTeXe ã§åæ§ã®å½¹å²ãæãã \texttt{plfonts.dtx} ããã¼ã¹ã«ï¼
+åæã¨ã³ã³ã¼ãã£ã³ã°ã®ç®¡ççãLuaã§æ¸ããªããããã®ã§ããï¼
+ããã§ã¯\ref{ssec-chgfnt}ç¯ã§è¿°ã¹ã¦ããªãã£ãå½ä»¤ã«ã¤ãã¦
+è¨è¿°ãã¦ããï¼
+%
-ãã¦ï¼ç¸¦çµã®æ¬§æãã¼ã¹ã©ã¤ã³è£æ£é\Param{talbaselineshift}ã¯ï¼
-å®éã«ã¯ \cs{ltj@tablshift} ã¨ããå±æ§ã¬ã¸ã¹ã¿ã«æ ¼ç´ããã¦ãã
-ï¼\ref{sec-para}\nobreak ç¯åç
§ï¼ï¼å±æ§ã¬ã¸ã¹ã¿ã¯é·ãã§ã¯ãªãæ´æ°å¤ãæ ¼ç´ãã\footnote{%
- å¾ã£ã¦ï¼\texttt{\textbackslash @savetbaselineshift=\textbackslash ltj@tablshift}\
- ã®ããã«è¨è¿°ãããã¨ã¯ã§ããªãï¼å±æ§ã¬ã¸ã¹ã¿ã \cs{tbaselineshift} ã¨ããå称ã«ããªãã£
- ãã®ã¯ãã®ããã§ããï¼
-}ãã®ã§ããï¼\cs{ltj@tablshift} ã¯è£æ£éã sp åä½ã§ä¿æãããã¨ããï¼
-ä¸è¨ã®ã³ã¼ãã¨åãå
容ãããéã以ä¸ã®ã³ã¼ãã§å®ç¾ãããã¨ãã§ããï¼
-\begin{lstlisting}
-\@savetbaselineshift\ltj@tablshift sp%
-\ltj@tablshift\z@
-...
-\ltj@tablshift\@savetbaselineshift
-\end{lstlisting}
-ãã®ææ³ã¯ \Pkg{ascmac} ããã±ã¼ã¸ã®\LuaTeX-ja対å¿ããã \Pkg{lltjp-tascmac.sty} ã§
-å®éã«ç¨ãããã¦ããï¼\Pkg{lltjp-tascmac.sty} ã¯èªåçã«èªã¿è¾¼ã¾ããã®ã§ï¼
-ã¦ã¼ã¶ã¯ä½ãæ°ã«ããæ®éã« \Pkg{ascmac} ããã±ã¼ã¸ã \cs{usepackage} ã§èªã¿ããã°è¯ãï¼
+\begin{cslist}%
+\item[\normalfont\bfseries %
+%追å ã®é·ãå¤æ°é
+%additonal dimensions
+]
+%<*en>
+Like \pLaTeXe, \LuaTeX-ja defines the following dimensions
+for information of current Japanese font:
+%
+%<*ja>
+\pLaTeXe ã¨åæ§ã«ï¼\LuaTeX-jaã¯ãç¾å¨ã®åæãã©ã³ãã®æ
å ±ããæ ¼ç´ããé·ãå¤æ°
+%
+\begin{quote}
+ \cs{cht}~(height), \cs{cdp}~(depth), \cs{cHT}~(sum of former two),\\
+ \cs{cwd}~(width), \cs{cvs}~(lineskip), \cs{chs}~(equals to \cs{cwd})
+\end{quote}
+%and its \cs{normalsize} version:
+%ã¨ï¼ãã® \cs{normalsize} çã§ãã
+\begin{quote}
+ \cs{Cht}~(height), \cs{Cdp}~(depth),
+ \cs{Cwd}~(width), \\\cs{Cvs}~(equals to \cs{baselineskip}),
+ \cs{Chs}~(equals to \cs{cwd})%
+%.
+\end{quote}
+%<*ja>
+ãå®ç¾©ãã¦ããï¼ãªãï¼\cs{cwd} 㨠\cs{zw}ï¼ã¾ã
+\cs{cHT} 㨠\cs{zh} ã¯ä¸è´ããªãå¯è½æ§ãããï¼ãªããªãï¼
+\cs{cwd},~\cs{cHT} ã¯ãããã®å¯¸æ³ãã決å®ãããã®ã«å¯¾ãï¼
+\cs{zw} 㨠\cs{zh} ã¯JFMã«æå®ãããå¤ã«éããªãããã§ããï¼
%
+%<*en>
+Note that \cs{cwd}~and~\cs{cHT} may differ from \cs{zw}~and~\cs{zh}
+respectively.
+On the one hand the former dimensions are determined from the character ``ã'',
+but on the other hand \cs{zw}~and~\cs{zh} are specified by JFM.
+%
-%\section{Other Commands for plain \TeX\ and \LaTeXe}
-%\section{plainã§ã\LaTeX ã§ãå©ç¨å¯è½ãªãã®ä»ã®å½ä»¤}
-%\subsection{Commands for compatibility with \pTeX}
-%\subsection{\pTeX äºæç¨å½ä»¤}
+\item[\cs{DeclareYokoKanjiEncoding}\{\}\{\}\{\}]
+%\ \\[\dimexpr-\medskipamount-2\baselineskip\relax]
+%\ \\[\dimexpr-2\baselineskip\relax]
+\item[\cs{DeclareTateKanjiEncoding}\{\}\{\}\{\}]
%<*en>
-The following commands are implemented for compatibility with \pTeX.
-Note that the former five commands don't support JIS~X~0213, but only JIS~X~0208.
-The last \cs{kansuji} converts an integer into its Chinese numerals.
+In NFSS2 under \LuaTeX-ja, distinction between alphabetic fonts
+ and Japanese fonts are only made by their
+ encodings. For example, encodings OT1 and T1 are encodings for
+ alphabetic fonts, and Japanese fonts cannot
+ have these encodings. These command define a new encoding
+ scheme for Japanese font families.
%
%<*ja>
-以ä¸ã®å½ä»¤ã¯\pTeX ã¨ã®äºææ§ã®ããã«å®è£
ããã¦ããï¼ãã®ããï¼JIS~X~0213ã«ã¯å¯¾å¿ããï¼
-\pTeX ã¨åãããã«JIS~X~0208ã®ç¯å²ãããµãã¼ããã¦ããªãï¼
+\LuaTeX-jaã®NFSS2ã«ããã¦ã¯ï¼æ¬§æãã©ã³ãã¨åæãã©ã³ãã¯
+ãã®ã¨ã³ã³ã¼ãã£ã³ã°ã«ãã£ã¦ã®ã¿åºå¥ãããï¼
+ä¾ãã°ï¼OT1ã¨T1ã®ã¨ã³ã³ã¼ãã£ã³ã°ã¯æ¬§æãã©ã³ãã®ã¨ã³ã³ã¼ãã£ã³ã°ã§ããï¼
+åæãã©ã³ãã¯ãããã®ã¨ã³ã³ã¼ãã£ã³ã°ãæã¤ãã¨ã¯ã§ããªãï¼
+ãããã³ãã³ãã¯æ¨ªçµç¨ã»ç¸¦çµç¨åæãã©ã³ãã®ããã®æ°ããã¨ã³ã³ã¼ãã£ã³ã°ã
+ããããå®ç¾©ããï¼
%
-\begin{center}
-\cs{kuten}, \cs{jis}, \cs{euc}, \cs{sjis}, \cs{ucs}, \cs{kansuji}
-\end{center}
+
+\item[\cs{DeclareKanjiEncodingDefaults}\{\}\{\}]
+%\ \\[\dimexpr-\medskipamount-2\baselineskip\relax]
+%\ \\[\dimexpr-2\baselineskip\relax]
+\item[\cs{DeclareKanjiSubstitution}\{\}\{\}\{\}\{\}]
+%\ \\[\dimexpr-\medskipamount-2\baselineskip\relax]
+%\ \\[\dimexpr-2\baselineskip\relax]
+\item[\cs{DeclareErrorKanjiFont}\{\}\{\}\{\}\{\}\{\}]
+
%<*en>
-These six commands takes an internal integer, and returns a \emph{string}.
+The above 3~commands are just the counterparts for \cs{DeclareFontEncodingDefaults} and~others.
%
%<*ja>
-ããã6å½ä»¤ã¯å
é¨æ´æ°ãå¼æ°ã¨ãããï¼å®è¡çµæã¯\textbf{æåå}ã§ãããã¨ã«æ³¨æï¼
+ä¸è¨3ã¤ã®ã³ãã³ãã¯ã¡ããã©NFSS2 ã® \cs{DeclareFontEncodingDefaults} ãªã©ã«å¯¾å¿ãããã®ã§ããï¼
%
-\begin{LTXexample}
-\newcount\hoge
-\hoge="2423 %"
-\the\hoge, \kansuji\hoge\\
-\jis\hoge, \char\jis\hoge\\
-\kansuji1701
-\end{LTXexample}
-%<*en>
-To change characters of Chinese numerals for each digit, set \Param{kansujichar} parameter:
-\begin{LTXexample}
-\ltjsetparameter{kansujichar={1,`壹}}
-\ltjsetparameter{kansujichar={7,`æ¼}}
-\ltjsetparameter{kansujichar={0,`é¶}}
-\kansuji1701
-\end{LTXexample}
-%
+\item[\cs{reDeclareMathAlphabet}\{\}\{\}\{\}]
+
+% ToDo: en
+%<*ja>
+åæã»æ¬§æã®æ°å¼ç¨ãã©ã³ããã¡ããªãä¸åº¦ã«å¤æ´ããå½ä»¤ãä½æããï¼
+å
·ä½çã«ã¯ï¼æ¬§ææ°å¼ç¨ãã©ã³ããã¡ããªå¤æ´ã®å½ä»¤ï¼\cs{mathrm} çï¼ã¨ï¼åææ°å¼ç¨ãã©
+ ã³ããã¡ããªå¤æ´ã®å½ä»¤ï¼\cs{mathmc} çï¼ã®2ã¤ãåæã«è¡ãå½ä»¤ã¨ãã¦
+ ãï¼åï¼å®ç¾©ããï¼å®éã®ä½¿ç¨ã§ã¯ã¨
+ ã«åããã®ãæå®ããï¼ããªãã¡ï¼ã§åæå´ãå¤
+ æ´ãããããã«ããã®ãä¸è¬çã¨æãããï¼
+æ¬å½ä»¤ã¯
+\begin{center}\tt
+\{\}\quad$\longrightarrow$\quad
+(ã®1段å±éçµæ)\{ã®1段å±éçµæ)\{\}\}
+\end{center}
+ã¨å®ç¾©ãè¡ãã®ã§ï¼ä½¿ç¨ã«ã¯æ³¨æãå¿
è¦ã§ããï¼
+%\vspace{-\medskipamount}
+\begin{itemize}
+\item ,~ã¯æ¢ã«å®ç¾©ããã¦ããªããã°ãªããªãï¼
+ \cs{reDeclareMathAlphabet}\\ã®å¾ã«
+両å½ä»¤ã®å
容ãåå®ç¾©ãã¦ãï¼ã®å
容ã«ããã¯åæ ãããªãï¼
+\item ,~ã«\verb+\@mathrm+ãªã©ã¨ \texttt{@} ãã¤ããå½ä»¤ãæå®ããæã®åä½ã¯ä¿è¨¼ã§ããªãï¼
+\end{itemize}
+%
-\subsection{\cs{inhibitglue}}
+\item[\cs{DeclareRelationFont}\{\}\{\}\{\}\{\}\\*
+ \null\hfill\{\}\{\}\{\}\{\}]
%<*en>
-\cs{inhibitglue} suppresses the insertion of \textbf{JAglue}.
-The following is an example, using a special JFM that there will be a glue between
-the beginning of a box and ``ã'', and also between ``ã''~and~``ã¦''.
+This command sets the ``accompanied'' alphabetic font (given by the latter 4~arguments)
+with respect to a Japanese font given by the former 4~arguments.
%
%<*ja>
-\cs{inhibitglue} ã¯\textbf{JAglue}ã®æ¿å
¥ãæå¶ããï¼
-以ä¸ã¯ï¼ããã¯ã¹ã®å§ãã¨ãããã®éï¼ããããã¦ãã®éã«ã°ã«ã¼ãå
¥ãç¹å¥ãªJFMãç¨ããä¾ã§
-ããï¼
+ãããããå¾å±æ¬§æããè¨å®ããããã®å½ä»¤ã§ããï¼ååã®4å¼æ°ã§è¡¨ãããåæãã©ã³ãã«å¯¾ãã¦ï¼
+ãã®ãã©ã³ãã«å¯¾å¿ãããå¾å±æ¬§æãã®ãã©ã³ããå¾åã®4å¼æ°ã«ããä¸ããï¼
%
-
-\begin{LTXexample}[width=0.4\textwidth]
-\jfont\g=file:KozMinPr6N-Regular.otf:jfm=test \g
-\fbox{\hbox{ãã¦ã\inhibitglue ã¦}}
-\inhibitglue\par\noindent ã1
-\par\inhibitglue\noindent ã2
-\par\noindent\inhibitglue ã3
-\par\hrule\noindent ãoff\inhibitglue ice
-\end{LTXexample}
-
+\item[\cs{SetRelationFont}]
%<*en>
-With the help of this example, we remark the specification of \cs{inhibitglue}:
+This command is almost same as \cs{DeclareRelationFont}, except that this command does a local
+assignment, where \cs{DeclareRelationFont} does a global assignment.
%
%<*ja>
-ãã®ä¾ãæ´ç¨ãã¦ï¼\cs{inhibitglue} ã®ä»æ§ã«ã¤ãã¦è¿°ã¹ãï¼
+ãã®ã³ãã³ã㯠\cs{DeclareRelationFont} ã¨ãã¼ã«ã«ãªæå®ã§ãããã¨ãé¤ãã¦
+ã»ã¨ãã©åãã§ããï¼\cs{DeclareRelationFont} ã¯ã°ãã¼ãã«ï¼ï¼
%
-\begin{itemize}
+
+\item[\cs{userelfont}]
%<*en>
-\item The call of \cs{inhibitglue} in the (internal) vertical mode is
- simply ignored.
+Change current alphabetic font encoding/family/\dots\ to the `accompanied' alphabetic
+ font family with respect to current Japanese font family,
+ which was set by
+ \cs{DeclareRelationFont} or \cs{SetRelationFont}.
+Like \cs{fontfamily}, \cs{selectfont} is required to take an effect.
%
%<*ja>
-\item \emph{\cs{inhibitglue} ã®åç´ã¢ã¼ãä¸ã§ã®å¼ã³åºãã¯æå³ãæããªã}\footnote{%
- ãã®ç¹ã¯\TeX~Live~2014ã§ã®\pTeX ã«ããã \cs{inhibitglue} ã®ä»æ§å¤æ´ã¨åãã§ããï¼
-}ï¼
-4è¡ç®ã®å
¥åã§æå¹ã«ãªããªãã®ã¯ï¼\cs{inhibitglue} ã®æç¹ã§ã¯åç´ã¢ã¼ãã§ããï¼
-\cs{noindent} ã®æç¹ã§æ°´å¹³ã¢ã¼ãã«ãªãããã§ããï¼
+ç¾å¨ã®æ¬§æãã©ã³ãã®ã¨ã³ã³ã¼ãã£ã³ã°ï¼ãã¡ããªï¼â¦â¦ ãï¼
+\cs{DeclareRelationFont} ã \cs{SetRelationFont} ã§æå®ããã
+ç¾å¨ã®åæãã©ã³ãã«å¯¾å¿ãããå¾å±æ¬§æããã©ã³ãã«å¤æ´ããï¼
+\cs{fontfamily} ã®ããã«ï¼æå¹ã«ããããã«ã¯ \cs{selectfont} ãå¿
è¦ã§ããï¼
%
+\item[\cs{adjustbaseline}]
%<*en>
-\item The call of \cs{inhibitglue} in the (restricted) horizontal
- mode is only effective on the spot; does not get over boundary of
- paragraphs. Moreover, \cs{inhibitglue} cancels ligatures and
- kernings, as shown in the last line of above example.
+In \pLaTeXe, \cs{adjustbaseline} sets \cs{tbaselineshift}
+to match the vertical center of ``M'' and that of ``ã'' in vertical typesetting:
+\[
+\text{\cs{tbaselineshift}} \leftarrow
+\frac{(h_{\text{M}}+d_{\text{M}}) - (h_{\text{ã}}+d_{\text{ã}})}2
+ + d_{\text{ã}} - d_{\text{M}},
+\]
+where $h_{a}$~and~$d_{a}$ denote the height of ``$a$'' and the depth, respectively.
+In \LuaTeX-ja, this \cs{adjustbaseline} does similar task, namely setting the
+ \Param{talbaselineshift} parameter.
+If the \LaTeX\ is 2015/10/01 release or later, \LuaTeX-ja use a Japanese
+character whose character class is zero, instead of `ã'.
%
%<*ja>
-\item \cs{inhibitglue} ã®ï¼å¶éãããï¼æ°´å¹³ã¢ã¼ãä¸ã§ã®å¼ã³åºãã¯ãã®å ´ã§ã®ã¿
- æå¹ã§ããï¼æ®µè½ã®å¢çãä¹ãè¶ããªãï¼
- ããã«ï¼\cs{inhibitglue} ã¯ä¸ã®ä¾ã®æçµè¡ã®ããã«ï¼æ¬§æã«ãããï¼ãªã¬ãã£ã¨ã«ã¼ãã³ã°ã
- æã¡æ¶ãï¼ããã¯ï¼\cs{inhibitglue} ãå
é¨çã«ã¯ãç¾å¨ã®ãªã¹ãä¸ã«whatsitãã¼ãã
- 追å ããããã¨ãè¡ãªã£ã¦ããããã§ããï¼
+\pLaTeXe ã§ã¯ï¼\cs{adjustbaseline} ã¯ç¸¦çµæã«ãMãã¨ãããã®ä¸å¿ç·ãä¸è´ãããããã«ï¼
+\cs{tbaselineshift} ãè¨å®ããå½¹å²ãæã£ã¦ããï¼
+\[
+\text{\cs{tbaselineshift}} \leftarrow
+\frac{(h_{\text{M}}+d_{\text{M}}) - (h_{\text{ã}}+d_{\text{ã}})}2
+ + d_{\text{ã}} - d_{\text{M}},
+\]
+ããã§ï¼$h_{a}$,~$d_{a}$ã¯ããããã$a$ãã®é«ãã»æ·±ãã表ãï¼
+\LuaTeX-jaã«ããã¦ã\cs{adjustbaseline} ã¯åæ§ã«\Param{talbaselineshift}ãã©ã¡ã¼ã¿ã®èª¿æ´å¦
+ çãè¡ã£ã¦ããï¼
+
+åæã«ï¼ããã\pLaTeXe ã® \cs{adjustbaseline} ã§åæ§ã®å¦çãè¡ããã¦ãããï¼
+ãæ¼¢ãã®å¯¸æ³ãå
ã«ï¼æ¬ç¯ã®æåã«è¿°ã¹ãï¼å°æåã§å§ã¾ãï¼\cs{cht}, \cs{cwd}
+ã¨ãã£ãé·ãå¤æ°ãè¨å®ããï¼
+
+ãªãï¼\LaTeX ã2015/10/01ç以éã®å ´åã¯ï¼ããããæ¼¢ãã®ä»£ããã«
+ãæåã¯ã©ã¹0ã®åææåããç¨ããï¼
%
+\item[\cs{fontfamily}\{\}]
%<*en>
-\item The call of \cs{inhibitglue} in math mode is just ignored.
+As in \LaTeXe, this command changes current font family (alphabetic, Japanese,~\emph{or both})
+to . See Subsection~\ref{ssec-fontfamilycmd} for detail.
%
%<*ja>
-\item \cs{inhibitglue} ãæ°å¼ã¢ã¼ãä¸ã§å¼ã³åºããå ´åã¯ãã ç¡è¦ãããï¼
+å
ã
ã®\LaTeXe ã«ããããã®ã¨åæ§ã«ï¼ãã®ã³ãã³ãã¯ç¾å¨ã®ãã©ã³ããã¡ããªï¼æ¬§æï¼
+åæï¼\emph{ãããã¯ä¸¡æ¹}ï¼ãã«å¤æ´ããï¼è©³ç´°ã¯\ref{ssec-fontfamilycmd}ç¯ãåç
§ãããã¨ï¼
%
+
+\begin{figure}[!tb]
+\begin{LTXexample}[pos=b]
+\DeclareKanjiFamily{JY3}{edm}{}
+\DeclareFontShape{JY3}{edm}{m}{n} {<-> s*KozMinPr6N-Regular:jfm=ujis;}{}
+\DeclareFontShape{JY3}{edm}{m}{green}{<-> s*KozMinPr6N-Regular:jfm=ujis;color=007F00}{}
+\DeclareFontShape{JY3}{edm}{m}{blue} {<-> s*KozMinPr6N-Regular:jfm=ujis;color=0000FF}{}
+\DeclareAlternateKanjiFont{JY3}{edm}{m}{n}{JY3}{edm}{m}{green}{"4E00-"67FF,{-2}-{-2}}
+\DeclareAlternateKanjiFont{JY3}{edm}{m}{n}{JY3}{edm}{m}{blue}{ "6800-"9FFF}
+{\kanjifamily{edm}\selectfont
+æ¥æ¬å½æ°ã¯ãæ£å½ã«é¸æãããå½ä¼ã«ããã代表è
ãéãã¦è¡åããâ¦â¦}
+\end{LTXexample}
+%\caption{\cs{DeclareAlternateKanjiFont} ã®ä½¿ç¨ä¾}
+%\caption{An example of \cs{DeclareAlternateKanjiFont}}
+\label{fig:altkanji}
+\end{figure}
+
+\item[\cs{DeclareAlternateKanjiFont}\{\}\{\}\{\}\{\}\\
+ \null\hfill\{\}\{\}\{\}\{\}\{\}]
%<*ja>
-\item \LaTeX ã§\LuaTeX-ja ã使ç¨ããå ´åã¯ï¼
-\cs{inhibitglue} ã®ä»£ããã¨ã㦠\verb+\<+ ã使ããã¨ãã§ããï¼
-æ¢ã« \verb+\<+ ãå®ç¾©ããã¦ããå ´åã¯ï¼\LuaTeX-ja ã®èªã¿è¾¼ã¿ã§å¼·å¶çã«ä¸æ¸ããããã®ã§
-注æãããã¨ï¼
+\ref{ssec-altfont}ç¯ã®\
+\cs{ltjdeclarealtfont} ã¨åæ§ã«ï¼ååã®4å¼æ°ã®
+åæãã©ã³ãï¼åºåºãã©ã³ãï¼ã®ãã¡ä¸ã®æåã
+第5ãã第8å¼æ°ã®åæãã©ã³ãã使ã£ã¦çµãããã«æ示ããï¼
+使ç¨ä¾ãå³\nobreak\ref{fig:altkanji}ã«è¼ããï¼
+
+\begin{itemize}
+ \item
+\cs{ltjdeclarealtfont} ã§ã¯åºåºãã©ã³ãã»ç½®ãæãå
åæãã©ã³ãã¯ãããããå®ç¾©ããã¦ã
+ ãªãã¨ãããªãï¼ãã®ä»£ããå³æçºå¹ï¼ã§ãã£ããï¼
+\cs{DeclareAlternateKanjiFont} ã®è¨å®ã
+å®éã«å¹åãçºæ®ããã®ã¯ï¼æ¸ä½å¤æ´ããµã¤ãºå¤æ´ãè¡ã£ãæï¼
+ãããã¯ï¼ããããå«ããï¼\cs{selectfont} ãå®è¡ãããæã§ããï¼
+ \item
+段è½ãhboxã®æå¾ã§ã®è¨å®å¤ã段è½ï¼hboxå
¨ä½ã«ããã£ã¦éç¨ããç¹ãï¼
+ã«è² æ°$-n$ãæå®ããå ´åï¼ããããåºåºãã©ã³ãã®æåã¯ã©ã¹$n$ã«å±ããæåå
¨ä½ã
+ã¨è§£éãããã®ã¯ \cs{ltjdeclarealtfont} ã¨åãã§ããï¼
+\end{itemize}%
%
-\end{itemize}
+%<*en>
+As \cs{ltjdeclarealtfont}~(Subsection~\ref{ssec-altfont}),
+characters in of the Japanese font (we say the \emph{base font})
+which specified by first 4 arguments are typeset
+by the Japanese font which specified by fifth to eighth arguments
+(we say the \emph{alternate font}).
+An example is shown in \autoref{fig:altkanji}.
+
+\begin{itemize}
+ \item
+In \cs{ltjdeclarealtfont}, the base font and the alternate font must be already defined.
+But this \cs{DeclareAlternateKanjiFont} is not so.
+In other words, \cs{DeclareAlternateKanjiFont} is effective only after
+current Japanese font is changed, or only after \cs{selectfont} is executed.
+ \item \dots
+\end{itemize}%
+\vspace{-\medskipamount}
+%
+\end{cslist}
+%<*en>
+As closing this subsection, we shall introduce an example of
+\cs{SetRelationFont} and \cs{userelfont}:
+%
+%<*ja>
+ãã®ç¯ã®çµããã«ï¼\cs{SetRelationFont} 㨠\cs{userelfont} ã®ä¾ã
+ç´¹ä»ãã¦ãããï¼\cs{userelfont} ã®ä½¿ç¨ã«ãã£ã¦ï¼ãabcãã®é¨åã®ãã©ã³ãã
+Avant Garde (OT1/pag/m/n) ã«å¤ãã£ã¦ãããã¨ããããï¼
+%
+\begin{LTXexample}[width=0.3\textwidth]
+\makeatletter
+\SetRelationFont{JY3}{\k@family}{m}{n}{OT1}{pag}{m}{n}
+ % \k@family: current Japanese font family
+\userelfont\selectfont ãããabc
+\end{LTXexample}
-\subsection{\cs{ltjdeclarealtfont}}
-\label{ssec-altfont}
+%\subsection{Detail of \cs{fontfamily} command}
+%\subsection{\cs{fontfamily}ã³ãã³ãã®è©³ç´°}
+\label{ssec-fontfamilycmd}
%<*en>
-Using \cs{ltjdeclarealtfont}, one can ``compose'' more than one Japanese fonts.
-This \cs{ltjdeclarealtfont} uses in the following form:
-\begin{quote}
-\ttfamily \textbackslash ltjdeclarealtfont\{\}
-\end{quote}
-where ~and~ are defined by \cs{jfont}.
-Its meaning is
-\begin{quote}
-If the current Japanese font is , characters which belong to
-is typeset by another Japanese font , instead of .
-\end{quote}
-Here is a comma-separated list of character codes, but also accepts negative integers:
-$-n$~($nâ¥1$) means that all characters of character classes~$n$, with respect to JFM used
-by . Note that characters which do not exist in are
-ignored.
+In this subsection, we describe when \cs{fontfamily} changes current
+Japanese/alphabetic font family. Basically, current Japanese fotn family is changed to
+ if it is recognized as a Japanese font family, and similar with alphabetic font
+family. There is a case that current Japanese/alphabetic font family are both changed to
+, and another case that isn't recognized as a Japanese/alphabetic font
+family either.
-For example, if \cs{hoge} uses \texttt{jfm-ujis.lua}, the standard JFM of \LuaTeX-ja,
-then
-\begin{lstlisting}
-\ltjdeclarealtfont\hoge\piyo{"3000-"30FF, {-1}-{-1}}
-\end{lstlisting}
-does
-\begin{quote}
-If the current Japanese font is \cs{hoge}, \texttt{U+3000}--\texttt{U+30FF}
-and characters in class~1 (ideographic opening brackets)
-are typeset by \cs{piyo}.
-\end{quote}
+\paragraph{Recognition as Japanese font family}
+First, Whether Japanese font family will be changed is determined in following order.
+This order is very similar to \cs{fontfamily} in \pLaTeXe, but we re-implemented in Lua.
+We use an auxiliary list~$N_{\mathrm{J}}$.
%
%<*ja>
-\cs{jfont} ã®æ¸å¼ãè¦ãã°ãããããã«ï¼åºæ¬çã«ã¯\LuaTeX-jaã«ããã1ã¤ã®åæãã©ã³ãã«
-使ç¨åºæ¥ããå®éã®ãã©ã³ããã¯1ã¤ã§ããï¼
-ãããï¼\cs{ltjdeclarealtfont} ãç¨ããã¨ï¼ãã®ååããå¤ãããã¨ãã§ããï¼
-
-\cs{ltjdeclarealtfont} ã¯ä»¥ä¸ã®æ¸å¼ã§ä½¿ç¨ããï¼
-\begin{quote}
-\ttfamily \textbackslash ltjdeclarealtfont\{\}
-\end{quote}
-ããã¯ãç¾å¨ã®åæãã©ã³ãããã§ããã¨ãï¼
-ã«å±ããæåã¯ãç¨ãã¦çµçãããï¼ã¨ããæå³ã§ããï¼
-\begin{itemize}
- \item , ã¯
-\cs{jfont} ã«ãã£ã¦å®ç¾©ãããåæãã©ã³ãã§ããï¼
- \item ã¯æåã³ã¼ãã®ç¯å²ã表ãã³ã³ãåºåãã®ãªã¹ãã§ãããï¼
- ä¾å¤ã¨ãã¦è² æ°$-n$ã¯ãã®JFMã®æåã¯ã©ã¹$n$ã«å±ããå
¨ã¦ã®æåã
- ãæå³ããï¼
-
-ä¸ã«ä¸ã«å®éã«ã¯åå¨ããªãæåãæå®ãããå ´åã¯ï¼
-ãã®æåã«å¯¾ããè¨å®ã¯ç¡è¦ãããï¼
-\end{itemize}
+æ¬ç¯ã§ã¯ï¼\cs{fontfamily} ããã¤åæ/欧æãã©ã³ããã¡ããªãå¤æ´ãããã«ã¤ãã¦è§£èª¬
+ããï¼åºæ¬çã«ã¯ï¼ãåæãã©ã³ããã¡ããªã ã¨èªèãããã°åæå´ãï¼æ¬§æãã©ã³ããã¡
+ããªã ã¨èªèãããã°æ¬§æå´ãå¤æ´ãããï¼ã©ã¡ãã¨ãèªèãããã°åæã»æ¬§æã®ä¸¡æ¹ãå¤ããã
+ã¨ã«ãªããï¼å½ç¶ã©ã¡ãã¨ãèªèãããªããã¨ãããï¼
-ä¾ãã°ï¼\cs{hoge} ã®JFMã\LuaTeX-jaæ¨æºã®
-\ \texttt{jfm-ujis.lua} ã§ãã£ãå ´åï¼
-\begin{lstlisting}
-\ltjdeclarealtfont\hoge\piyo{"3000-"30FF, {-1}-{-1}}
-\end{lstlisting}
-ã¯ã\cs{hoge} ãå©ç¨ãã¦ããã¨ãï¼
-\texttt{U+3000}--\texttt{U+30FF}ã¨
-æåã¯ã©ã¹1ï¼éãæ¬å¼§é¡ï¼ä¸ã®æåã ã㯠\cs{piyo} ãç¨ããã
-ãã¨ãè¨å®ããï¼\verb+{-1}-{-1}+ ã¨ããå¤ãã£ãæå®ã®ä»æ¹ããã¦ããã®ã¯ï¼
-æ®éã« \texttt{-1} ã¨æå®ããã®ã§ã¯æ£ãã$-1$ã¨èªã¿åãããªãã¨ãã
-ãã¯ãã®é½åã«ããï¼
+\paragraph{åæãã©ã³ããã¡ããªã¨ãã¦ã®èªè}
+ã¾ãï¼ãåæãã©ã³ããã¡ããªã¨ãã¦èªèããããã¯ä»¥ä¸ã®é åºã§æ±ºå®ãããï¼
+ããã¯\pLaTeXe ã® \cs{fontfamily} ã«ã¨ã¦ãä¼¼ã¦ãããï¼ããã§ã¯Luaã«ãã£ã¦å®è£
ãã¦ããï¼
+è£å©çã«ãåæãã©ã³ããã¡ããªã§ã¯ãªãã¨èªèãããããã¡ããªãæ ¼ç´ãããªã¹ã$N_{\mathrm{J}}$ãç¨ããï¼
%
-
+\begin{enumerate}
+%<*en>
+\item If the family~ has been defined already by \cs{DeclareKanjiFamily},
+ is recognized as a Japanese font family.
+ Note that need not be defined under \emph{current} Japanese font encoding.
+%
%<*ja>
-\subsection{\cs{ltjalchar} 㨠\cs{ltjjachar}}
-æåã³ã¼ãã$\text{}~(\geq 128=\mathtt{0x80})$ã®æåã
-\ \cs{char} ããªããã£ãã使ã \cs{char} ã¨ãã¦åºåãããã¨ï¼
-ãã®æåã®å±ããæåç¯å²ï¼\ref{ssec-setrange}ç¯åç
§ï¼ã«ãã£ã¦
-\textbf{ALchar}ã\textbf{JAchar}ãï¼ã¤ã¾ã欧æãã©ã³ãã§åºåããããåæãã©ã³ãã§åºåãã
-ããã決ã¾ãï¼
-
-æåç¯å²ã®è¨å®ãç¡è¦ãï¼æåã³ã¼ãã$\text{}~(\geq 128=\mathtt{0x80})$ã®æåãå¼·å¶çã«
-\textbf{ALchar}, \textbf{JAchar}ã§åºåããå½ä»¤ããããã
-\ \cs{ltjalchar},~\cs{ltjjachar} ã§ããï¼ä½¿ç¨æ¹æ³ã¯ \cs{char} ã¨åãã
-\ \cs{ltjalchar}, \cs{ltjjachar}ã¨ããã°ããï¼
-ã127以ä¸ã®å ´åã¯ï¼\cs{ltjjachar} ã§ãã£ã¦ã\textbf{ALchar}ã¨ãã¦åºåããããã¨
-ã«æ³¨æï¼
-
-以ä¸ã¯\ref{ssec-setrange}ç¯ã«è¼ããä¾ã«ï¼\cs{char} ã®åä½ã追å ãããã®ã§ããï¼
-\begin{LTXexample}[width=0.25\textwidth]
-\gtfamily\large % default, ALchar, JAchar
-¶, \char`¶, \ltjalchar`¶, \ltjjachar`¶\\ % default: ALchar
-α, \char`α, \ltjalchar`α, \ltjjachar`α % default: JAchar
-\end{LTXexample}
+\item ãã¡ããªãæ¢ã« \cs{DeclareKanjiFamily} ã«ãã£ã¦å®ç¾©ããã¦ããå ´åï¼
+ ã¯åæãã©ã³ããã¡ããªã§ããã¨èªèãããï¼
+ ããã§ï¼ã¯ç¾å¨ã®åæãã©ã³ãã¨ã³ã³ã¼ãã£ã³ã°ã§å®ç¾©ããã¦ããªãã¦ãããï¼
+%
+%<*en>
+\item If the family~ has been listed in a list~$N_{\mathrm{J}}$, this means
+ that is not a Japanese font family.
+%
+%<*ja>
+\item ãã¡ããªããªã¹ã$N_{\mathrm{J}}$ã«æ¢ã«å«ã¾ãã¦ããã°ï¼ããã¯
+ ãåæãã©ã³ããã¡ããªã§ã¯ãªããã¨ãæå³ããï¼
%
+%<*en>
+\item If the \Pkg{luatexja-fontspec} package is loaded, we stop here, and is not
+ recognized as a Japanese font family.
+ If the \Pkg{luatexja-fontspec} package is \emph{not} loaded,
+now \LuaTeX-ja looks whether there exists a Japanese font encoding~ such that
+ a font definition named \texttt{.fd} (the file name is
+ all lowercase) exists. If so, is recognized as a Japanese font family (the font definition file won't be loaded here).
+ If not, is not a Japanese font family, and
+ is appended to the list~$N_{\mathrm{J}}$.
+%
+%<*ja>
+\item ãã\Pkg{luatexja-fontspec}ããã±ã¼ã¸ãèªã¿è¾¼ã¾ãã¦ããã°ï¼ããã§çµäºã§ããï¼
+ã¯åæãã©ã³ããã¡ããªã¨ãã¦èªèãããªããã¨ã«ãªãï¼
-%\section{Commands for \LaTeXe}
-%\section{\LaTeXe ç¨ã®å½ä»¤}
+ãã\Pkg{luatexja-fontspec}ããã±ã¼ã¸ãèªã¿è¾¼ã¾ãã¦ããªããã°ï¼åæã¨ã³ã³ã¼ãã£ã³ã°ã§
+ãã©ã³ãå®ç¾©ãã¡ã¤ã«\texttt{.fd}ï¼ãã¡ã¤ã«åã¯å
¨ã¦å°æåï¼ãåå¨ãããããªã
+ ã®ããããã©ããã調ã¹ãï¼
+åå¨ããã°ï¼ã¯åæãã©ã³ããã¡ããªã¨èªèãããï¼ãã©ã³ãå®ç¾©ãã¡ã¤ã«ã¯èªã¿è¾¼ã¾ããª
+ ãï¼ï¼
+åå¨ããªããã°ï¼ã¯åæãã©ã³ããã¡ããªã§ãªãã¨èªèããï¼ãªã¹ã$N_{\mathrm{J}}$ã«ã追å ãããã¨ã§ãããè¨æ¶ããï¼
-%\subsection{Patch for NFSS2}
-%\subsection{NFSS2ã¸ã®ããã}
-\label{ssec-nfsspat}
+%
+\end{enumerate}
%<*en>
-Japanese patch for NFSS2 in \LuaTeX-ja
-is based on \texttt{plfonts.dtx} which plays the same role in \pLaTeXe.
-We will describe
-commands which are not described in Subsection~\ref{ssec-chgfnt}.
+\paragraph{Recognition as alphabetic font family}
+Next, whether alphabetic font family will be changed is determined in following order.
+We use auxiliary lists $F_{\mathrm{A}}$~and~$N_{\mathrm{A}}$,
%
%<*ja>
-\LuaTeX-jaã®NFSS2ã¸ã®æ¥æ¬èªãããã¯
-\pLaTeXe ã§åæ§ã®å½¹å²ãæãã \texttt{plfonts.dtx} ããã¼ã¹ã«ï¼
-åæã¨ã³ã³ã¼ãã£ã³ã°ã®ç®¡ççãLuaã§æ¸ããªããããã®ã§ããï¼
-ããã§ã¯\ref{ssec-chgfnt}ç¯ã§è¿°ã¹ã¦ããªãã£ãå½ä»¤ã«ã¤ãã¦
-è¨è¿°ãã¦ããï¼
+\paragraph{欧æãã©ã³ããã¡ããªã¨ãã¦ã®èªè}
+åæ§ã«ï¼ãåæãã©ã³ããã¡ããªã¨ãã¦èªèããããã¯ä»¥ä¸ã®é åºã§æ±ºå®ãããï¼
+è£å©çã«ã欧æãã©ã³ããã¡ããªã¨æ¢ã«èªèãããããã¡ããªã®ãªã¹ã$F_{\textrm{A}}$ã¨ï¼
+ã欧æãã©ã³ããã¡ããªã§ã¯ãªãã¨èªèãããããã¡ããªãæ ¼ç´ãããªã¹ã$N_{\mathrm{A}}$ãç¨ããï¼
%
-\begin{cslist}%
-\item[\normalfont\bfseries %
-%追å ã®é·ãå¤æ°é
-%additonal dimensions
-]
+\begin{enumerate}
%<*en>
-Like \pLaTeXe, \LuaTeX-ja defines the following dimensions
-for information of current Japanese font:
+\item If the family~ has been listed in a list~$F_{\mathrm{A}}$,
+ is recognized as an alphabetic font family.
%
%<*ja>
-\pLaTeXe ã¨åæ§ã«ï¼\LuaTeX-jaã¯ãç¾å¨ã®åæãã©ã³ãã®æ
å ±ããæ ¼ç´ããé·ãå¤æ°
+\item ãã¡ããªããªã¹ã$F_{\mathrm{A}}$ã«æ¢ã«å«ã¾ãã¦ããã°ï¼
+ ã¯æ¬§æãã©ã³ããã¡ããªã¨èªèãããï¼
%
-\begin{quote}
- \cs{cht}~(height), \cs{cdp}~(depth), \cs{cHT}~(sum of former two),\\
- \cs{cwd}~(width), \cs{cvs}~(lineskip), \cs{chs}~(equals to \cs{cwd})
-\end{quote}
-%and its \cs{normalsize} version:
-%ã¨ï¼ãã® \cs{normalsize} çã§ãã
-\begin{quote}
- \cs{Cht}~(height), \cs{Cdp}~(depth),
- \cs{Cwd}~(width), \\\cs{Cvs}~(equals to \cs{baselineskip}),
- \cs{Chs}~(equals to \cs{cwd})%
-%.
-\end{quote}
+%<*en>
+\item If the family~ has been listed in a list~$N_{\mathrm{A}}$, this means
+ that is not an alphabetic font family.
+%
%<*ja>
-ãå®ç¾©ãã¦ããï¼ãªãï¼\cs{cwd} 㨠\cs{zw}ï¼ã¾ã
-\cs{cHT} 㨠\cs{zh} ã¯ä¸è´ããªãå¯è½æ§ãããï¼ãªããªãï¼
-\cs{cwd},~\cs{cHT} ã¯ãããã®å¯¸æ³ãã決å®ãããã®ã«å¯¾ãï¼
-\cs{zw} 㨠\cs{zh} ã¯JFMã«æå®ãããå¤ã«éããªãããã§ããï¼
+\item ãã¡ããªããªã¹ã$N_{\mathrm{A}}$ã«æ¢ã«å«ã¾ãã¦ããã°ï¼ããã¯
+ ã欧æãã©ã³ããã¡ããªã§ã¯ãªããã¨ãæå³ããï¼
%
%<*en>
-Note that \cs{cwd}~and~\cs{cHT} may differ from \cs{zw}~and~\cs{zh}
-respectively.
-On the one hand the former dimensions are determined from the character ``ã'',
-but on the other hand \cs{zw}~and~\cs{zh} are specified by JFM.
+\item If there exists an alphabetic font encoding such that the family~ has been
+ defined under it, is recognized as an alphabetic font family, and
+ to memorize this, is appended to the list~$F_{\mathrm{A}}$.
%
-
-
-\item[\cs{DeclareYokoKanjiEncoding}\{\}\{\}\{\}]
-%\ \\[\dimexpr-\medskipamount-2\baselineskip\relax]
-%\ \\[\dimexpr-2\baselineskip\relax]
-\item[\cs{DeclareTateKanjiEncoding}\{\}\{\}\{\}]
-
+%<*ja>
+\item ãã欧æãã©ã³ãã¨ã³ã³ã¼ãã£ã³ã°ä¸ã§ãã¡ããªãå®ç¾©ããã¦ããã°ï¼
+ ã¯æ¬§æãã©ã³ããã¡ããªã¨èªèããï¼ãªã¹ã$F_{\mathrm{A}}$ã«ã追å ãããã¨ã§ãã®ãã¨ãè¨æ¶ããï¼
+%
%<*en>
-In NFSS2 under \LuaTeX-ja, distinction between alphabetic fonts
- and Japanese fonts are only made by their
- encodings. For example, encodings OT1 and T1 are encodings for
- alphabetic fonts, and Japanese fonts cannot
- have these encodings. These command define a new encoding
- scheme for Japanese font families.
+\item Now \LuaTeX-ja looks whether there exists an alphabetic font encoding~ such that
+ a font definition named \texttt{.fd} (the file name is
+ all lowercase) exists. If so, current alphabetic font family will be changed to
+ ~(the font definition file won't be loaded here).
+ If not, current alphabetic font family won't be changed, and
+ is appended to the list~$N_{\mathrm{A}}$.
%
%<*ja>
-\LuaTeX-jaã®NFSS2ã«ããã¦ã¯ï¼æ¬§æãã©ã³ãã¨åæãã©ã³ãã¯
-ãã®ã¨ã³ã³ã¼ãã£ã³ã°ã«ãã£ã¦ã®ã¿åºå¥ãããï¼
-ä¾ãã°ï¼OT1ã¨T1ã®ã¨ã³ã³ã¼ãã£ã³ã°ã¯æ¬§æãã©ã³ãã®ã¨ã³ã³ã¼ãã£ã³ã°ã§ããï¼
-åæãã©ã³ãã¯ãããã®ã¨ã³ã³ã¼ãã£ã³ã°ãæã¤ãã¨ã¯ã§ããªãï¼
-ãããã³ãã³ãã¯æ¨ªçµç¨ã»ç¸¦çµç¨åæãã©ã³ãã®ããã®æ°ããã¨ã³ã³ã¼ãã£ã³ã°ã
-ããããå®ç¾©ããï¼
+\item æçµæ®µéã§ã¯ï¼æ¬§æã¨ã³ã³ã¼ãã£ã³ã°ã§
+ãã©ã³ãå®ç¾©ãã¡ã¤ã«\texttt{.fd}ï¼ãã¡ã¤ã«åã¯å
¨ã¦å°æåï¼ãåå¨ãããããªã
+ ã®ããããã©ããã調ã¹ãï¼
+åå¨ããã°ï¼ã¯æ¬§æãã©ã³ããã¡ããªã¨èªèãããï¼ãã©ã³ãå®ç¾©ãã¡ã¤ã«ã¯èªã¿è¾¼ã¾ããªãï¼ï¼
+åå¨ããªããã°ï¼ã¯æ¬§æãã©ã³ããã¡ããªã¨èªèãããªãã®ã§ï¼ãªã¹ã$N_{\mathrm{A}}$ã«
+ ã追å ãã¦ãã®ãã¨ãè¨æ¶ããï¼
%
-
-\item[\cs{DeclareKanjiEncodingDefaults}\{\}\{\}]
-%\ \\[\dimexpr-\medskipamount-2\baselineskip\relax]
-%\ \\[\dimexpr-2\baselineskip\relax]
-\item[\cs{DeclareKanjiSubstitution}\{\}\{\}\{\}\{\}]
-%\ \\[\dimexpr-\medskipamount-2\baselineskip\relax]
-%\ \\[\dimexpr-2\baselineskip\relax]
-\item[\cs{DeclareErrorKanjiFont}\{\}\{\}\{\}\{\}\{\}]
+\end{enumerate}
%<*en>
-The above 3~commands are just the counterparts for \cs{DeclareFontEncodingDefaults} and~others.
+Also, each call of \cs{DeclareFontFamily} \emph{after} loading of \LuaTeX-ja makes
+the second argument (family) is appended to the list~$F_{\mathrm{A}}$.
%
%<*ja>
-ä¸è¨3ã¤ã®ã³ãã³ãã¯ã¡ããã©NFSS2 ã® \cs{DeclareFontEncodingDefaults} ãªã©ã«å¯¾å¿ãããã®ã§ããï¼
+ã¾ãï¼\cs{DeclareFontFamily}ã\LuaTeX-jaã®èªã¿è¾¼ã¿å¾ã«å®è¡ãããå ´åã¯ï¼
+第2å¼æ°ï¼ãã¡ããªåï¼ãèªåçã«$F_{\mathrm{A}}$ã«è¿½å ãããï¼
%
-\item[\cs{reDeclareMathAlphabet}\{\}\{\}\{\}]
-
-% ToDo: en
+%<*en>
+The above order is very similar to \cs{fontfamily} in \pLaTeXe, but more complicated (clause~3.).
+This is because \pLaTeXe\ is a \emph{format} however \LuaTeX-ja is not,
+hence \LuaTeX-ja does not know calls of \cs{DeclareFontFamily} \emph{before} itself is
+loaded.
+%
%<*ja>
-åæã»æ¬§æã®æ°å¼ç¨ãã©ã³ããã¡ããªãä¸åº¦ã«å¤æ´ããå½ä»¤ãä½æããï¼
-å
·ä½çã«ã¯ï¼æ¬§ææ°å¼ç¨ãã©ã³ããã¡ããªå¤æ´ã®å½ä»¤ï¼\cs{mathrm} çï¼ã¨ï¼åææ°å¼ç¨ãã©
- ã³ããã¡ããªå¤æ´ã®å½ä»¤ï¼\cs{mathmc} çï¼ã®2ã¤ãåæã«è¡ãå½ä»¤ã¨ãã¦
- ãï¼åï¼å®ç¾©ããï¼å®éã®ä½¿ç¨ã§ã¯ã¨
- ã«åããã®ãæå®ããï¼ããªãã¡ï¼ã§åæå´ãå¤
- æ´ãããããã«ããã®ãä¸è¬çã¨æãããï¼
+以ä¸ã®æ¹éã¯\pLaTeXe ã«ããã \cs{fontfamily} ã«ãã¯ãé¡ä¼¼ãã¦ãããï¼3.ãå ããè¥å¹²è¤éã«ãªã£ã¦ããï¼
+ããã¯\pLaTeXe ããã©ã¼ãããã§ããã®ã«å¯¾ã\LuaTeX-jaã¯ããã§ãªãããï¼
+\LuaTeX-jaã¯èªèº«ãèªã¿è¾¼ã¾ããåã«ã©ããã\cs{DeclareFontFamily}ã®å¼ã³åºãããã£ãã
+ææ¡ã§ããªãããã§ããï¼
+%
-æ¬å½ä»¤ã¯
-\begin{center}\tt
-\{\}\quad$\longrightarrow$\quad
-(ã®1段å±éçµæ)\{ã®1段å±éçµæ)\{\}\}
-\end{center}
-ã¨å®ç¾©ãè¡ãã®ã§ï¼ä½¿ç¨ã«ã¯æ³¨æãå¿
è¦ã§ããï¼
-%\vspace{-\medskipamount}
-\begin{itemize}
-\item ,~ã¯æ¢ã«å®ç¾©ããã¦ããªããã°ãªããªãï¼
- \cs{reDeclareMathAlphabet}\\ã®å¾ã«
-両å½ä»¤ã®å
容ãåå®ç¾©ãã¦ãï¼ã®å
容ã«ããã¯åæ ãããªãï¼
-\item ,~ã«\verb+\@mathrm+ãªã©ã¨ \texttt{@} ãã¤ããå½ä»¤ãæå®ããæã®åä½ã¯ä¿è¨¼ã§ããªãï¼
-\end{itemize}
+%\paragraph{Remarks}
+%\paragraph{注æ}
+%<*en>
+Of course, there is a case that is not recognized as a Japanese font family, nor
+an alphabetic font family.
+In this case, \LuaTeX-ja treats ``the argument is wrong'', so
+set both current alphabetic and Japanese font family to ,
+to use the default family for font substitution.
+%
+%<*ja>
+ãã¦ï¼å¼æ°ã«ãã£ã¦ã¯ï¼ãåæãã©ã³ããã¡ããªã¨ã欧æãã©ã³ããã¡ããªãèªèãããªãã£ãã
+ã¨ããäºæ
ãããå¾ãï¼
+ ãã®å ´åï¼å¼æ°ã¯ä¸æ£ã ã£ãï¼ã¨ãããã¨ã«ãªãã®ã§ï¼
+åæã»æ¬§æã®ä¸¡æ¹ã®ãã©ã³ããã¡ããªãã«è¨å®ãï¼ä»£ç¨ãã©ã³ãã使ãããã«ä»»ãããã¨ã«ããï¼
%
-\item[\cs{DeclareRelationFont}\{\}\{\}\{\}\{\}\\*
- \null\hfill\{\}\{\}\{\}\{\}]
%<*en>
-This command sets the ``accompanied'' alphabetic font (given by the latter 4~arguments)
-with respect to a Japanese font given by the former 4~arguments.
+\subsection{Notes on \cs{DeclareTextSymbol}}
+From \LaTeX~2017/01/01, the standard encoding of \LuaLaTeX\ is changed to the \texttt{TU}
+encoding. This menas that symbols defined by \texttt{T1}~and~\texttt{TS1} encodings can be used
+without loading any package. To produces these symbols in alphabetic fonts in \LuaTeX-ja,
+\LuaTeX-ja patches \cs{DeclareTextSymbol}, and reloads \texttt{tuenc.def}.
+
+Under original definition of \cs{DeclareTextSymbol},
+internal commands which is defined by \cs{DeclareTextSymbol} (such as \cs{T1\cs{textquotedblleft}})
+are \textit{chardef} tokens. However, this no longer holds in \LuaTeX-ja;
+for example, the meaning of \cs{TU\cs{textquotedblleft}} is \cs{ltjalchar8220\ltjalchar"2423 }.
%
%<*ja>
-ãããããå¾å±æ¬§æããè¨å®ããããã®å½ä»¤ã§ããï¼ååã®4å¼æ°ã§è¡¨ãããåæãã©ã³ãã«å¯¾ãã¦ï¼
-ãã®ãã©ã³ãã«å¯¾å¿ãããå¾å±æ¬§æãã®ãã©ã³ããå¾åã®4å¼æ°ã«ããä¸ããï¼
+\subsection{\cs{DeclareTextSymbol}使ç¨æã®æ³¨æ}
+\LaTeX~(2017/01/01)以éã§ã¯ï¼\texttt{TU}ã¨ã³ã³ã¼ãã£ã³ã°ãæ¨æºã¨ãªãï¼ç¹ã«ä½ãããªãã¦ã
+\texttt{T1},~\texttt{TS1}ã¨ã³ã³ã¼ãã£ã³ã°ã§å®ç¾©ããã¦ããè¨å·é¡ã
+使ããããã«ãªã£ãï¼\LuaTeX-jaã§ã¯ãããã®å½ä»¤ã«ãã£ã¦è¨å·ã欧æãã©ã³ãã§åºåãããããã«ããããï¼
+\cs{DeclareTextSymbol}å½ä»¤ãæ¹å¤ãï¼ããã¦\texttt{TU}ã¨ã³ã³ã¼ãã£ã³ã°ã®å®ç¾©ã§ãã
+\texttt{tuenc.def}ãåèªè¾¼ãã¦ããï¼
+
+å¾æ¥ã¯ \cs{DeclareTextSymbol} ã§å
é¨çã«å®ç¾©ããã\cs{T1\cs{textquotedblleft}}ã¨ãã£ãå½ä»¤ã¯
+\textit{chardef}ãã¼ã¯ã³ã§ãã£ãï¼ãããå段è½ã§è¿°ã¹ãæ¹å¤ã«ãããã¯ãããã§ã¯ãªããªã£ã¦ããï¼ä¾ãã°
+\cs{TU\cs{textquotedblleft}}㯠\cs{ltjalchar8220\ltjalchar"2423 } ã¨ããå®ç¾©ã«ãªã£ã¦ããï¼%"
%
-\item[\cs{SetRelationFont}]
+
+\begin{table}[t]
+ \centering\small
+ \caption{strut}\label{tab:strutbox}
+ \begin{tabular}{llcccl}
+ \toprule
+ \textbf{box}&\textbf{direction}&\textbf{width}&\textbf{height}&\textbf{depth}
+ &\textbf{user command}\\
+ \midrule
+ \cs{ystrutbox}&yoko&0&0.7\cs{baselineskip}&0.3\cs{baselineskip}&\cs{ystrut}\\\midrule
+ \cs{tstrutbox}&tate, utod&0&0.5\cs{baselineskip}&0.5\cs{baselineskip}&\cs{tstrut}\\\midrule
+ \cs{dstrutbox}&dtou&0&0.7\cs{baselineskip}&0.3\cs{baselineskip}&\cs{dstrut}\\\midrule
+ \cs{zstrutbox}&---&0&0.7\cs{baselineskip}&0.3\cs{baselineskip}&\cs{zstrut}\\\bottomrule
+ \end{tabular}
+\end{table}
%<*en>
-This command is almost same as \cs{DeclareRelationFont}, except that this command does a local
-assignment, where \cs{DeclareRelationFont} does a global assignment.
+\subsection{\cs{strutbox}}
+As \pLaTeX~(2017/04/08 or later), \cs{strutbox} is \emph{a macro} which is expanded to one of
+\cs{ystrutbox},~\cs{tstrutbox},~and~\cs{dstrutbox}
+(all of them are shown in \autoref{tab:strutbox}), according to the current direction.
+Similarly, \cs{strut} now uses one of these boxes.
%
%<*ja>
-ãã®ã³ãã³ã㯠\cs{DeclareRelationFont} ã¨ãã¼ã«ã«ãªæå®ã§ãããã¨ãé¤ãã¦
-ã»ã¨ãã©åãã§ããï¼\cs{DeclareRelationFont} ã¯ã°ãã¼ãã«ï¼ï¼
+\subsection{\cs{strutbox}}
+\pLaTeX~2017/04/08以éã¨åãããã«ï¼
+\cs{strutbox}ã¯ç¾å¨ã®çµæ¹åã«ãã£ã¦\cs{ystrutbox}, \cs{tstrutbox}, \cs{dstrutbox}ã®
+ããããã«å±éããã\emph{ãã¯ã}ã¨ãªã£ã¦ããï¼ãããã«ã¤ãã¦ã¯\autoref{tab:strutbox}åç
§ï¼ï¼
+åæ§ã«\cs{strut}ããã®3\nobreak ããã¯ã¹ã®ãããããçµæ¹åã«ãã£ã¦ä½¿ãåããããã«ãªã£ã¦ããï¼
+
+\cs{zstrutbox}ã¯utodæ¹åï¼\pTeX ã§ãã縦æ°å¼ãã£ã¬ã¯ã·ã§ã³ï¼ã§ä½¿ãããæ¯æ±ããã¯ã¹ã§ãããï¼
+å®éã«ä½¿ãããã®ã¯\cs{zstrut}ãæ示çã«çºè¡ãããæï¼ããã¦
+\Pkg{lltjext}ããã±ã¼ã¸ã§è¿½å ãããçµæ¹åæå®ã§ \texttt{} ãæå®ããæï¼ããã³
+å¨å²ã縦çµã®ç¶æ³ã§ \texttt{} ãæå®ããæã«éããã¦ããï¼
%
-\item[\cs{userelfont}]
%<*en>
-Change current alphabetic font encoding/family/\dots\ to the `accompanied' alphabetic
- font family with respect to current Japanese font family,
- which was set by
- \cs{DeclareRelationFont} or \cs{SetRelationFont}.
-Like \cs{fontfamily}, \cs{selectfont} is required to take an effect.
+\section{Addon packages}
+\LuaTeX-ja has several addon packages.
+These addons are written as \LaTeX\ packages, but
+\Pkg{luatexja-otf} and~\Pkg{luatexja-adjust} can be loaded in plain \LuaTeX\
+by \cs{input}.
%
%<*ja>
-ç¾å¨ã®æ¬§æãã©ã³ãã®ã¨ã³ã³ã¼ãã£ã³ã°ï¼ãã¡ããªï¼â¦â¦ ãï¼
-\cs{DeclareRelationFont} ã \cs{SetRelationFont} ã§æå®ããã
-ç¾å¨ã®åæãã©ã³ãã«å¯¾å¿ãããå¾å±æ¬§æããã©ã³ãã«å¤æ´ããï¼
-\cs{fontfamily} ã®ããã«ï¼æå¹ã«ããããã«ã¯ \cs{selectfont} ãå¿
è¦ã§ããï¼
+\section{æ¡å¼µããã±ã¼ã¸}
+\LuaTeX-jaã«ã¯ï¼åä½ã«ã¯å¿
é ã§ã¯ãªããï¼èªç±ã«èªã¿è¾¼ããæ¡å¼µãä»å±ãã¦ããï¼
+ãããã¯\LaTeX ã®ããã±ã¼ã¸ã¨ãã¦å¶ä½ãã¦ãããï¼
+\Pkg{luatexja-otf}ã¨\Pkg{luatexja-adjust}ã«ã¤ãã¦ã¯plain \LuaTeX ã§ã\
+\cs{input} ã§èªã¿è¾¼ã¿å¯è½ã§ããï¼
%
-
-\item[\cs{adjustbaseline}]
+\subsection{\Pkg{luatexja-fontspec}}
+\label{ssec-fontspec2}
%<*en>
-In \pLaTeXe, \cs{adjustbaseline} sets \cs{tbaselineshift}
-to match the vertical center of ``M'' and that of ``ã'' in vertical typesetting:
-\[
-\text{\cs{tbaselineshift}} \leftarrow
-\frac{(h_{\text{M}}+d_{\text{M}}) - (h_{\text{ã}}+d_{\text{ã}})}2
- + d_{\text{ã}} - d_{\text{M}},
-\]
-where $h_{a}$~and~$d_{a}$ denote the height of ``$a$'' and the depth, respectively.
-In \LuaTeX-ja, this \cs{adjustbaseline} does similar task, namely setting the
- \Param{talbaselineshift} parameter.
-If the \LaTeX\ is 2015/10/01 release or later, \LuaTeX-ja use a Japanese
-character whose character class is zero, instead of `ã'.
+As described in Subsection~\ref{ssec-fontspec}, this optional package
+provides the counterparts for several commands defined in the
+\Pkg{fontspec} package (requires \Pkg{fontspec}~v2.4).
+In addition to OpenType font features in the original \Pkg{fontspec},
+the following ``font features'' specifications are allowed for
+the commands of Japanese version:
%
%<*ja>
-\pLaTeXe ã§ã¯ï¼\cs{adjustbaseline} ã¯ç¸¦çµæã«ãMãã¨ãããã®ä¸å¿ç·ãä¸è´ãããããã«ï¼
-\cs{tbaselineshift} ãè¨å®ããå½¹å²ãæã£ã¦ããï¼
-\[
-\text{\cs{tbaselineshift}} \leftarrow
-\frac{(h_{\text{M}}+d_{\text{M}}) - (h_{\text{ã}}+d_{\text{ã}})}2
- + d_{\text{ã}} - d_{\text{M}},
-\]
-ããã§ï¼$h_{a}$,~$d_{a}$ã¯ããããã$a$ãã®é«ãã»æ·±ãã表ãï¼
-\LuaTeX-jaã«ããã¦ã\cs{adjustbaseline} ã¯åæ§ã«\Param{talbaselineshift}ãã©ã¡ã¼ã¿ã®èª¿æ´å¦
- çãè¡ã£ã¦ããï¼
-
-åæã«ï¼ããã\pLaTeXe ã® \cs{adjustbaseline} ã§åæ§ã®å¦çãè¡ããã¦ãããï¼
-ãæ¼¢ãã®å¯¸æ³ãå
ã«ï¼æ¬ç¯ã®æåã«è¿°ã¹ãï¼å°æåã§å§ã¾ãï¼\cs{cht}, \cs{cwd}
-ã¨ãã£ãé·ãå¤æ°ãè¨å®ããï¼
+\ref{ssec-fontspec}ç¯ã§è¿°ã¹ãããã«ï¼ãã®è¿½å ããã±ã¼ã¸ã¯\Pkg{fontspec}%
+ããã±ã¼ã¸ã§å®ç¾©ããã¦ããã³ãã³ãã«å¯¾å¿ããåæãã©ã³ãç¨ã®ã³ãã³ããæä¾ããï¼
-ãªãï¼\LaTeX ã2015/10/01 ç以éã®å ´åã¯ï¼ããããæ¼¢ãã®ä»£ããã«
-ãæåã¯ã©ã¹0ã®åææåããç¨ããï¼
+\Pkg{fontspec}ããã±ã¼ã¸ã§æå®å¯è½ãªå種OpenTypeæ©è½ã«å ãã¦ï¼åæçã®ã³ãã³ãã«ã¯
+以ä¸ã®ããã©ã³ãæ©è½ããæå®ãããã¨ãã§ããï¼
%
-\item[\cs{fontfamily}\{\}]
+
+\begin{cslist}
+\item[CID=\textrm{, }JFM=\textrm{, }JFM-var=]
+
%<*en>
-As in \LaTeXe, this command changes current font family (alphabetic, Japanese,~\emph{or both})
-to . See Subsection~\ref{ssec-fontfamilycmd} for detail.
+These 3 keys correspond to \texttt{cid}, \texttt{jfm} and
+\texttt{jfmvar} keys for \cs{jfont}~and~\cs{tfont} respectively.
+See Subsections~\ref{ssec-jfont} and \ref{ssec-psft} for details
+ of \texttt{cid}, \texttt{jfm} and
+\texttt{jfmvar} keys.
+
+The \texttt{CID} key is effective only when with \texttt{NoEmbed}
+described below. The same JFM cannot be used in both horizontal Japanese fonts and
+ vertical Japanese fonts, hence the \texttt{JFM} key
+will be actually used in \texttt{YokoFeatures}~and~\texttt{TateFeatures} keys.
%
%<*ja>
-å
ã
ã®\LaTeXe ã«ããããã®ã¨åæ§ã«ï¼ãã®ã³ãã³ãã¯ç¾å¨ã®ãã©ã³ããã¡ããªï¼æ¬§æï¼
-åæï¼\emph{ãããã¯ä¸¡æ¹}ï¼ãã«å¤æ´ããï¼è©³ç´°ã¯\ref{ssec-fontfamilycmd}ç¯ãåç
§ãããã¨ï¼
+ããã3ã¤ã®ãã¼ã¯ãããã \cs{jfont},~\cs{tfont}ã«å¯¾ãã
+\texttt{cid}, \texttt{jfm}, \texttt{jfmvar}ãã¼ã¨ãããã対å¿ããï¼
+\texttt{cid}, \texttt{jfm}, \texttt{jfmvar}ãã¼ã®è©³ç´°ã¯\ref{ssec-jfont}ç¯
+ ã¨\ref{ssec-psft}ç¯ãåç
§ï¼
+
+\texttt{CID} ãã¼ã¯ä¸ã® \texttt{NoEmbed} ã¨åããã¦ç¨ããããã¨ãã®ã¿æå¹ã§ããï¼
+ã¾ãï¼æ¨ªçµç¨JFMã¨ç¸¦çµç¨JFMã¯å
±ç¨ã§ããªãããï¼å®éã« \texttt{JFM} ãã¼ãç¨ããéã¯
+å¾ã«è¿°ã¹ã\ \texttt{YokoFeatures} ãã¼ã \texttt{TateFeatures}\ ã®ä¸ã§ç¨ãã
+ãã¨ã«ãªãï¼
%
+\item[NoEmbed]
+%<*en>
+By specifying this key, one can use ``name-only'' Japanese font which
+will not be embedded in the output PDF file. See Subsection~\ref{ssec-psft}.
+%
+%<*ja>
+ãããæå®ãããã¨ã§ï¼PDFã«åãè¾¼ã¾ããªããååã ããã®ãã©ã³ããæå®ãããã¨ã
+ã§ããï¼\ref{ssec-psft}ç¯ãåç
§ï¼
+%
\begin{figure}[!tb]
-\begin{LTXexample}[pos=b]
-\DeclareKanjiFamily{JY3}{edm}{}
-\DeclareFontShape{JY3}{edm}{m}{n} {<-> s*KozMinPr6N-Regular:jfm=ujis;}{}
-\DeclareFontShape{JY3}{edm}{m}{green}{<-> s*KozMinPr6N-Regular:jfm=ujis;color=007F00}{}
-\DeclareFontShape{JY3}{edm}{m}{blue} {<-> s*KozMinPr6N-Regular:jfm=ujis;color=0000FF}{}
-\DeclareAlternateKanjiFont{JY3}{edm}{m}{n}{JY3}{edm}{m}{green}{"4E00-"67FF,{-2}-{-2}}
-\DeclareAlternateKanjiFont{JY3}{edm}{m}{n}{JY3}{edm}{m}{blue}{ "6800-"9FFF}
-{\kanjifamily{edm}\selectfont
-æ¥æ¬å½æ°ã¯ãæ£å½ã«é¸æãããå½ä¼ã«ããã代表è
ãéãã¦è¡åããâ¦â¦}
+\begin{LTXexample}[width=0.25\textwidth]
+\jfontspec[
+ YokoFeatures={Color=007F00}, TateFeatures={Color=00007F},
+ TateFont=KozGoPr6N-Regular
+]{KozMinPr6N-Regular}
+\hbox{\yoko 横çµã®ãã¹ã}\hbox{\tate 縦çµã®ãã¹ã}
+\addjfontfeatures{Color=FF0000}
+\hbox{\yoko 横çµ}\hbox{\tate 縦çµ}
\end{LTXexample}
-%\caption{\cs{DeclareAlternateKanjiFont} ã®ä½¿ç¨ä¾}
-%\caption{An example of \cs{DeclareAlternateKanjiFont}}
-\label{fig:altkanji}
+%\caption{\texttt{TateFeatures} çã®ä½¿ç¨ä¾}
+%\caption{An example of \texttt{TateFeatures} etc.}
+\label{fig:yokotate-fontspec}
\end{figure}
-\item[\cs{DeclareAlternateKanjiFont}\{\}\{\}\{\}\{\}\\
- \null\hfill\{\}\{\}\{\}\{\}\{\}]
+\item[Kanjiskip=]
%<*ja>
-\ref{ssec-altfont}ç¯ã®\
-\cs{ltjdeclarealtfont} ã¨åæ§ã«ï¼ååã®4å¼æ°ã®
-åæãã©ã³ãï¼åºåºãã©ã³ãï¼ã®ãã¡ä¸ã®æåã
-第5ãã第8å¼æ°ã®åæãã©ã³ãã使ã£ã¦çµãããã«æ示ããï¼
-使ç¨ä¾ãå³\nobreak\ref{fig:altkanji}ã«è¼ããï¼
-
-\begin{itemize}
- \item
-\cs{ltjdeclarealtfont} ã§ã¯åºåºãã©ã³ãã»ç½®ãæãå
åæãã©ã³ãã¯ãããããå®ç¾©ããã¦ã
- ãªãã¨ãããªãï¼ãã®ä»£ããå³æçºå¹ï¼ã§ãã£ããï¼
-\cs{DeclareAlternateKanjiFont} ã®è¨å®ã
-å®éã«å¹åãçºæ®ããã®ã¯ï¼æ¸ä½å¤æ´ããµã¤ãºå¤æ´ãè¡ã£ãæï¼
-ãããã¯ï¼ããããå«ããï¼\cs{selectfont} ãå®è¡ãããæã§ããï¼
- \item
-段è½ãhboxã®æå¾ã§ã®è¨å®å¤ã段è½ï¼hboxå
¨ä½ã«ããã£ã¦éç¨ããç¹ãï¼
-ã«è² æ°$-n$ãæå®ããå ´åï¼ããããåºåºãã©ã³ãã®æåã¯ã©ã¹$n$ã«å±ããæåå
¨ä½ã
-ã¨è§£éãããã®ã¯ \cs{ltjdeclarealtfont} ã¨åãã§ããï¼
-\end{itemize}%
+\pageref{pg:ltjksp}ãã¼ã¸ã§èª¬æãã \verb+\jfont+ ä¸ã§ã® \texttt{ltjksp} æå®ã¨
+åä¸ã®å¹åãæã¡ï¼
+JFMä¸ã«ããã \texttt{kanjiskip\_natural}, \texttt{kanjiskip\_stretch},\
+\texttt{kanjiskip\_shrink}ãã¼ï¼\pageref{pg:ksp_nat}ãã¼ã¸ï¼ã®æå¹/ç¡å¹ãåãæ¿ããï¼
+æ¨æºå¤ã¯ \texttt{true} ã§ããï¼
%
-%<*en>
-As \cs{ltjdeclarealtfont}~(Subsection~\ref{ssec-altfont}),
-characters in of the Japanese font (we say the \emph{base font})
-which specified by first 4 arguments are typeset
-by the Japanese font which specified by fifth to eighth arguments
-(we say the \emph{alternate font}).
-An example is shown in Figure~\ref{fig:altkanji}.
-
-\begin{itemize}
- \item
-In \cs{ltjdeclarealtfont}, the base font and the alternate font must be already defined.
-But this \cs{DeclareAlternateKanjiFont} is not so.
-In other words, \cs{DeclareAlternateKanjiFont} is effective only after
-current Japanese font is changed, or only after \cs{selectfont} is executed.
- \item \dots
-\end{itemize}%
-\vspace{-\medskipamount}
-%
-\end{cslist}
+\item[TateFeatures=\{\}\textrm{, }TateFont=]
%<*en>
-As closing this subsection, we shall introduce an example of
-\cs{SetRelationFont} and \cs{userelfont}:
+The \texttt{TateFeatures} key specifies font features which are only turned~on in
+vertical writing, such as \texttt{Style=VerticalKana}~(\texttt{vkna} feature).
+Similarly, the \texttt{TateFont} key specifies the Japanese font which will be used only
+ in vertical writing.
+A demonstrarion is shown in \autoref{fig:yokotate-fontspec}.
%
%<*ja>
-ãã®ç¯ã®çµããã«ï¼\cs{SetRelationFont} 㨠\cs{userelfont} ã®ä¾ã
-ç´¹ä»ãã¦ãããï¼\cs{userelfont} ã®ä½¿ç¨ã«ãã£ã¦ï¼ãabcãã®é¨åã®ãã©ã³ãã
-Avant Garde (OT1/pag/m/n) ã«å¤ãã£ã¦ãããã¨ããããï¼
+縦çµã«ããã¦ä½¿ç¨ããããã©ã³ããï¼ç¸¦çµã«ããã¦ã®ã¿é©ç¨ããããã©ã³ãæ©è½éã
+æå®ããï¼ä½¿ç¨ä¾ã¯\autoref{fig:yokotate-fontspec}åç
§ï¼
%
-\begin{LTXexample}[width=0.3\textwidth]
-\makeatletter
-\SetRelationFont{JY3}{\k@family}{m}{n}{OT1}{pag}{m}{n}
- % \k@family: current Japanese font family
-\userelfont\selectfont ãããabc
-\end{LTXexample}
-%\subsection{Detail of \cs{fontfamily} command}
-%\subsection{\cs{fontfamily}ã³ãã³ãã®è©³ç´°}
-\label{ssec-fontfamilycmd}
+\item[YokoFeatures=\{\}]
%<*en>
-In this subsection, we describe when \cs{fontfamily} changes current
-Japanese/alphabetic font family. Basically, current Japanese fotn family is changed to
- if it is recognized as a Japanese font family, and similar with alphabetic font
-family. There is a case that current Japanese/alphabetic font family are both changed to
-, and another case that isn't recognized as a Japanese/alphabetic font
-family either.
-
-\paragraph{Recognition as Japanese font family}
-First, Whether Japanese font family will be changed is determined in following order.
-This order is very similar to \cs{fontfamily} in \pLaTeXe, but we re-implemented in Lua.
-We use an auxiliary list~$N_{\mathrm{J}}$.
+The \texttt{YokoFeatures} key specifies font features which are only turned~on in
+horizontal writing,.
+A demonstrarion is shown in \autoref{fig:yokotate-fontspec}.
%
%<*ja>
-æ¬ç¯ã§ã¯ï¼\cs{fontfamily} ããã¤åæ/欧æãã©ã³ããã¡ããªãå¤æ´ãããã«ã¤ãã¦è§£èª¬
-ããï¼åºæ¬çã«ã¯ï¼ãåæãã©ã³ããã¡ããªã ã¨èªèãããã°åæå´ãï¼æ¬§æãã©ã³ããã¡
-ããªã ã¨èªèãããã°æ¬§æå´ãå¤æ´ãããï¼ã©ã¡ãã¨ãèªèãããã°åæã»æ¬§æã®ä¸¡æ¹ãå¤ããã
-ã¨ã«ãªããï¼å½ç¶ã©ã¡ãã¨ãèªèãããªããã¨ãããï¼
-
-\paragraph{åæãã©ã³ããã¡ããªã¨ãã¦ã®èªè}
-ã¾ãï¼ãåæãã©ã³ããã¡ããªã¨ãã¦èªèããããã¯ä»¥ä¸ã®é åºã§æ±ºå®ãããï¼
-ããã¯\pLaTeXe ã® \cs{fontfamily} ã«ã¨ã¦ãä¼¼ã¦ãããï¼ããã§ã¯Luaã«ãã£ã¦å®è£
ãã¦ããï¼
-è£å©çã«ãåæãã©ã³ããã¡ããªã§ã¯ãªãã¨èªèãããããã¡ããªãæ ¼ç´ãããªã¹ã$N_{\mathrm{J}}$ãç¨ããï¼
+åæ§ã«ï¼æ¨ªçµã«ããã¦ã®ã¿é©ç¨ããããã©ã³ãæ©è½éã
+æå®ããï¼ä½¿ç¨ä¾ã¯\autoref{fig:yokotate-fontspec}åç
§ï¼
%
-\begin{enumerate}
-%<*en>
-\item If the family~ has been defined already by \cs{DeclareKanjiFamily},
- is recognized as a Japanese font family.
- Note that need not be defined under \emph{current} Japanese font encoding.
+
+
+\begin{figure}[!tb]
+\begin{LTXexample}[pos=b]
+\jfontspec[
+ AltFont={
+ {Range="4E00-"67FF, Color=007F00},
+ {Range="6800-"9EFF, Color=0000FF},
+ {Range="3040-"306F, Font=KozGoPr6N-Regular},
+ }
+]{KozMinPr6N-Regular}
+æ¥æ¬å½æ°ã¯ãæ£å½ã«é¸æãããå½ä¼ã«ããã代表è
ãéãã¦è¡åãããããã¨ãããã®åå«ã®ããã«ã
+諸å½æ°ã¨ã®ååã«ããææã¨ãããå½å
¨åã«ããã¤ã¦èªç±ã®ããããæµæ²¢ã確ä¿ããâ¦â¦
+\end{LTXexample}
+%\caption{\texttt{AltFont} ã®ä½¿ç¨ä¾}
+%\caption{An example of \texttt{AltFont}}
+\label{fig:altkanji-fontspec}
+\end{figure}
+
+\item[AltFont]
+
+%<*en>
+As \cs{ltjdeclarealtfont}~(Subsection~\ref{ssec-altfont}) and
+\cs{DeclareAlternateKanjiFont}~(Subsection~\ref{ssec-nfsspat}),
+with this key, one can typeset some Japanese characters
+by a different font and/or using different features.
+The \texttt{AltFont} feature takes a comma-separated list of comma-separated lists,
+as the following:
%
%<*ja>
-\item ãã¡ããªãæ¢ã« \cs{DeclareKanjiFamily} ã«ãã£ã¦å®ç¾©ããã¦ããå ´åï¼
- ã¯åæãã©ã³ããã¡ããªã§ããã¨èªèãããï¼
- ããã§ï¼ã¯ç¾å¨ã®åæãã©ã³ãã¨ã³ã³ã¼ãã£ã³ã°ã§å®ç¾©ããã¦ããªãã¦ãããï¼
+\ref{ssec-altfont}ç¯ã® \cs{ltjdeclarealtfont} ãï¼
+\ref{ssec-nfsspat}ç¯ã® \cs{DeclareAlternateKanjiFont} ã¨åæ§ã«ï¼
+ãã®ãã¼ãç¨ããã¨ä¸é¨ã®æåãç°ãªã£ããã©ã³ããæ©è½ãã¡ã使ã£ã¦çµããã¨ãã§ããï¼
+\texttt{AltFont} ãã¼ã«æå®ããå¤ã¯ï¼æ¬¡ã®ããã«äºéã®ã³ã³ãåºåããªã¹ãã§ããï¼
%
+\begin{lstlisting}[escapechar=\#]
+AltFont = {
+ ...
+ { Range=#\LARG range>#, #\LARG features>#},
+ { Range=#\LARG range>#, Font=#\LARG font~name>#, #\LARG features># },
+ { Range=#\LARG range>#, Font=#\LARG font~name># },
+ ...
+}
+\end{lstlisting}
%<*en>
-\item If the family~ has been listed in a list~$N_{\mathrm{J}}$, this means
- that is not a Japanese font family.
+Each sublist should have the \texttt{Range} key
+(sublist which does not contain \texttt{Range} key is simply ignored).
+A demonstrarion is shown in \autoref{fig:altkanji-fontspec}.
%
%<*ja>
-\item ãã¡ããªããªã¹ã$N_{\mathrm{J}}$ã«æ¢ã«å«ã¾ãã¦ããã°ï¼ããã¯
- ãåæãã©ã³ããã¡ããªã§ã¯ãªããã¨ãæå³ããï¼
+åé¨åãªã¹ãã«ã¯ \texttt{Range} ãã¼ãå¿
é ã§ããï¼å«ã¾ããªãé¨åãªã¹ãã¯
+åç´ã«ç¡è¦ãããï¼ï¼æå®ä¾ã¯\autoref{fig:altkanji-fontspec}ã«ç¤ºããï¼
+%
+\end{cslist}
+
+%<*ja>
+ãªãï¼\Pkg{luatexja-fontspec} èªã¿è¾¼ã¿æã«ã¯åæãã©ã³ãå®ç¾©ãã¡ã¤ã«%
+\texttt{.fd}ã¯å
¨ãåç
§ãããªããªãï¼
%
+
+
%<*en>
-\item If the \Pkg{luatexja-fontspec} package is loaded, we stop here, and is not
- recognized as a Japanese font family.
+\paragraph{Remark on \texttt{AltFont}, \texttt{YokoFeatures}, \texttt{TateFeatures} keys}
+\leavevmode\par
+In \texttt{AltFont},~\texttt{YokoFeatures},~\texttt{TateFeatures} keys,
+one cannot specify per-shape settings such as \texttt{BoldFeatures}.
+For example,
+\begin{lstlisting}
+AltFont = {
+ { Font=HogeraMin-Light, BoldFont=HogeraMin-Bold,
+ Range="3000-"30FF, BoldFeatures={Color=007F00} }
+}
+\end{lstlisting}
+does \emph{not} work. Instead, one have to write
+\begin{lstlisting}
+UprightFeatures = {
+ AltFont = { { Font=HogeraMin-Light, Range="3000-"30FF, } },
+},
+BoldFeatures = {
+ AltFont = { { Font=HogeraMin-Bold, Range="3000-"30FF, Color=007F00 } },
+}
+\end{lstlisting}
- If the \Pkg{luatexja-fontspec} package is \emph{not} loaded,
-now \LuaTeX-ja looks whether there exists a Japanese font encoding~ such that
- a font definition named \texttt{.fd} (the file name is
- all lowercase) exists. If so, is recognized as a Japanese font family (the font definition file won't be loaded here).
- If not, is not a Japanese font family, and
- is appended to the list~$N_{\mathrm{J}}$.
+On the other hand, \texttt{YokoFeatures}, \texttt{TateFeatures} and \texttt{TateFont}
+keys can be specified in each list in the \texttt{AltFont} key. Also,
+one can specify \texttt{AltFont} inside \texttt{YokoFeatures},~\texttt{TateFeatures}.
+
+Note that features which are specified in \texttt{YokoFeatures}~and~\texttt{TateFeatures}
+are always interpreted \emph{after} other ``direction-independent'' features.
+This explains why \cs{addjfontfeatures} at~line~6 in~\autoref{fig:yokotate-fontspec}
+has no effect, because a color specification is already done in
+\texttt{YokoFeatures}~and~\texttt{TateFeatures} keys.
%
%<*ja>
-\item ãã\Pkg{luatexja-fontspec}ããã±ã¼ã¸ãèªã¿è¾¼ã¾ãã¦ããã°ï¼ããã§çµäºã§ããï¼
-ã¯åæãã©ã³ããã¡ããªã¨ãã¦èªèãããªããã¨ã«ãªãï¼
+\paragraph{\texttt{AltFont}, \texttt{YokoFeatures}, \texttt{TateFeatures} çã®å¶é}
+\texttt{AltFont},~\texttt{YokoFeatures},~\texttt{TateFeatures}ã®åãã¼ã¯
+ã·ã§ã¤ãå¥ã«æå®ãããã¹ããã®ã§ããï¼
+å
é¨ã§ã¯ \texttt{BoldFeatures} ãªã©ã®ã·ã§ã¤ãå¥ã®æå®ã¯è¡ããã¨ãåºæ¥ãªãï¼
+ä¾ãã°ï¼
+\begin{lstlisting}
+AltFont = {
+ { Font=HogeraMin-Light, BoldFont=HogeraMin-Bold,
+ Range="3000-"30FF, BoldFeatures={Color=007F00} }
+}
+\end{lstlisting}
+ã®ããã«æå®ãããã¨ã¯åºæ¥ãï¼
+\begin{lstlisting}
+UprightFeatures = {
+ AltFont = { { Font=HogeraMin-Light, Range="3000-"30FF, } },
+},
+BoldFeatures = {
+ AltFont = { { Font=HogeraMin-Bold, Range="3000-"30FF, Color=007F00 } },
+}
+\end{lstlisting}
+ã®ããã«æå®ããªããã°ãªããªãï¼
-ãã\Pkg{luatexja-fontspec}ããã±ã¼ã¸ãèªã¿è¾¼ã¾ãã¦ããªããã°ï¼åæã¨ã³ã³ã¼ãã£ã³ã°ã§
-ãã©ã³ãå®ç¾©ãã¡ã¤ã«\texttt{.fd}ï¼ãã¡ã¤ã«åã¯å
¨ã¦å°æåï¼ãåå¨ãããããªã
- ã®ããããã©ããã調ã¹ãï¼
-åå¨ããã°ï¼ã¯åæãã©ã³ããã¡ããªã¨èªèãããï¼ãã©ã³ãå®ç¾©ãã¡ã¤ã«ã¯èªã¿è¾¼ã¾ããª
- ãï¼ï¼
-åå¨ããªããã°ï¼ã¯åæãã©ã³ããã¡ããªã§ãªãã¨èªèããï¼ãªã¹ã$N_{\mathrm{J}}$ã«ã追å ãããã¨ã§ãããè¨æ¶ããï¼
+ä¸æ¹ï¼\texttt{AltFont} ãã¼å
ã®åãªã¹ãã§ã¯
+\ \texttt{YokoFeatures},~\texttt{TateFeatures} åã³ \texttt{TateFont} ãã¼ã
+æå®ãããã¨ã¯å¯è½ã§ããï¼ã¾ã\ \texttt{YokoFeatures},~\texttt{TateFeatures} ãã¼ã®
+ä¸èº«ã« \texttt{AltFont} ãæå®ãããã¨ãã§ããï¼
+
+ã¾ãï¼\autoref{fig:yokotate-fontspec}å¾åé¨ã§ã¯6è¡ç®ã®è²ã®æå®ãå¹ããï¼
+2è¡ç®ã§æå®ãã\ \texttt{YokoFeatures},~\texttt{TateFeatures}\ ã«ããè²ã®æå®ãæå¹ã«ãªã£
+ãã¾ã¾ã§ããï¼ããã¯\emph{\ \texttt{YokoFeatures},~\texttt{TateFeatures}\ ã«ãã
+OpenTypeæ©è½æå®ã¯
+çµæ¹åã«ä¾åããªãOpenTypeæ©è½ã®æå®ããå¾ã«è§£éããã}ããã§ããï¼
%
-\end{enumerate}
+
+\subsection{\Pkg{luatexja-otf}}
+\label{ssec-ltjotf}
%<*en>
-\paragraph{Recognition as alphabetic font family}
-Next, whether alphabetic font family will be changed is determined in following order.
-We use auxiliary lists $F_{\mathrm{A}}$~and~$N_{\mathrm{A}}$,
+This optional package supports typesetting glyphs
+by specifying a CID number.
+The package \Pkg{luatexja-otf} offers the following 2~low-level
+commands:
%
%<*ja>
-\paragraph{欧æãã©ã³ããã¡ããªã¨ãã¦ã®èªè}
-åæ§ã«ï¼ãåæãã©ã³ããã¡ããªã¨ãã¦èªèããããã¯ä»¥ä¸ã®é åºã§æ±ºå®ãããï¼
-è£å©çã«ã欧æãã©ã³ããã¡ããªã¨æ¢ã«èªèãããããã¡ããªã®ãªã¹ã$F_{\textrm{A}}$ã¨ï¼
-ã欧æãã©ã³ããã¡ããªã§ã¯ãªãã¨èªèãããããã¡ããªãæ ¼ç´ãããªã¹ã$N_{\mathrm{A}}$ãç¨ããï¼
+ãã®è¿½å ããã±ã¼ã¸ã¯CIDçªå·ã«ããæåã®åºåããµãã¼ãããï¼
+\Pkg{luatexja-otf}ã¯ä»¥ä¸ã®2ã¤ã®ä½ã¬ãã«ã³ãã³ããæä¾ããï¼
%
-
-\begin{enumerate}
+\begin{cslist}
+\item[\cs{CID}\{\}]
%<*en>
-\item If the family~ has been listed in a list~$F_{\mathrm{A}}$,
- is recognized as an alphabetic font family.
+Typeset a glyph whose CID number is .
+If the Japanese font is neither Adobe-Japan1,~Adobe-GB1, Adobe-CNS1,~nor~Adobe-Korea1 CID-keyed font,
+\LuaTeX-ja treats that is a CID number of Adobe-Japan1 character collection,
+and tries to typeset a ``most suitable glyph''.
%
%<*ja>
-\item ãã¡ããªããªã¹ã$F_{\mathrm{A}}$ã«æ¢ã«å«ã¾ãã¦ããã°ï¼
- ã¯æ¬§æãã©ã³ããã¡ããªã¨èªèãããï¼
+CIDçªå·ãã®æåãåºåããï¼
+ããç¾å¨ã®åæãã©ã³ããAdobe-Japan1,~Adobe-GB1, Adobe-CNS1,~Adobe-Korea1ã®
+ ãããã®CID-keyed fontã§ããªãå ´åï¼ã¯Adobe-Japan1ã®CIDçªå·ã§ããã¨è§£éã
+ ãé©åãªã°ãªãã\footnote{%
+ ä¾ãã°ãã©ã³ãã«IVDã³ã¬ã¯ã·ã§ã³Adobe-Japan1ãå«ã¾ãã¦ããã°ï¼ãã®æ
å ±ãç¨ãã¦
+ ã°ãªããé¸æããï¼
+}ãåºåããï¼
%
+
+\item[\cs{UTF}\{\}]
%<*en>
-\item If the family~ has been listed in a list~$N_{\mathrm{A}}$, this means
- that is not an alphabetic font family.
+Typeset a character whose character code is (in hexadecimal).
+This command is similar to \verb+\char"+,\ %"
+but please remind remarks below.
%
%<*ja>
-\item ãã¡ããªããªã¹ã$N_{\mathrm{A}}$ã«æ¢ã«å«ã¾ãã¦ããã°ï¼ããã¯
- ã欧æãã©ã³ããã¡ããªã§ã¯ãªããã¨ãæå³ããï¼
+æåã³ã¼ããï¼16é²ã§ï¼ã®æåãåºåããï¼
+ãã®ã³ãã³ã㯠\verb+\char"+ã¨ä¼¼ã¦ãããï¼ä¸ã®æ³¨æãåç
§ãããã¨ï¼%"
+%
+\end{cslist}
+
+%<*ja>
+ãã®ããã±ã¼ã¸ã¯ï¼ãã¯ãé \texttt{luatexja-ajmacros.sty}\footnote{\Pkg{otf}ããã±ã¼ã¸ä»å±ã®äºä¸æµ©ä¸æ°ã«ãããã¯ãé
+\texttt{ajmacros.sty} ã«å¯¾ãã¦
+æ¼¢åã³ã¼ããUTF-8ã«ãããï¼plain \LuaTeX ã§ãå©ç¨å¯è½ã«ããã¨ãã
+ä¿®æ£ãå ãããã®ã§ããï¼}\ ãèªåçã«èªã¿è¾¼ãï¼
+\texttt{luatexja-ajmacros.sty} ã¯ï¼
+ãã®ããï¼\Pkg{luatexja-otf} ãèªã¿ããã° \texttt{ajmacros.sty} ãã¯ãéã«ãã \cs{ajåè§} ãªã©ã®ãã¯ãããã®ã¾ã¾ä½¿ããã¨ãã§ããï¼
%
%<*en>
-\item If there exists an alphabetic font encoding such that the family~ has been
- defined under it, is recognized as an alphabetic font family, and
- to memorize this, is appended to the list~$F_{\mathrm{A}}$.
+This package automatically loads \texttt{luatexja-ajmacros.sty}, which is slightly
+modified version of \texttt{ajmacros.sty}\footnote{Useful macros by iNOUE Koich!, for the
+\Pkg{japanese-otf} package.}.
+Hence one can use macros which sre defined in \texttt{ajmacros.sty}, such as~\cs{ajåè§}.
+%
+
+%\paragraph{Remarks}
+%\paragraph{注æ}
+%<*en>
+Characters by \cs{CID} and \cs{UTF} commands are different from
+ordinary characters in the following points:
%
%<*ja>
-\item ãã欧æãã©ã³ãã¨ã³ã³ã¼ãã£ã³ã°ä¸ã§ãã¡ããªãå®ç¾©ããã¦ããã°ï¼
- ã¯æ¬§æãã©ã³ããã¡ããªã¨èªèããï¼ãªã¹ã$F_{\mathrm{A}}$ã«ã追å ãããã¨ã§ãã®ãã¨ãè¨æ¶ããï¼
+\cs{CID} 㨠\cs{UTF} ã³ãã³ãã«ãã£ã¦åºåãããæåã¯
+以ä¸ã®ç¹ã§é常ã®æåã¨ç°ãªãï¼
%
+\begin{itemize}
%<*en>
-\item Now \LuaTeX-ja looks whether there exists an alphabetic font encoding~ such that
- a font definition named \texttt{.fd} (the file name is
- all lowercase) exists. If so, current alphabetic font family will be changed to
- ~(the font definition file won't be loaded here).
- If not, current alphabetic font family won't be changed, and
- is appended to the list~$N_{\mathrm{A}}$.
+\item Always treated as \textbf{JAchar}s.
%
%<*ja>
-\item æçµæ®µéã§ã¯ï¼æ¬§æã¨ã³ã³ã¼ãã£ã³ã°ã§
-ãã©ã³ãå®ç¾©ãã¡ã¤ã«\texttt{.fd}ï¼ãã¡ã¤ã«åã¯å
¨ã¦å°æåï¼ãåå¨ãããããªã
- ã®ããããã©ããã調ã¹ãï¼
-åå¨ããã°ï¼ã¯æ¬§æãã©ã³ããã¡ããªã¨èªèãããï¼ãã©ã³ãå®ç¾©ãã¡ã¤ã«ã¯èªã¿è¾¼ã¾ããªãï¼ï¼
-åå¨ããªããã°ï¼ã¯æ¬§æãã©ã³ããã¡ããªã¨èªèãããªãã®ã§ï¼ãªã¹ã$N_{\mathrm{A}}$ã«
- ã追å ãã¦ãã®ãã¨ãè¨æ¶ããï¼
+\item 常ã«\textbf{JAchar}ã¨ãã¦æ±ãããï¼
%
-\end{enumerate}
-
%<*en>
-Also, each call of \cs{DeclareFontFamily} \emph{after} loading of \LuaTeX-ja makes
-the second argument (family) is appended to the list~$F_{\mathrm{A}}$.
+\item Processing codes for supporting OpenType features (\textit{e.g.},
+ glyph replacement and kerning) by the \Pkg{luaotfload} package
+ is not performed to these characters.
%
%<*ja>
-ã¾ãï¼\cs{DeclareFontFamily}ã\LuaTeX-jaã®èªã¿è¾¼ã¿å¾ã«å®è¡ãããå ´åã¯ï¼
-第2å¼æ°ï¼ãã¡ããªåï¼ãèªåçã«$F_{\mathrm{A}}$ã«è¿½å ãããï¼
+\item OpenTypeæ©è½ï¼ä¾ãã°ã°ãªãç½®æãã«ã¼ãã³ã°ï¼ããµãã¼ãããããã®
+ \Pkg{luaotfload}ããã±ã¼ã¸ã®ã³ã¼ãã¯ãããã®æåã«ã¯åããªãï¼
%
+\end{itemize}
+
+%\paragraph{Additional syntax of JFM}
+%\paragraph{JFMã¸ã®è¨æ³ã®è¿½å }
%<*en>
-The above order is very similar to \cs{fontfamily} in \pLaTeXe, but more complicated (clause~3.).
-This is because \pLaTeXe\ is a \emph{format} however \LuaTeX-ja is not,
-hence \LuaTeX-ja does not know calls of \cs{DeclareFontFamily} \emph{before} itself is
-loaded.
+The package \Pkg{luatexja-otf} extends the syntax of JFM; the entries of \texttt{
+chars} table in JFM now allows a string in the form
+\verb+'AJ1-xxx'+, which stands for the character
+whose CID number in Adobe-Japan1 is \verb+xxx+.
+
+This extended notation is used in the standard JFM \texttt{jfm-ujis.lua}
+to typeset halfwidth Hiragana glyphs (CID~516--598) in halfwidth.
%
%<*ja>
-以ä¸ã®æ¹éã¯\pLaTeXe ã«ããã \cs{fontfamily} ã«ãã¯ãé¡ä¼¼ãã¦ãããï¼3.ãå ããè¥å¹²è¤éã«ãªã£ã¦ããï¼
-ããã¯\pLaTeXe ããã©ã¼ãããã§ããã®ã«å¯¾ã\LuaTeX-jaã¯ããã§ãªãããï¼
-\LuaTeX-jaã¯èªèº«ãèªã¿è¾¼ã¾ããåã«ã©ããã\cs{DeclareFontFamily}ã®å¼ã³åºãããã£ãã
-ææ¡ã§ããªãããã§ããï¼
+\Pkg{luatexja-otf}ããã±ã¼ã¸ãèªã¿è¾¼ãã¨ï¼
+JFMã®\texttt{chars}ãã¼ãã«ã®ã¨ã³ããªã¨ã㦠\verb+'AJ1-xxx'+ ã®å½¢ã®æååã
+使ããããã«ãªãï¼ããã¯Adobe-Japan1ã«ãããCIDçªå·ã \verb+xxx+ ã®æåã表ãï¼
+
+ãã®æ¡å¼µè¨æ³ã¯ï¼æ¨æºJFM~\texttt{jfm-ujis.lua}ã§ï¼åè§ã²ãããªã®ã°ãªãï¼CID~516--598ï¼ã
+æ£ããåè§å¹
ã§çµãããã«å©ç¨ããã¦ããï¼
%
-%\paragraph{Remarks}
-%\paragraph{注æ}
-%<*en>
-Of course, there is a case that is not recognized as a Japanese font family, nor
-an alphabetic font family.
-In this case, \LuaTeX-ja treats ``the argument is wrong'', so
-set both current alphabetic and Japanese font family to ,
-to use the default family for font substitution.
-%
-%<*ja>
-ãã¦ï¼å¼æ°ã«ãã£ã¦ã¯ï¼ãåæãã©ã³ããã¡ããªã¨ã欧æãã©ã³ããã¡ããªãèªèãããªãã£ãã
-ã¨ããäºæ
ãããå¾ãï¼
- ãã®å ´åï¼å¼æ°ã¯ä¸æ£ã ã£ãï¼ã¨ãããã¨ã«ãªãã®ã§ï¼
-åæã»æ¬§æã®ä¸¡æ¹ã®ãã©ã³ããã¡ããªãã«è¨å®ãï¼ä»£ç¨ãã©ã³ãã使ãããã«ä»»ãããã¨ã«ããï¼
-%
+\subsection{\Pkg{luatexja-adjust}}
+\label{ssec-adj}
+\begin{figure}[t]
+\def\sq{%
+ \hbox to 1\zw{\hss\fboxsep=-.5\fboxrule\fbox{%
+ ã\hskip\dimexpr-.5\zw-.2pt\vrule width.4pt height.08\zw depth.12\zw%
+ \hskip\dimexpr.5\zw-.2pt\relax}\hss}}
+\def\sb{\hbox to 1\zw{\hss\fboxsep=-.5\fboxrule\fbox{%
+ â \hskip\dimexpr-.5\zw-.2pt\vrule width.4pt height.08\zw depth.12\zw%
+ \hskip\dimexpr.5\zw-.2pt\relax}\hss}}
+\newbox\gridbox
+\def\outbox#1{{\Large%
+ \ltjsetparameter{kanjiskip=0pt plus .2\zw minus .2\zw}%
+ \setbox\gridbox=\hbox to 20\zw{\sq\sq\sq\sq\sb\sq\sq\sq\sq\sb\sq\sq\sq\sq\sb\sq\sq\sq\sq\sb}%
+ \hbox{\textcolor{cyan}{\copy\gridbox}\hskip-20\zw%
+ \vbox{\hsize=20\zw\noindent\leftskip0pt\rightskip0pt\parfillskip0pt#1}\vrule}%
+}}
+
+{\centering
+\begin{tabular}{lc}
+\toprule
+no adjustment&\outbox{以ä¸ã®åçã¯ï¼ãå
é¤åçãã¨ããå¼ã°ããã\hskip-.5\zw\null}\\
+without priority&%
+\ltjdisableadjust
+\outbox{以ä¸ã®åçã¯ï¼ãå
é¤åçãã¨ããå¼ã°ããã}%
+\ltjenableadjust\\
+with priority&%
+\outbox{以ä¸ã®åçã¯ï¼ãå
é¤åçãã¨ããå¼ã°ããã}
+%\ltjdisableadjust
+\\
+\bottomrule
+\end{tabular}\par}
+\smallskip
+
+Note: the value of
+\Param{kanjiskip} is 0\,pt${}^{+1/5\,\mathrm{em}}_{-1/5\,\mathrm{em}}$ in this figure,
+for making the difference obvious.
+%\caption{è¡é·èª¿æ´}\label{fig:adj}
+%\caption{Line adjustment}\label{fig:adj}
+\end{figure}
%<*en>
-\section{Addon packages}
-\LuaTeX-ja has several addon packages.
-These addons are written as \LaTeX\ packages, but
-\Pkg{luatexja-otf} and~\Pkg{luatexja-adjust} can be loaded in plain \LuaTeX\
-by \cs{input}.
-%
-%<*ja>
-\section{æ¡å¼µããã±ã¼ã¸}
-\LuaTeX-jaã«ã¯ï¼åä½ã«ã¯å¿
é ã§ã¯ãªããï¼èªç±ã«èªã¿è¾¼ããæ¡å¼µãä»å±ãã¦ããï¼
-ãããã¯\LaTeX ã®ããã±ã¼ã¸ã¨ãã¦å¶ä½ãã¦ãããï¼
-\Pkg{luatexja-otf}ã¨\Pkg{luatexja-adjust}ã«ã¤ãã¦ã¯plain \LuaTeX ã§ã\
-\cs{input} ã§èªã¿è¾¼ã¿å¯è½ã§ããï¼
-%
-\subsection{\Pkg{luatexja-fontspec}}
-\label{ssec-fontspec2}
-%<*en>
-As described in Subsection~\ref{ssec-fontspec}, this optional package
-provides the counterparts for several commands defined in the
-\Pkg{fontspec} package (requires \Pkg{fontspec}~v2.4).
-In addition to OpenType font features in the original \Pkg{fontspec},
-the following ``font features'' specifications are allowed for
-the commands of Japanese version:
+(see Japanese version of this manual)
%
%<*ja>
-\ref{ssec-fontspec}ç¯ã§è¿°ã¹ãããã«ï¼ãã®è¿½å ããã±ã¼ã¸ã¯\Pkg{fontspec}%
-ããã±ã¼ã¸ã§å®ç¾©ããã¦ããã³ãã³ãã«å¯¾å¿ããåæãã©ã³ãç¨ã®ã³ãã³ããæä¾ããï¼
+ãã®è¿½å ããã±ã¼ã¸ã¯ä»¥ä¸ã®æ©è½ãæä¾ããï¼è©³ç´°ãªä»æ§ã«ã¤ãã¦ã¯\ref{sec-adjspec}ç« ãåç
§ãã¦ã»ããï¼
+\begin{description}
+\item[è¡æ«æåã®ä½ç½®èª¿æ´]
+ \pTeX ã§ã¯ï¼ï¼æ¯éã¯ã¨ãããï¼ãè¡æ«ã®èªç¹ã¯ã¶ãä¸ããäºååããå
¨è§åãã®ããããã«ãã®ããã«
+ è¡æ«æåã¨å®éã®è¡æ«ã®ä½ç½®é¢ä¿ã2éã以ä¸ã«ãããã¨ã¯é¢åã§ãã£ãï¼
+ åæãã©ã³ãã¡ããªãã¯ã ãã§ã¯ã常ã«è¡æ«ã®èªç¹ã¯ã¶ãä¸ããã¨ãã£ããã¨ããã§ããï¼
+ åã®æã«æ¸ãããã¨ãå®ç¾ããã«ã¯
+\begin{lstlisting}
+\def\ã{%
+ \penalty10000 % ç¦åããã«ãã£
+ \hbox to0pt{ã\hss}\penalty0 % ã¶ãä¸ãã®å ´å
+ \kern.5\zw\penalty0 % äºååãã®å ´å
+ \kern.5\zw\penalty0 % å
¨è§åãã®å ´å
+}
+\end{lstlisting}
+ ã®ãããªå½ä»¤ãå®ç¾©ãï¼æä¸ã®å
¨ã¦ã®å¥ç¹ã \lstinline+\ã+ ã§æ¸ããã¨ãå¿
è¦ã ã£ãï¼
-\Pkg{fontspec}ããã±ã¼ã¸ã§æå®å¯è½ãªå種OpenTypeæ©è½ã«å ãã¦ï¼åæçã®ã³ãã³ãã«ã¯
-以ä¸ã®ããã©ã³ãæ©è½ããæå®ãããã¨ãã§ããï¼
-%
+\Pkg{luatexja-adjust}ããã±ã¼ã¸ã¯ï¼ä¸ã§è¿°ã¹ãè¡æ«æåã¨å®éã®è¡æ«ã¨ã®ä½ç½®é¢ä¿ã
+2éã以ä¸ããèªåçã«é¸æããæ©è½ãæä¾ããï¼
+\pdfTeX ã¨åãããã«ï¼ã\TeX ã«ããè¡åå²ã®å¾ã§è¡æ«æåã®ä½ç½®ãè£æ£ãããæ¹æ³ã¨
+ ãè¡åå²ã®éç¨ã§è¡æ«æåã®ä½ç½®ãèæ
®ã«å
¥ãããæ¹æ³ãé¸ã¹ãããã«ããï¼
+\Pkg{luatexja-adjust}ããã±ã¼ã¸ã®æ¢å®ã§ã¯åè
ï¼ï¼
+
+\item[åªå
é ä½ä»ãã®è¡é·èª¿æ´]
+\pTeX ã§ã¯ï¼è¡é·èª¿æ´ã«ããã¦åªå
度ã®æ¦å¿µãåå¨ããªãã£ãããï¼å³
+\ref{fig:adj}ä¸æ®µã«ãããåè§åã®å端ã¯ï¼\autoref{fig:adj}ä¸æ®µã®ããã«ï¼éµ
+æ¬å¼§å¨è¾ºã®ç©ºç½ã¨åæé空ç½(\Param{kanjiskip})ã®ä¸¡æ¹ã«ãã£ã¦è² æ
ãããï¼ã
+ããï¼ãæ¥æ¬èªçµçå¦çã®è¦ä»¶ã\cite{jlreq}ãJIS~X~4051~\cite{x4051}ã«ãã
+ã¦ã¯ï¼ãã®ãããªç¶æ³ã§ã¯å端ã¯éµæ¬å¼§å¨è¾ºã®ç©ºç½ã®ã¿ã§è² æ
ãï¼ãã®ä»ã®åæ
+æåã¯ãã¿çµã§çµã¾ããï¼\autoref{fig:adj}ä¸æ®µï¼ãã¨ã«ãªã£ã¦ããï¼
+\Pkg{luatexja-adjust}ããã±ã¼ã¸ã®æä¾ãã第2ã®æ©è½ã¯ï¼
+\cite{jlreq}ã\cite{x4051}ã«ãããè¦å®ã®ãããªï¼åªå
é ä½ä»ã
+ã®è¡é·èª¿æ´ã§ããï¼
+\begin{itemize}
+ \item åªå
度ä»ãè¡é·èª¿æ´ã¯ï¼æ®µè½ãè¡åå²ããå¾ã«åã
ã®è¡ã«ã¤ãã¦è¡ããããã®ã§ããï¼
+ãã®ããï¼è¡åå²ã®ä½ç½®ã¯å¤åãããã¨ã¯ãªãï¼
+
+\verb+\hbox{...}+ ã¨ãã£ããéä¸ã§æ¹è¡ã§ããªãæ°´å¹³ããã¯ã¹ãã§ã¯ï¼ãã¨ãå¹
ãæå®ããã¦ãã¦ãï¼ç¡å¹ã§ããï¼
+ \item åªå
度ä»ãè¡é·èª¿æ´ãè¡ãã¨ï¼åæå¦çã°ã«ã¼ã®èªç¶é·ã¯å¤åããªããï¼ä¼¸ã³éã縮ã¿éã¯
+ä¸è¬ã«å¤åããï¼ãã®ããï¼æ¢ã«çµã¾ãã段è½ã \cs{unhbox} ãªã©ãå©ç¨ãã¦çµã¿ç´ãå¦çã
+è¡ãå ´åã«ã¯æ³¨æãå¿
è¦ã§ããï¼
+\end{itemize}
+\end{description}
+\Pkg{luatexja-adjust}ããã±ã¼ã¸ã¯ï¼ä¸è¨ã§è¿°ã¹ã2æ©è½ãæå¹å/ç¡å¹åããããã®
+以ä¸ã®å½ä»¤ãæä¾ããï¼ãããã¯ãã¹ã¦ã°ãã¼ãã«ã«å¹åãçºæ®ããï¼
\begin{cslist}
-\item[CID=\textrm{, }JFM=\textrm{, }JFM-var=]
+\item[\cs{ltjenableadjust[...]}]
+\verb+...+ ã«æå®ããkey-valueãªã¹ãã«å¾ãï¼ãè¡æ«æåã®ä½ç½®èª¿æ´ããåªå
é ä½ä»ãã®è¡é·èª¿æ´ããæå¹å/ç¡å¹åããï¼
+æå®ã§ãããã¼ã¯ä»¥ä¸ã®éãï¼
+\begin{description}
+ \item[\texttt{lineend=[false,true,extended]}]
+ è¡æ«æåã®ä½ç½®èª¿æ´ã®æ©è½ãç¡å¹å(\texttt{false})ï¼ãè¡åå²å¾ã«èª¿æ´ãã®å½¢ã§æå¹å(\texttt{true})ï¼
+ ãè¡åå²ã®ä»®å®ã§èæ
®ã(\texttt{extended})ããï¼
+ \item[\texttt{priority=[false,true]}]
+ åªå
é ä½ä»ãã®è¡é·èª¿æ´ãç¡å¹å(\texttt{false})ï¼ã¾ãã¯æå¹å(\texttt{true})ããï¼
+\end{description}
+両ãã¼ã¨ããã¼åã®ã¿ãæå®ããå ´åã¯å¤ã¨ãã¦\texttt{true}ãæå®ããããã®ã¨æ±ãããï¼
-%<*en>
-These 3 keys correspond to \texttt{cid}, \texttt{jfm} and
-\texttt{jfmvar} keys for \cs{jfont}~and~\cs{tfont} respectively.
-See Subsections~\ref{ssec-jfont} and \ref{ssec-psft} for details
- of \texttt{cid}, \texttt{jfm} and
-\texttt{jfmvar} keys.
+äºææ§ã®çºï¼ãªãã·ã§ã³ç¡ãã§ãã \cs{ltjenableadjust}ãå¼ã³åºãããå ´åã¯ï¼
+\begin{lstlisting}
+\ltjenableadjust[lineend=true,priority=true]
+\end{lstlisting}
+ã¨æ±ãããï¼
+
+\item[\cs{ltjdisableadjust}]
+\Pkg{luatexja-adjust}ããã±ã¼ã¸ã®æ©è½ãç¡å¹åããï¼
+\begin{lstlisting}
+\ltjenableadjust[lineend=false,priority=false]
+\end{lstlisting}
+ã¨å義ï¼
+\end{cslist}
-The \texttt{CID} key is effective only when with \texttt{NoEmbed}
-described below. The same JFM cannot be used in both horizontal Japanese fonts and
- vertical Japanese fonts, hence the \texttt{JFM} key
-will be actually used in \texttt{YokoFeatures}~and~\texttt{TateFeatures} keys.
+ã¾ãï¼åªå
é ä½ä»ãã®è¡é·èª¿æ´ã®ããã«ï¼æ¬¡ã®2ãã©ã¡ã¼ã¿ã\cs{ltjsetparameter}å
ã§
+追å ãããï¼ä¸¡ãã©ã¡ã¼ã¿ã¨ãã°ãã¼ãã«ã«å¹åãçºæ®ããï¼
+\begin{cslist}[style=standard]
+\item[\DParam{stretch\_priority}\,=\{\}]
+\Param{kanjiskip}, \Param{xkanjiskip}ï¼ããã³ã\textbf{JAglue}以å¤ã®ã°ã«ã¼ããï¼
+ãè¡ãèªç¶é·ãã伸ã°ããå ´åã®èª¿æ´ã«ç¨ããåªå
度ãæå®ããï¼
+
+æå®æ¹æ³ã¯ï¼ã®ä¸ã«key-value listã®å½¢ã§
+\begin{lstlisting}
+stretch_priority={kanjiskip=-35,xkanjiskip=-25,others=50}
+\end{lstlisting}
+ã®ããã«ãã¦è¡ãï¼ãã¼å\texttt{kanjiskip},~\texttt{xkanjiskip}ã«ã¤ãã¦ã¯
+ãã®ã¾ã¾ã®æå³ã§ããï¼
+\texttt{others}ãã¼ãã\textbf{JAglue}以å¤ã®ã°ã«ã¼ãã表ãï¼
+åãã¼ã®å¤ã¯ï¼JFMã°ã«ã¼ã«ããããåªå
度$i$ãã$10i$ã«å¯¾å¿ãããæ´æ°å¤ã§ããï¼
+ 大ããæ¹ãå
ã«ä¼¸ã°ããããã¨ãæå³ãã¦ããï¼
+
+\item[\DParam{shrink\_priority}\,=\{\}]
+åæ§ã«ï¼ãè¡ãèªç¶é·ãã縮ãããå ´åã®èª¿æ´ã«ç¨ããåªå
度ãæå®ããï¼
+ãã以å¤ã¯\Param{stretch\_priority}ã¨æå®ã®å½¢å¼ã¯å¤ãããªãï¼
+\end{cslist}
+åæå¤ã¯\Param{stretch\_priority}, \Param{shrink\_priority}ã¨ã
+\begin{lstlisting}
+{kanjiskip=-35,xkanjiskip=-25,others=50}
+\end{lstlisting}
+ã§ããï¼ãåªå
度$-4$ãã¨æå®ããã¦ããJFMã°ã«ã¼ãæã伸ã³ï¼ç¸®ã¿ï¼ã«ããããã«ãªã£ã¦ããï¼
+%
+
+\subsection{\Pkg{luatexja-ruby}}
+%<*en>
+This addon package provides functionality of ``ruby'' (\emph{furigana}) annotations
+using callbacks of \LuaTeX-ja.
+There is no detailed manual of \Pkg{luatexja-ruby.sty} in English.
+(Japanese manual is another PDF file, \url{luatexja-ruby.pdf}.)
%
%<*ja>
-ããã3ã¤ã®ãã¼ã¯ãããã \cs{jfont},~\cs{tfont}ã«å¯¾ãã
-\texttt{cid}, \texttt{jfm}, \texttt{jfmvar}ãã¼ã¨ãããã対å¿ããï¼
-\texttt{cid}, \texttt{jfm}, \texttt{jfmvar}ãã¼ã®è©³ç´°ã¯\ref{ssec-jfont}ç¯
- ã¨\ref{ssec-psft}ç¯ãåç
§ï¼
+ãã®è¿½å ããã±ã¼ã¸ã¯ï¼\LuaTeX-jaã®æ©è½ãå©ç¨ããã«ãï¼æ¯ãä»®åï¼ã®çµçæ©è½ãæä¾ããï¼
+åå¾ã®æå種ã«å¿ããåå¾ã¸ã®èªåé²å
¥ãï¼
+è¡é å½¢ã»è¡ä¸å½¢ã»è¡æ«å½¢ã®èªåçãªä½¿ãåããç¹å¾´ã§ããï¼
-\texttt{CID} ãã¼ã¯ä¸ã® \texttt{NoEmbed} ã¨åããã¦ç¨ããããã¨ãã®ã¿æå¹ã§ããï¼
-ã¾ãï¼æ¨ªçµç¨JFMã¨ç¸¦çµç¨JFMã¯å
±ç¨ã§ããªãããï¼å®éã« \texttt{JFM} ãã¼ãç¨ããéã¯
-å¾ã«è¿°ã¹ã\ \texttt{YokoFeatures} ãã¼ã \texttt{TateFeatures}\ ã®ä¸ã§ç¨ãã
-ãã¨ã«ãªãï¼
+ã«ãçµçã«è¨å®å¯è½ãªé
ç®ã注æäºé
ãå¤ãããï¼æ¬è¿½å ããã±ã¼ã¸ã®è©³ç´°ãªèª¬æã¯
+使ç¨ä¾ã¨å
±ã« \url{luatexja-ruby.pdf}\ ã¨ããå¥ãã¡ã¤ã«ã«è¼ãã¦ããï¼
+ãã®ç¯ã§ã¯ç°¡åãªä½¿ç¨æ¹æ³ã®ã¿è¿°ã¹ãï¼
%
-\item[NoEmbed]
+\begin{description}
%<*en>
-By specifying this key, one can use ``name-only'' Japanese font which
-will not be embedded in the output PDF file. See Subsection~\ref{ssec-psft}.
+ \item[Group-ruby]
+By default, ruby characters (the second argument of \cs{ruby})
+are attached to base characters (the first argument), as one object.
+This type of ruby is called \emph{group-ruby}.
%
%<*ja>
-ãããæå®ãããã¨ã§ï¼PDFã«åãè¾¼ã¾ããªããååã ããã®ãã©ã³ããæå®ãããã¨ã
-ã§ããï¼\ref{ssec-psft}ç¯ãåç
§ï¼
+ \item[ã°ã«ã¼ãã«ã] æ¨æºã§ã¯ã°ã«ã¼ãã«ãã®å½¢ã§çµã¾ããï¼ç¬¬1å¼æ°ã«è¦ªæåï¼
+第2å¼æ°ã«ã«ããè¨è¿°ããï¼
%
-
-\begin{figure}[!tb]
-\begin{LTXexample}[width=0.25\textwidth]
-\jfontspec[
- YokoFeatures={Color=007F00}, TateFeatures={Color=00007F},
- TateFont=KozGoPr6N-Regular
-]{KozMinPr6N-Regular}
-\hbox{\yoko 横çµã®ãã¹ã}\hbox{\tate 縦çµã®ãã¹ã}
-\addjfontfeatures{Color=FF0000}
-\hbox{\yoko 横çµ}\hbox{\tate 縦çµ}
+\begin{LTXexample}[width=0.3\textwidth]
+æ±è¥¿ç·\ruby{å¦å
¸}{ã¿ããã§ã}é§
ã¯â¦â¦\\
+æ±è¥¿ç·ã®\ruby{å¦å
¸}{ã¿ããã§ã}é§
ã¯â¦â¦\\
+æ±è¥¿ç·ã®\ruby{å¦å
¸}{ã¿ããã§ã}ã¨ããé§
â¦â¦\\
+æ±è¥¿ç·\ruby{è西}{ããã}é§
ã¯â¦â¦
\end{LTXexample}
-%\caption{\texttt{TateFeatures} çã®ä½¿ç¨ä¾}
-%\caption{An example of \texttt{TateFeatures} etc.}
-\label{fig:yokotate-fontspec}
-\end{figure}
+%<*en>
+As the above example, ruby hangover is allowed on the Hiragana before/after
+its base characters.
+%
+% ãã®ä¾ã®ããã«ï¼æ¨æºã§ã¯åå¾ã®å¹³ä»®åã«ã«ãå
¨è§ã¾ã§ãããããã«ãªã£ã¦ããï¼
-\item[Kanjiskip=]
+%<*en>
+\item[Mono-ruby]
+To attach ruby characters to each base characters (\emph{mono-ruby}),
+one should use \cs{ruby} multiple times:
+%
%<*ja>
-\pageref{pg:ltjksp}ãã¼ã¸ã§èª¬æãã \verb+\jfont+ ä¸ã§ã® \texttt{ltjksp} æå®ã¨
-åä¸ã®å¹åãæã¡ï¼
-JFMä¸ã«ããã \texttt{kanjiskip\_natural}, \texttt{kanjiskip\_stretch},\
-\texttt{kanjiskip\_shrink}ãã¼ï¼\pageref{pg:ksp_nat}ãã¼ã¸ï¼ã®æå¹/ç¡å¹ãåãæ¿ããï¼
-æ¨æºå¤ã¯ \texttt{true} ã§ããï¼
+ \item[ã¢ãã«ã] 親æåã1æåã«ããã¨ã¢ãã«ãã¨ãªãï¼
+2æå以ä¸ã®çèªãã¢ãã«ãã®å½¢ã§çµã¿ããå ´åã¯ï¼é¢åã§ã
+ãã®æ°ã ã \cs{ruby} ãæ¸ãå¿
è¦ãããï¼
%
+\begin{LTXexample}[width=0.3\textwidth]
+æ±è¥¿ç·ã®\ruby{å¦}{ã¿ãã}\ruby{å
¸}{ã§ã}é§
ã¯â¦â¦
+\end{LTXexample}
-\item[TateFeatures=\{\}\textrm{, }TateFont=]
%<*en>
-The \texttt{TateFeatures} key specifies font features which are only turned~on in
-vertical writing, such as \texttt{Style=VerticalKana}~(\texttt{vkna} feature).
-Similarly, the \texttt{TateFont} key specifies the Japanese font which will be used only
- in vertical writing.
-A demonstrarion is shown in Figure~\ref{fig:yokotate-fontspec}.
+ \item[Jukugo-ruby]
+Vertical bar~\verb+|+ denotes a boundary of \emph{groups}.
%
%<*ja>
-縦çµã«ããã¦ä½¿ç¨ããããã©ã³ããï¼ç¸¦çµã«ããã¦ã®ã¿é©ç¨ããããã©ã³ãæ©è½éã
-æå®ããï¼ä½¿ç¨ä¾ã¯å³\ref{fig:yokotate-fontspec}åç
§ï¼
+ \item[çèªã«ã] å¼æ°å
ã®ç¸¦æ£ \verb+|+ ã¯ã°ã«ã¼ãã®åºåãã表ãï¼
+è¤æ°ã°ã«ã¼ãã®ã«ãã¯çèªã«ãã¨ãã¦çµã¾ããï¼
+\cite{x4051}ã«ããããã«ï¼
+ã©ã®ã°ã«ã¼ãã§ãã親æåãã対å¿ããã«ã以ä¸ã®é·ãã®å ´åã¯
+åã°ã«ã¼ããã¨ã«ï¼ããã§ãªãã¨ãã¯å
¨ä½ãã¾ã¨ãã¦1ã¤ã®ã°ã«ã¼ãã«ãã¨ãã¦çµã¾ããï¼
+\cite{jlreq}ã§è¦å®ããã¦ããçµã¿æ¹ã¨ã¯ç°ãªãã®ã§æ³¨æï¼
%
+\begin{LTXexample}
+\ruby{å¦|å
¸}{ã¿ãã|ã§ã}\
+\ruby{è|西}{ã|ãã}\
+\ruby{ç¥æ¥½|å}{ããã|ãã}
+\end{LTXexample}
+%<*en>
+If there are multiple groups in one \cs{ruby} call,
+A linebreak between two groups is allowed.
+%
+% è¤æ°ã«ãã§ã¯ã°ã«ã¼ãã¨ã°ã«ã¼ãã®éã§æ¹è¡ãå¯è½ã§ããï¼
+\begin{LTXexample}[width=0.3\textwidth]
+\vbox{\hsize=6\zw\noindent
+ \hbox to 2.5\zw{}\ruby{京|æ¥|è²|ç°}{ãã|ããã|ãã¾|ã}
+ \hbox to 2.5\zw{}\ruby{京|æ¥|è²|ç°}{ãã|ããã|ãã¾|ã}
+ \hbox to 3\zw{}\ruby{京|æ¥|è²|ç°}{ãã|ããã|ãã¾|ã}
+}
+\end{LTXexample}
+\end{description}
-\item[YokoFeatures=\{\}]
%<*en>
-The \texttt{YokoFeatures} key specifies font features which are only turned~on in
-horizontal writing,.
-A demonstrarion is shown in Figure~\ref{fig:yokotate-fontspec}.
+If the width of ruby characters are longer than that of base characters,
+\cs{ruby} automatically selects the appropriate form
+among the line-head form, the line-middle form, and the line-end form.
%
%<*ja>
-åæ§ã«ï¼æ¨ªçµã«ããã¦ã®ã¿é©ç¨ããããã©ã³ãæ©è½éã
-æå®ããï¼ä½¿ç¨ä¾ã¯å³\ref{fig:yokotate-fontspec}åç
§ï¼
+ã¾ãï¼ã«ãæåã®ã»ãã親æåãããé·ãå ´åã¯ï¼èªåçã«
+è¡é å½¢ã»è¡ä¸å½¢ã»è¡æ«å½¢ã®ããããé©åãªãã®ãé¸æããï¼
%
+\begin{LTXexample}[width=0.3\textwidth]
+\vbox{\hsize=8\zw\noindent
+\null\kern3\zw â¦â¦ã\ruby{æ¿}{ãããã¾ã}ã
+ \kern1\zw â¦â¦ã\ruby{æ¿}{ãããã¾ã}ã\\
+\null\kern5\zw â¦â¦ã\ruby{æ¿}{ãããã¾ã}ã
+}
+\end{LTXexample}
-\begin{figure}[!tb]
-\begin{LTXexample}[pos=b]
-\jfontspec[
- AltFont={
- {Range="4E00-"67FF, Color=007F00},
- {Range="6800-"9EFF, Color=0000FF},
- {Range="3040-"306F, Font=KozGoPr6N-Regular},
- }
-]{KozMinPr6N-Regular}
-æ¥æ¬å½æ°ã¯ãæ£å½ã«é¸æãããå½ä¼ã«ããã代表è
ãéãã¦è¡åãããããã¨ãããã®åå«ã®ããã«ã
-諸å½æ°ã¨ã®ååã«ããææã¨ãããå½å
¨åã«ããã¤ã¦èªç±ã®ããããæµæ²¢ã確ä¿ããâ¦â¦
-\end{LTXexample}
-%\caption{\texttt{AltFont} ã®ä½¿ç¨ä¾}
-%\caption{An example of \texttt{AltFont}}
-\label{fig:altkanji-fontspec}
-\end{figure}
+%<*ja>
+\subsection{\Pkg{lltjext}}
+\pLaTeX ã§ã¯ç¸¦çµç¨ã®æ¡å¼µã¨ã㦠\Pkg{plext} ããã±ã¼ã¸ãç¨æããã¦ãããï¼
+ããã\LuaTeX-jaç¨ã«æ¸ããªããããã®ãæ¬è¿½å ããã±ã¼ã¸ \Pkg{lltjext} ã§ããï¼
-\item[AltFont]
+å¾æ¥ã® \Pkg{plext} ããã±ã¼ã¸ã¨ã®éãã¯ï¼
+{\catcode`\<=12
+\begin{itemize}
+ \item çµæ¹åãªãã·ã§ã³ \texttt{}ï¼æ¨ªçµï¼ï¼\texttt{}ï¼ç¸¦çµï¼ï¼
+\texttt{}\ ã®ä»ã«\ \texttt{}ï¼dtouæ¹åï¼ï¼\texttt{}ï¼utodæ¹åï¼ã追å ããï¼
+\texttt{} 㨠\texttt{} ã®éãã¯ï¼\texttt{} ãï¼\Pkg{plext} ããã±ã¼ã¸ã¨åæ§ã«ï¼
+å¨å²ã®çµæ¹åã縦çµã®ã¨ãã«ããæå³ãæããªã
+ \footnote{%
+ å¨å²ã®çµæ¹åã縦çµä»¥å¤ã®ã¨ãã¯ï¼\texttt{} ãæå®ãã¦ãä¸èº«ã®çµæ¹åã¯å¨å²ã®çµæ¹åã¨å¤ãããªãï¼
+ }%
+ã®ã«å¯¾ãï¼\texttt{} ã«ã¯ãã®ãããªå¶éããªããã¨ã§ããï¼
+ \item é£æ°åç¨å½ä»¤ \cs{rensuji} ã«ãããä½ç½®åãããªãã·ã§ã³ \texttt{[l]}, \texttt{[c]},
+ \texttt{[r]} ã®æåãè¥å¹²å¤æ´ããï¼
+\end{itemize}
+}
+%
%<*en>
-As \cs{ltjdeclarealtfont}~(Subsection~\ref{ssec-altfont}) and
-\cs{DeclareAlternateKanjiFont}~(Subsection~\ref{ssec-nfsspat}),
-with this key, one can typeset some Japanese characters
-by a different font and/or using different features.
-The \texttt{AltFont} feature takes a comma-separated list of comma-separated lists,
-as the following:
+\subsection{\texttt{lltjext.sty}}
+\pLaTeX\ supplies additional macros for vertical writing in the \Pkg{plext} package.
+The \Pkg{lltjext} package which we want to describe here is the \LuaTeX-ja
+counterpart of the \Pkg{plext} package.
%
+
%<*ja>
-\ref{ssec-altfont}ç¯ã® \cs{ltjdeclarealtfont} ãï¼
-\ref{ssec-nfsspat}ç¯ã® \cs{DeclareAlternateKanjiFont} ã¨åæ§ã«ï¼
-ãã®ãã¼ãç¨ããã¨ä¸é¨ã®æåãç°ãªã£ããã©ã³ããæ©è½ãã¡ã使ã£ã¦çµããã¨ãã§ããï¼
-\texttt{AltFont} ãã¼ã«æå®ããå¤ã¯ï¼æ¬¡ã®ããã«äºéã®ã³ã³ãåºåããªã¹ãã§ããï¼
-%
-\begin{lstlisting}[escapechar=\#]
-AltFont = {
- ...
- { Range=#\LARG range>#, #\LARG features>#},
- { Range=#\LARG range>#, Font=#\LARG font~name>#, #\LARG features># },
- { Range=#\LARG range>#, Font=#\LARG font~name># },
+念ã®çºï¼æ¬ \Pkg{lltjext} ããã±ã¼ã¸ã§è¿½å ã»å¤æ´ãã¦ããå½ä»¤ã®ä¸è¦§ãè¼ãã¦ããï¼
+\begin{cslist}
+\item[tabular\textrm{, }array\textrm{, }minipageç°å¢]
+ãããã®ç°å¢ã¯ï¼
+\begin{lstlisting}
+\begin{tabular}[pos]{table spec} ... \end{tabular}
+\begin{array}[pos]{table spec} ... \end{array}
+\begin{minipage}[pos]{width} ... \end{minipage}
+\end{lstlisting}
+ã®ããã«ï¼çµæ¹åãªãã·ã§ã³ \texttt{\} ãæ¡å¼µããã¦ããï¼
+æ¢ã«è¿°ã¹ãããã«ï¼çµæ¹åãªãã·ã§ã³ã«æå®ã§ããå¤ã¯ä»¥ä¸ã®5ã¤ã§ããï¼
+ãã以å¤ãæå®ããæãç¡æå®æã¯å¨å²ã®çµæ¹åã¨åãçµæ¹åã«ãªãï¼
+\begin{description}
+ \item[y] 横çµ(\cs{yoko})
+ \item[t] 縦çµ(\cs{tate})
+ \item[z] å¨å²ã縦çµã®æã¯utodæ¹åï¼ãã以å¤ã¯ãã®ã¾ã¾
+ \item[d] dtouæ¹å
+ \item[u] utodæ¹å
+\end{description}
+\item[\cs{parbox}\<\>{[]}\{\}\{\}]
+\cs{parbox} å½ä»¤ãåæ§ã«ï¼çµæ¹åã®æå®ãã§ããããã«æ¡å¼µããã¦ããï¼
+
+\item[\cs{pbox}\<\>{[][]}\{\}]
+çµæ¹åã§ã®ä¸èº«ãLRã¢ã¼ãã§çµãå½ä»¤ã§ããï¼
+ãæ£ã®å¤ã§ããã¨ãã¯ï¼ããã¯ã¹å
¨ä½ã®å¹
ããã®å¤ã¨ãªãï¼
+ãã®éï¼ä¸èº«ã¯ã®å¤ã«å¾ãï¼å·¦å¯ã(\texttt{l})ï¼å³æã(\texttt{r})ï¼
+ä¸å¤®æãï¼ãã以å¤ï¼ãããï¼
+\item[pictureç°å¢]
+å³è¡¨ä½æã«ç¨ãã\texttt{picture}ç°å¢ãï¼
+\begin{lstlisting}
+\begin{picture}(x_size, y_size)(x_offset,y_offset)
...
-}
+\end{picture}
\end{lstlisting}
-%<*en>
-Each sublist should have the \texttt{Range} key
-(sublist which does not contain \texttt{Range} key is simply ignored).
-A demonstrarion is shown in Figure~\ref{fig:altkanji-fontspec}.
-%
-%<*ja>
-åé¨åãªã¹ãã«ã¯ \texttt{Range} ãã¼ãå¿
é ã§ããï¼å«ã¾ããªãé¨åãªã¹ãã¯
-åç´ã«ç¡è¦ãããï¼ï¼æå®ä¾ã¯å³\ref{fig:altkanji-fontspec}ã«ç¤ºããï¼
-%
-\end{cslist}
+ã¨çµæ¹åãæå®ã§ããããã«æ¡å¼µããã¦ããï¼
+$x$æåã®å¢å æ¹åã¯åéãæ¹åï¼$y$æåã®å¢å æ¹åã¯è¡éãæ¹åã®\emph{å対æ¹å}ã¨ãªãï¼
+\Pkg{plext} ããã±ã¼ã¸ã¨åæ§ã«
+å
é¨ã§ã¯ãã¼ã¹ã©ã¤ã³è£æ£ï¼\Param{yalbaselineshift}ãã©ã¡ã¼ã¿ãªã©ï¼ã®å½±é¿ãåããªãããã«ï¼
+\cs{put},~\cs{line}, \cs{vector}, \cs{dashbox}, \cs{oval},~\cs{circle}ã
+ãã¼ã¹ã©ã¤ã³è£æ£ãåããªãããã«åå®ç¾©ããã¦ããï¼
-%<*ja>
-ãªãï¼\Pkg{luatexja-fontspec} èªã¿è¾¼ã¿æã«ã¯åæãã©ã³ãå®ç¾©ãã¡ã¤ã«%
-\texttt{.fd}ã¯å
¨ãåç
§ãããªããªãï¼
-%
+\item[\cs{rensuji}{[]}\{\}\textrm{, }\cs{rensujiskip}]
+\item[\cs{Kanji}\{\}]
+
+\item[\cs{kasen}\{\}\textrm{, }\cs{bou}\{\}\textrm{,
+ }\cs{boutenchar}]
+\item[åç
§çªå·]
+\end{cslist}
+%
%<*en>
-\paragraph{Remark on \texttt{AltFont}, \texttt{YokoFeatures}, \texttt{TateFeatures} keys}
-In \texttt{AltFont},~\texttt{YokoFeatures},~\texttt{TateFeatures} keys,
-one cannot specify per-shape settings such as \texttt{BoldFeatures}.
-For example,
+\begin{cslist}
+\item[tabular\textrm{, }array\textrm{, }minipage\textrm{ environments}]
+These environments are extended by \texttt{\}, which specifies the direction,
+as follows:
\begin{lstlisting}
-AltFont = {
- { Font=HogeraMin-Light, BoldFont=HogeraMin-Bold,
- Range="3000-"30FF, BoldFeatures={Color=007F00} }
-}
+\begin{tabular}[pos]{table spec} ... \end{tabular}
+\begin{array}[pos]{table spec} ... \end{array}
+\begin{minipage}[pos]{width} ... \end{minipage}
\end{lstlisting}
-does \emph{not} work. Instead, one have to write
+This option permits one of the following five values. If none of them is specified,
+the direction inside the environment is same as that outside the enviromnent.
+\begin{description}
+ \item[y] \emph{yoko} direction (horizontal writing)
+ \item[t] \emph{tate} direction (vertical writing)
+ \item[z] \emph{utod} direction if direction outside the env.\ is \emph{tate}.
+ \item[d] \emph{dtou} direction
+ \item[u] \emph{utod} direction
+\end{description}
+\item[\cs{parbox}\<\>{[]}\{\}\{\}]
+\cs{parbox} command is also extended by \texttt{\<\>}.
+
+\item[\cs{pbox}\<\>{[][]}\{\}]
+This commands typeset in LR-mode, in direction.
+If is positive, the width of the box becomes this .
+In this case, will be aligned to left (when is \texttt{l}),
+center (\texttt{c}), or~right (\texttt{r}).
+
+\item[picture\textrm{\ environment}]
+\texttt{picture} environment also extended by \texttt{\<\>}, as follows:
\begin{lstlisting}
-UprightFeatures = {
- AltFont = { { Font=HogeraMin-Light, Range="3000-"30FF, } },
-},
-BoldFeatures = {
- AltFont = { { Font=HogeraMin-Bold, Range="3000-"30FF, Color=007F00 } },
-}
+\begin{picture}(x_size, y_size)(x_offset,y_offset)
+ ...
+\end{picture}
\end{lstlisting}
-On the other hand, \texttt{YokoFeatures}, \texttt{TateFeatures} and \texttt{TateFont}
-keys can be specified in each list in the \texttt{AltFont} key. Also,
-one can specify \texttt{AltFont} inside \texttt{YokoFeatures},~\texttt{TateFeatures}.
+\item[\cs{rensuji}{[]}\{\}\textrm{, }\cs{rensujiskip}]
-Note that features which are specified in \texttt{YokoFeatures}~and~\texttt{TateFeatures}
-are always interpreted \emph{after} other ``direction-independent'' features.
-This explains why \cs{addjfontfeatures} at~line~6 in~Figure~\ref{fig:yokotate-fontspec}
-has no effect, because a color specification is already done in
-\texttt{YokoFeatures}~and~\texttt{TateFeatures} keys.
+\item[\cs{Kanji}\{\}]
+
+\item[\cs{kasen}\{\}\textrm{, }\cs{bou}\{\}\textrm{,
+ }\cs{boutenchar}]
+
+\item[åç
§çªå·]
+\end{cslist}
+%
+
+%<*ja>
+\paragraph{表çµä»ã®æãä½ç½®}
+表çµï¼\texttt{array}, \texttt{tabular}ç°å¢ï¼ï¼\cs{parbox}å½ä»¤ï¼\cs{minipage}ç°å¢ã®
+æãä½ç½®ã«ã¤ãã¦ã¯\autoref{tab:lltjext_dir}ãåç
§ï¼\pLaTeX~2017-07-29ã¨
+ã§ããã ãåãæåã«ãªãããã«ãã¦ããï¼\autoref{tab:lltjext_dir}ä¸ã®A--Dã®æå³ã¯æ¬¡ã®éãï¼
+
+\begin{table}
+ \caption{\Pkg{lltjext}ããã±ã¼ã¸ã«ããã表çµã»\cs{parbox}å½ä»¤ä»ã®æãä½ç½®}
+ \label{tab:lltjext_dir}
+ {\centering
+ \begin{tabular}{lcccc}
+ \toprule
+ âä¸èº«ï¼¼å¨å²â&\cs{yoko}&\cs{tate}&\cs{utod}&\cs{dtou}\\
+ \midrule
+ \cs{yoko}&A&B&B&B\\
+ \cs{tate}&B&A&D&C\\
+ \cs{utod}&B&D&A&C\\
+ \cs{dtou}&B&C&C&A\\
+ \bottomrule
+ \end{tabular}\par}
+\end{table}
+
+\begin{description}
+ \item[A] å¨å²ã®çµæ¹åã¨ä¸èº«ã®çµæ¹åãåãå ´åï¼
+ \begin{itemize}
+ \item \texttt{[t]}æå®ã®ã¨ãï¼
+ ä¸èº«ã®å
é è¡ã®ãã¼ã¹ã©ã¤ã³ãå¨å²ã®ãã¼ã¹ã©ã¤ã³ã¨ä¸è´ããï¼
+ 表çµã§å
é è¡ã®ä¸ã«ç½«ç·ããã£ãå ´åã¯ï¼ããããã¼ã¹ã©ã¤ã³ã®ä½ç½®
+ \footnote{\LuaTeX-jaã§ã¯åæå´ã®ãã¼ã¹ã©ã¤ã³ã®ä½ç½®ãä¸ä¸ç§»åã§ãããã¨ã«æ³¨æï¼
+ ãã®ãããåæãã¼ã¹ã©ã¤ã³ãã®ä½ç½®ã«æ¥ãã¨ã¯éããªãï¼}ã¨ãªãï¼
+ \item \texttt{[c]}æå®ã®ã¨ãï¼
+ ä¸èº«ã®ä¸ä¸ã®ä¸å¿ãå¨å²ã®æ°å¼ã®è»¸ãéãï¼
+ \item \texttt{[b]}æå®ã®ã¨ãï¼
+ ä¸èº«ã®æçµè¡ã®ãã¼ã¹ã©ã¤ã³ãå¨å²ã®ãã¼ã¹ã©ã¤ã³ã¨ä¸è´ããï¼
+ 表çµã§æçµè¡ã®ä¸ã«ç½«ç·ããã£ãå ´åã¯ï¼ããããã¼ã¹ã©ã¤ã³ã®ä½ç½®ã¨ãªãï¼
+ \end{itemize}
+ \item[B] å¨å²ã®çµæ¹åã¨ä¸èº«ã®çµæ¹åã90度ããã¦ããå ´åï¼
+ \begin{itemize}
+ \item \texttt{[t]}æå®ã®ã¨ãï¼
+ 表çµã«ããã¦ã¯ï¼ä¸ç«¯ãå¨å²ã®ãã¼ã¹ã©ã¤ã³ã¨ä¸è´ããï¼
+ \cs{parbox}ã\cs{minipage}ç°å¢ã«ããã¦ã¯ï¼ä¸ç«¯ãå¨å²ã®åææåã®ä¸ç«¯ã¨ä¸è´ããï¼
+ \item \texttt{[c]}æå®ã®ã¨ãï¼
+ ä¸èº«ã®ä¸ä¸ã®ä¸å¿ãå¨å²ã®æ°å¼ã®è»¸ãéãï¼
+ \item \texttt{[b]}æå®ã®ã¨ãï¼
+ 表çµã«ããã¦ã¯ï¼ä¸ç«¯ãå¨å²ã®ãã¼ã¹ã©ã¤ã³ã¨ä¸è´ããï¼
+ \cs{parbox}ã\cs{minipage}ç°å¢ã«ããã¦ã¯ï¼ä¸ç«¯ãå¨å²ã®åææåã®ä¸ç«¯ã¨ä¸è´ããï¼
+ \end{itemize}
+ \item[C] å¨å²ã®çµæ¹åã¨ä¸èº«ã®çµæ¹åã180度ããã¦ããå ´åï¼
+ \cs{parbox}ã\cs{minipage}ç°å¢ã«ããã¦ã¯ï¼ä¸ã®Bã®å ´åã¨åãæåã§ããï¼è¡¨çµã«ããã¦ã¯ï¼
+ Aã§\texttt{[t]}ã¨\texttt{[b]}ãå
¥ãæ¿ãã
+ \begin{itemize}
+ \item \texttt{[t]}æå®ã®ã¨ãï¼
+ ä¸èº«ã®æçµè¡ã®ãã¼ã¹ã©ã¤ã³ãå¨å²ã®ãã¼ã¹ã©ã¤ã³ã¨ä¸è´ããï¼
+ æçµè¡ã®ä¸ã«ç½«ç·ããã£ãå ´åã¯ï¼ããããã¼ã¹ã©ã¤ã³ã®ä½ç½®ã¨ãªãï¼
+ \item \texttt{[c]}æå®ã®ã¨ãï¼
+ ä¸èº«ã®ä¸ä¸ã®ä¸å¿ãå¨å²ã®æ°å¼ã®è»¸ãéãï¼
+ \item \texttt{[b]}æå®ã®ã¨ãï¼
+ ä¸èº«ã®å
é è¡ã®ãã¼ã¹ã©ã¤ã³ãå¨å²ã®ãã¼ã¹ã©ã¤ã³ã¨ä¸è´ããï¼
+ 表çµã§å
é è¡ã®ä¸ã«ç½«ç·ããã£ãå ´åã¯ï¼ããããã¼ã¹ã©ã¤ã³ã®ä½ç½®ã¨ãªãï¼
+ \end{itemize}
+ \item[D] é常ã®ç¸¦çµ(\cs{tate})ã¨ã縦æ°å¼ãã£ã¬ã¯ã·ã§ã³ãã«ç¸å½ãã\cs{utod}æ¹åã絡ãã å ´åï¼
+ \cs{parbox}ã\cs{minipage}ç°å¢ã«ããã¦ã¯ï¼ä¸ã®Bã®å ´åã¨åãæåã§ããï¼è¡¨çµã«ããã¦ã¯ï¼
+ \begin{itemize}
+ \item \texttt{[t]}æå®ã®ã¨ãï¼
+ ä¸èº«ã®å
é è¡ã®æ¬§æãã¼ã¹ã©ã¤ã³ãå¨å²ã®æ¬§æãã¼ã¹ã©ã¤ã³ã¨ä¸è´ããï¼
+ \item \texttt{[c]}æå®ã®ã¨ãï¼
+ ä¸èº«ã®ä¸ä¸ã®ä¸å¿ãå¨å²ã®æ°å¼ã®è»¸ãéãï¼
+ \item \texttt{[b]}æå®ã®ã¨ãï¼
+ ä¸èº«ã®æçµè¡ã®æ¬§æãã¼ã¹ã©ã¤ã³ãå¨å²ã®æ¬§æãã¼ã¹ã©ã¤ã³ã¨ä¸è´ããï¼
+ \end{itemize}
+\end{description}
+%
+
+\subsection{\Pkg{luatexja-preset}}
+\label{ssec:preset}
+
+%<*en>
+As described in Subsection~\ref{ssec:preset-abst},
+One can load the \Pkg{luatexja-preset}
+package to use several ``presets'' of Japanese fonts.
+This package provides functions in a part of \Pkg{japanese-otf} package (changing fonts)
+and a part of \Pkg{PXchfon} package (presets) by Takayuki Yato.
+
+Options which are given in \cs{usepackage} but not described in this~chapter
+are simply passed to the \Pkg{luatexja-fontspec}\footnote{if \texttt{nfssonly} option is
+\emph{not} specified; in this case these options are simply ignored.}.
+For example, the line~5 in below example is equivalent to lines 1--3.
%
%<*ja>
-\paragraph{\texttt{AltFont}, \texttt{YokoFeatures}, \texttt{TateFeatures} çã®å¶é}
-\texttt{AltFont},~\texttt{YokoFeatures},~\texttt{TateFeatures}ã®åãã¼ã¯
-ã·ã§ã¤ãå¥ã«æå®ãããã¹ããã®ã§ããï¼
-å
é¨ã§ã¯ \texttt{BoldFeatures} ãªã©ã®ã·ã§ã¤ãå¥ã®æå®ã¯è¡ããã¨ãåºæ¥ãªãï¼
-ä¾ãã°ï¼
-\begin{lstlisting}
-AltFont = {
- { Font=HogeraMin-Light, BoldFont=HogeraMin-Bold,
- Range="3000-"30FF, BoldFeatures={Color=007F00} }
-}
-\end{lstlisting}
-ã®ããã«æå®ãããã¨ã¯åºæ¥ãï¼
+\ref{ssec:preset-abst}ç¯ã§è¿°ã¹ãããã«ï¼ãã使ããã¦ããåæãã©ã³ãè¨å®ãä¸è¡ã§æå®ã§ããããã«ããã®ã
+\Pkg{luatexja-preset}ããã±ã¼ã¸ã§ããï¼ãã®ããã±ã¼ã¸ã¯ï¼
+\Pkg{otf}ããã±ã¼ã¸ã®ä¸é¨ï¼å¤æ¸ä½åï¼ã¨å
«ç»å´ä¹æ°ã«ãã\Pkg{PXchfon}ããã±ã¼ã¸ã®ä¸é¨ï¼ããªã»ããæå®ï¼
+ã¨ãåããããããªæ ¼å¥½ããã¦ããï¼
+
+ããã±ã¼ã¸èªã¿è¾¼ã¿æã«æ¸¡ããããªãã·ã§ã³ã®ãã¡ï¼
+æ¬ç« ï¼\ref{ssec:ltjpreset-general}ç¯ãã\ref{ssec:ltjpreset-hg}ç¯ï¼ã«ãªã
+ãæå®ããå ´åï¼ãããã¯ãã®ã¾ã¾
+\Pkg{luatexja-fontspec}ããã±ã¼ã¸ã«æ¸¡ããã\footnote{\texttt{nfssonly} ãªãã·ã§ã³ã
+æå®ããã¦ããå ´åã¯ï¼\Pkg{luatexja-fontspec}ããã±ã¼ã¸ã¯èªã¿è¾¼ã¾ããªãã®ã§åç´ã«ç¡è¦ãã
+ãï¼}ï¼ä¾ãã°ï¼ä¸ã®1--3è¡ç®ã¯5è¡ç®ã®ããã«ä¸è¡ã«ã¾ã¨ãããã¨ãã§ããï¼
+%
\begin{lstlisting}
-UprightFeatures = {
- AltFont = { { Font=HogeraMin-Light, Range="3000-"30FF, } },
-},
-BoldFeatures = {
- AltFont = { { Font=HogeraMin-Bold, Range="3000-"30FF, Color=007F00 } },
-}
+\usepackage[no-math]{fontspec}
+\usepackage[match]{luatexja-fontspec}
+\usepackage[kozuka-pr6n]{luatexja-preset}
+%%--------
+\usepackage[no-math,match,kozuka-pr6n]{luatexja-preset}
\end{lstlisting}
-ã®ããã«æå®ããªããã°ãªããªãï¼
-ä¸æ¹ï¼\texttt{AltFont} ãã¼å
ã®åãªã¹ãã§ã¯
-\ \texttt{YokoFeatures},~\texttt{TateFeatures} åã³ \texttt{TateFont} ãã¼ã
-æå®ãããã¨ã¯å¯è½ã§ããï¼ã¾ã\ \texttt{YokoFeatures},~\texttt{TateFeatures} ãã¼ã®
-ä¸èº«ã« \texttt{AltFont} ãæå®ãããã¨ãã§ããï¼
+%\subsection{General Options}
+%\subsection{ä¸è¬çãªãªãã·ã§ã³}
+\label{ssec:ltjpreset-general}
+
+\begin{cslist}[before*=]
+\item[fontspec%
+%\textrm{~(enabled by default)}
+%\emph{\gtfamily ï¼æ¢å®ï¼}
+]
+%<*en>
+With this option, Japanese fonts are selected using functionality of
+the \Pkg{luatexja-fontspec} package. This means that the \Pkg{fontspec} package is
+ automatically loaded by this package.
-ã¾ãï¼å³\ref{fig:yokotate-fontspec}å¾åé¨ã§ã¯6è¡ç®ã®è²ã®æå®ãå¹ããï¼
-2è¡ç®ã§æå®ãã\ \texttt{YokoFeatures},~\texttt{TateFeatures}\ ã«ããè²ã®æå®ãæå¹ã«ãªã£
-ãã¾ã¾ã§ããï¼ããã¯\emph{\ \texttt{YokoFeatures},~\texttt{TateFeatures}\ ã«ãã
-OpenTypeæ©è½æå®ã¯
-çµæ¹åã«ä¾åããªãOpenTypeæ©è½ã®æå®ããå¾ã«è§£éããã}ããã§ããï¼
+If you need to pass some options to \Pkg{fontspec}, you can load \Pkg{fontspec} manually
+before \Pkg{luatexja-preset}:
+%
+%<*ja>
+\Pkg{luatexja-fontspec}ããã±ã¼ã¸ã®æ©è½ãç¨ãã¦åæãã©ã³ããé¸æããï¼
+ããã¯ï¼\Pkg{fontspec}ããã±ã¼ã¸ãèªåã§èªã¿è¾¼ã¾ãããã¨ãæå³ããï¼
+ãã\Pkg{fontspec}ããã±ã¼ã¸ã«ä½ããã®ãªãã·ã§ã³ã渡ãå¿
è¦ããã
+\footnote{ä¾ãã°ï¼æ°å¼ãã©ã³ãã¾ã§ç½®æããã¦ãã¾ãï¼\cs{mathit}ã«ãã£ã¦ã®ãªã·ã£æåã®
+æä½å¤§æåãåºãªããªãï¼ãªã©ï¼}å ´åã¯ï¼
+次ã®ããã«\Pkg{luatexja-preset}ã®åã«\Pkg{fontspec}ãæåã§èªã¿ããã°è¯ãï¼
%
+\begin{lstlisting}
+\usepackage[no-math]{fontspec}
+\usepackage[...]{luatexja-preset}
+\end{lstlisting}
-
-\subsection{\Pkg{luatexja-otf}}
-\label{ssec-ltjotf}
+\item[nfssonly]
%<*en>
-This optional package supports typesetting characters in
-Adobe-Japan1 character collection
-(or other CID character collection, if the font is supported).
-The package \Pkg{luatexja-otf} offers the following 2~low-level
-commands:
+With this option, selecting Japanese fonts won't be performed using the functionality of
+ the \Pkg{fontspec} package, but only standard NFSS2 (hence without
+ \cs{addjfontfeatures} etc.).
+This option is ignored when \Pkg{luatexja-fontspec} package is loaded.
+
+When this option is specified, \Pkg{fontspec}~and~\Pkg{luatexja-fontspec} are
+\emph{not} loaded by default. Nevertheless,
+the package\Pkg{fontspec} can coexist with the option, as the following:
+\begin{lstlisting}
+\usepackage{fontspec}
+\usepackage[hiragino-pron,nfssonly]{luatexja-preset}
+\end{lstlisting}
+In this case, one can use \cs{setmainfont} etc.\ to select \emph{alphabetic} fonts.
%
%<*ja>
-ãã®è¿½å ããã±ã¼ã¸ã¯Adobe-Japan1ï¼ãã©ã³ãèªèº«ãæã£ã¦ããã°ï¼
-å¥ã®CIDæåã»ããã§ãå¯ï¼ã®æåã®åºåããµãã¼ãããï¼
-\Pkg{luatexja-otf}ã¯ä»¥ä¸ã®2ã¤ã®ä½ã¬ãã«ã³ãã³ããæä¾ããï¼
+\LaTeX æ¨æºã®ãã©ã³ãé¸ææ©æ§(NFSS2)ãç¨ãã¦
+\texttt{ltjpm}ï¼ææï¼ï¼\texttt{ltjpg}ï¼ã´ã·ãã¯ï¼ï¼ããã«å¾ã«è¿°ã¹ã \texttt{deluxe} ãªã
+ ã·ã§ã³ãæå®ãããå ´åã«ã¯ \texttt{ltjpmg}ï¼ä¸¸ã´ã·ãã¯ï¼ã¨ãã
+3ã¤ã®åæãã©ã³ããã¡ããªãå®ç¾©ãï¼ããããç¨ããï¼
+
+æ¬ãªãã·ã§ã³æå®æã«ã¯\Pkg{fontspec}ã»\Pkg{luatexja-fontspec}ããã±ã¼ã¸ã¯
+èªåã§ã¯èªã¿è¾¼ã¾ããªãï¼ãããï¼
+\begin{lstlisting}
+\usepackage{fontspec}
+\usepackage[hiragino-pron,nfssonly]{luatexja-preset}
+\end{lstlisting}
+ã®ããã«ããã°ï¼ãã®ãªãã·ã§ã³ãæå®ããã°
+欧æãã©ã³ãã\Pkg{fontspec}ããã±ã¼ã¸ã®æ©è½ã使ã£ã¦æå®ãããã¨ãã§ããï¼
+ä¸æ¹ï¼
+ããã±ã¼ã¸èªã¿è¾¼ã¿æã«æ¢ã«\Pkg{luatexja-fontspec}ããã±ã¼ã¸ãèªã¿è¾¼ã¾ãã¦
+ ããå ´å㯠\texttt{nfssonly} ãªãã·ã§ã³ã¯ç¡è¦ãããï¼
%
-\begin{cslist}
-\item[\cs{CID}\{\}]
+
+\item[match]
%<*en>
-Typeset a character whose CID number is .
+If this option is specified, usual family-changing commands such as
+\cs{rmfamily},~\cs{textrm}, \cs{sffamily},~\dots\ also change Japanese font family.
+This option is passed to \Pkg{luatexja-fontspec}, if \texttt{fontspec}
+option is specifed.
%
+
%<*ja>
-CIDçªå·ãã®æåãåºåããï¼
+ãã®ãªãã·ã§ã³ãæå®ãããã¨ï¼ã\pLaTeXe æ°ããã¥ã¡ã³ãã¯ã©ã¹ãã®ããã«\
+\cs{rmfamily}, \verb+\textrm{...}+, \cs{sffamily} çã
+欧æãã©ã³ãã ãã§ãªãåæãã©ã³ããå¤æ´ããããã«ãªãï¼
+\ \texttt{fontspec}\
+ãªãã·ã§ã³ãæå¹ã«ãªã£ã¦ããå ´åã¯ï¼ãã®ãªãã·ã§ã³ã¯ \Pkg{luatexja-fontspec} ããã±ã¼ã¸ã¸ã¨æ¸¡ãããï¼
%
-\item[\cs{UTF}\{\}]
+
+\item[nodeluxe%
+%\textrm{~(enabled by default)}
+%\emph{\gtfamily ï¼æ¢å®ï¼}
+]
%<*en>
-Typeset a character whose character code is