Solved How do I add a collection of custom examples in Qt 5.5 Creator?
-
I've read Building and Running an Example here ...
http://doc.qt.io/qtcreator/creator-build-example-application.html
but I see no advice about adding a custom example.I've seen the master list of Examples here ...http://doc.qt.io/qt-5/all-examples.html
Is there a tutorial explaining how to add my own private collection of examples into the Qt examples folder (or elsewhere) and for these examples to be seen and run in Qt 5.5 Creator?
I have Qt 5.5.1 is installed in /opt/qt55 in Ubuntu 14.04 (32 bit).
-
Hi,
Do you mean you would like to contribute new examples to Qt ?
-
Not yet. I'm not that experienced in Qt.
I have in mind using Qt Creator > Examples as a repository for my own custom applications built locally so that any app can be rapidly copied into Qt Creator as a template app to be modified.I've come to the view that to achieve my own goals and with my limited experience of Qt I need to build hybrid apps where I have Qt 5 thin clients as wrappers for HTML5 widgets. This opens up applications such as data visualisation.
I'll give an example of one HTML/JS/CSS widgets framework.
http://www.jqwidgets.com/jquery-widgets-demo/So I aim to create a custom Qt5 app for each of the jqwidgets.
And there are other js frameworks I hope to integrate.
e.g. http://philogb.github.io/jit/I have created one test custom app using webview but I intend to use Qt 5.6 with QtWebEngine.
It may be that some of these hybrid apps might be of interest to the Qt community but note that jqwidgets requires a licence (free usage for non commercial use).
Other frameworks will use local jetty server. Of course any server (local or remote) can be used in webview.
I appreciate that with this hybrid approach I'm not using all the features of Qt5 but I need to run in parallel while learning Qt 5. And I'm not experienced in C++.
-
IIRC you should be able to add your own application template to Qt Creator so that when calling New, you can select them from the list like you are currently doing.
-
Thanks for that tip.
I'm hoping that this is how to do this ..
File > New File or Project > Choose a template: > Import Project > Import Existing ProjectThe Application template does not offer a way to navigate added projects.
However I don't yet see how to add thumbnail summaries of added projects to Examples in Qt Creator.
-
You can also ask on the Qt Creator mailing list whether there's a feature for that use case.
-
Thanks. That mailing list will be helpful for future reference.
Pursuing my understanding of Examples and Tutorials I followed the recent thread by @clayton
https://forum.qt.io/topic/64216/how-to-configure-qt-creator-to-find-the-examples-on-the-welcome-panel/2From link2 posted by @Ratzz I found this ... https://wiki.qt.io/Qt_Examples_in_Qt_Creator
This helps to understand the Examples and Tutorials folder.
I opened in text editor ..
images_areaofinterest.xml ($QTCREATORDIR/share/qtcreator/welcomescreen/images_areaofinterest.xml)
qtcreator_tutorials.xml ($QTCREATORDIR/share/qtcreator/welcomescreen/qtcreator_tutorials.xml)to get some idea of layout.
Note that in an XML editor (XMLCopyEditor) element errors showed up in both xml files.
e.g. Error at line 2, column 29: no declaration found for element 'instructionals'.
However my opening question is answered so I will mark this thread as "solved".