(content, position)
| 233 | template = self.default_template |
| 234 | |
| 235 | def _line_at_position(content, position): |
| 236 | start = content.rfind("\n", 0, position) + 1 |
| 237 | end = content.find("\n", position) |
| 238 | end = end if end != -1 else len(content) |
| 239 | line_num = content.count("\n", 0, start) + 1 |
| 240 | msg = f"\n{line_num}: {content[start:end]}" |
| 241 | if len(msg) > 79: |
| 242 | return f"\n{line_num}" |
| 243 | return msg |
| 244 | |
| 245 | def converter(matchobj): |
| 246 | """ |