Issue loading UI with a fresh template
-
Greetings!
I'm a beginner both in Python and Qt, but I have some programming experienceSo here's the issue and how to replicate it:
- Start a project using this template: "Qt for Python - Window (UI file)"
- Select "QMainWindow" as base class
- Add any object into the UI through qt designer
- Save and run the program
and all I see is an empty window, and the terminal does not show any error related to the UI
Please notice that I didn't touch any of the automatically generated codeHere's what the terminal says:
17:23:03: Starting /usr/bin/python -u /home/enf/Projects/HealthCalcs/main.py...
(now i close the window)
17:23:11: /usr/bin/python exited with code 0This problem does not occur if I use "QWidget" as a base class
I also happen to have this problem
"Qt WebEngine seems to be initialized from a plugin. Please set Qt::AA_ShareOpenGLContexts using CoreApplication::setAttribute before constructing QGuiApplication."which I solved by pasting this line of code in my main function
QtCore.QCoreApplication.setAttribute(QtCore.Qt.AA_ShareOpenGLContexts)Am I doing something wrong?
Here's some extra information that might be useful:
- OS Linux Manjaro KDE x64
- qt-creator 4.12.4-1
- Python 3.8.3