Merge topic 'unicode-cmake-gui'
649789a7
Unicode: cmake-gui encoding now matches KWSys encoding.
This commit is contained in:
commit
85ffb02919
|
@ -55,6 +55,11 @@ else()
|
|||
endif()
|
||||
endif()
|
||||
|
||||
|
||||
if(WIN32 AND KWSYS_ENCODING_DEFAULT_CODEPAGE MATCHES CP_UTF8)
|
||||
add_definitions(-DKWSYS_CP_UTF8)
|
||||
endif()
|
||||
|
||||
set(SRCS
|
||||
AddCacheEntry.cxx
|
||||
AddCacheEntry.h
|
||||
|
|
|
@ -14,6 +14,7 @@
|
|||
#include <QDir>
|
||||
#include <QTranslator>
|
||||
#include <QLocale>
|
||||
#include <QTextCodec>
|
||||
#include "QMacInstallDialog.h"
|
||||
#include "CMakeSetupDialog.h"
|
||||
#include "cmDocumentation.h"
|
||||
|
@ -78,6 +79,13 @@ int main(int argc, char** argv)
|
|||
|
||||
QApplication app(argc, argv);
|
||||
|
||||
#if defined(KWSYS_CP_UTF8)
|
||||
QTextCodec* utf8_codec = QTextCodec::codecForName("UTF-8");
|
||||
QTextCodec::setCodecForCStrings(utf8_codec);
|
||||
QTextCodec::setCodecForLocale(utf8_codec);
|
||||
QTextCodec::setCodecForTr(utf8_codec);
|
||||
#endif
|
||||
|
||||
// clean out standard Qt paths for plugins, which we don't use anyway
|
||||
// when creating Mac bundles, it potentially causes problems
|
||||
foreach(QString p, QApplication::libraryPaths())
|
||||
|
|
Loading…
Reference in New Issue