OSDN Git Service

sync lltjext.sty with platex/7c56cb02
[luatex-ja/luatexja.git] / doc / luatexja.dtx
index 304d76f..ce67c8c 100644 (file)
@@ -4312,9 +4312,9 @@ This field is a list of characters which are in this character
 \toprule
 Direction of JFM&\textbf{\texttt{'yoko'} (horizontal)}&\multicolumn{1}{l}{\textbf{\texttt{'tate'} (vertical)}}\\
 \midrule
-\texttt{width} field&the width of the ``real'' glyph&1.0~(full-width)\\
-\texttt{height} field&the height of the ``real'' glyph&0.5~(half-width)\\
-\texttt{depth} field&the depth of the ``real'' glyph&0.5~(half-width)\\
+\texttt{width} field&\multicolumn{2}{c}{the width of the ``real'' glyph}\\
+\texttt{height} field&the height of the ``real'' glyph&0.0\\
+\texttt{depth} field&the depth of the ``real'' glyph&0.0\\
 \midrule
 \texttt{italic} field&\multicolumn{2}{c}{0.0}\\
 \bottomrule
@@ -4333,9 +4333,9 @@ as values of these fields. The default values are shown in Table~\ref{tab-wid}.
 \toprule
 JFM書字方向&\emph{\texttt{'yoko'}(横組)}&\multicolumn{1}{l}{\emph{\texttt{'tate'}(縦組)}}\\
 \midrule
-\texttt{width}&「実際のグリフ」の幅&1.0(全角)\\
-\texttt{height}&「実際のグリフ」の高さ&0.5(二分)\\
-\texttt{depth}&「実際のグリフ」の深さ&0.5(二分)\\
+\texttt{width}&\multicolumn{2}{c}{「実際のグリフ」の幅}\\
+\texttt{height}&「実際のグリフ」の高さ&0.0\\
+\texttt{depth}&「実際のグリフ」の深さ&0.0\\
 \midrule
 \texttt{italic}&\multicolumn{2}{c}{0.0}\\
 \bottomrule
@@ -4610,12 +4610,16 @@ we specify <ratio> to $0.25/(0.5+0.25)=1/3$.
 次のキーを指定できる,
 \begin{cslist}[style=standard]
 \item[priority=<priority>]
-             \Pkg{luatexja-adjust} による優先順位付き
-            行長調整(\ref{ssec-adj}節)の際に使われる値であり,
-行調整処理におけるこのglueの優先
-             度を$-2$から$+2$の間の整数で指定する.大きい値ほど「伸びやすく,縮みやすい」
-             ことを意味する.省略時の値
-             は0であり,範囲外の値が指定されたときの動作は未定義である.
+             \Pkg{luatexja-adjust}による優先順位付き
+            行長調整(\ref{ssec-adj}節)において,このグルーの優先度を指定する.許される値は以下の通り:
+  \begin{description}
+    \item[バージョン1のとき] $-4$から$+3$の間の整数
+    \item[バージョン2のとき] $-4$から$+3$の間の整数の2つ組\texttt{\{<stretch>, <shrink>\}}か,
+    または$-4$から$+3$の間の整数.<stretch>, <shrink>はそれぞれこのグルーが伸びるときの優先度,縮むときの
+    優先度であり,単に整数$i$が指定された場合は\texttt{\{$i$, $i$\}}であると解釈される.
+  \end{description}
+  ここで指定する値は,大きい値ほど「先に伸ばされる」「先に縮ませる」ことを意味しており,省略時の値
+             は0である.範囲外の値が指定されたときの動作は未定義である.
 \item[kanjiskip\_natural=<num>\textrm{, }%
   kanjiskip\_stretch=<num>\textrm{, }kanjiskip\_shrink=<num>]\leavevmode
   \label{pg:ksp_nat}
@@ -4652,10 +4656,12 @@ In case of glue, one can specify following additional keys in each \texttt{[$j$]
             subtable:
 \begin{cslist}[style=standard]
 \item[priority=<priority>]
-An integer in $[-2,2]$ (treated as 0 if omitted), and this is
+An integer in $[-4,3]$ (treated as 0 if omitted), or
+a pair of these integers \texttt{\{<stretch>, <shrink>\}} (version~2 only).
+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,
-and is also easy to shrink.
+and is also easy to shrink. 
 \item[kanjiskip\_natural=<num>\textrm{, }%
   kanjiskip\_stretch=<num>\textrm{, }kanjiskip\_shrink=<num>]\leavevmode
 
@@ -6996,7 +7002,7 @@ for making the difference obvious.
 
 指定方法は,<list>の中にkey-value listの形で
 \begin{lstlisting}
-stretch_priority={kanjiskip=-40,xkanjiskip=-30,others=50}
+stretch_priority={kanjiskip=-35,xkanjiskip=-25,others=50}
 \end{lstlisting}
 のようにして行う.キー名\texttt{kanjiskip},~\texttt{xkanjiskip}については
 そのままの意味であり,
@@ -7010,9 +7016,9 @@ stretch_priority={kanjiskip=-40,xkanjiskip=-30,others=50}
 \end{cslist}
 初期値は\Param{stretch\_priority}, \Param{shrink\_priority}とも
 \begin{lstlisting}
-{kanjiskip=-40,xkanjiskip=-30,others=50}
+{kanjiskip=-35,xkanjiskip=-25,others=50}
 \end{lstlisting}
-である.
\81§ã\81\82ã\82\8aï¼\8cã\80\8cå\84ªå\85\88度$-4$ã\80\8dã\81¨æ\8c\87å®\9aã\81\95ã\82\8cã\81¦ã\81\84ã\82\8bJFMã\82°ã\83«ã\83¼ã\81\8cæ\9c\80ã\82\82伸ã\81³ï¼\88縮ã\81¿ï¼\89ã\81«ã\81\8fã\81\84ã\82\88ã\81\86ã\81«ã\81ªã\81£ã\81¦ã\81\84ã\82\8bï¼\8e
 %</ja>
 
 \subsection{\Pkg{luatexja-ruby}}
@@ -9362,12 +9368,13 @@ the \texttt{lstlisting} environment or other environments/commands.
 \item \textbf{JAglue}ではないグルー
 \item JFMグルー(優先度\footnote{%
   \ref{ssec-jfm-str}節にあるように,
-  各JFMグルーには$-2$から2までの優先度がついている.}%
+  各JFMグルーには$-4$から3までの優先度がついている.場合によっては
+  伸びと縮みで異なる優先度が付いているかもしれない.}%
 別にまとめられる)
 \item 和欧文間空白(\Param{xkanjiskip})
 \item 和文間空白(\Param{kanjiskip})
 \end{itemize}
