0
votes

Since 1 week I try to create a dynamic library which content my qml in resource file. in qmldir I declare my qml files with qrc path for not distribute my qml files to the client.

All component is in qrc:

So when I use qrc path in my qmldir, I cannot use the auto-complementation for access to my component and I cannot access to my component form the Designer ...

But when I deploy my application my dll work fine

When I use the relative path, so without qrc://, the auto-complementation working but I cannot access to my component form the Designer ... And when i deploy my application I NEED to deploy my qml file also of my component library

I the both case I cannot access to my component from the designer. Maybe I make something wrong when I create my library or I forgot something ...

Any help will be appreciated for my issues...

1 : Can display my custom component in the Designer

2 : Access to auto-complementation without deploy qml

1

1 Answers

0
votes

I don't know about designer, never ever used that, but in order to get auto-complete for your custom types, in addition to the qmldir file you must have a plugins.qmltypes file, which pretty much describes the structure of the components.

The good news is it can be auto-generated via:

qmlplugindump My.Module 1.0 /import/path > /import/path/my/module/plugins.qmltypes

From the looks of it, your custom types should appear in designer in their own respective tab when you import the appropriate module and have the necessary support files.