plugin: Add new onBufferOptionChanged callback

This can become handy in the moment a plugin needs to react on e.g. changed
file type.
This commit is contained in:
Jöran Karl
2023-10-13 01:56:16 +02:00
parent 2898f1590d
commit 415ceee46b
2 changed files with 14 additions and 1 deletions

View File

@@ -62,6 +62,10 @@ that micro defines:
* `onBufferOpen(buf)`: runs when a buffer is opened. The input contains
the buffer object.
* `onBufferOptionChanged(buf, option, old, new)`: runs when an option of the
buffer has changed. The input contains the buffer object, the option name,
the old and the new value.
* `onBufPaneOpen(bufpane)`: runs when a bufpane is opened. The input
contains the bufpane object.