diff options
author | Karl Berry <karl@freefriends.org> | 2014-10-13 22:10:02 +0000 |
---|---|---|
committer | Karl Berry <karl@freefriends.org> | 2014-10-13 22:10:02 +0000 |
commit | 44cb8e3fdd11a1ec6f1dd29e110ba10309bc6cd1 (patch) | |
tree | 666a3352effc147618e30969bb89d02e77a3028d | |
parent | a81c9d1ef0b46432af068c7bb16347426eb1f7ce (diff) |
luatexja (13oct14)
git-svn-id: svn://tug.org/texlive/trunk@35368 c570f23f-e606-0410-a88d-b1316a301751
-rw-r--r-- | Master/texmf-dist/doc/luatex/luatexja/README | 12 | ||||
-rw-r--r-- | Master/texmf-dist/doc/luatex/luatexja/luatexja-en.pdf | bin | 376712 -> 379321 bytes | |||
-rw-r--r-- | Master/texmf-dist/doc/luatex/luatexja/luatexja-ja.pdf | bin | 739421 -> 746236 bytes | |||
-rw-r--r-- | Master/texmf-dist/doc/luatex/luatexja/luatexja.dtx | 161 | ||||
-rw-r--r-- | Master/texmf-dist/tex/luatex/luatexja/addons/luatexja-preset.sty | 2 | ||||
-rw-r--r-- | Master/texmf-dist/tex/luatex/luatexja/ltj-adjust.lua | 3 | ||||
-rw-r--r-- | Master/texmf-dist/tex/luatex/luatexja/ltj-jfmglue.lua | 2 | ||||
-rw-r--r-- | Master/texmf-dist/tex/luatex/luatexja/ltj-jfont.lua | 3 | ||||
-rw-r--r-- | Master/texmf-dist/tex/luatex/luatexja/ltj-plain.sty | 6 | ||||
-rw-r--r-- | Master/texmf-dist/tex/luatex/luatexja/ltj-pretreat.lua | 7 | ||||
-rw-r--r-- | Master/texmf-dist/tex/luatex/luatexja/ltj-stack.lua | 21 | ||||
-rw-r--r-- | Master/texmf-dist/tex/luatex/luatexja/luatexja-core.sty | 1 | ||||
-rw-r--r-- | Master/texmf-dist/tex/luatex/luatexja/patches/lltjdefs.sty | 6 |
13 files changed, 143 insertions, 81 deletions
diff --git a/Master/texmf-dist/doc/luatex/luatexja/README b/Master/texmf-dist/doc/luatex/luatexja/README index 1a512476d8c..ec829936504 100644 --- a/Master/texmf-dist/doc/luatex/luatexja/README +++ b/Master/texmf-dist/doc/luatex/luatexja/README @@ -1,4 +1,4 @@ -The LuaTeX-ja Package 20140906.0 +The LuaTeX-ja Package 20141013.0 -------------------------------- Copyright (c) 2011--2014 The LuaTeX-ja project License: modified BSD (see COPYING) @@ -22,10 +22,12 @@ Installation ------------ 0. Please make sure that your TeX distribution is up-to-date. - This version of LuaTeX-ja requires + This version of LuaTeX-ja requires - LuaTeX beta-0.74.0 or later - luaotfload v2.2 - luatexbase v0.6 + - everysel package + - IPAex fonts (http://ipafont.ipa.go.jp/) Hence this version does not work in TeX Live 2012 (or earlier). 1. If you are using TeX Live 2013 or later, you can install LuaTeX-ja via tlmgr. @@ -33,9 +35,9 @@ Installation 2. If you must/want to install manually: a. Download the source archive from CTAN, - or tagged as 20140906.0 in the Git repository by + or tagged as 20141013.0 in the Git repository by <http://git.sourceforge.jp/view?p=luatex-ja/luatexja.git - ;a=snapshot;h=refs/tags/20140906.0;sf=tgz> + ;a=snapshot;h=refs/tags/20141013.0;sf=tgz> b1. Extract the archive and process following three files by LuaLaTeX to generate classes for Japanese typesetting: @@ -80,4 +82,4 @@ Notes * src/*.{ins.dtx} and src/ltj-kinsoku_make.tex are not needed in regular use. -Last commit date: Sat Sep 6 17:20:21 2014 +0900 +Last commit date: Mon Oct 13 15:12:04 2014 +0900 diff --git a/Master/texmf-dist/doc/luatex/luatexja/luatexja-en.pdf b/Master/texmf-dist/doc/luatex/luatexja/luatexja-en.pdf Binary files differindex 11dae1c3d06..9a397716855 100644 --- a/Master/texmf-dist/doc/luatex/luatexja/luatexja-en.pdf +++ b/Master/texmf-dist/doc/luatex/luatexja/luatexja-en.pdf diff --git a/Master/texmf-dist/doc/luatex/luatexja/luatexja-ja.pdf b/Master/texmf-dist/doc/luatex/luatexja/luatexja-ja.pdf Binary files differindex f1d26f67b62..a664af6c94b 100644 --- a/Master/texmf-dist/doc/luatex/luatexja/luatexja-ja.pdf +++ b/Master/texmf-dist/doc/luatex/luatexja/luatexja-ja.pdf diff --git a/Master/texmf-dist/doc/luatex/luatexja/luatexja.dtx b/Master/texmf-dist/doc/luatex/luatexja/luatexja.dtx index b0d7a89baae..f98bd5dfcd0 100644 --- a/Master/texmf-dist/doc/luatex/luatexja/luatexja.dtx +++ b/Master/texmf-dist/doc/luatex/luatexja/luatexja.dtx @@ -540,6 +540,8 @@ and \emph{Japanese fonts} for fonts used in \textbf{JAchar}. \item \Pkg{xunicode} v0.981~(2011/09/09) \item \Pkg{adobemapping} (Adobe cmap and pdfmapping files) \item \Pkg{everysel} +%<en>\item \emph{IPAex fonts(\url{http://ipafont.ipa.go.jp/})} +%<ja>\item \emph{IPAexフォント(\url{http://ipafont.ipa.go.jp/})} \end{itemize} %<*en> @@ -549,13 +551,15 @@ since \LuaTeX\ binary and \Pkg{luaotfload} is updated in \medskip -Now \LuaTeX-ja is available from the following archive and distributions: +Now \LuaTeX-ja is available from +CTAN (in the \texttt{macros/luatex/generic/luatexja} directory), and +the following distributions: \begin{itemize} - \item CTAN (in the \texttt{macros/luatex/generic/luatexja} directory) \item MiK\TeX\ (in \texttt{luatexja.tar.lzma}); see the next subsection \item \TeX\ Live (in \texttt{texmf-dist/tex/luatex/luatexja}) \item W32\TeX\ (in \texttt{luatexja.tar.xz}) \end{itemize} +IPAex fonts are also available in these distributions. If you are using \TeX~Live~2014, you can install \LuaTeX-ja from \TeX~Live manager (\texttt{tlmgr}): @@ -569,13 +573,15 @@ $ tlmgr install luatexja \medskip -現在,\LuaTeX-jaは以下のアーカイブ,およびディストリビューションに収録されている: +現在,\LuaTeX-jaはCTAN (\texttt{macros/luatex/generic/luatexja})に収録されている他, +以下のディストリビューションにも収録されている: \begin{itemize} - \item CTAN (\texttt{macros/luatex/generic/luatexja}) \item MiK\TeX\ (\texttt{luatexja.tar.lzma}) \item \TeX\ Live (\texttt{texmf-dist/tex/luatex/luatexja}) \item W32\TeX\ (\texttt{luatexja.tar.xz}) \end{itemize} +これらのディストリビューションはIPAexフォントも収録している. +W32\TeX においてはIPAexフォントは \texttt{luatexja.tar.xz} 内にある. 例えば\TeX~Live~2014を利用しているなら,\LuaTeX-jaは\TeX~Live manager (\texttt{tlmgr})を 使ってインストールすることができる. @@ -765,8 +771,8 @@ run \LuaTeX-ja in this directory, and finally delete the temporary directory. \textbf{direction}& \textbf{classification}&\textbf{font name}&\bf `10\,pt'&\bf`7\,pt'&\bf`5\,pt'\\\midrule \smash{\raisebox{-1ex}{\emph{yoko} (horizontal)}}& -\emph{mincho}&Ryumin-Light &\cs{tenmin}&\cs{sevenmin}&\cs{fivemin}\\ -&\emph{gothic}&GothicBBB-Medium&\cs{tengt} &\cs{sevengt} &\cs{fivegt}\\ +\emph{mincho}&IPAex Mincho&\cs{tenmin}&\cs{sevenmin}&\cs{fivemin}\\ +&\emph{gothic}&IPAex Gothic&\cs{tengt} &\cs{sevengt} &\cs{fivegt}\\ \bottomrule \end{tabular} \end{center} @@ -776,28 +782,22 @@ run \LuaTeX-ja in this directory, and finally delete the temporary directory. \begin{center}\small \begin{tabular}{cccccc} \toprule -&\emph{字体}&\emph{フォント名}&\bf `10\,pt'&\bf`7\,pt'&\bf`5\,pt'\\\midrule +&\emph{字体}&\emph{フォント}&\bf `10\,pt'&\bf`7\,pt'&\bf`5\,pt'\\\midrule & -明朝体&Ryumin-Light &\cs{tenmin}&\cs{sevenmin}&\cs{fivemin}\\ -&ゴシック体&GothicBBB-Medium&\cs{tengt} &\cs{sevengt} &\cs{fivegt}\\ +明朝体&IPex明朝&\cs{tenmin}&\cs{sevenmin}&\cs{fivemin}\\ +&ゴシック体&IPAexゴシック&\cs{tengt} &\cs{sevengt} &\cs{fivegt}\\ \bottomrule \end{tabular} \end{center} %</ja> \begin{itemize} %<*en> -\item It is widely accepted that fonts ``Ryumin-Light'' and - ``GothicBBB-Medium'' aren't embedded into PDF files, and a PDF reader - substitute them by some external Japanese fonts (\textit{e.g.}, - Ryumin-Light is substituted with Kozuka Mincho in Adobe Reader). - We adopt this custom to the default setting. +\item With \texttt{luatexja.cfg}, one can use other fonts +as ``default'' Japanese fonts (Subsection~\ref{ssec-cfg}). %</en> %<*ja> -\item ``Ryumin-Light''と``GothicBBB-Medium''はPDFファイルに埋め込まずに - 名前参照のみで用いることが広く受け入れられており,この場合PDFリーダーが - 適切な外部フォントで代用する(例えば,Adobe ReaderではRyumin-Lightは - 小塚明朝で代替される).そこで,これらを引き続きデフォルトのフォントと - して採用する. +\item \texttt{luatexja.cfg} を用いることによって,標準和文フォントを +IPAexフォントから別のフォントに置き換えることができる.\ref{ssec-cfg}節を参照. %</ja> %<*en> @@ -832,8 +832,6 @@ run \LuaTeX-ja in this directory, and finally delete the temporary directory. %<ja>\subsection{\LaTeX で使う} \label{ssec-ltx} -\paragraph{\LaTeXe} - %<*en> Using in \LaTeXe\ is basically same. To set up the minimal environment for Japanese, you only have to load \texttt{luatexja.sty}: @@ -883,15 +881,14 @@ By default, the following fonts are used for \emph{mincho} and \emph{gothic}: \begin{center}\small \begin{tabular}{ccccc} \toprule -\textbf{classification}&\textbf{family name}&\cs{mdseries}&\cs{bfseries}&\textbf{scale}\\\midrule -\emph{mincho} (明朝体)&\tt mc&Ryumin-Light &GothicBBB-Medium&0.962216\\ -\emph{gothic} (\textgt{ゴシック体})&\tt gt&GothicBBB-Medium&GothicBBB-Medium&0.962216\\ +\textbf{classification}&\textbf{family}&\cs{mdseries}&\cs{bfseries}&\textbf{scale}\\\midrule +\emph{mincho} (明朝体)&\tt mc&IPAex Mincho&IPAex Gothic&0.962216\\ +\emph{gothic} (\textgt{ゴシック体})&\tt gt&IPAex Gothic&IPAex Gothic&0.962216\\ \bottomrule \end{tabular} \end{center} -Note that the bold series in both family are same as the medium series of \emph{gothic} family. -This is a convention in \pLaTeX. This is trace that there were only 2~fonts (these are Ryumin-Light -and GothicBBB-Medium) in early years of DTP. There is no italic nor slanted shape for +Note that the bold series in both family are same as the medium series of \emph{gothic} + family. There is no italic nor slanted shape for these \texttt{mc}~and~\texttt{gt}. %</en> %<*ja> @@ -910,16 +907,14 @@ and GothicBBB-Medium) in early years of DTP. There is no italic nor slanted shap \begin{tabular}{ccccc} \toprule \emph{字体}&\emph{ファミリ}&\cs{mdseries}&\cs{bfseries}&\emph{スケール}\\\midrule -明朝体&\tt mc&Ryumin-Light &GothicBBB-Medium&0.962216\\ -ゴシック体&\tt gt&GothicBBB-Medium&GothicBBB-Medium&0.962216\\ +明朝体&\tt mc&IPAex明朝&IPAexゴシック&0.962216\\ +ゴシック体&\tt gt&IPAexゴシック&IPAexゴシック&0.962216\\ \bottomrule \end{tabular} \end{center} どちらのファミリにおいても,そのboldシリーズで使われるフォントは -ゴシック体のmediumシリーズで使われるフォントと同じあることに注意. -これは初期のDTPにおいて和文フォントが2つ(それがちょうど\ -Ryumin-Light, GothicBBB-Mediumだった)しか利用できなかった時の名残であり,\pLaTeX{} -での標準設定とも同じである. +ゴシック体のmediumシリーズで使われるフォントと同じであることに注意. +また,どちらのファミリでもイタリック体・スラント体は定義されない. %</ja> @@ -952,6 +947,21 @@ Okumura), namely, \Pkg{ltjclasses}\footnote{% がそれぞれ用意されている. %</ja> +%<*ja> +\paragraph{脚注とボトムフロートの出力順序} +オリジナルの\LaTeX では脚注がボトムフロートの上に来るようになっており, +\pLaTeX では脚注がボトムフロートの下に来るように変更されている. + +\LuaTeX-jaでは「欧文クラスの中にちょっとだけ日本語を入れる」という利用も考慮し, +脚注とボトムフロートの順序は\LaTeX 通りとした.もし\pLaTeX の出力順序が好みならば, +\Pkg{stfloats}パッケージを利用して +\begin{lstlisting} + \usepackage{stfloats} \fnbelowfloat +\end{lstlisting} +のようにすればよい.\Pkg{footmisc}パッケージを \texttt{bottom}\ オプションを指定して +読み込むという方法もあるが,それだとボトムフロートと脚注の間が開いてしまう. +%</ja> + %<en>\section{Changing Fonts} %<ja>\section{フォントの変更} @@ -1351,6 +1361,7 @@ We didn't taken account of when both \texttt{90jis} and \texttt{jis2004} are sp 同時に指定された場合の動作については全く考慮していない. %</ja> + \newpage %<en>\paragraph{Presets for multi weight} %<ja>\paragraph{多ウェイト用プリセットの一覧} @@ -1537,9 +1548,9 @@ even if \texttt{deluxe} option is also specified). \midrule %<*en> \it mincho&Ryumin-Light (non-embedded) -&IPAMincho&IPAexMincho&MS Mincho\\ +&IPA Mincho&IPAex Mincho&MS Mincho\\ \it gothic&GothicBBB-Medium (non-embedded) -&IPAGothic&IPAexGothic&MS Gothic\\ +&IPA Gothic&IPAex Gothic&MS Gothic\\ %</en> %<*ja> \gtfamily 明朝体&Ryumin-Light(非埋込) @@ -1568,14 +1579,14 @@ We can use HG~fonts bundled with Microsoft~Office for realizing multiple weights \midrule %<*en> \bf mincho medium -&IPAMincho&IPAexMincho&MS Mincho\\\midrule +&IPA Mincho&IPAex Mincho&MS Mincho\\\midrule \bf mincho bold& \multicolumn{3}{c}{HG Mincho E}\\\midrule \bf Gothic medium\\ ~~without \texttt{deluxe} -&IPAGothic&IPAexGothic&MS Gothic\\ +&IPA Gothic&IPAex Gothic&MS Gothic\\ ~~with {\tt jis2004} -&IPAGothic&IPAexGothic&MS Gothic\\ +&IPA Gothic&IPAex Gothic&MS Gothic\\ \cmidrule(lr){1-4} ~~otherwise& \multicolumn{3}{c}{HG Gothic M}\\\midrule @@ -1677,6 +1688,59 @@ If you want to use these functions, load \Pkg{luatexja-otf} package. \ref{ssec-fontspec}節 (\Pkg{fontspec}) の方法で手動で指定する必要がある. %</ja> +%<en>\subsection{Changing default Japanese fonts} +%<ja>\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. + +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> +%<*ja> +\LuaTeX から見える位置に \texttt{luatexja.cfg} があれば,\LuaTeX-jaはそれを読み込む. +このファイルを用いるとplain~\TeX, \LaTeXe における標準和文フォントを +IPAex明朝・IPAexゴシックから変更することがdできる. +しかし,基本的には\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} +と記述すればよい. +%</ja> + %<en>\section{Changing Parameters} %<ja>\section{パラメータの変更} @@ -1796,7 +1860,7 @@ these eight ranges belongs to the character range~217. %</ja> \begin{description} %<*en> -\newpage + \item[Range~8${}^{\text{J}}$] 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: @@ -1973,7 +2037,7 @@ The block list is indicated in Table~\ref{table-rng7}. \end{description} -%<en>\newpage\subsection{\Param{kanjiskip} and \Param{xkanjiskip}} +%<en>\subsection{\Param{kanjiskip} and \Param{xkanjiskip}} %<ja>\subsection{\Param{kanjiskip}と\Param{xkanjiskip}} \label{subs-kskip} @@ -2814,9 +2878,9 @@ Besides ``\texttt{file:}''\ and ``\texttt{name:}''\ prefixes which are introduced in the \Pkg{luaotfload} package, \LuaTeX-ja adds ``\texttt{psft:}''\ prefix in \cs{jfont} (and~\cs{font}), to specify a ``name-only'' Japanese font which -will not be embedded to PDF. Typical use of this prefix is to specify -standard, non-embedded Japanese fonts, namely, ``Ryumin-Light'' and -``GothicBBB-Medium''. +will not be embedded to PDF. +Note that these non-embedded fonts under current \LuaTeX\ has Identity-H encoding, +and this violates the standard ISO32000-1:2008~(\cite{pdfstd}). \emph{OpenType font features, such as ``{\tt +jp90}'', have no meaning in name-only fonts using ``{\tt psft:}''\ prefix, @@ -2830,8 +2894,10 @@ with \texttt{psft} prefix, because they are only simple linear transformations. \cs{jfont}(と \cs{font} プリミティブ)では \texttt{psft:}プリフィックスを用いることができる. このプリフィックスを用いることで,PDFには埋め込まれない「名前だけの」 -和文フォントを指定することができる.「標準的な」非埋め込み和文フォント, -つまり「Ryumin-Light」「GothicBBB-Medium」の指定でこのプリフィックスが使われる. +和文フォントを指定することができる. +なお,現行の\LuaTeX で非埋め込みフォントを作成するとPDF内でのエンコーディングが +Identity-Hとなり,PDFの標準規格ISO32000-1:2008~(\cite{pdfstd})に非準拠になってしまう +ので注意してほしい. \emph{\texttt{psft} プリフィックスの下では \texttt{+jp90} などのOpenType font featureの効力はない. @@ -7558,6 +7624,11 @@ Requirements for Japanese Text Layout (W3C Working Group Note), 2011, 2012. \new \\\null\hfill\texttt{.../texmf-dist/doc/ptex/base/ptexdoc.pdf} \bibitem{ptextug} Hisato Hamano. \newblock \textit{Vertical Typesetting with \TeX}, TUGBoat~\textbf{11}(3), 346--352, 1990. +\bibitem{pdfstd} International Organization for Standardization. \newblock +ISO 32000-1:2008, \textit{Document management -- Portable document format -- Part 1: PDF + 1.7}, 2008. \newblock +\\\null\hfill +\url{http://www.iso.org/iso/iso\_catalogue/catalogue_tc/catalogue\_detail.htm?csnumber=51502} \end{thebibliography} \newpage diff --git a/Master/texmf-dist/tex/luatex/luatexja/addons/luatexja-preset.sty b/Master/texmf-dist/tex/luatex/luatexja/addons/luatexja-preset.sty index 6f8ad23509a..3f6b4efc9f5 100644 --- a/Master/texmf-dist/tex/luatex/luatexja/addons/luatexja-preset.sty +++ b/Master/texmf-dist/tex/luatex/luatexja/addons/luatexja-preset.sty @@ -194,7 +194,7 @@ \bool_set_true:N \l_ltjpreset_noembed_bool } -\ExecuteOptions{noembed} +\ExecuteOptions{ipaex} \ProcessOptions* %% KozMinPr6N の場合はjp04 feature がないので,nlck にする diff --git a/Master/texmf-dist/tex/luatex/luatexja/ltj-adjust.lua b/Master/texmf-dist/tex/luatex/luatexja/ltj-adjust.lua index 6a5a300986e..729f186f37b 100644 --- a/Master/texmf-dist/tex/luatex/luatexja/ltj-adjust.lua +++ b/Master/texmf-dist/tex/luatex/luatexja/ltj-adjust.lua @@ -172,7 +172,8 @@ end -- step 1: 行末に kern を挿入(句読点,中点用) local function aw_step1(p, res, total) - local x = node_tail(getlist(p)); if not x then return false end + local head = getlist(p) + local x = node_tail(head); if not x then return false end -- x: \rightskip x = node_prev(x); if not x then return false end if getid(x) == id_glue and getsubtype(x) == 15 then diff --git a/Master/texmf-dist/tex/luatex/luatexja/ltj-jfmglue.lua b/Master/texmf-dist/tex/luatex/luatexja/ltj-jfmglue.lua index 9840da825bb..6b2fb95d4a5 100644 --- a/Master/texmf-dist/tex/luatex/luatexja/ltj-jfmglue.lua +++ b/Master/texmf-dist/tex/luatex/luatexja/ltj-jfmglue.lua @@ -105,7 +105,7 @@ local slow_find_char_class do slow_find_char_class = function (c, m, oc) local cls = ltjf_find_char_class(oc, m) - if not c and cls==0 then + if cls==0 then return ltjf_find_char_class(-c, m), oc else return cls, oc diff --git a/Master/texmf-dist/tex/luatex/luatexja/ltj-jfont.lua b/Master/texmf-dist/tex/luatex/luatexja/ltj-jfont.lua index 45bf490b1c5..ff0788d82bf 100644 --- a/Master/texmf-dist/tex/luatex/luatexja/ltj-jfont.lua +++ b/Master/texmf-dist/tex/luatex/luatexja/ltj-jfont.lua @@ -553,6 +553,7 @@ end ------------------------------------------------------------------------ local is_ucs_in_japanese_char = ltjc.is_ucs_in_japanese_char_direct +local font = font -- EXT: italic correction function append_italic() local p = to_direct(tex.nest[tex.nest.ptr].tail) @@ -566,7 +567,7 @@ function append_italic() local j = font_metric_table[f] setfield(g, 'kern', j.char_type[find_char_class(getchar(p), j)].italic) else - local h = font_getfont(f) + local h = font_getfont(f) or font.fonts[f] if h then setfield(g, 'kern', h.characters[getchar(p)].italic) else diff --git a/Master/texmf-dist/tex/luatex/luatexja/ltj-plain.sty b/Master/texmf-dist/tex/luatex/luatexja/ltj-plain.sty index c958ddd0b47..933d056bb59 100644 --- a/Master/texmf-dist/tex/luatex/luatexja/ltj-plain.sty +++ b/Master/texmf-dist/tex/luatex/luatexja/ltj-plain.sty @@ -14,7 +14,7 @@ \ifltj@in@latex %<*LaTeX> \NeedsTeXFormat{LaTeX2e} \PackageWarning{ltj-plain}{Don't load this package directly; load luatexja.sty instead.} - \ProvidesPackage{ltj-plain}[2013/06/12] + \ProvidesPackage{ltj-plain}[2014/09/19] \fi %</LaTeX> %%------------------ @@ -23,8 +23,8 @@ %! ↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓ % LuaTeX-ja macros against plain TeX -\def\ltj@stdmcfont{psft:Ryumin-Light} -\def\ltj@stdgtfont{psft:GothicBBB-Medium} +\def\ltj@stdmcfont{IPAExMincho} +\def\ltj@stdgtfont{IPAExGothic} \newread\ltj@@cfgread \openin\ltj@@cfgread{luatexja.cfg}% \ifeof\ltj@@cfgread diff --git a/Master/texmf-dist/tex/luatex/luatexja/ltj-pretreat.lua b/Master/texmf-dist/tex/luatex/luatexja/ltj-pretreat.lua index 14cec985159..5cdb1404ffd 100644 --- a/Master/texmf-dist/tex/luatex/luatexja/ltj-pretreat.lua +++ b/Master/texmf-dist/tex/luatex/luatexja/ltj-pretreat.lua @@ -42,6 +42,7 @@ local is_ucs_in_japanese_char = ltjc.is_ucs_in_japanese_char_direct local ltjf_replace_altfont = ltjf.replace_altfont local attr_orig_char = luatexbase.attributes['ltj@origchar'] local STCK = luatexja.userid_table.STCK +local lang_ja = token.create('ltj@japanese')[2] ------------------------------------------------------------------------ -- MAIN PROCESS STEP 1: replace fonts @@ -56,7 +57,8 @@ do local pc = getchar(p) local pf = ltjf_replace_altfont(has_attr(p, attr_curjfnt) or getfont(p), pc) setfield(p, 'font', pf); set_attr(p, attr_curjfnt, pf) - setfield(p, 'subtype', floor(getsubtype(p)*0.5)*2) + setfield(p, 'lang', lang_ja) + -- setfield(p, 'subtype', floor(getsubtype(p)*0.5)*2) set_attr(p, attr_orig_char, pc) end return p @@ -74,8 +76,7 @@ do wt, head = {}, p while p do local pfunc = suppress_hyphenate_ja_aux[getid(p)] - if pfunc then p = pfunc(p) end - p = node_next(p) + p = node_next(pfunc and pfunc(p) or p) end head = to_node(head) lang.hyphenate(head) diff --git a/Master/texmf-dist/tex/luatex/luatexja/ltj-stack.lua b/Master/texmf-dist/tex/luatex/luatexja/ltj-stack.lua index 2a90fd2c89f..81fd8519cd8 100644 --- a/Master/texmf-dist/tex/luatex/luatexja/ltj-stack.lua +++ b/Master/texmf-dist/tex/luatex/luatexja/ltj-stack.lua @@ -3,7 +3,7 @@ -- luatexbase.provides_module({ name = 'luatexja.stack', - date = '2014/01/24', + date = '2014/09/24', description = 'LuaTeX-ja stack system', }) module('luatexja.stack', package.seeall) @@ -37,8 +37,7 @@ function get_stack_level() charprop_stack_table[i] = table.fastcopy(charprop_stack_table[i-1]) tex.setcount('ltj@@stack', i) if gd~=0 then tex.globaldefs = gd end - if tex.nest[tex.nest.ptr].mode == hmode or - tex.nest[tex.nest.ptr].mode == -hmode then + if tex.nest[tex.nest.ptr].mode == -hmode then -- rest. hmode のみ local g = node_new(id_whatsit, sid_user) g.user_id=STCK; g.type=100; g.value=j; node.write(g) end @@ -46,21 +45,7 @@ function get_stack_level() return i end --- local function table_to_str(v) --- local s = '' --- for i, a in pairs(v) do --- s = s .. i .. "=" .. tostring(a) .. ', ' --- end --- return s --- end --- function print_stack_table(i) --- print('\n>>> get_stack_level:') --- for k, v in pairs(charprop_stack_table[i]) do --- print(" " , k, type(k), table_to_str(v)); --- end --- end - -function set_stack_table(m,p) +function set_stack_table(m, p) local i = get_stack_level() charprop_stack_table[i][m] = p if luatexja.isglobal=='global' then diff --git a/Master/texmf-dist/tex/luatex/luatexja/luatexja-core.sty b/Master/texmf-dist/tex/luatex/luatexja/luatexja-core.sty index b4fd007f79f..75b011c7882 100644 --- a/Master/texmf-dist/tex/luatex/luatexja/luatexja-core.sty +++ b/Master/texmf-dist/tex/luatex/luatexja/luatexja-core.sty @@ -143,6 +143,7 @@ \newluatexattribute\ltj@yablshift % attribute for \yabaselineshift \newluatexattribute\ltj@ykblshift % attribute for \ykbaselineshift \newluatexattribute\jfam % index for current jfam +\newlanguage\ltj@@japanese \ltj@icflag=0 \ltj@origchar=0 \ltj@charclass=0 diff --git a/Master/texmf-dist/tex/luatex/luatexja/patches/lltjdefs.sty b/Master/texmf-dist/tex/luatex/luatexja/patches/lltjdefs.sty index 9cd76430e11..4363948d8e4 100644 --- a/Master/texmf-dist/tex/luatex/luatexja/patches/lltjdefs.sty +++ b/Master/texmf-dist/tex/luatex/luatexja/patches/lltjdefs.sty @@ -3,10 +3,10 @@ % \NeedsTeXFormat{LaTeX2e} -\ProvidesPackage{lltjdefs}[2013/06/12 Default font settings of LuaTeX-ja] +\ProvidesPackage{lltjdefs}[2014/09/19 Default font settings of LuaTeX-ja] -\def\ltj@stdmcfont{psft:Ryumin-Light} -\def\ltj@stdgtfont{psft:GothicBBB-Medium} +\def\ltj@stdmcfont{IPAExMincho} +\def\ltj@stdgtfont{IPAExGothic} \InputIfFileExists{luatexja.cfg}{}{} \DeclareKanjiEncodingDefaults{}{} |