\def\luatexjalatexLoaded{\endinput}
\NeedsTeXFormat{LaTeX2e}
-\ProvidesPackage{ltj-latex}[2012/04/21 LuaLaTeX-ja]
+\ProvidesPackage{ltj-latex}[2013/05/14 LaTeX support of LuaTeX-ja]
+
+% I (HK) don't know why the code below is not necessary.
+%\let\ltj@@orig@end=\@@end
+%\outer\protected\def\@@end{%
+% \directlua{luatexja.direction.remove_end_whatsit()}\ltj@@orig@end}
% Globally add to the head of a macro (cf. LaTeX2e's \g@addto@macro)
\long\def\ltj@g@addto@macro#1#2{
\usepackage{lltjcore}
%%% default parameters
+\directlua{
+ local s = kpse.find_file('ltj-kinsoku.lua', 'tex')
+ luatexja.stack.charprop_stack_table[0] = s and dofile(s) or {}
+}
+
\ltjsetparameter{kanjiskip=0pt plus 0.4pt minus 0.4pt,
xkanjiskip=.25\zw plus 1pt minus 1pt,
autospacing, autoxspacing, jacharrange={-1},
yalbaselineshift=0pt, yjabaselineshift=0pt,
- jcharwidowpenalty=500, differentjfm=average
+ jcharwidowpenalty=500, differentjfm=paverage
}
-\input luatexja-kinsoku.tex
\expandafter\let\csname JY3/mc/m/n/10\endcsname\relax
%%% patch for packages
\ltj@pkgpatch{listings}
\ltj@pkgpatch{unicode-math}
\ltj@pkgpatch{xunicode}
+\ltj@pkgpatch{fontspec}
%%------------------ all done