Comments (6)
If you use a similar method as the one I present in #40 , you have to link to two libraries: PythonQt
and PythonQt_QtAll
.
from pythonqt.
Hi,
thanks for the suggestion, but unfortunately your fork doesn't work with qt5.
Any plans to support it?
from pythonqt.
I won't make it compliant with Qt5 in a near future but the changes I made are independent of Qt so you can apply the same changes to a Qt5 compatible version of PythonQt.
From the error message, I would say you lack one (at least) of the following:
- a file similar to
extensions/CMakeLists.txt
of my fork in your PythonQt source directory, - a
TARGET_LINK_LIBRARY(yourcpp PythonQt_QtAll)
in the project that depends on PythonQt.
from pythonqt.
your fork doesn't work with qt5.
Support for Qt5 has been integrated in commontk/PythonQt. Using the fork shouldn't be needed
re: #40
Would make sense to integrate.
@iltommi or @jmirabel Would you mind rebasing the PR against the current patched-6
branch ?
Thanks
Jc
from pythonqt.
Hello @jcfr, and thanks for the help.
I switched to #patched-6 branch and it compiles after removing WebKitWidgets
and webkit
from
set(qt5libs Core Widgets Network OpenGL Sql Svg UiTools WebKitWidgets Xml XmlPatterns)
^^^^^^^^^^^^^
set(qt4libs core gui network opengl sql svg uitools webkit xml xmlpatterns)
^^^^^^
and comment this line:
# set(qtlib_to_wraplib_WebKitWidgets webkit)
Since they are no more shipped starting with 5.6 (or at least I don't have with the homebrew installation on mac). I'm not that confident in cmake to create a switch over something like if(${found_qt_version} VERSION_LESS [....]
, but It would be nice to have that fixed.
Now coming to my problem I think I have found a solution:
To use all the wrapped qt (which in the qmake version on sourceforge come in a separate library libPythonQt_QtAll.dylib
)
I #include "PythonQt_QtBindings.h"
and call PythonQt_init_QtBindings();
Is this correct?
With the qmake version, I used to link libPythonQt_QtAll.dylib
the included #include <PythonQt_QtAll.h>
and call PythonQt_QtAll::init();
Thanks again!
p.s.
As side note I added this line (which seems missing):
install(FILES src/gui/PythonQtScriptingConsole.h DESTINATION ${PythonQt_INSTALL_INCLUDE_DIR}/gui)
Would it be possible to include it in the next commit?
from pythonqt.
Closing. Support for Qt5 is now up-to-date and available in patched-8
branch
from pythonqt.
Related Issues (20)
- Update CMake to handle extensions and install PythonQtScriptingConsole.h HOT 1
- Qt 5.6 support HOT 4
- QSound belongs to QtMultimedia not QtGui
- matplotlib.pyplot.ion() does not work very well HOT 3
- Problem with Paraview compling
- Update plan? HOT 3
- patched-8 missing Qt private includes HOT 1
- How to deal with multiple py files? HOT 1
- PythonQt_DEBUG=ON generates error, anyone know what I am doing wrong? Ubuntu 17.04 HOT 1
- qt4.8.6 with patched-7 HOT 2
- cross compile with mingw HOT 3
- fatal error: 'private/qmetaobjectbuilder_p.h' on Mac HOT 8
- Support for Python global interpreter lock HOT 2
- Crash if delegate subclass implements displayText HOT 6
- fatal error: private/qmetaobjectbuilder_p.h: No such file or directory for ubuntu 16.04 HOT 3
- Cannot find external simbol: QBasicMutex::QBasicMutex(void) HOT 1
- Error with python 3.7 : Require native threads HOT 1
- How to build PythonQt with PythonQtConfig.cmake?
- State of cmake files HOT 14
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from pythonqt.