Qml Image cannot be opened if containing special characters(from utf 8 like clémentine.jpg)



  • Hello,
    When i try to load the picture clémentine.jpg on embedded board by using the below code i get this error:
    file:///media/datastore/ui/HMIApplications/Media/qml/MediaHMILib/test.qml:92:5: QML Image: Cannot open: file:///media/datastore/ui/HMIApplications/Media/qml/MediaHMILib/cl?mentine.jpg
    Using the exact path into a text item the path is display correctly(looks like the encoding utf 8 is ok)
    The following test code was done on windows and linux pc and the picture is displayed and i cannot figure out why on the embedded is not working.

    Can you please help me with some information.
    Thank you,
    Ovidiu
    import QtQuick 2.0
    Rectangle {
    property url url: "relative_path/clémentine.jpg"
    Component.onCompleted:
    {
    console.log(myImage.source);
    }
    Image
    {
    id:myImage
    source:url
    }
    }


Log in to reply
 

Looks like your connection to Qt Forum was lost, please wait while we try to reconnect.