Problems with Open-Source Downloads read https://www.qt.io/blog/problem-with-open-source-downloads and https://forum.qt.io/post/638946

QFileDialog not visible?



  • Hello,

    I have a weird problem:

    I have build a project under Ubuntu 20.4.1 / Unity with Qt5.12

    Now when I want to open a QFileDialog the Mainwindow dimms, but there is no filedialog..
    It just does not get visible or something like that.
    However when I setup a test-application with just a Mainwindow and file dialog it works.
    Also on anther machine Debian/KDE it works..

    The buid-kit is the same and everything.
    What could be the reason that it is not working on my project, I just have no idea where to search for the problem?

    EDIT: Ok it is even more confusing:

    When I call QFileDialog directly in the main or also inside MainWindow it shows until a certain point in the code.
    What happens at that point is that a row is inserted in some AbstractItemModel with beginInsertRows() endInsertRows()....

    From there on no file dialogs are shown any more... that does not make sense at all : (



  • @gde23
    You'd have to show repeatable code for anyone to have any idea why this might be. If you have it working in a small standalone but not in your larger app then clearly it's something you have done. Normal debugging technique is to is alter the two programs till they get more similar to locate whatever the issue is.

    Apart from anything else, you do not even say whether you are using the Qt or the native dialog. Not that on its own anyone will know.



  • @JonB Thanks for the advice. The problem here is, that the point in the application is really random and therefore i guess by now, has nothing to do with the dialog.
    I'm just using

    QFileDialog::getOpenFileName();
    

    without any further configuration.

    I think I might have found the problem though. From valgrind I get lots of memory errors from inside Qt that occure in i965_dri.so so it seems to be some problem with opengl/mesa/qt whatever on that machine..

    ==25398== Invalid write of size 8
    ==25398==    at 0x1662307B: ??? (in /usr/lib/x86_64-linux-gnu/dri/i965_dri.so)
    ==25398==    by 0x167B9D93: ??? (in /usr/lib/x86_64-linux-gnu/dri/i965_dri.so)
    ==25398==    by 0x160EEDCE: ??? (in /usr/lib/x86_64-linux-gnu/dri/i965_dri.so)
    ==25398==    by 0x160F10A7: ??? (in /usr/lib/x86_64-linux-gnu/dri/i965_dri.so)
    ==25398==    by 0x160F4B77: ??? (in /usr/lib/x86_64-linux-gnu/dri/i965_dri.so)
    ==25398==    by 0x561FA55: ??? (in /usr/lib/x86_64-linux-gnu/libQt5Widgets.so.5.12.8)
    ==25398==    by 0x561FBD8: QOpenGLWidget::resizeEvent(QResizeEvent*) (in /usr/lib/x86_64-linux-gnu/libQt5Widgets.so.5.12.8)
    ==25398==    by 0x55FD946: QWidget::event(QEvent*) (in /usr/lib/x86_64-linux-gnu/libQt5Widgets.so.5.12.8)
    ==25398==    by 0x55BAA65: QApplicationPrivate::notify_helper(QObject*, QEvent*) (in /usr/lib/x86_64-linux-gnu/libQt5Widgets.so.5.12.8)
    ==25398==    by 0x55C40EF: QApplication::notify(QObject*, QEvent*) (in /usr/lib/x86_64-linux-gnu/libQt5Widgets.so.5.12.8)
    ==25398==    by 0x65B9939: QCoreApplication::notifyInternal2(QObject*, QEvent*) (in /usr/lib/x86_64-linux-gnu/libQt5Core.so.5.12.8)
    ==25398==    by 0x55F5E6D: QWidgetPrivate::sendPendingMoveAndResizeEvents(bool, bool) (in /usr/lib/x86_64-linux-gnu/libQt5Widgets.so.5.12.8)
    ==25398==  Address 0x7fd9dcf4f24c is not stack'd, malloc'd or (recently) free'd
    
    

    EDIT: I'll close this thread since I guess it has nothing to do with the filedialog or other directly-Qt-related stuff


Log in to reply