summaryrefslogtreecommitdiffstats
path: root/Lib/idlelib/FormatParagraph.py
diff options
context:
space:
mode:
authorTerry Jan Reedy <tjreedy@udel.edu>2014-12-16 08:21:26 (GMT)
committerTerry Jan Reedy <tjreedy@udel.edu>2014-12-16 08:21:26 (GMT)
commitdf9386940a0104ba4dce1beee38848bc44a17036 (patch)
tree05453cf09bd484041108531cd5be680ac745b2ef /Lib/idlelib/FormatParagraph.py
parent4d5115c7b55a7b2a49324572f138298b0f3df916 (diff)
downloadcpython-df9386940a0104ba4dce1beee38848bc44a17036.zip
cpython-df9386940a0104ba4dce1beee38848bc44a17036.tar.gz
cpython-df9386940a0104ba4dce1beee38848bc44a17036.tar.bz2
Issue #20577: move configuration of FormatParagraph extension to new extension
configuration dialog. Patch by Tal Einat.
Diffstat (limited to 'Lib/idlelib/FormatParagraph.py')
-rw-r--r--Lib/idlelib/FormatParagraph.py6
1 files changed, 4 insertions, 2 deletions
diff --git a/Lib/idlelib/FormatParagraph.py b/Lib/idlelib/FormatParagraph.py
index 9b10c0a..7a9d185 100644
--- a/Lib/idlelib/FormatParagraph.py
+++ b/Lib/idlelib/FormatParagraph.py
@@ -44,9 +44,11 @@ class FormatParagraph:
The length limit parameter is for testing with a known value.
"""
- if limit == None:
+ if limit is None:
+ # The default length limit is that defined by pep8
limit = idleConf.GetOption(
- 'main', 'FormatParagraph', 'paragraph', type='int')
+ 'extensions', 'FormatParagraph', 'max-width',
+ type='int', default=72)
text = self.editwin.text
first, last = self.editwin.get_selection_indices()
if first and last: