6 %% Avoid multiple loading.
7 \csname luatexjalatexLoaded\endcsname
8 \edef\ltj@latex@AtEnd{%
9 \endlinechar=\the\endlinechar
12 \def\luatexjalatexLoaded{\endinput}
14 \NeedsTeXFormat{LaTeX2e}
15 \ProvidesPackage{luatexja-latex}[2011/11/22 LuaLaTeX-ja]
17 \def\ltj@pkgpatchlist{}
19 \@ifpackageloaded{#1}{\usepackage{lltjp-#1}}{
20 \@ifpackageloaded{filehook}{\AtEndOfPackageFile*{#1}{\usepackage{lltjp-#1}}}{}
22 \ifx\ltj@pkgpatchlist\@empty
23 \gdef\ltj@pkgpatchlist{#1}
25 \xdef\ltj@pkgpatchlist{\ltj@pkgpatchlist, #1}
29 % similar to \ltj@pkgpatch, but this is used .sty which
30 % can be reloaded inside the document by \input.
32 \@ifpackageloaded{#1}{\input{lltjp-#1.sty}}{
33 \@ifpackageloaded{filehook}{\AtEndOfFile{#1.sty}{\input{lltjp-#1.sty}}}{}
35 \ifx\ltj@pkgpatchlist\@empty
36 \gdef\ltj@pkgpatchlist{#1}
38 \xdef\ltj@pkgpatchlist{\ltj@pkgpatchlist, #1}
49 %%% default parameters
50 \ltjsetparameter{kanjiskip=0pt plus 0.4pt minus 0.4pt,
51 xkanjiskip=.25\zw plus 1pt minus 1pt,
52 autospacing, autoxspacing, jacharrange={-1},
53 yalbaselineshift=0pt, yjabaselineshift=0pt,
54 jcharwidowpenalty=500, differentjfm=average
57 \input luatexja-kinsoku.tex
58 \expandafter\let\csname JY3/mc/m/n/10\endcsname\relax
60 %%% patch for packages
61 \IfFileExists{filehook.sty}{\usepackage{filehook}}{}
62 \ltj@pkgpatch{listings}
63 \ltj@pkgpatch{unicode-math}
64 \ltj@pkgpatch{xunicode}
65 \@ifpackageloaded{filehook}{}{%
66 \@PackageWarningNoLine{luatexja-latex}{
67 LuaTeX-ja uses filehook package to apply patches to the following packages:\MessageBreak
68 \ltj@pkgpatchlist.\MessageBreak
69 But your TeX system does not have the filehook package.\MessageBreak
70 Therefore problems may occur if you load the above packages after this message}%
73 %%------------------ all done