]> git.lyx.org Git - lyx.git/blobdiff - src/Paragraph.cpp
* sk.po
[lyx.git] / src / Paragraph.cpp
index 0df5e364321dda2f2f0459f6d13455369077244c..9f3fb5ec982f4b71e6a4dc6533a05c8081cb4663 100644 (file)
@@ -1156,10 +1156,12 @@ void Paragraph::Private::latexSpecialChar(otexstream & os,
        char_type const c = text_[i];
 
        if (style.pass_thru || runparams.pass_thru) {
-               if (c != '\0')
-                       // FIXME UNICODE: This can fail if c cannot
-                       // be encoded in the current encoding.
+               if (c != '\0') {
+                       Encoding const * const enc = runparams.encoding;
+                       if (enc && enc->latexChar(c, true).empty())
+                               throw EncodingException(c);
                        os.put(c);
+               }
                return;
        }