better tdf spacing

This commit is contained in:
Gordon Shumway 2019-05-04 01:20:50 -04:00 committed by GitHub
parent 693362a041
commit 5af0ee9669
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 3 additions and 2 deletions

View File

@ -799,9 +799,10 @@ class ASCII(callbacks.Plugin):
return
paste = ""
self.stopped[msg.args[0]] = False
output = output.decode().replace('\r\r\n', '\r\n').replace('\x03\x03', '')
output = output.decode().replace('\r\r\n', '\r\n')
for line in output.splitlines():
line = re.sub('\x03$', '', line)
line = re.sub('\x03\x03\s*', '\x0F ', line)
line = re.sub('\x0F\s*$', '', line)
if self.registryValue('pasteEnable', msg.args[0]):
paste += line + "\n"
if not line.strip() and not self.stopped[msg.args[0]]: