mirror of
https://github.com/Tha14/toxic.git
synced 2025-06-30 08:36:44 +02:00
Enable multiline input
Adds a nonl() call to avoid translation from \r to \n when pressing enter. C-J -> \n Enter -> \r To allow multiline input, \n chars (e.g. when pressing C-J) are replaced with a pilcrow. After hitting enter, every pilcrow is substituted with \n again.
This commit is contained in:
@ -66,4 +66,8 @@ void add_line_to_hist(ChatContext *ctx);
|
||||
resets line if at end of history */
|
||||
void fetch_hist_item(ChatContext *ctx, int key_dir);
|
||||
|
||||
/* Substitutes all occurrences of old with new. */
|
||||
void strsubst(char *str, char old, char new);
|
||||
void wstrsubst(wchar_t *str, wchar_t old, wchar_t new);
|
||||
|
||||
#endif /* #define TOXIC_STRINGS_H */
|
||||
|
Reference in New Issue
Block a user