qt5.6

QSqlDatabase open always returns true after update

人走茶凉 提交于 2019-12-02 04:41:46
After updating Qt from 5.5 to 5.6 QSqlDatabase:open always returns true - even if the host is not reachable and/or username/password/database settings are set to nonsense. Test code: QSqlDatabase* db = new QSqlDatabase(QSqlDatabase::addDatabase("QMYSQL", "TESTCONNECTION")); db->setHostName(ip); db->setPort(port); db->setUserName(user); db->setPassword(pwd); db->setDatabaseName(dbName); db->setConnectOptions("MYSQL_OPT_CONNECT_TIMEOUT=4"); bool ok = db->open(); I compiled the Qt sql libs against the latest mysql version (5.6.x). This was actually a reported bug: QSqlDatabase::open always

How to fix QT VS Add-in for Qt 5.6 beta and VS2015?

丶灬走出姿态 提交于 2019-12-01 23:33:31
I did not compile Qt myself, rather I used installer from official Qt website (5.6 beta is available since few days ago). Installation was successful, Qt folder conatins bin folder with qmake and everything. Building apps in Qt Creator works. However, when I try to launch Qt using VS addin 1.2.5.9 I get error No default Qt version found. Pleae check your Qt Visual Studio Add-in settings. I have edited QT5 -> Qt Options to contain the correct Qt path to 5.6 beta, error still persists. I have also added QTDIR into Path in Windows 10. I am using Community Edition of Visual Studio 2015 How to fix

Qt5.6: high DPI support and OpenGL (OpenSceneGraph)

蓝咒 提交于 2019-12-01 07:35:41
I have a minimal application which uses QOpenGLWidget that integrates an OpenGL wrapper library (OpenSceneGraph). I am trying to figure out how to correctly use the Qt5.6 support for high DPI screens when dealing with OpenGL content like I use. My main() function has the following code: int main(int argc, char** argv) { // DPI support is on QApplication::setAttribute(Qt::AA_EnableHighDpiScaling); QApplication app(argc, argv); QMainWindow window; // QOpenGLWidget with OpenSceneGraph content QtOSGWidget* widget = new QtOSGWidget(); window.setCentralWidget(widget); window.show(); return app.exec(

Qt5.6: high DPI support and OpenGL (OpenSceneGraph)

跟風遠走 提交于 2019-12-01 05:16:52
问题 I have a minimal application which uses QOpenGLWidget that integrates an OpenGL wrapper library (OpenSceneGraph). I am trying to figure out how to correctly use the Qt5.6 support for high DPI screens when dealing with OpenGL content like I use. My main() function has the following code: int main(int argc, char** argv) { // DPI support is on QApplication::setAttribute(Qt::AA_EnableHighDpiScaling); QApplication app(argc, argv); QMainWindow window; // QOpenGLWidget with OpenSceneGraph content

defaultServiceProvider::requestService(): no service found for - “org.qt-project.qt.camera”

时光怂恿深爱的人放手 提交于 2019-11-30 16:58:50
问题 I'm trying to execute QCamera example on Ubuntu, Qt 5.6. "The camera service is missing" message observed. defaultServiceProvider::requestService(): no service found for - "org.qt-project.qt.camera" 回答1: Check if you have all dependencies installed. They are: qtmultimedia5-dev _ libqt5multimedia5-plugins Ex: sudo apt-get install libqt5multimedia5-plugins 回答2: Checking the example code it seems the example tries to construct the camera object with default camera. Method setCamera is obviously

Style sheets / Qt Designer support for high dpi screens?

六月ゝ 毕业季﹏ 提交于 2019-11-28 20:43:49
Today I have ported my application from Qt5.5 to Qt5.6RC. Running it on my high dpi screen the widgets appeared tiny. After reading this and setting QT_AUTO_SCREEN_SCALE_FACTOR to "1" at least it is usable again. However they say : In the longer term, the application should be adapted to run unmodified: 1) Always use the qreal versions of the QPainter drawing API. 2) Size windows and dialogs in relation to the screen size. 3) Replace hard-coded sizes in layouts and drawing code by values calculated from font metrics or screen size. Not all style sheet attributes support em (".. from font

Qt5.6 QML, why are dynamic models destroyed after garbage collection?

喜欢而已 提交于 2019-11-28 05:01:33
问题 I have a variable number of components, so i'm trying to give each one its own model . In this example, i just create one, but the idea is the same. GC() is a bit random, so in the example, i force the gc() after a click to flush out the problem. What happens is that the model is destroyed and becomes null. after that the click method cannot use it. main.qml: import QtQuick 2.5 import QtQuick.Controls 1.4 import QtQuick.Controls.Styles 1.4 import QtQuick.Layouts 1.2 import com.example.qml 1.0

Style sheets / Qt Designer support for high dpi screens?

早过忘川 提交于 2019-11-27 20:34:40
问题 Today I have ported my application from Qt5.5 to Qt5.6RC. Running it on my high dpi screen the widgets appeared tiny. After reading this and setting QT_AUTO_SCREEN_SCALE_FACTOR to "1" at least it is usable again. However they say: In the longer term, the application should be adapted to run unmodified: 1) Always use the qreal versions of the QPainter drawing API. 2) Size windows and dialogs in relation to the screen size. 3) Replace hard-coded sizes in layouts and drawing code by values

QSqlDatabase: QMYSQL driver not loaded on Ubuntu 15.04 64bits

筅森魡賤 提交于 2019-11-27 15:52:07
In Ubuntu 15.04 64 bits I installed Qt5.6 (online installer) and while trying to move my development environment from Windows 7 to Linux I faced the following: SqlDatabase: QMYSQL driver not loaded Following this , I managed to find ~/Qt/5.6/gcc_64/plugins/sqldrivers/libqsqlmysql.so and then: $ ldd libqsqlmysql.so linux-vdso.so.1 => (0x00007ffffd571000) libmysqlclient_r.so.16 => not found libz.so.1 => /lib/x86_64-linux-gnu/libz.so.1 (0x00007fe94ef24000) libcrypt.so.1 => /lib/x86_64-linux-gnu/libcrypt.so.1 (0x00007fe94ecec000) libnsl.so.1 => /lib/x86_64-linux-gnu/libnsl.so.1 (0x00007fe94ead2000

Error on execution -version `Qt_5' not found required by

删除回忆录丶 提交于 2019-11-26 14:22:06
问题 On execution of eiskaltdc++ on ubuntu 15.10 ,I get the following error: eiskaltdcpp-qt: /usr/lib/x86_64-linux-gnu/libQt5Multimedia.so.5: version `Qt_5' not found (required by eiskaltdcpp-qt) eiskaltdcpp-qt: /usr/lib/x86_64-linux-gnu/libQt5DBus.so.5: version `Qt_5' not found (required by eiskaltdcpp-qt) eiskaltdcpp-qt: /usr/lib/x86_64-linux-gnu/libQt5Concurrent.so.5: version `Qt_5' not found (required by eiskaltdcpp-qt) eiskaltdcpp-qt: /usr/lib/x86_64-linux-gnu/libQt5Sql.so.5: version `Qt_5'