Gtk2::Notify3pm
Perl interface to libnotify
Usage
use Gtk2::Notify -init, "app_name";my $notification = Gtk2::Notify->new($summary,$message,$icon,$attach_widget);$notification->show;
Hierarchy
Glib::Object+----Gtk2::Notify
Initialisation
use Gtk2::Notify qw/-init app_name/;
- -init
-
Importing Gtk2::Notify with the -init option requires one additional argument: the application name to use. This is equivalent to
"Gtk2::Notify->init($app_name)".
Methods
notify = Gtk2::Notify->new ($summary, $body=undef, $icon=undef)
•
|
|
|---|---|
•
|
|
•
|
|
$notification->add_action ($action, $label, $callback, $userdata=undef)
•
|
|
|---|---|
•
|
|
•
|
|
•
|
|
string = Gtk2::Notify->get_app_name
$notification->set_category ($category)
- •
-
$category(string)
$notification->clear_actions
$notification->clear_hints
notify = $notification->close
$notification->set_hint_byte_array ($key, $value)
•
|
|
|---|---|
•
|
|
$notification->set_hint_byte ($key, $value)
•
|
|
|---|---|
•
|
|
$notification->set_hint_double ($key, $value)
•
|
|
|---|---|
•
|
|
$notification->set_hint_int32 ($key, $value)
•
|
|
|---|---|
•
|
|
$notification->set_hint ($key, $value)
•
|
|
|---|---|
•
|
|
$notification->set_hint_string ($key, $value)
•
|
|
|---|---|
•
|
|
$notification->set_icon_from_pixbuf ($icon)
- •
-
$icon(Gtk2::Gdk::Pixbuf)
boolean = Gtk2::Notify->init ($app_name)
- •
-
$app_name(string)
boolean = Gtk2::Notify->is_initted
list = Gtk2::Notify->get_server_caps
(notify, name, vendor, version, spec_version) = Gtk2::Notify->get_server_info
notify = $notification->show
$notification->set_timeout ($timeout)
- •
-
$timeout(integer)
Gtk2::Notify->uninit
boolean = $notification->update ($summary, $message=undef, $icon=undef)
•
|
|
|---|---|
•
|
|
•
|
|
$notification->set_urgency ($urgency)
- •
-
$urgency(Gtk2::Notify::NotifyUrgency)
Properties
'app-name' (string : default undef : readable / writable)
|
The application name to use for this notification |
|---|---|
'body' (string : default undef : readable / writable / construct)
|
The message body text |
'closed-reason' (integer : default -1 : readable)
|
The reason code for why the notification was closed |
'icon-name' (string : default undef : readable / writable / construct)
|
The icon filename or icon theme-compliant name |
'id' (integer : default 0 : readable / writable / construct)
|
The notification ID |
'summary' (string : default undef : readable / writable / construct)
|
The summary text |
Signals
closed(Gtk2::Notify)
Enums and flags
enum Gtk2::Notify::NotifyUrgency
•
|
'low' / 'NOTIFY_URGENCY_LOW' |
|---|---|
•
|
'normal' / 'NOTIFY_URGENCY_NORMAL' |
•
|
'critical' / 'NOTIFY_URGENCY_CRITICAL' |
Support
You can find documentation for this module with the perldoc command.
perldoc Gtk2::Notify
You can also look for information at:
- •
-
AnnoCPAN: Annotated CPAN documentation
<http://annocpan.org/dist/Gtk2-Notify>
- •
-
CPAN Ratings
<http://cpanratings.perl.org/d/Gtk2-Notify>
- •
-
RT: CPAN's request tracker
<http://rt.cpan.org/NoAuth/Bugs.html?Dist=Gtk2-Notify>
- •
-
Search CPAN
<http://search.cpan.org/dist/Gtk2-Notify>
Releases
4 releases since Debian 6.0 (Squeeze); the text changed 3 times.