fixed readline() prompt offset with '\001' and '\002' escape characters.

Colors change works, still bug with special chars like '€' .
This commit is contained in:
LuckyLaszlo
2021-10-07 07:24:37 +02:00
parent f0e19b02d4
commit dae94fee81
4 changed files with 52 additions and 29 deletions

View File

@@ -6,7 +6,7 @@
/* By: lperrey <lperrey@student.42.fr> +#+ +:+ +#+ */
/* +#+#+#+#+#+ +#+ */
/* Created: 2021/10/03 19:14:46 by lperrey #+# #+# */
/* Updated: 2021/10/03 19:14:49 by lperrey ### ########.fr */
/* Updated: 2021/10/07 06:33:55 by lperrey ### ########.fr */
/* */
/* ************************************************************************** */
@@ -39,7 +39,7 @@
** <signal.h>: sigaction()
** <readline/readline.h>,
** <readline/history.h>,
** lib readline (-lreadline),
** Readline Library (-lreadline),
** readline(), rl_clear_history(), rl_on_new_line(),
** rl_replace_line(), rl_redisplay(), add_history()
** ------------------
@@ -58,8 +58,9 @@
** <dirent.h>: opendir(), readdir(), closedir()
** <termios.h>: tcsetattr(), tcgetattr()
** <curses.h>,
** <term.h>: tgetent(), tgetflag(), tgetnum(),
** tgetstr(), tgoto(), tputs()
** <term.h>: Termcap Library (-ltermcap)
** tgetent(), tgetflag(), tgetnum(), tgetstr(),
** tgoto(), tputs()
** ------------------
** <sys/stat.h>: open(), stat(), lstat(), fstat()
** <sys/types.h>: open(), wait(), waitpid(), wait3(), wait4(), kill()