Edited 2016-06-05: Now with Qt 5.7 RC the Gallery is included and enhanced.
Edited 2016-04-28: Unfortunately Qt 5.7 Beta doesn’t include the Gallery because of some renaming-trouble. To test a first deployment running Qt 5.7 Beta please follow this article: qt-5.7-beta
Now it’s time to check if your installation and settings are well done. Easiest way to do this is to deploy an existing example to Android and iOS.
Qt Quick Controls 2 Gallery Example
Open Qt Creator, then goto Welcome –> Examples and search for labs.controls: (Qt 5.6) or search for Gallery 2 from Qt 5.7
In 5.6 where qt.labs.controls are only a TechPreview there’s only one Example: Gallery
Build and Run Configuration
Click on Gallery selects ‘Project’ on the left side and opens two windows: Project Build and Help:
Click on Add Kit to add your Kits:
I always only test on real devices, so I’m using these two Kits: Android for arm and iPhone.
Hover with your mouse over the top-right corner of a Kit and you can Remove it.
Each Kit has Build and Run Tabs where you can configure the build. Qt Creator should have done most of the work automatically – so for running the Example it should work out of the box.
Here’s the Android Build:
check the APK Build, where you can select the SDK. Also there’s the checkbox to use Gradle and how Qt libraries are bundled:
Compile, Deploy and Run on Android
Now connect your Android Phone via USB.
At left-bottom side please select the correct Kit to be used: Android – Debug:
Now we can (Build and) Run the APP:
Qt Creator asks you which Device to use. We already have connected the Android Device: STV100-4 is the BlackBerry PRIV:
Select the Device and Qt Creator will compile and build. Open the Compile Output to see what happens:
As next the APP was deployed to the Device and started. You can verify the Console output from ‘Application Output’.
Compile, Deploy and Run on iOS
Now we want to do the same for iOS.
Connect your iPhone via USB and again select the right Kit:
This time there’s no extra Dialog to select the Device – it’s on top of Kit Selection. iPhone and Debug are selected – so we can Run again.
Project compiles, deploys and runs the APP on iPhone.
Go through this Gallery Example to see most of UI and Navigation Controls in Action.
From Settings you can switch between Material, Universal and Default.