Added in 1.9.4
/savebuf [-aglosN] [n1-n2] <window | dialog id> <filename>
Saves the specified number of lines from the end of the buffer of the specified window into the specified filename.
n1-n2 - Save only lines n1 to n2 starting from the end of the buffer. (if no lines are specified, all lines are saved)
<window | dialog id> - Window or dialog/dialogid to save from.
<filename> - Filename to save to.
-a - Append the text to the end of the file.
-l - Use side-listbox
-o - Indicates that you have specified [dialog id] parameters instead of a window name in order to save text from a custom dialog control.
-s - Use status window.
-N - Keep the nickcolumn character when saving a window. (AdiIRC only)