X-Git-Url: http://git.osdn.jp/view?a=blobdiff_plain;f=doc%2Fluatexja.dtx;h=4dad142829a191b0775ffdff14f9bb3e14c048cd;hb=26c1be2a3b0b812eada662aae96e73977f4ccccb;hp=303d42c497d9c71a83af7eac87eb4b43536ee107;hpb=73ad088f631a2bdff6dc6e4f6110a9974f3da495;p=luatex-ja%2Fluatexja.git diff --git a/doc/luatexja.dtx b/doc/luatexja.dtx index 303d42c..4dad142 100644 --- a/doc/luatexja.dtx +++ b/doc/luatexja.dtx @@ -1562,56 +1562,6 @@ The following presets are defined: %として読み込み,小塚書体(Pr6N)を使うことを指定している. % which means that Kozuka~Pr6N fonts will be used in this document. -%<*ja> -上記のプリセット以外の和文フォント設定を使いたい場合,本来は -\Pkg{luatexja-fontspec}パッケージの提供する -\cs{setmainjfont}, \cs{setsansjfont}を使って自分で指定するべきである. -\texttt{custom}オプションを使うことで,\Pkg{luatexja-preset}パッケージの内部に直接アクセスして -\begin{lstlisting} -\usepackage[kozuka-pr6n, % kozuka-pr6n プリセットを基礎にして, - custom={ - mc=SourceHanSerif-Regular, % 明朝体(全ウェイト) - mc-l=SourceHanSerif-Bold, % 明朝体細字 - mc-m=KozMinPr6N-Regular, % 明朝体中字 - % mc-bx=KozMinPr6N-Bold, % 明朝体太字 - % gt=HirakakuProN-W3, % ゴシック体(全ウェイト) - % gt-m=SourceHanSans-Regular, % ゴシック体中字(deluxe オプション指定時) - % gt-bx=HiraKakuProN-W6,ular, % ゴシック体太字 - % gt-eb=HiraKakuProN-W6,ular, % ゴシック体極太 - mg-m=HG Maru Gothic PRO, % 丸ゴシック体 - }, - deluxe,expert,jis2004,match,nfssonly -]{luatexja-preset} -\end{lstlisting} -のようにすることもできるが,\texttt{custom}オプションの書式は予告なく変更されることがある -上,\texttt{90jis}や\texttt{JIS2004}オプションとの相性があまり良くないので推奨はしない. -% -%<*en> -To use a Japanese font setting which does not match with any presets, -the legitimate method is to use \cs{setmainjfont}~and~\cs{setsansjfont} -which are provided by the \Pkg{luatexja-fontspec} package. - -One can use the \texttt{custom} option, such as -\begin{lstlisting} -\usepackage[kozuka-pr6n, % based on the kozuka-pr6n preset (Kozuka Pr6N), - custom={ - mc=SourceHanSerif-Regular, % mincho family (all weights) - mc-l=SourceHanSerif-Bold, % mincho light - mc-m=KozMinPr6N-Regular, % mincho medium - % mc-bx=KozMinPr6N-Bold, % mincho bold - % gt=HirakakuProN-W3, % gothic family (all weights) - % gt-m=SourceHanSans-Regular, % gothic medium (with deluxe option) - % gt-bx=HiraKakuProN-W6,ular, % gothic bold - % gt-eb=HiraKakuProN-W6,ular, % gothic extrabold - mg-m=HG Maru Gothic PRO, % rounded gothic - }, - deluxe,expert,jis2004,match,nfssonly -]{luatexja-preset} -\end{lstlisting} -However, we do not recommend this \cs{custom} option; -the format might change, and this \cs{custom} option is not well-compatible with -\texttt{90jis}~nor~\cs{jis2004} options. -% %<*en> \subsection{\cs{CID}, \cs{UTF}, and macros in \Pkg{japanese-otf} package} @@ -2400,7 +2350,6 @@ However, the penalty inserted after it is 10 which is the \Param{postbreakpenalt ``ア'', not 20. % %<*ja> -\newpage \subsection{禁則処理関連パラメータとOpenTypeのfont feature} 禁則処理や \Param{kanjiskip}, \Param{xkanjiskip} の挿入に関連したパラメータのうち \begin{quote} @@ -2802,7 +2751,9 @@ 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 +only when the current list is null. +These commands cannot be executed in unrestricted horizontal modes, nor math modes. +The direction of a math formula is changed to \emph{utod}, when the direction outside the math formula is \emph{tate} (vertical writing). % @@ -2816,6 +2767,8 @@ Down-TO-Upの意味なのだろう.\cs{dtou} を使用する機会はないだ 組方向は,\cs{yoko},~\cs{tate}, \cs{dtou},~\cs{utod} をそれぞれ使用することで, 現在作成中のリストやボックスが空の時にのみ変更可能である. +ただし,現在のモードが非制限水平モードや(文中,別行立て問わず)数式モードであるときには +組方向を変更することは出来ない. また,縦組中の数式内のボックスは\pTeX と同じように組方向が \cs{utod} となる. % @@ -3660,14 +3613,27 @@ JFM中における \texttt{kanjiskip\_natural}, \texttt{kanjiskip\_stretch},\ 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). + \item OpenType Feature~\texttt{vrt2}% + \footnote{If the font does not define \texttt{vrt2} feature, + use \texttt{vert} instead.} is automatically activated, + unless \texttt{vert}~and//or~\texttt{vrt2} are explicitly activated + or deactivated (as the second line in the example below). \begin{lstlisting} -\tfont\S=file:KozMinPr6N-Regular.otf:jfm=ujisv - % vert and vrt2 are automatically activated +\tfont\S=file:KozMinPr6N-Regular.otf:jfm=ujisv % vrt2 is automatically activated \tfont\T=file:KozMinPr6N-Regular.otf:jfm=ujisv;-vert % vert and vrt2 are not activated +\tfont\U=file:ipaexm.ttf:jfm=ujisv + % vert is automatically activated, since this font does not have vrt2 \end{lstlisting} - \item ... + \item Sometimes \texttt{vert} and/or \texttt{vrt2} are not activated + while one specified activation of these feature. + This is because the font does not define these features in current combination of + script~tag and language~system~identifier. + + In this situation, \LuaTeX-ja performs all replacements which is defined in~\texttt{vert} + feature for \emph{some} scripts for \emph{some} languages. + \item Furthermore, a glyph is automatically rotated 90~degrees, + if it is not replaced by \texttt{vert} feature for \emph{any} script + for \emph{any} language, and if it is marked as `r''~or~``Tr'' in UAX~\#50. \item One have to specify the name of vertical JFM in \texttt{jfm=}. \LuaTeX-ja ships following vertical JFMs: \begin{description} @@ -3685,14 +3651,32 @@ A font defined by~\cs{tfont} differs the following points from that by~\cs{jfont \cs{tfont} で定義された縦組用和文フォントは, 以下の点が \cs{jfont} による横組用和文フォントとは異なる: \begin{itemize} - \item 自動的に \texttt{vert}, \texttt{vrt2} の両OpenType featureが有効化される. -但し,以下の例の3行目に示すように,明示的に \texttt{vert}, \texttt{vrt2}(のいずれか)の -有効・無効を指定した場合は別である. + \item 明示的に \texttt{vert}, \texttt{vrt2}(のいずれか)の + 有効・無効を指定した場合を除き,自動的に OpenType feature~\texttt{vrt2} の有効化が + 指定されたものとみなされる + \footnote{もしフォントが\texttt{vrt2}を定義していなかった場合,代わりに + \texttt{vert}を用いる.}. \begin{lstlisting} -\tfont\S=file:KozMinPr6N-Regular.otf:jfm=ujisv - % vert and vrt2 are automatically activated +\tfont\S=file:KozMinPr6N-Regular.otf:jfm=ujisv % vrt2 is automatically activated \tfont\T=file:KozMinPr6N-Regular.otf:jfm=ujisv;-vert % vert and vrt2 are not activated +\tfont\U=file:ipaexm.ttf:jfm=ujisv + % vert is automatically activated, since this font does not have vrt2 \end{lstlisting} + \item \texttt{vert}, \texttt{vrt2} の少なくとも一つの有効を指定した場合にも関わらず, + script tagとlanguage system identifierの値の組み合わせによって + 実際には有効にならなかった場合,\LuaTeX-jaは + \begin{quote} + どれかのscript,~languageで定義されている\texttt{vert}による + (単一グリフから単一グリフへの)置換を全部適用する + \end{quote} + という挙動を取る\footnote{% + 例えば,Windows~7に付属しているSimHeiでは,\texttt{vert}はScriptが\texttt{hani}, + Languageが\texttt{CHN}という状況でのみ定義されている.しかし,\Pkg{luaotfload}では + このscript,~languageの組み合わせを指定することはできないので, + \Pkg{luaotfload}そのままでは\texttt{vert}を適用させることはできない. + }. + \item さらに,「いかなるscript,~languageでも\texttt{vert}により置換されない」グリフ + のうち,UAX~\#50で``r''もしくは``Tr''と指定されているものは90度自動回転させる. \item \ref{ssec-math}節で述べる,数式中の和文フォントには縦組用和文フォントは指定できない. \item \texttt{jfm=}\ の部分には縦組用JFMを指定する. 以下の縦組用JFMが\LuaTeX-jaには同梱されている.%おり,違いを\autoref{tab-difjfm-tate}に示した. @@ -6485,6 +6469,7 @@ A demonstrarion is shown in \autoref{fig:altkanji-fontspec}. %<*en> \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, @@ -7119,8 +7104,8 @@ 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. -One can specified other options other than listed below. -These are simply passed to the \Pkg{luatexja-fontspec}\footnote{if \texttt{nfssonly} option is +Options which are given in \cs{usepackage} but not described in this~subsection +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. % @@ -7130,7 +7115,8 @@ For example, the line~5 in below example is equivalent to lines 1--3. \Pkg{otf}パッケージの一部(多書体化)と八登崇之氏による\Pkg{PXchfon}パッケージの一部(プリセット指定) とを合わせたような格好をしている. -オプションとして,以下のリストにないものも指定することができるが,それらは +パッケージ読み込み時に渡されたオプションのうち, +本節にないものを指定した場合,それらはそのまま \Pkg{luatexja-fontspec}パッケージに渡される\footnote{\texttt{nfssonly} オプションが 指定されていた場合は,\Pkg{luatexja-fontspec}パッケージは読み込まれないので単純に無視され る.}.例えば,下の1--3行目は5行目のように一行にまとめることができる. @@ -7143,6 +7129,10 @@ For example, the line~5 in below example is equivalent to lines 1--3. \usepackage[no-math,match,kozuka-pr6n]{luatexja-preset} \end{lstlisting} +%\subsubsection{General Options} +%\subsubsection{一般的なオプション} +\label{sssec:ltjpreset-general} + \begin{cslist}[before*=] \item[fontspec% %\textrm{~(enabled by default)} @@ -7242,10 +7232,10 @@ This means that \verb+\mcfamily\bfseries+, \verb+\gtfamily\bfseries+ and \item[deluxe] %<*en> Use the mincho family with three weights (light, medium, and~bold), -the gothic family with three weights (medium, bold, and~extrabold), and \textit{rounded gothic}% +the gothic family with three weights (medium, bold, and extra~bold), and \textit{rounded gothic}% \footnote{Provided by \cs{mgfamily} and \cs{textmg}, because ``rounded gothic'' is called \textit{maru gothic} (丸ゴシック) in Japanese.}. -The light weight of mincho and the extrabold weight of gothic can be used by +Mincho light and gothic extra~bold can be by \cs{mcfamily}\cs{ltseries}~and~\cs{gtfamily}\cs{ebseries}, respectively. \begin{itemize} @@ -7337,8 +7327,10 @@ We didn't taken account of when both \texttt{90jis} and \texttt{jis2004} are sp 両オプションが同時に指定された場合の動作については全く考慮していない. % -%\paragraph{Presets for multi weight} -%\paragraph{多ウェイト用プリセットの一覧} +%\subsubsection{Presets which support multi weights} +%\subsubsection{多ウェイト用プリセットの一覧} +\label{sssec:ltjpreset-multi} + %<*en> Besides \texttt{morisawa-pro}~and~\texttt{morisawa-pr6n} presets, fonts are specified by font name, not by file name. @@ -7367,7 +7359,7 @@ There is not rounded gothic family in Kozuka fonts. 「小塚丸ゴシック」は存在しないので,便宜的に小塚ゴシックHによって代用している. % \begin{center}\small -\begin{tabular}{cllll} +\begin{tabular}{lllll} \toprule \bfseries family&\bfseries series&\ttfamily kozuka-pro&\ttfamily kozuka-pr6&\ttfamily kozuka-pr6n\\ \midrule @@ -7384,7 +7376,7 @@ There is not rounded gothic family in Kozuka fonts. %\smash{\raisebox{2ex}{\textit{gothic}}}% %\smash{\raisebox{2ex}{\gt ゴシック}}% &bold&KozGoPro-Bold&KozGoProVI-Bold&KozGoPr6N-Bold\\ - &extrabold&KozGoPro-Heavy&KozGoProVI-Heavy&KozGoPr6N-Heavy\\ + &extra bold&KozGoPro-Heavy&KozGoProVI-Heavy&KozGoPr6N-Heavy\\ \midrule %\textit{rounded gothic} %\gt 丸ゴシック @@ -7401,8 +7393,8 @@ There is not rounded gothic family in Kozuka fonts. %<*en> Hiragino fonts (except Hiragino~Mincho~W2) 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 extrabold weight of gothic family only supports -Adobe-Japan1-3 character collection (Std/StdN), while others supports +Note that fonts for gothic extra~bold (HiraKakuStd[N]-W8) only contains characters in +Adobe-Japan1-3 character collection, while others contains those in Adobe-Japan1-5 character collection. % %<*ja> @@ -7414,7 +7406,7 @@ Std/StdNフォントであり,その他はAdobe-Japan1-5対応である. 別途購入する必要がある. % \begin{center}\small -\begin{tabular}{clll} +\begin{tabular}{llll} \toprule \bf family&\bf series&\tt hiragino-pro&\tt hiragino-pron\\ \midrule @@ -7431,7 +7423,7 @@ Std/StdNフォントであり,その他はAdobe-Japan1-5対応である. %\smash{\raisebox{2ex}{\textit{gothic}}}% %\smash{\raisebox{2ex}{\gt ゴシック}}% &bold&Hiragino~Kaku~Gothic~Pro~W6&Hiragino~Kaku~Gothic~ProN~W6\\ - &extrabold&Hiragino~Kaku~Gothic~Std~W8&Hiragino~Kaku~Gothic~StdN~W8\\ + &extra bold&Hiragino~Kaku~Gothic~Std~W8&Hiragino~Kaku~Gothic~StdN~W8\\ \midrule %\textit{rounded gothic} %\gt 丸ゴシック @@ -7443,8 +7435,8 @@ Std/StdNフォントであり,その他はAdobe-Japan1-5対応である. \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} +\begin{center}\footnotesize +\begin{tabular}{ll>{\tt}l>{\tt}l} \toprule \bf family&\bf series&morisawa-pro&morisawa-pr6n\\ \midrule @@ -7458,7 +7450,7 @@ Std/StdNフォントであり,その他はAdobe-Japan1-5対応である. %\textit{gothic}% %\gt ゴシック &bold&A-OTF-FutoGoB101Pro-Bold.otf&A-OTF-FutoGoB101Pr6N-Bold.otf\\ - &extrabold&A-OTF-MidashiGoPro-MB31.otf&A-OTF-MidashiGoPr6N-MB31.otf\\ + &extra bold&A-OTF-MidashiGoPro-MB31.otf&A-OTF-MidashiGoPr6N-MB31.otf\\ \midrule %\textit{rounded gothic} %\gt 丸ゴシック @@ -7474,7 +7466,7 @@ Std/StdNフォントであり,その他はAdobe-Japan1-5対応である. % \\*[-\dimexpr\medskipamount+\baselineskip\relax] \item[yu-osx] Yu fonts bundled with OSX~Mavericks. \begin{center}\small -\begin{tabular}{cllll} +\begin{tabular}{lllll} \toprule \bf family&\bf series&\texttt{yu-win}&\texttt{yu-win10}&\texttt{yu-osx}\\ \midrule @@ -7491,7 +7483,7 @@ Std/StdNフォントであり,その他はAdobe-Japan1-5対応である. %\textit{gothic}% %\gt ゴシック &bold&YuGothic-Bold&YuGothic-Bold&YuGothic~Bold\\ - &extrabold&YuGothic-Bold&YuGothic-Bold&YuGothic~Bold\\ + &extra bold&YuGothic-Bold&YuGothic-Bold&YuGothic~Bold\\ \midrule %\textit{rounded gothic} %\gt 丸ゴシック @@ -7506,7 +7498,7 @@ Std/StdNフォントであり,その他はAdobe-Japan1-5対応である. %\par These fonts can be downloaded from \url{http://yozvox.web.fc2.com/}. %これらのフォントは \url{http://yozvox.web.fc2.com/} からダウンロードできる. \begin{center}\small -\begin{tabular}{clll} +\begin{tabular}{llll} \toprule \bf family&\bf series&\bf default, \texttt{90jis}~option&\bf \texttt{jis2004} option\\ \midrule @@ -7519,7 +7511,7 @@ Std/StdNフォントであり,その他はAdobe-Japan1-5対応である. %\textit{gothic}% %\gt ゴシック &bold&Moga90Gothic Bold&MogaGothic Bold\\ - &extrabold&Moga90Gothic Bold&MogaGothic Bold\\ + &extra bold&Moga90Gothic Bold&MogaGothic Bold\\ \midrule %\textit{rounded gothic} %\gt 丸ゴシック @@ -7534,7 +7526,7 @@ Std/StdNフォントであり,その他はAdobe-Japan1-5対応である. %\par 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} +\begin{tabular}{lll} \toprule \bf family&\bf series&\bf default\\ \midrule @@ -7549,7 +7541,7 @@ Std/StdNフォントであり,その他はAdobe-Japan1-5対応である. %\textit{gothic}% %\gt ゴシック &bold&Ume Gothic O5\\ - &extrabold&Ume Gothic O5\\ + &extra bold&Ume Gothic O5\\ \midrule %\textit{rounded gothic} %\gt 丸ゴシック @@ -7563,7 +7555,7 @@ Std/StdNフォントであり,その他はAdobe-Japan1-5対応である. \item[sourcehan-jp] Source Han Serif JP and Source Han Sans JP fonts (Region-specific Subset OTF) \begin{center}\small \def\AD#1#2{Source Han #1 #2&Source Han #1 JP #2}% -\begin{tabular}{cllll} +\begin{tabular}{lllll} \toprule \bf family&\bf series&\texttt{sourcehan}&\texttt{sourcehan-jp}\\ \midrule @@ -7580,7 +7572,7 @@ Std/StdNフォントであり,その他はAdobe-Japan1-5対応である. %\smash{\raisebox{2ex}{\textit{gothic}}}% %\smash{\raisebox{2ex}{\gt ゴシック}}% &bold&\AD{Sans}{Bold}\\ - &extrabold&\AD{Sans}{Heavy}\\ + &extra bold&\AD{Sans}{Heavy}\\ \midrule %\textit{rounded gothic} %\gt 丸ゴシック @@ -7595,7 +7587,7 @@ Std/StdNフォントであり,その他はAdobe-Japan1-5対応である. \item[noto-otf] Noto Serif CJK and Noto Sans CJK fonts (Language-specific OTF) \begin{center}\small \def\AD#1#2{Noto #1 CJK #2&Noto #1 CJK JP #2}% -\begin{tabular}{cllll} +\begin{tabular}{lllll} \toprule \bf family&\bf series&\texttt{noto-otc}&\texttt{noto-otf}\\ \midrule @@ -7612,7 +7604,7 @@ Std/StdNフォントであり,その他はAdobe-Japan1-5対応である. %\smash{\raisebox{2ex}{\textit{gothic}}}% %\smash{\raisebox{2ex}{\gt ゴシック}}% &bold&\AD{Sans}{Bold}\\ - &extrabold&\AD{Sans}{Black}\\ + &extra bold&\AD{Sans}{Black}\\ \midrule %\textit{rounded gothic} %\gt 丸ゴシック @@ -7621,11 +7613,11 @@ Std/StdNフォントであり,その他はAdobe-Japan1-5対応である. \end{tabular} \end{center} - - \end{cslist} -%\paragraph{Presets for single weight} -%\paragraph{単ウェイト用プリセット一覧} +%\subsubsection{Presets which do not support multi weights} +%\subsubsection{単ウェイト用プリセット一覧} +\label{sssec:ltjpreset-single} + %<*en> Next, we describe settings for using only single weight. % @@ -7646,68 +7638,56 @@ Next, we describe settings for using only single weight. &IPA Gothic&IPAex Gothic&MS Gothic\\ % %<*ja> -\gtfamily 明朝体&Ryumin-Light(非埋込) +\gtfamily 明朝&Ryumin-Light(非埋込) &IPA明朝&IPAex明朝&MS明朝\\ -\gtfamily ゴシック体&GothicBBB-Medium(非埋込) +\gtfamily ゴシック&GothicBBB-Medium(非埋込) &IPAゴシック&IPAexゴシック&MSゴシック\\ % \bottomrule \end{tabular}\par\medskip} -%\paragraph{Using HG fonts} -%\paragraph{HGフォントの利用} +%\subsubsection{Presets which use HG fonts} +%\subsubsection{HGフォントを使うプリセット} +\label{sssec:ltjpreset-hg} %<*en> We can use HG~fonts bundled with Microsoft~Office for realizing multiple weights. +In the table below, starred fonts (e.g., IPA~Gothic*) are used +only if \texttt{jis2004} or \texttt{nodeluxe} option is spefified. % %<*ja> すぐ前に書いた単ウェイト用設定を,Microsoft Office等に付属するHGフォントを使って -多ウェイト化した設定もある. +多ウェイト化した設定もある.以下の表では,*~付きのフォント(例:IPAゴシック*)は +\texttt{jis2004}と\texttt{nodeluxe}のいずれかのオプションが有効になっているときに使われる. % \par\nobreak\medskip {\centering\small -\begin{tabular}{llll} +\begin{tabular}{lllll} \toprule -&\tt ipa-hg&\tt ipaex-hg&\tt ms-hg\\ +\textbf{family}&\textbf{series}&\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 extrabold& -\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}\\ +&medium&IPA Mincho&IPAex Mincho&MS Mincho\\ +\smash{\raisebox{1.5ex}{\textit{mincho}}}% +&bold&HG Mincho E&HG Mincho E&HG Mincho E\\\midrule +&&IPA Gothic*&IPAex Gothic*&MS Gothic*\\ +&\smash{\raisebox{1.5ex}{medium}}% +&HG Gothic M&HG Gothic M&HG Gothic M\\\cmidrule{2-5} +\textit{gothic}&bold&HG Gothic E&HG Gothic E&HG Gothic E\\\cmidrule{2-5} +&extra bold&HG Soei Kaku Gothic UB&HG Soei Kaku Gothic UB&HG Soei Kaku Gothic UB\\\midrule +\textit{rounded gothic}&& +HG MaruGothic M PRO&HG MaruGothic M PRO&HG MaruGothic M PRO\\ +% +%<*ja> +&medium&IPA明朝&IPAex明朝&MS明朝\\ +\smash{\raisebox{1.5ex}{\textgt{明朝}}}% +&bold&HG明朝E&HG明朝E&HG明朝E\\\midrule +&&IPAゴシック*&IPAexゴシック*&MSゴシック*\\ +&\smash{\raisebox{1.5ex}{medium}}% +&HGゴシックM&HGゴシックM&HGゴシックM\\\cmidrule{2-5} +\textgt{ゴシック}&bold&HGゴシックE&HGゴシックE&HGゴシックE\\\cmidrule{2-5} +&extra bold&HG創英角ゴシックUB&HG創英角ゴシックUB&HG創英角ゴシックUB\\\midrule +\textgt{丸ゴシック}&& +HG丸ゴシックM-PRO&HG丸ゴシックM-PRO&HG丸ゴシックM-PRO\\ % \bottomrule \end{tabular}\par\medskip} @@ -7733,6 +7713,138 @@ are internally specified by: として指定を行っているので注意すること. % +%\subsubsection{Define/Use Custom Presets} +%\subsubsection{新たなプリセットの定義} + +%<*ja> +バージョン********.0以降では,自分で新たなプリセットを定義することが出来るようになった. +以下に説明する2命令はプリアンブルでしか実行できない. +% +%<*en> +From version~********.0, one can define new presets using \cs{ltjnewpreset}, +and use them by \cs{ltjapplypreset}. These two commands can only be used in the preamble. +% +\begin{cslist} + \item[\cs{ltjnewpreset}\{\}\{\}] +%<*ja> + 新たにという名称のプリセットを定義する.この名称は, + すでに定義されているプリセット名や, + \ref{sssec:ltjpreset-general}で定義されているオプション,さらに + 次の9つと重複してはならない. + \begin{quote} + \ttfamily + mc mc-l mc-m mc-bx gt gt-m gt-bx gt-eb mg-m + \end{quote} + + は,プリセット名や以下のキー達のコンマ区切りリストを指定する: + \begin{description} + \item[\ttfamily mc-l=] 明朝体細字(\cs{mcfamily}\cs{ltseries}) + \item[\ttfamily mc-m=] 明朝体中字(\cs{mcfamily}\cs{mdseries}) + \item[\ttfamily mc-bx=] 明朝体太字(\cs{mcfamily}\cs{bfseries}) + \item[\ttfamily gt-m=] ゴシック体中字(\cs{gtfamily}\cs{mdseries}) + \item[\ttfamily gt-bx=] ゴシック体太字(\cs{gtfamily}\cs{bfseries}) + \item[\ttfamily gt-eb=] ゴシック体太字(\cs{gtfamily}\cs{ebseries}) + \item[\ttfamily mg-m=] 丸ゴシック体(\cs{mgfamily}) + \item[\ttfamily mc=] 明朝体の細字・中字・太字全部を設定. + 以下を指定したことと同じである: + \begin{quote} + \ttfamily mc-l=, mc-m=, mc-bx= + \end{quote} + \item[\ttfamily gt=] ゴシック体の中字・太字・極太全部を設定. + 以下を指定したことと同じである: + \begin{quote} + \ttfamily gt-m=, gt-bx=, gt-eb= + \end{quote} + \end{description} + なお,パッケージ読み込み時に \texttt{deluxe} が有効でない場合は, + 上記9キーのうち\texttt{mc}, \texttt{gt}しか実質的に意味を持たない. +% +%<*en> + Define new preset~. This cannot be same as other presets, + options described in Subsubsection~\ref{sssec:ltjpreset-general}, nor + following nine strings: + \begin{quote} + \ttfamily + mc mc-l mc-m mc-bx gt gt-m gt-bx gt-eb mg-m + \end{quote} + + is a comma-separated list which consists of + other presets and/or the following keys: + \begin{description} + \item[\ttfamily mc-l=] mincho light + \item[\ttfamily mc-m=] mincho medium + \item[\ttfamily mc-bx=] mincho bold + \item[\ttfamily gt-m=] gothic medium + \item[\ttfamily gt-bx=] gothic bold + \item[\ttfamily gt-eb=] gothic extra~bold + \item[\ttfamily mg-m=] rounded gothic + \item[\ttfamily mc=] Same as + \begin{quote} + \ttfamily mc-l=, mc-m=, mc-bx= + \end{quote} + \item[\ttfamily gt=] Same as + \begin{quote} + \ttfamily gt-m=, gt-bx=, gt-eb= + \end{quote} + \end{description} + If \texttt{deluxe} is not specified at loading the package, + only \texttt{mc}~and~\texttt{gt} keys (among above 9~keys) have a meaning. +% + \item[\cs{ltjnewpreset}*\{\}\{\}] +%<*ja> + \cs{ltjnewpreset}とほぼ同じであるが,こちらはすでに定義されているプリセット名 + をに指定した場合にはエラーを出さずに定義を置き換える. +% +%<*en> + Almost same as \cs{ltjnewpreset}. However, if matches a preset which already defined, + this command simply overwrite it. +% + \item[\cs{ltjapplypreset}\{\}] +% で指定されたプリセットを使って和文フォントを設定する. +% Set Japanese font families using preset~. +\end{cslist} + +%<*ja> +なお,\cs{ltjnewpreset}の第二引数に含まれる +プリセット名は\cs{ltjnewpreset}の時点で定義されている必要はなく, +\cs{ltjapplypreset}で実際に使うときに定義されていれば良い. +そのため,次のような記述も可能である: +\begin{lstlisting} + \ltjnewpreset{hoge}{piyo,mc-bx=HiraMinProN-W6} + \ltjnewpreset{piyo}{mg-m=HiraMaruProN-W4} + \ltjapplypreset{hoge} +\end{lstlisting} + +\paragraph{注意} +\cs{ltjnewpreset}で定義したプリセットには以下の制限がある. +\begin{itemize} + \item 非埋め込みのフォントを指定することはできない. + \item \texttt{ipa-hg}などのいくつかのプリセットでは + 「\texttt{90jis}, \texttt{jis2004}が指定されているか否かでフォントの指定を変える」処理が + 行われていたが,\cs{ltjnewpreset}で定義したプリセットではこの処理は働かない. + HGフォントやモガ明朝などを使うプリセットを定義する場合には注意すること. +\end{itemize} +% +%<*en> +Note that \cs{ltjnewpreset} does not ``expand'' the definition to define a preset. +This means that one can write as the following: +\begin{lstlisting} + \ltjnewpreset{hoge}{piyo,mc-bx=HiraMinProN-W6} + \ltjnewpreset{piyo}{mg-m=HiraMaruProN-W4} + \ltjapplypreset{hoge} +\end{lstlisting} + +\paragraph{Restrictions} +Presets which are defined by \cs{ltjnewpreset} have following restrictions: +\begin{itemize} + \item One cannot specify non-embedded fonts (such as Ryumin-Light). + \item Some presets, such as \texttt{ipa-hg}, have a feature that + fonts are changed according to whether \texttt{90jis}~or~\texttt{jis2004} is speified. + This feature is not usable in presets which are defined by \cs{ltjnewpreset}. +\end{itemize} +% + + \clearpage %\part{Implementations} %\part{実装}