]> git.lyx.org Git - features.git/commitdiff
Patch from "hzluo" <memcache@gmail.com>:
authorJean-Marc Lasgouttes <lasgouttes@lyx.org>
Thu, 10 May 2007 10:35:57 +0000 (10:35 +0000)
committerJean-Marc Lasgouttes <lasgouttes@lyx.org>
Thu, 10 May 2007 10:35:57 +0000 (10:35 +0000)
Remove all explicit 8bit characters from the source, to fix compilation
with windows xp under a chinese locale (bug 3496).

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@18256 a592a061-630c-0410-9148-cb99ea01b6c8

src/Counters.cpp
src/Font.cpp
src/support/environment.h
src/tex2lyx/math.cpp
src/tex2lyx/text.cpp

index 20654b7e8e5340830387be39aec386a2a915325b..61a4a239c842faf3910af315601f9c3f92fbe8ea 100644 (file)
@@ -231,9 +231,9 @@ char alphaCounter(int const n)
 char hebrewCounter(int const n)
 {
        static const char hebrew[22] = {
-               'à', 'á', 'â', 'ã', 'ä', 'å', 'æ', 'ç', 'è',
-               'é', 'ë', 'ì', 'î', 'ð', 'ñ', 'ò', 'ô', 'ö',
-               '÷', 'ø', 'ù', 'ú'
+               '\xe0', '\xe1', '\xe2', '\xe3', '\xe4', '\xe5', '\xe6', '\xe7', '\xe8',
+               '\xe9', '\xeb', '\xec', '\xee', '\xf0', '\xf1', '\xf2', '\xf4', '\xf6',
+               '\xf7', '\xf8', '\xf9', '\xfa'
        };
 
        if (n < 1 || n > 22)
index ccbc937e797573360c7d62f41bd81295cc7ba8ef..ccaa923caba7adfbcc9c51f80194c690e51f52d0 100644 (file)
@@ -674,7 +674,7 @@ Font & Font::lyxRead(Lexer & lex)
                        } else if (ttok == "noun") {
                                setNoun(ON);
                        } else {
-                               lex.printError("Illegal misc type `$$Token´");
+                               lex.printError("Illegal misc type `$$Token'");
                        }
                } else if (tok == "color") {
                        lex.next();
index d312bffe632afe26d3565c824d738cbe05642fb5..296ebc15fbd09d7dfb3416a7755296d4bc9ab51f 100644 (file)
@@ -28,7 +28,7 @@ std::string const getEnv(std::string const & envname);
  *  guarantee that it is in the form of a unix-style path.
  *  If the environment variable is not set, then the function returns
  *  an empty vector.
- */
+ */
 std::vector<std::string> const getEnvPath(std::string const & name);
 
 /** Set the contents of the environment variable @c name to @c value.
index c2af18f0095ec17d0a30a81e525b1a576c43f536..30af6a6cb2a42764e2af7c0b5dbd3878690e8d2f 100644 (file)
@@ -207,17 +207,17 @@ void parse_math(Parser & p, ostream & os, unsigned flags, const mode_type mode)
 
                else if (t.cs() == "\"") {
                        string const name = p.verbatim_item();
-                            if (name == "a") os << 'ä';
-                       else if (name == "o") os << 'ö';
-                       else if (name == "u") os << 'ü';
-                       else if (name == "A") os << 'Ä';
-                       else if (name == "O") os << 'Ö';
-                       else if (name == "U") os << 'Ü';
+                            if (name == "a") os << '\xe4';
+                       else if (name == "o") os << '\xf6';
+                       else if (name == "u") os << '\xfc';
+                       else if (name == "A") os << '\xc4';
+                       else if (name == "O") os << '\xd6';
+                       else if (name == "U") os << '\xdc';
                        else os << "\"{" << name << "}";
                }
 
                else if (t.cs() == "ss")
-                       os << "ß";
+                       os << "\xdf";
 
                else if (t.cs() == "cr") {
                        // lyx can't handle \\cr
index 7ca211e3f5ef7d3a717bee68344e5658eac79504..a013208f57f14c97a424a2014ac36fbef6ad5cce 100644 (file)
@@ -3,7 +3,7 @@
  * This file is part of LyX, the document processor.
  * Licence details can be found in the file COPYING.
  *
- * \author André Pönitz
+ * \author André Pönitz
  * \author Jean-Marc Lasgouttes
  *
  * Full author contact details are available in file CREDITS.
@@ -1647,7 +1647,7 @@ void parse_text(Parser & p, ostream & os, unsigned flags, bool outer,
                        p.skip_spaces();
                        context.check_layout(os);
                        string const s = p.verbatim_item();
-                       if (s == "±" || s == "³" || s == "²" || s == "µ")
+                       if (s == "\xb1" || s == "\xb3" || s == "\xb2" || s == "\xb5")
                                os << s;
                        else
                                handle_ert(os, "\\ensuremath{" + s + "}",
@@ -2081,12 +2081,12 @@ void parse_text(Parser & p, ostream & os, unsigned flags, bool outer,
                else if (t.cs() == "\"") {
                        context.check_layout(os);
                        string const name = p.verbatim_item();
-                            if (name == "a") os << 'ä';
-                       else if (name == "o") os << 'ö';
-                       else if (name == "u") os << 'ü';
-                       else if (name == "A") os << 'Ä';
-                       else if (name == "O") os << 'Ö';
-                       else if (name == "U") os << 'Ü';
+                            if (name == "a") os << '\xe4';
+                       else if (name == "o") os << '\xf6';
+                       else if (name == "u") os << '\xfc';
+                       else if (name == "A") os << '\xc4';
+                       else if (name == "O") os << '\xd6';
+                       else if (name == "U") os << '\xdc';
                        else handle_ert(os, "\"{" + name + "}", context);
                }
 
@@ -2104,7 +2104,7 @@ void parse_text(Parser & p, ostream & os, unsigned flags, bool outer,
                        // subset of LaTeX, so don't parse anything here,
                        // but use the raw argument.
                        // Otherwise we would convert \~{\i} wrongly.
-                       // This will of course not translate \~{\ss} to \~{ß},
+                       // This will of course not translate \~{\ss} to \~{ß},
                        // but that does at least compile and does only look
                        // strange on screen.
                        context.check_layout(os);
@@ -2115,7 +2115,7 @@ void parse_text(Parser & p, ostream & os, unsigned flags, bool outer,
 
                else if (t.cs() == "ss") {
                        context.check_layout(os);
-                       os << "ß";
+                       os << "\xdf";
                        skip_braces(p); // eat {}
                }