(self)
| 1315 | self.cursor_offset = len(self.current_line) |
| 1316 | |
| 1317 | def keyboard_interrupt(self): |
| 1318 | # TODO factor out the common cleanup from running a line |
| 1319 | self.cursor_offset = -1 |
| 1320 | self.unhighlight_paren() |
| 1321 | self.display_lines.extend(self.display_buffer_lines) |
| 1322 | self.display_lines.extend( |
| 1323 | paint.display_linize(self.current_cursor_line, self.width) |
| 1324 | ) |
| 1325 | self.display_lines.extend( |
| 1326 | paint.display_linize("KeyboardInterrupt", self.width) |
| 1327 | ) |
| 1328 | self.clear_current_block(remove_from_history=False) |
| 1329 | |
| 1330 | def unhighlight_paren(self): |
| 1331 | """Modify line in self.display_buffer to unhighlight a paren if |
no test coverage detected