Skip to content

KDE/kirigami-addons

Repository files navigation

Kirigami Addons is an additional set of visual components that work well on mobile and desktop and are guaranteed to be cross-platform. It uses Kirigami under the hood to create its components and should look native with any QtQuick Controls style.

Structure

The examples/ folder contains full project examples that can be built individually using -DBUILD_EXAMPLES=ON. Each project can be built with a CMake target available in the CMakeLists.txt, e.g. cmake --build build/ --target mobile-about. Some examples, such as MobileFormTutorial, are used for the Kirigami tutorial.

The autotests/ folder contains tests done at build time.

The tests/ folder contains individual QML files used for testing. It also serves as an up-do-date showcase of existing components.

The src/components/ folder contains minor standalone components.

The src/dateandtime/ folder contains ready-to-use time components.

The src/delegates/ folder contains base delegates to be used in ListViews following the Kirigami Addons style.

The src/formcard/ folder contains components used to create your own About and Settings pages. They are ready to use and extensible. It depends on Ki18n.

The src/settings/ folder contains categorized settings components, visually similar to the categorized sidebar of Plasma System Settings.

The src/sounds/ folder contains a ready-to-use sound picker for picking ringtones and notifications.

The src/treeview/ folder contains a ready-to-use Tree View implementation in QML. Note that Qt has a new TreeView QML type available since Qt 6.4.

Scope

Kirigami Addons must follow these rules:

  • It must be cross-platform: depending on other KDE Frameworks libraries is fine, but it must still work on Android. Components can use platform specializations, for example native dialogs, but a generic implementation for all platforms must exist.

  • Components must be grouped according to topic: for example, "dateandtime" or "chat". Each group should have its own source directory and QML import name. The name should follow the scheme of "org.kde.kirigamiaddons.topic", for example: "org.kde.kirigamiaddons.dateandtime".

  • All user-exposed QML items should have an examples implemented in the tests folder, not necessarily in a separate file.

In particular, Kirigami Addons is not the right place for:

  • exposing non-visual QML bindings
  • QML bindings for other libraries
  • API for a specific platform

Building

To build locally and use it in your application:

cmake -B build/ -DCMAKE_INSTALL_PREFIX=$HOME/kde/usr/
cmake --build build/
cmake --install build/
source build/prefix.sh

For development purposes, the best way to build Kirigami Addons is to build it with kdesrc-build.

Contributing

Like other projects in the KDE ecosystem, contributions are welcome from all. This repository is managed in KDE Invent, our GitLab instance.

If you get stuck or need help with anything at all, head over to the KDE New Contributors room on Matrix. For questions about Kirigami Add-ons, please ask in the Kirigami room. See Matrix for more details.