KNotificationConfiguration Class
Configure notifications using the means of the platform. More...
| Header: | #include <KNotificationConfiguration> |
| CMake: | find_package(KF6 REQUIRED COMPONENTS Notifications)target_link_libraries(mytarget PRIVATE KF6::Notifications) |
| Since: | 6.29 |
Properties
- isAvailable : bool
Static Public Members
| bool | isAvailable() |
| void | show() |
Detailed Description
This provides ways to interact with platform-specific means of configuring notifications of the current application.
This is particularly relevant for sandboxed applications (Flatpak, APK, etc) where the host platform ultimately decides if/how notifications are shown.
This requires an installed .notifyrc file matching the application name to work, a .notifyrc file bundled as Qt resource will only work on Android.
Member Function Documentation
[static] bool KNotificationConfiguration::isAvailable()
Returns true if notifications can be configured on the current platform.
Note: Getter function for property isAvailable.
[static invokable] void KNotificationConfiguration::show()
Opens a platform-specific UI for configuring the notifications of the current application.
Note: This function can be invoked via the meta-object system and from QML. See Q_INVOKABLE.