Subject: | No way to re-draw current prompt |
I would like my completion routine to be able to print helpful text to
screen and then have the prompt printed correctly again. For instance,
in the Bash shell, hitting tab twice causes a directory listing to be
printed.
As far as I can tell, Term::Readline::Perl does not allow my program to
print helpful text while completing. It does have a force_redraw
variable, which is exactly what is needed, it just doesn't offer any way
for my program to set it.
Term::ReadLine::Gnu offers the rl_on_new_line function, telling it that
the cursor has moved to a new line so the entire prompt needs to be
printed again.
http://search.cpan.org/~hayashi/Term-ReadLine-Gnu-1.16/Gnu.pm#on_new_line
Is there any chance of adding rl_on_new_line to Term::Readline::Perl?
Reference: http://rt.cpan.org/Ticket/Display.html?id=26692