Rewrite the readline redraw code to make the screen lines explicit

This commit is contained in:
Kovid Goyal
2022-11-14 15:42:06 +05:30
parent f945ef8ee8
commit 3c4a411cad
7 changed files with 171 additions and 37 deletions
+8
View File
@@ -244,6 +244,14 @@ func (self *Loop) EndBracketedPaste() {
self.QueueWriteString(BRACKETED_PASTE.EscapeCodeToReset())
}
func (self *Loop) AllowLineWrapping(allow bool) {
if allow {
self.QueueWriteString(DECAWM.EscapeCodeToSet())
} else {
self.QueueWriteString(DECAWM.EscapeCodeToReset())
}
}
func (self *Loop) Quit(exit_code int) {
self.exit_code = exit_code
self.keep_going = false