Importing and Including
Step 1 - Add to project sources
MauiKit supports qmake and cmake
Importing - Statically linking
To statically add MauiKit to your project using qmake, you need to clone the MauiKit repository inside you project's root folder, and then the project's [project-name].pro
should look like this :
This will include MauiKit as a sub-module. It is recommended to only do this to deploy your project to other systems besides GNU Linux, like Android, Mac OS X, WIndows, etc...
MauiKit works on top of Kirigami and so it depends on it. If you plan to deploy your app on a device running Android you will also need to add the Kirigami submodule.
MauiKit's mauikit.pri file creates a useful definition named STATIC_MAUIKIT, you can make use of this definition in your project source code to differentiate when deploying to different systems.
Including - Framework
For GNU Linux the best way to make use of MauiKit is to install it system wide.
After building and installing MauiKit you can now include it in your project to start making use of it.
To include MauiKit with cmake:
To use it with qmake you need to include the MauiKit shared library into your project .pro file:
You can skip to the third step if you installed MauiKit system wide.
Step 2 - Include MauiKit Header File
This step is only necessary if you are statically linking MauiKit into your project.
Include the MauiKit header file as follows :
Then, register MauiKit Components :
Step 3 - Import MauiKit QML Controls
On your QML files you now can import the Maui Kit controls as follows :
You’re ready to start creating your next convergent application using MauiKit
Last updated