(s, line, word, line_width, next_line_prefix, legacy)
| 811 | |
| 812 | |
| 813 | def _extendLine(s, line, word, line_width, next_line_prefix, legacy): |
| 814 | needs_wrap = len(line) + len(word) > line_width |
| 815 | if legacy > 113: |
| 816 | # don't wrap lines if it won't help |
| 817 | if len(line) <= len(next_line_prefix): |
| 818 | needs_wrap = False |
| 819 | |
| 820 | if needs_wrap: |
| 821 | s += line.rstrip() + "\n" |
| 822 | line = next_line_prefix |
| 823 | line += word |
| 824 | return s, line |
| 825 | |
| 826 | |
| 827 | def _extendLine_pretty(s, line, word, line_width, next_line_prefix, legacy): |
no test coverage detected
searching dependent graphs…