]> git.lyx.org Git - features.git/commitdiff
Fix issues with tilde in inputpath
authorJuergen Spitzmueller <spitz@lyx.org>
Wed, 20 Nov 2019 10:57:32 +0000 (11:57 +0100)
committerJuergen Spitzmueller <spitz@lyx.org>
Mon, 27 Jan 2020 07:32:11 +0000 (08:32 +0100)
Fixes #11699

(cherry picked from commit a426b33067ae4e9d5452f13284f3e223d87ac45d)

src/Buffer.cpp
status.23x

index 912baec403b239a938c4c6e2fe9533fada78c26a..92c3d5d9c7f998e58d84607e737318563aa565ea 100644 (file)
@@ -1911,11 +1911,12 @@ void Buffer::writeLaTeXSource(otexstream & os,
                                        os << "\\catcode`\\%=11"
                                              "\\def\\%{%}\\catcode`\\%=14\n";
                                }
+                               if (contains(docdir, '~'))
+                                       docdir = subst(docdir, "~", "\\string~");
                                bool const nonascii = !isAscii(from_utf8(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 detokenize = !utfpathlatex && nonascii;
                                bool const quote = contains(docdir, ' ');
                                if (utfpathlatex && nonascii)
                                        os << "\\UseRawInputEncoding\n";
index 5cb8a2b4e4232e04011ba2cdd828f05ca8098826..6780f0332fe4d2cb59ad9d0c1476efdad518c690 100644 (file)
@@ -44,6 +44,9 @@ What's new
 - Fix problems with non-ASCII characters in file path with recent LaTeX
   (bug 11146).
 
+- Fix problems with recent LaTeX when \input@path contains tilde and space
+  (bug 11699).
+
 
 * USER INTERFACE