-の$1+1+5+1=8$つに類別する.
+の$1+1+8+1=10$つに類別する.
 そして許容されている伸び量(\texttt{stretch}の値)の合計を
 無限のレベルごとに
 \begin{align*}
@@ -9456,20 +9463,24 @@ $n$個あるペナルティの箇所が改行可能箇所である.いずれ
 段落最終行の行末文字の位置調整は,すでに述べた「行分割後の場合」における最終行の処理をそのまま用いている.
 
 \subsection{グルーの調整}
-$|\textit{total}|$の分だけが,行中のグルーの伸び量に応じて負担されることになる.
+$|\textit{total}|$の分だけが,行中のグルーの伸び量,あるいは縮み量に応じて負担されることになる.
 以下,$\textit{total}\geq 0$であると仮定して話を進めるが,負のときも同様である.
-負担するグルーの優先度は以下の順であり,
-できるだけ \Param{kanjiskip} を自然長のままにすることを
-試みている.
+\Pkg{luatexja-adjust}の初期値では以下の順に伸び量を負担するようになっており,
+(優先度$-4$のJFMグルーは例外として)できるだけ\Param{kanjiskip}を自然長のままにすることを
+試みている.この順番は\Param{stretch\_priority}(縮み量については\Param{shrink\_priority})
+パラメータで変更可能である.
 \begin{enumerate}\def\labelenumi{(\Alph{enumi})}
  \item \textbf{JAglue}以外のグルー
+ \item 優先度3のJFMグルー
  \item 優先度2のJFMグルー
  \item 優先度1のJFMグルー
  \item 優先度0のJFMグルー
  \item 優先度$-1$のJFMグルー
  \item 優先度$-2$のJFMグルー
  \item \Param{xkanjiskip}
+ \item 優先度$-3$のJFMグルー
  \item \Param{kanjiskip}
+ \item 優先度$-4$のJFMグルー
 \end{enumerate}
 \begin{enumerate}
  \item 行末の\textbf{JAchar}を移動したことで$\textit{total}=0$となれば,
@@ -9486,7 +9497,7 @@ $|\textit{total}|$の分だけが,行中のグルーの伸び量に応じて
 \texttt{glue\_set}, \texttt{glue\_sign}, \texttt{glue\_order}を再計算する.
 これによって,\textit{total}は\textbf{JAglue}以外のグルーによって負担される.
 \end{enumerate}
-\item \textit{total}が「(A)の伸び量の合計」以上ならば,(A)--(H)のどこまで負担すれば
+\item \textit{total}が「(A)の伸び量の合計」以上ならば,(A)--(K)のどこまで負担すれば
 \textit{total}以上になるかを計算する.
 例えば,
 \[\catcode`\<=12
@@ -9497,17 +9508,17 @@ $|\textit{total}|$の分だけが,行中のグルーの伸び量に応じて
 \begin{itemize}
  \item (A),~(B)に属するグルーは各グルーで許された伸び量まで伸ばす.
  \item (C)に属するグルーはそれぞれ$p\times (\text{伸び量})$だけ伸びる.
- \item (D)--(H)に属するグルーは自然長のまま.
+ \item (D)--(K)に属するグルーは自然長のまま.
 \end{itemize}
 実際には,前に述べた「設計」に従い,次のように処理している:
 \begin{enumerate}
 \item (C)に属するグルーの伸び量を$p$倍する.
-\item (D)--(H)に属するグルーの伸び量を0とする.
+\item (D)--(K)に属するグルーの伸び量を0とする.
 \item 行が格納されているhboxの
 \texttt{glue\_set}, \texttt{glue\_sign}, \texttt{glue\_order}を再計算する.
 これによって,\textit{total}は\textbf{JAglue}以外のグルーによって負担される.
 \end{enumerate}
-\item \textit{total}が(A)--(H)の伸び量の合計よりも大きい場合,どうしようもないので
+\item \textit{total}が(A)--(K)の伸び量の合計よりも大きい場合,どうしようもないので
       \verb+^^;+何もしない.
 \end{enumerate}