I found a problem with diff. If you scroll with the mouse wheel, diff reports an error - command not allowed in diff mode. You can use the command below to toggle the key bindings temporarily so that WheelUp and WheelDown bind to fast_scroll.
_command void toggle_scroll_with_cursor_keys() name_info(',')
{
if ( def_scroll_up_with_cursor == 0 ) {
if (_message_box('Enable scroll with cursor', "", MB_YESNO) != IDYES) {
message("Cursor scrolling is disabled");
return;
}
def_scroll_up_with_cursor = 1;
scroll_up_with_cursor_key_bindings = 1;
}
scroll_up_with_cursor_key_bindings = (int)!scroll_up_with_cursor_key_bindings;
if ( scroll_up_with_cursor_key_bindings ) {
execute('bind-to-key -r fast_scroll 'event2index(name2event('WHEEL-UP')),"");
execute('bind-to-key -r fast_scroll 'event2index(name2event('WHEEL-DOWN')),"");
message("Bind to fast-scroll");
}
else {
execute('bind-to-key -r my_scroll_up 'event2index(name2event('WHEEL-UP')),"");
execute('bind-to-key -r my_scroll_down 'event2index(name2event('WHEEL-DOWN')),"");
message("Bind to my-scroll");
}
}