summaryrefslogtreecommitdiffstats
path: root/Lib/idlelib/FormatParagraph.py
diff options
context:
space:
mode:
Diffstat (limited to 'Lib/idlelib/FormatParagraph.py')
-rw-r--r--Lib/idlelib/FormatParagraph.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/Lib/idlelib/FormatParagraph.py b/Lib/idlelib/FormatParagraph.py
index 80c654e..ed9f28d 100644
--- a/Lib/idlelib/FormatParagraph.py
+++ b/Lib/idlelib/FormatParagraph.py
@@ -47,7 +47,7 @@ class FormatParagraph:
lines = map(lambda st, l=len(comment_header): st[l:], lines)
data = "\n".join(lines)
# Reformat to maxformatwidth chars or a 20 char width, whichever is greater.
- format_width = max(maxformatwidth, len(comment_header), 20)
+ format_width = max(maxformatwidth - len(comment_header), 20)
newdata = reformat_paragraph(data, format_width)
# re-split and re-insert the comment header.
newdata = newdata.split("\n")