Linux specific Qt5 port

This commit is contained in:
wmayer
2016-12-13 19:47:32 +01:00
parent 743b83e853
commit 11ffc5bca9
4 changed files with 63 additions and 5 deletions

View File

@@ -91,11 +91,13 @@ int main( int argc, char ** argv )
// Make sure to setup the Qt locale system before setting LANG and LC_ALL to C.
// which is needed to use the system locale settings.
(void)QLocale::system();
#if QT_VERSION < 0x050000
// http://www.freecadweb.org/tracker/view.php?id=399
// Because of setting LANG=C the Qt automagic to use the correct encoding
// for file names is broken. This is a workaround to force the use of UTF-8 encoding
QFile::setEncodingFunction(myEncoderFunc);
QFile::setDecodingFunction(myDecoderFunc);
#endif
// Make sure that we use '.' as decimal point. See also
// http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=559846
putenv("LC_NUMERIC=C");