mirror of
https://git.lyx.org/repos/lyx.git
synced 2024-11-25 19:07:45 +00:00
parent
e887bbc544
commit
878efbaf62
@ -120,6 +120,20 @@
|
|||||||
#6
|
#6
|
||||||
\fi}
|
\fi}
|
||||||
|
|
||||||
|
% Test for the LaTeX version
|
||||||
|
\newcommand{\TestLaTeXVersion}[1]{
|
||||||
|
\message{^^J\prefix checking for LaTeX version at least as of #1...}
|
||||||
|
\@ifl@t@r\fmtversion{#1}{\existstrue}{\existsfalse}
|
||||||
|
\ifexists
|
||||||
|
\message{yes^^J}
|
||||||
|
\AddVariable{#1}{yes}
|
||||||
|
\AddPackage{LaTeX-#1}
|
||||||
|
\else
|
||||||
|
\message{no^^J}
|
||||||
|
\AddVariable{#1}{no}
|
||||||
|
\fi}
|
||||||
|
|
||||||
|
|
||||||
% Adapted from ltxcheck.tex
|
% Adapted from ltxcheck.tex
|
||||||
\newcommand{\TestFont}[2][\default]{
|
\newcommand{\TestFont}[2][\default]{
|
||||||
\def\default{#2}
|
\def\default{#2}
|
||||||
@ -204,6 +218,10 @@
|
|||||||
\message{^^J\prefix checking for LaTeX version... \fmtversion}
|
\message{^^J\prefix checking for LaTeX version... \fmtversion}
|
||||||
\AddVariable{fmtversion}{\fmtversion}
|
\AddVariable{fmtversion}{\fmtversion}
|
||||||
|
|
||||||
|
%%% Crucial versions
|
||||||
|
% This one introduces path encoding changes
|
||||||
|
\TestLaTeXVersion{2019/10/01}
|
||||||
|
|
||||||
%%% And now, the list of available languages
|
%%% And now, the list of available languages
|
||||||
% The trick is to know that \the\everyjob contains something like
|
% The trick is to know that \the\everyjob contains something like
|
||||||
% \typeout{LaTeX2e <2001/06/01>}
|
% \typeout{LaTeX2e <2001/06/01>}
|
||||||
|
@ -1911,9 +1911,14 @@ void Buffer::writeLaTeXSource(otexstream & os,
|
|||||||
os << "\\catcode`\\%=11"
|
os << "\\catcode`\\%=11"
|
||||||
"\\def\\%{%}\\catcode`\\%=14\n";
|
"\\def\\%{%}\\catcode`\\%=14\n";
|
||||||
}
|
}
|
||||||
bool const detokenize = !isAscii(from_utf8(docdir))
|
bool const nonascii = !isAscii(from_utf8(docdir));
|
||||||
|| contains(docdir, '~');
|
// LaTeX 2019/10/01 handles non-ascii path without detokenize
|
||||||
|
bool const utfpathlatex = features.isAvailable("LaTeX-2019/10/01");
|
||||||
|
bool const detokenize = !utfpathlatex
|
||||||
|
&& (nonascii || contains(docdir, '~'));
|
||||||
bool const quote = contains(docdir, ' ');
|
bool const quote = contains(docdir, ' ');
|
||||||
|
if (utfpathlatex && nonascii)
|
||||||
|
os << "\\UseRawInputEncoding\n";
|
||||||
os << "\\makeatletter\n"
|
os << "\\makeatletter\n"
|
||||||
<< "\\def\\input@path{{";
|
<< "\\def\\input@path{{";
|
||||||
if (detokenize)
|
if (detokenize)
|
||||||
|
@ -41,6 +41,9 @@ What's new
|
|||||||
|
|
||||||
* DOCUMENT INPUT/OUTPUT
|
* DOCUMENT INPUT/OUTPUT
|
||||||
|
|
||||||
|
- Fix problems with non-ASCII characters in file path with recent LaTeX
|
||||||
|
(bug 11146).
|
||||||
|
|
||||||
|
|
||||||
* USER INTERFACE
|
* USER INTERFACE
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user