Hello,
I wrote an item: LineEdit.qml, and I have another qml 'main.qml) which creates many LineEdit items.
It works fine if I put LineEdit.qml into a directory with qmldir file etc..
But, that causes the need to carry several files, and this is not really friendly user. I would like to make all in one file.
main.qml is loaded into C++/Qt application.
So, I'm looking for solution about providing the LineEdit.qml from c++ into the qml context/engine/view.
So the first try is to save the LineEdit.qml into my application resource file, and load it into QQmlComponent, but I got the error: LineEdit is not a type.
Is there a way to do so ? I know that it possible to define my LineEdit through c++ class (subclassing QQuickItem or QQuickPaintedItem...) but it is easier for me if I keep the LineEdit.qml file approach as I don't have to get bored with painting code...
Thanks
Bookmarks