]> git.lyx.org Git - features.git/commitdiff
Fix import of latex documents with scaled fonts.
authorEnrico Forestieri <forenr@lyx.org>
Sun, 3 Aug 2014 16:42:04 +0000 (18:42 +0200)
committerEnrico Forestieri <forenr@lyx.org>
Sun, 3 Aug 2014 16:42:04 +0000 (18:42 +0200)
src/support/os_cygwin.cpp
src/support/os_unix.cpp
src/tex2lyx/Preamble.cpp
status.21x

index 4179d491c300b3a108418eb46485ab0520b59e33..e0c0bd17a04a0e45217d8e45f1f56b9b7729da65 100644 (file)
@@ -217,6 +217,7 @@ void init(int argc, char * argv[])
 
        // Set environment's default locale
        setlocale(LC_ALL, "");
+       setlocale(LC_NUMERIC, "C");
 
        // Make sure that the TEMP variable is set
        // and sync the Windows environment.
index 03dfb381c22480c03d08fcfaac692bb7154d4007..b298a7da85efd444e5640baa6a7dff9e82637d49 100644 (file)
@@ -49,6 +49,7 @@ void init(int argc, char * argv[])
 
        // Set environment's default locale
        setlocale(LC_ALL, "");
+       setlocale(LC_NUMERIC, "C");
 }
 
 
index 0676cad19b35eb3336f3946182a8819217097565..c87b766d083a9d52458cfa677644d41d0b3d4d14 100644 (file)
@@ -424,7 +424,8 @@ bool scale_as_percentage(string const & scale, string & percentage)
        if (pos != string::npos) {
                string value = scale.substr(pos + 1);
                if (isStrDbl(value)) {
-                       percentage = convert<string>(100 * convert<double>(value));
+                       percentage = convert<string>(
+                               static_cast<int>(100 * convert<double>(value)));
                        return true;
                }
        }
index d58771c1bfc33fb8138acc3acf5f16825685e25d..7997e0f26a573902cbb5d84037967053942f2fe3 100644 (file)
@@ -57,6 +57,8 @@ What's new
 - Fix wrong line spacing in last paragraph of a document if the font size
   is non-normal (bug 9231).
 
+- Fix import of latex documents with scaled fonts.
+
 
 
 * LYX2LYX