[solved] Ways to deliver the .qml source ?
-
Hey guys I wondering how to deliver the qml parts of an application.
I mean i have the c++ part which I deliver as binaries.
But the QML part is plain text. So how can I prevent the user from changing the qml source ?I there any way I didn't figure out yet ?
-
try to include qml file to .qrc
"http://developer.qt.nokia.com/forums/viewthread/1065/":http://developer.qt.nokia.com/forums/viewthread/1065/
-
Link to the docs about the Qt Resource System: "http://doc.qt.nokia.com/4.7/resources.html":http://doc.qt.nokia.com/4.7/resources.html
-
Hey thanks, I already read this. But I didn't think about using the resource system.
But its the right way.
Thank you Guys.
I have another question about using qml but maybe we can discuss this right here.
Once I implement the qml system I hab to deliver several Qt librarys used by qml.
But is it really necessary to deliver them all ?I mean I get dependencies to the SQL, XML, Web libraries and so on but I don't use them.
Is there a way to reduce the amount of dependencies when using qml ? -
I think you need to recompile the library with the stuff that you need. not sure if this is the only way since I'm new to Qt, but searching on net this is the solution that I found.
-
Hmm sounds like an idea, if there is no other way maybe I will try this out.
-
also depends what device are you targeting. desktop or mobile? if you are going for mobile(symbian or maemo) you don't need to provide for the qt library since is included in the OS
-
[quote author="Schneidi" date="1285868016"]Once I implement the qml system I hab to deliver several Qt librarys used by qml.
But is it really necessary to deliver them all ?I mean I get dependencies to the SQL, XML, Web libraries and so on but I don't use them.
Is there a way to reduce the amount of dependencies when using qml ?[/quote]Hi,
The declarative module is conditionally dependant on several other modules. If you look in the project files for declarative, you can see several statements like:
@contains(QT_CONFIG, svg): QT += svg@
This means that if Qt was configured with SVG support, than declarative will depend on it, otherwise not. There is no way to configure Qt without SQL support, so that dependancy can't be removed. Dependancies you should be able to get rid of, if you are not using the features, include:
- svg
- opengl
- xmlpatterns (required if you are using XmlListModel)
- webkit (required if you are using WebView; declarative does not have a dependancy on this, but the WebView plugin does)
Regards,
Michael -
Hey I targeting desktop systems generally Linux and Windows systems.
I'm currently testing and developing on windows 7.
It seems that it isn't enough to avoid the libraries by avoiding the features they provide.
As far as I'm implementing just the most simple qml part, I have to delivering all kinds of libraries which ends up in several MB of load.
So do I have to reconfigure my Qt ?
I'm not so experienced in customizing Qt itself. But if this is answer I would try that out. -
Yes, you will need to reconfigure (configure -help gives the list of all available options). You might also be interested in "Fine-Tuning Features in Qt":http://doc.troll.no/4.7/fine-tuning-features.html (usually used for targeting embedded devices).
-
Ok thanks for reply.
I should take a look at the configure anyway.
The "Fine-Tuning" sounds pretty interesting for me, maybe this could be helpful in this cases.
-
[quote author="Schneidi" date="1285853515"]So how can I prevent the user from changing the qml source ?[/quote]
Why would you intentionally want to do that?
-
MTK358, I think, it's useful possibility.