--- AnyEvent-ReadLine-Gnu/README 2012/05/10 21:53:03 1.2 +++ AnyEvent-ReadLine-Gnu/README 2012/05/11 15:38:02 1.3 @@ -50,6 +50,10 @@ Once initialised, this module will also restore the terminal settings on a normal program exit. + The callback will be installed with the "CallbackHandlerInstall", + which means it handles history expansion and history, among other + things. + The following key-value pairs are supported: on_line => $cb->($string) @@ -105,7 +109,37 @@ The last string should end with a newline. +CAVEATS + There are some issues with readline that can be problematic in + event-based programs: + + blocking I/O + Readline uses blocking terminal I/O. Under most circumstances, this + does not cause big delays, but ttys have the potential to block + programs indefinitely (e.g. on XOFF). + + unexpected disk I/O + By default, readline does filename completion on TAB, and reads its + config files. + + Tab completion can be disabled by calling "$rl->unbind_key (9)". + + tty settings + After readline has been initialised, it will mangle the termios tty + settings. This does not normally affect output very much, but should + be taken into consideration. + + output intermixing + Your program might wish to print messages (for example, log + messages) to STDOUT or STDERR. This will usually cause confusion, + unless readline is hidden with the hide method. + + Oh, and the above list is probably not complete. + AUTHOR, CONTACT, SUPPORT Marc Lehmann - http://software.schmorp.de/pkg/AnyEvent-Readline-Gnu.html + http://software.schmorp.de/pkg/AnyEvent-ReadLine-Gnu.html + +SEE ALSO + rltelnet - a simple tcp_connect-with-readline program using this module.