# the name of the day in English instead of Japanese.
export/examples/ja/multilingual_lyx.*
-# CJKutf8 uses $\mu$ for \textmu unless overwritten by textcomp.
-# libertine loads textcomp and is loaded before CJKutf8
-export/export/latex/CJK/micro-sign_utf8-cjk_libertine.*
-
# No localization of auto-strings with Chinese language:
export/export/latex/CJK/zh_CN-toc.*
\begin_layout Enumerate
Short texts may be written without setting the language (hyphenation will
be missing and spell-checking complain): Greetings; Grüße; Приветы; χαιρετισμός
-\lang greek
-
-\begin_inset Foot
-status open
-
-\begin_layout Plain Layout
-
-\lang english
-CJKutf8 (4.8.4) maps the Greek letter
-\lang greek
-μ
-\lang english
- to a mathematical (italic) symbol
-\begin_inset Formula $\mu$
-\end_inset
-
- unless the package
-\family typewriter
-textcomp
-\family default
- is loaded.
-\end_layout
-
-\end_inset
-
-
\end_layout
\begin_layout Enumerate
os << "\\usepackage{unicode-math}\n";
}
+ // load CJK support package before font selection
+ // (see autotests/export/latex/CJK/micro-sign_utf8-cjk-libertine.lyx)
+ if (!useNonTeXFonts && encoding().package() != Encoding::none
+ && (encoding().package() == Encoding::CJK || features.mustProvide("CJK"))) {
+ if (encoding().iconvName() == "UTF-8"
+ && LaTeXFeatures::isAvailable("CJKutf8"))
+ os << "\\usepackage{CJKutf8}\n";
+ else
+ os << "\\usepackage[encapsulated]{CJK}\n";
+ }
+
// font selection must be done before loading fontenc.sty
string const fonts = loadFonts(features);
if (!fonts.empty())
else
os << "]{inputenc}\n";
}
- if (package == Encoding::CJK || features.mustProvide("CJK")) {
- if (language->encoding()->name() == "utf8-cjk"
- && LaTeXFeatures::isAvailable("CJKutf8"))
- os << "\\usepackage{CJKutf8}\n";
- else
- os << "\\usepackage{CJK}\n";
- }
} else if (inputenc != "default") {
switch (encoding().package()) {
case Encoding::none:
+ case Encoding::CJK:
case Encoding::japanese:
break;
case Encoding::inputenc:
else
os << "]{inputenc}\n";
break;
- case Encoding::CJK:
- if (encoding().name() == "utf8-cjk"
- && LaTeXFeatures::isAvailable("CJKutf8"))
- os << "\\usepackage{CJKutf8}\n";
- else
- os << "\\usepackage{CJK}\n";
- break;
- }
- // Load the CJK package if needed by a secondary language.
- // If the main encoding is some variant of UTF8, use CJKutf8.
- if (encoding().package() != Encoding::CJK && features.mustProvide("CJK")) {
- if (language->encoding()->name() == "utf8-cjk"
- && LaTeXFeatures::isAvailable("CJKutf8"))
- os << "\\usepackage{CJKutf8}\n";
- else
- os << "\\usepackage{CJK}\n";
}
}
}