Byobu -screen has a shotcut available (Ctrl-a !) to disable the function keys (see http://dodoincfedora.wordpress.com/2012/05/24/byobu-and-mc/), which lets you manually disable the function-keys for the current session.
To permanently disable the function-keys in *every* new session, I’ve found this way:
- edit the file ~/.byobu/keybindings
- after the existing line “source $BYOBU_PREFIX/share/byobu/keybindings/common”, add a new line “source $BYOBU_PREFIX/share/byobu/keybindings/f-keys.screen.disable”
The file should finally look something like mine:
Also if you use screen or byobu-screen through Putty, be aware of a bug explained in section BUGS of “man byobu”, basically saying that keys F1, F2, F3, F4 may not work correctly, which can be easily fixed:
“You can fix this problem in the PuTTY config, Terminal -> Keyboard -> Function keys: Xterm R6. See: http://email@example.com/msg01525.html”