]> git.lyx.org Git - lyx.git/commitdiff
texlyx: re-privatize a variable as suggested
authorUwe Stöhr <uwestoehr@lyx.org>
Wed, 27 Jun 2012 20:32:36 +0000 (22:32 +0200)
committerUwe Stöhr <uwestoehr@lyx.org>
Wed, 27 Jun 2012 20:32:36 +0000 (22:32 +0200)
src/tex2lyx/Parser.h
src/tex2lyx/text.cpp

index 3cf3dbde83df0d2635668833787077e434c2574e..c0c5685bb83fc449cf2567c39f00206b38fb3629 100644 (file)
@@ -251,8 +251,6 @@ public:
        void setCatCode(char c, CatCode cat);
        ///
        CatCode getCatCode(char c) const;
-       /// latex name of the current encoding
-       std::string encoding_latex_;
 
 private:
        ///
@@ -267,6 +265,8 @@ private:
        idocstringstream * iss_;
        ///
        idocstream & is_;
+       /// latex name of the current encoding
+       std::string encoding_latex_;
 };
 
 
index 2962cffcbf6078bc69703d5774984f5207247d18..f46789c8ca31b471c9b6d4b8fdc050b7b3456bee 100644 (file)
@@ -1461,7 +1461,7 @@ void parse_environment(Parser & p, ostream & os, bool outer,
                eat_whitespace(p, os, parent_context, false);
                parent_context.check_end_layout(os);
                // store the encoding to be able to reset it
-               string const encoding_old = p.encoding_latex_;
+               string const encoding_old = p.getEncoding();
                string const encoding = p.getArg('{', '}');
                // SJIS and BIG5 don't work with LaTeX according to the comment in unicode.cpp
                // JIS does not work with LyX's encoding conversion
@@ -1500,7 +1500,7 @@ void parse_environment(Parser & p, ostream & os, bool outer,
                        parent_context.font.language = lang_old;
                        parent_context.new_paragraph(os);
                }
-               p.encoding_latex_ = encoding_old;
+               p.getEncoding() = encoding_old;
                p.skip_spaces();
        }