For example
gnome chat

Or the Filezilla Notification "Upload complete!".

How can i use it in my C++ Application? I have searched at developer.gnome.org and found this and this but they were not very helpful.

有帮助吗?

解决方案

the notification in the screenshot is a chat notification, and it's handled by GNOME Shell directly; chat notifications cannot be implemented outside of the Shell, so you'll either need to patch GNOME Shell or write a Shell extension.

generic notifications (transient or permanent) can be sent from your application by using the libnotify API: https://git.gnome.org/browse/libnotify

you can also send notifications using the console, through the notify-send command line utility (which is usually shipped as part of the libnotify package).

许可以下: CC-BY-SA归因
不隶属于 StackOverflow
scroll top