… | |
… | |
14 | # |
14 | # |
15 | # You should have received a copy of the GNU General Public License along |
15 | # You should have received a copy of the GNU General Public License along |
16 | # with this program; if not, write to the Free Software Foundation, Inc., |
16 | # with this program; if not, write to the Free Software Foundation, Inc., |
17 | # 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. |
17 | # 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. |
18 | |
18 | |
|
|
19 | #:META:X_RESOURCE:%:string:the shell snippet to execute |
|
|
20 | |
|
|
21 | =head1 NAME |
|
|
22 | |
|
|
23 | bell-command - execute a command when the bell rings |
|
|
24 | |
|
|
25 | =head1 DESCRIPTION |
|
|
26 | |
|
|
27 | Runs the command specified by the C<URxvt.bell-command> resource when |
|
|
28 | a bell event occurs. For example, the following pops up a notification |
|
|
29 | bubble with the text "Beep, Beep" using notify-send: |
|
|
30 | |
|
|
31 | URxvt.bell-command: notify-send "Beep, Beep" |
|
|
32 | |
|
|
33 | =cut |
|
|
34 | |
19 | sub on_start { |
35 | sub on_start { |
20 | my ($self) = @_; |
36 | my ($self) = @_; |
21 | |
37 | |
22 | $self->{bell_cmd} = $self->x_resource ("bell-command"); |
38 | $self->{bell_cmd} = $self->x_resource ("bell-command"); |
23 | |
39 | |