Important: Please read the Qt Code of Conduct -

SetPixmap doesn't work in linux but works in windows

  • Hello Qt World!
    The following code doesn't work in Kubuntu 12.4, but works fine in Windows.
    @QPixmap pixmap("filename.png"));

    It's executed in the main thread.
    Seems like this problems is more related to an OS configuration than the code.

  • Moderators

    IIRC windows filesystem is case insensitive while Linux is case sensitive. Check the capitalization of the file.

    Make sure the working directory is indeed the one you assume it is when using relative pathes.

Log in to reply