From d52091e8187f17e279526063441e38f36cee2484 Mon Sep 17 00:00:00 2001 From: sf-exg Date: Wed, 6 Jan 2010 17:52:43 +0000 Subject: [PATCH] Add on_bell perl hook that is called on receipt of a bell character. --- Changes | 1 + src/hookinc.h | 2 ++ src/screen.C | 1 + src/urxvt.pm | 4 ++++ 4 files changed, 8 insertions(+) diff --git a/Changes b/Changes index 3c7f541..2291489 100644 --- a/Changes +++ b/Changes @@ -1,5 +1,6 @@ rxvt-unicode changelog <= google-friendly title + - new on_bell perl hook (Emanuele Giaquinta). - new iso14755 option to disable ISO 14755 at runtime (Emanuele Giaquinta). 9.07 Wed Dec 30 07:07:18 CET 2009 diff --git a/src/hookinc.h b/src/hookinc.h index 346fc59..311056e 100644 --- a/src/hookinc.h +++ b/src/hookinc.h @@ -52,3 +52,5 @@ def (CUSTOM_REND) // hovering over custom rendition, generate enter/leave maybe? + def (BELL) + diff --git a/src/screen.C b/src/screen.C index 0d75f14..4e7cb07 100644 --- a/src/screen.C +++ b/src/screen.C @@ -1935,6 +1935,7 @@ rxvt_term::scr_bell () NOTHROW } else XBell (dpy, 0); + HOOK_INVOKE ((this, HOOK_BELL, DT_END)); #endif } diff --git a/src/urxvt.pm b/src/urxvt.pm index 02e773c..ac0b46a 100644 --- a/src/urxvt.pm +++ b/src/urxvt.pm @@ -711,6 +711,10 @@ subwindow. Called when various types of ClientMessage events are received (all with format=32, WM_PROTOCOLS or WM_PROTOCOLS:WM_DELETE_WINDOW). +=item on_bell $term + +Called on receipt of a bell character. + =back =cut -- 1.9.1