Notification: QtObject [uncreatable]

import Quickshell.Services.Notifications

A notification emitted by a NotificationServer. More

Properties

Functions

Signals

Detailed Description

A notification emitted by a NotificationServer.

ℹ️
This type is Retainable. It can be retained after destruction if necessary.

Property Details

[readonly]

actions: list<NotificationAction>

Actions that can be taken for this notification.

[readonly]

appIcon: string

The sending application’s icon. If none was provided, then the icon from an associated desktop entry will be retrieved. If none was found then “”.

[readonly]

appName: string

The sending application’s name.

[readonly]

body: string

No details provided.

[readonly]

desktopEntry: string

The name of the sender’s desktop entry or "" if none was supplied.

[readonly]

expireTimeout: real

Time in seconds the notification should be valid for

[readonly]

hasActionIcons: bool

If actions associated with this notification have icons available.

See NotificationAction.identifier for details.

[readonly]

hints: unknown

All hints sent by the client application as a javascript object. Many common hints are exposed via other properties.

[readonly]

id: int

Id of the notification as given to the client.

[readonly]

image: string

An image associated with the notification.

This image is often something like a profile picture in instant messaging applications.

[readonly]

lastGeneration: bool

If this notification was carried over from the last generation when quickshell reloaded.

Notifications from the last generation will only be emitted if NotificationServer.keepOnReload is true.

[readonly]

resident: bool

If true, the notification will not be destroyed after an action is invoked.

[readonly]

summary: string

The image associated with this notification, or "" if none.

tracked: bool

If the notification is tracked by the notification server.

Setting this property to false is equivalent to calling dismiss().

[readonly]

transient: bool

If true, the notification should skip any kind of persistence function like a notification area.

[readonly]

urgency: NotificationUrgency

No details provided.

Function Details

void dismiss()

Destroy the notification and hint to the remote application that it was explicitly closed by the user.

void expire()

Destroy the notification and hint to the remote application that it has timed out an expired.

Signal Details

closed(reason: NotificationCloseReason)

Sent when a notification has been closed.

The notification object will be destroyed as soon as all signal handlers exit.