qtwidgets

improper scaling of Qt Desktop application in windows 10

为君一笑 提交于 2019-12-21 12:13:49
问题 I'm writing a simple Qt (Widgets) Gui application for windows 10. I'm using the 5.6.0 beta version of Qt. The problem I'm having is that it isn't scaling right to the screen of my surfacebook at all: It's a bit hard to tell because SO scales the image, but notice how small the dock widget title bar controls are relative to the window title bar controls. This link from Qt talks about scaling, but it's mostly focuses on qml/qtQuick and mobile applications in general, and additionally seems to

Qt 5.3. QtWidgets: No such file or directory #include <QtWidgets>

落爺英雄遲暮 提交于 2019-12-21 12:07:22
问题 I want to compile Qt example. I get error QtWidgets: No such file or directory #include greaterThan(QT_MAJOR_VERSION, 4): QT += widgets - does not help QT += widgets - does not help INCLUDEPATH += /opt/Qt/5.3/Src/qtbase/include/ - does not help Qt 5.3. Ubuntu 14.04 x64. 回答1: You need to double check that you completed all these steps: Module installed greaterThan(QT_MAJOR_VERSION, 4): QT += widgets You re-run the Qt 5 qmake. Having said that, I would like to remind you that including the

Virtual keyboard or onscreen keyboard for QtWidgets applications?

戏子无情 提交于 2019-12-13 04:26:58
问题 I'm going to deploy the qtvirtualkeyboard in my widget-based application like so: #include <QtWidgets> int main(int argc, char *argv[]) { qputenv("QT_IM_MODULE", QByteArray("qtvirtualkeyboard")); QApplication app(argc, argv); QMainWindow window; QLineEdit input(&window); input.move(250, 250); window.show(); return app.exec(); } But the only issue is that the virtual keyboard input panel hides the underlying widgets and cover them! How should I achieve this? Is there any document or solution

How to dock a QDockWidgets inside a QSplitter?

元气小坏坏 提交于 2019-12-11 15:28:36
问题 I am trying to have a QSplitter accept QDockWidgets in my application. So far, I have done everything through the Qt Designer and what I have done is create three individual QWidgets. I then select all three of the QWidgets and I right click on them and select Layout->Lay out Vertically in a Splitter. This lays all three of the widgets in a splitter quite nicely. I then drag a Dock Widget to the Object/Class Window in the top right and set them in the Splitters Widget. This places the

“Module use of python34.dll conflicts with this version of Python”

做~自己de王妃 提交于 2019-12-11 02:05:10
问题 My knowledge of Python is still pretty basic, and I am only now trying to wrap my head around how to use / call libraries from within Maya. (Because I need to create a basic UI from QT Designer and have it be opened in Maya after converting it to a .py file) After I learned to properly convert a .ui to a .py, I now get this error in Maya "Module use of python34.dll conflicts with this version of Python" I tried following what was said here and here, but even then - after setting these

qmake does not add widgets

你说的曾经没有我的故事 提交于 2019-12-10 20:17:23
问题 i have a simple program. my program is: #include <QApplication> #include <QLabel> int main(int argc, char *argv[]) { int rc ; QApplication app(argc, argv); QLabel *label = new QLabel("Hello Qt!"); label->show(); rc = app.exec(); return(rc) ; } i want to compile and build this code in command line. i have installed qt and mingw. first my command is: qmake -project then i give this command. qmake then qmake creates .pro file which is: TEMPLATE = app TARGET = HELLO INCLUDEPATH += . # Input

PyQt5 - Error import QtWidgets QtGui

不羁岁月 提交于 2019-12-10 10:57:20
问题 I'm running Ubuntu 13.10 (python-3.3.2+) . I've installed Qt5.2.1 (linux installer) , SIP 4.15.5 & PyQt5 both from source of the official site. PyQt5 build : The Qt qmake is located here jeby6372@mercure:~$ ls /opt/Qt/5.2.1/gcc_64/bin assistant qdbus qml1plugindump qmlviewer designer qdbuscpp2xml qml2puppet qtpaths lconvert qdbusviewer qmlbundle rcc linguist qdbusxml2cpp qmlimportscanner syncqt.pl lrelease qdoc qmlmin uic lupdate qhelpconverter qmlplugindump xmlpatterns moc qhelpgenerator

qt-updating ui by thread

空扰寡人 提交于 2019-12-09 01:06:59
问题 hi I have a problem with updating ui by a thread. code works correctly but the problem is when I want to move my window as you know in that moment ui thread will stop updating. and my thread sends values to stopped thread that causes error. I don't know how to fix this. here is my thread code header: #ifndef READERTHREAD_H #define READERTHREAD_H #include <QtSerialPort/QSerialPort> #include <QtSerialPort/QSerialPortInfo> #include <QThread> class readerThread : public QThread { Q_OBJECT public:

Qt 5.3. QtWidgets: No such file or directory #include <QtWidgets>

╄→尐↘猪︶ㄣ 提交于 2019-12-04 05:52:21
I want to compile Qt example. I get error QtWidgets: No such file or directory #include greaterThan(QT_MAJOR_VERSION, 4): QT += widgets - does not help QT += widgets - does not help INCLUDEPATH += /opt/Qt/5.3/Src/qtbase/include/ - does not help Qt 5.3. Ubuntu 14.04 x64. You need to double check that you completed all these steps: Module installed greaterThan(QT_MAJOR_VERSION, 4): QT += widgets You re-run the Qt 5 qmake. Having said that, I would like to remind you that including the whole module is not a good idea as it includes all the widgets related things. Try to narrow it down to the

improper scaling of Qt Desktop application in windows 10

被刻印的时光 ゝ 提交于 2019-12-04 05:00:02
I'm writing a simple Qt (Widgets) Gui application for windows 10. I'm using the 5.6.0 beta version of Qt. The problem I'm having is that it isn't scaling right to the screen of my surfacebook at all: It's a bit hard to tell because SO scales the image, but notice how small the dock widget title bar controls are relative to the window title bar controls. This link from Qt talks about scaling, but it's mostly focuses on qml/qtQuick and mobile applications in general, and additionally seems to imply that in a desktop QtWidgets application, QPainter will automatically determine the proper scaling,