]> git.lyx.org Git - lyx.git/commitdiff
Omit escape-chars in pass_thru context
authorJuergen Spitzmueller <spitz@lyx.org>
Mon, 12 Aug 2024 12:28:59 +0000 (14:28 +0200)
committerJuergen Spitzmueller <spitz@lyx.org>
Mon, 12 Aug 2024 12:28:59 +0000 (14:28 +0200)
src/Paragraph.cpp

index e485c1a852da159ef1cee875b64e4e349c884b70..eb94ac2f09873b681ecef2a8ec02715520f0ac49 100644 (file)
@@ -1253,12 +1253,14 @@ void Paragraph::Private::latexSpecialChar(otexstream & os,
                return;
        }
 
-       if (!style.escape_chars.empty() && contains(style.escape_chars.substr(1), c)){
+       if (!style.pass_thru && !runparams.pass_thru && !style.escape_chars.empty()
+           && contains(style.escape_chars.substr(1), c)){
                os << style.escape_chars.substr(0,1);
                os.put(c);
                return;
        }
-       if (!runparams.escape_chars.empty() && contains(runparams.escape_chars.substr(1), c)){
+       if (!style.pass_thru && !runparams.pass_thru && !runparams.escape_chars.empty()
+           && contains(runparams.escape_chars.substr(1), c)){
                os << runparams.escape_chars.substr(0,1);
                os.put(c);
                return;