aboutsummaryrefslogtreecommitdiffstats
path: root/sources/pyside2/libpyside/pyside.h
diff options
context:
space:
mode:
authorAlexandru Croitor <alexandru.croitor@qt.io>2018-04-17 14:12:50 +0200
committerAlexandru Croitor <alexandru.croitor@qt.io>2018-04-20 13:48:40 +0000
commitf3e798c4572e308f6f520c6d966ae7f74fe835b7 (patch)
treebcf7cebcc9fb224d161ff491494294fd66c78ffe /sources/pyside2/libpyside/pyside.h
parent516682fc232db273511440d3c7107ab15f08b5ea (diff)
Improve qt.conf registration handling
When PyInstaller is used to deploy a PySide2 application, it changes the layout of the copied PySide2 files (no Qt subfolder, all shared libraries are copied next to tehe generated executable). In that case using the internal qt.conf won't work. Detect if there a exists a qt.conf file next to the executable, and use that file instead. Note that this won't work when the executable path has unicode characters in conjunction with Python 2 and Windows, but that is an unsupported config anyway (due to the mixing MSVC issue). Also add a logging category to ease figuring out which qt.conf file is used if a need ever arises to do so. Task-number: PYSIDE-642 Change-Id: I1260cbc13e5e62be72c4ed9c64c2aa5905d2e9c6 Reviewed-by: Cristian Maureira-Fredes <cristian.maureira-fredes@qt.io> Reviewed-by: Friedemann Kleint <Friedemann.Kleint@qt.io>
Diffstat (limited to 'sources/pyside2/libpyside/pyside.h')
-rw-r--r--sources/pyside2/libpyside/pyside.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/sources/pyside2/libpyside/pyside.h b/sources/pyside2/libpyside/pyside.h
index becb92208..d36965d7b 100644
--- a/sources/pyside2/libpyside/pyside.h
+++ b/sources/pyside2/libpyside/pyside.h
@@ -50,6 +50,7 @@
#include <QMetaType>
#include <QHash>
#include <QList>
+#include <QLoggingCategory>
struct SbkObjectType;
@@ -163,6 +164,8 @@ PYSIDE_API QString pyStringToQString(PyObject *str);
*/
PYSIDE_API bool registerInternalQtConf();
+Q_DECLARE_LOGGING_CATEGORY(lcPySide2)
+
} //namespace PySide