From 99a793e2d015c5cd890e40263522d0ec42a54e3a Mon Sep 17 00:00:00 2001 From: Patrick Totzke Date: Sun, 17 Feb 2013 22:38:07 +0000 Subject: document new hooks --- docs/source/configuration/hooks.rst | 45 +++++++++++++++++++++++++++++++++++++ 1 file changed, 45 insertions(+) (limited to 'docs') diff --git a/docs/source/configuration/hooks.rst b/docs/source/configuration/hooks.rst index 40b46271..90b4fc30 100644 --- a/docs/source/configuration/hooks.rst +++ b/docs/source/configuration/hooks.rst @@ -123,3 +123,48 @@ Apart from command pre- and posthooks, the following hooks will be interpreted: :type subject: str :rtype: str +.. py:function:: pre_buffer_open(ui= None, dbm=None, buf=buf) + + run before a new buffer is opened + + :param buf: buffer to open + :type buf: alot.buffer.Buffer + +.. py:function:: post_buffer_open(ui=None, dbm=None, buf=buf) + + run after a new buffer is opened + + :param buf: buffer to open + :type buf: alot.buffer.Buffer + +.. py:function:: pre_buffer_close(ui=None, dbm=None, buf=buf) + + run before a buffer is closed + + :param buf: buffer to open + :type buf: alot.buffer.Buffer + +.. py:function:: post_buffer_close(ui=None, dbm=None, buf=buf, success=success) + + run after a buffer is closed + + :param buf: buffer to open + :type buf: alot.buffer.Buffer + :param success: true if successfully closed buffer + :type success: boolean + +.. py:function:: pre_buffer_focus(ui=None, dbm=None, buf=buf) + + run before a buffer is focused + + :param buf: buffer to open + :type buf: alot.buffer.Buffer + +.. py:function:: post_buffer_focus(ui=None, dbm=None, buf=buf, success=success) + + run after a buffer is focused + + :param buf: buffer to open + :type buf: alot.buffer.Buffer + :param success: true if successfully focused buffer + :type success: boolean -- cgit v1.2.3