Skip to content

General and Desktop

This is where all the desktop OS and general Qt questions belong.
84.1k Topics 460.3k Posts
Qt 6.11 is out! See what's new in the release blog
  • To pass a string between functions

    Solved
    4
    0 Votes
    4 Posts
    1k Views
    R
    Thank you @LeLev , @JonB for your feedback
  • Connecting two windows

    Solved
    40
    0 Votes
    40 Posts
    11k Views
    R
    Thank you @jsulm , @SGaist for your feedback
  • QSqlquery exec timeout

    Unsolved qsqldatabase qsqlquery timeout exec qt 5.12
    5
    0 Votes
    5 Posts
    3k Views
    BartoszPajB
    Process still block, when I lost connection.
  • How to find current line number in QTextEdit?

    Unsolved
    2
    0 Votes
    2 Posts
    495 Views
    ODБOïO
    @LeroyNethan hi https://forum.qt.io/topic/108009/how-to-find-current-line-number-in-qtextedit
  • Qt Creator and windows alt+keycode

    Unsolved
    11
    0 Votes
    11 Posts
    3k Views
    G
    @PsylumDan I had the same problem with QtCreator on Windows 10. You can edit keyboard shortcuts (Tools -> Options -> Environment -> Keyboard) and remove all the shortcuts Alt+0 through Alt+9. Then you'll be able to enter symbols with alt+keycode normally.
  • QXCB could not connect to the display on BBB

    Locked Unsolved
    3
    0 Votes
    3 Posts
    614 Views
    SGaistS
    Locked this one since you duplicated here.
  • Qxcb connection:could not connect to display

    Unsolved
    3
    0 Votes
    3 Posts
    717 Views
    SGaistS
    Please don't post the same question multiple times. As I have told you, I've already forked earlier your original question here....
  • QGraphicsView / QGraphicsScene not updating (intermittently!)

    Solved
    5
    0 Votes
    5 Posts
    2k Views
    S
    The automated "scan" process was running as its own thread and although I tried using mutexes and everything else I could, I think I was still getting enough uncertainty in the delivery of signals that the QGraphicsView was getting confused. I changed the code so that the scan does not run in a separate thread and things seem to be working now. I also tried using a QOpenGLWidget as the viewport of the QGraphicsView and that worked to eliminate the graphics view hangs, but I had other artifacts and would prefer not to rely on OpenGL graphics implementation if possible.
  • QSystemTrayIcon signals not emitting on mouse click in Ubuntu 19.04

    Unsolved
    14
    0 Votes
    14 Posts
    3k Views
    A
    Sorry I haven't posted on this thread for a while since I got pulled off on other issues. So compiling Qt myself is not an option as we use the distribution provided by the repository "apt-get" in Ubuntu. The problematic Ubuntu version is 19.04 which also has an update to Gnome. The main issue right now is that the QSystemTrayIcon does not send out any signals when receiving mouse clicks and is completely unresponsive. Do you think it could somehow be sitting behind the system tray and somehow I need to bring it to the front? QSystemTrayIcon is not a QWidget so it doesn't have any capability to capture QMouseEvents which I was hoping. Do you guys have any ideas for workarounds to somehow capture mouse clicks? I did see someone implement a small transparent QWidget window that fits over the QSystemTrayIcon and then it can capture the QMouseEvents and handle them appropriately. The only problem is that in order to get THAT working I need to use the geometry() method and I'm not sure that the QSystemTrayIcon's geometry() method returns anything. The last time I played around with it returned point (0,0). I'll try again. QRect rect = trayIcon->geometry(); qDebug() << "Tray GEO: " << rect; This returns: Tray GEO: QRect(0,0 0x0) If you guys have any ideas of creative workarounds that would be great. Messing with Qt internals isn't an option unfortunately.
  • Resize window when replacing widget

    Unsolved
    6
    0 Votes
    6 Posts
    1k Views
    JonBJ
    @Smeeth If there isn't an automatic size policy you can apply to the main window to shrink to contents (I don't know), what about mainWindow->adjustSize() (or resize(minimumSizeHint()))? You may have to call it on a QTimer after the board's dimensions have been changed.
  • I have the same problem, do we now have any solution

    Unsolved
    6
    0 Votes
    6 Posts
    935 Views
    SGaistS
    You don't apply this property, you need to build the corresponding module with the suggestion applied there.
  • GUI closes

    Unsolved
    3
    0 Votes
    3 Posts
    487 Views
    SGaistS
    Hi and welcome to devnet, In addition to to what @dheerendra wrote, since you are new to Qt, please follow the code examples in the documentation. In none of them you'll see such a way to setup and run a Qt application.
  • Are there Qt5 or Qt4 Binding for Dlang with duic converter?

    Unsolved
    2
    0 Votes
    2 Posts
    341 Views
    SGaistS
    Hi, I think that you should contact the author of the bindings you would like to use. They likely will be faster to answer that question.
  • Handling network timeout in Qt

    4
    0 Votes
    4 Posts
    6k Views
    ekkescornerE
    @rcari said in Handling network timeout in Qt: This has been an open question for a while now given this "bug report":https://bugreports.qt-project.org/browse/QTBUG-3443. It does not seem to be a priority. finally a 10 yrs old bug is fixed for Qt 5.15 :) https://codereview.qt-project.org/c/qt/qtbase/+/278064
  • Mainwindow content gets vignetted at border

    Unsolved
    6
    0 Votes
    6 Posts
    2k Views
    gde23G
    @SGaist: here is a screenshot of the GUI. On the top there is a QTabWidget where the QTabBar is normally visible, however here it is vignetted. The vignetting can also be seen on the bottom, where the StatusBar is cut off half. [image: 53809463-21c0-4422-b558-f2fd6927289b.jpg] The GUI is using a stylesheet, that is why the QDockWidgets look a bit different than usual. In the designer of course I have set a layout and added all the widgets to the layout. The Qt Version is 5.13.0 and I have been tried it on several machnies Linux and Windows (also with High-DPI Screen scaling turned on in Windows) which works fine on any machine I've tested it, except on that one Dell-Notebook with Windows 10.
  • Virtual keyboard code using qwidget.

    Solved
    1
    0 Votes
    1 Posts
    370 Views
    No one has replied
  • Compiler Error : use of undefined type ' '

    Unsolved
    4
    0 Votes
    4 Posts
    2k Views
    Crawl.WC
    When I declare a func which ret type is QVariantList, report error error: C2027: use of undefined type 'QVariant'.In this case, we need include #include <QVariant> in the header file.
  • missing qt eglfs libraries in my BBB

    Unsolved
    12
    0 Votes
    12 Posts
    2k Views
    jsulmJ
    @Asha yes
  • Terminal Example for QSerialPort doesn't work correctly

    Solved
    9
    0 Votes
    9 Posts
    3k Views
    O
    @J-Hilk said in Terminal Example for QSerialPort doesn't work correctly: If you remove the QThread::msleep(10000); call, you'll get the 2nd package much much faster. That is normal behavior, you get noticed each event loop cycle, if new data arrived at the Serial port. -> getting partial data is normal and expected. It is your task as a developer to collect and store the data and decide when the answer is complete. Thank you very much for quich answer! QThread::msleep() I used only to check how readyRead() signal works.
  • how to upload images taken from QTapp to Cloud Server

    Unsolved google drive qcamera api
    9
    0 Votes
    9 Posts
    4k Views
    dheerendraD
    You can use QNetworkAccessManager upload the contents to the GoogleDrive. Also you need to setup the GoogleDrive for accessing like web-server.