Author terry.reedy
Recipients cheryl.sabella, taleinat, terry.reedy
Date 2019-07-11.23:37:56
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <>
I believe I meant the opposite of what I said, which fortunately is what Tal did.  PR 14500 is the one I looked at and commented on and the name change in PR 14500 is what needed to be included in PR 12481 (done).

I would like to retitle this issue 'IDLE: Move format functions into 1 file:. and put all the functions for the Format submenu in one file,, with  The result will be near 400 lines.  Rename and and put contents of proposed new files in those instead.  Add another class, FormatFile for the 3 file reforming functions.

If you want, I would not mind merging the PR as is, but with 'region' removed from the names, and adding in FormatParagraph and a new FormatFile in a separate PR.  But I don't know the consequence for the file history and git blame.  I would prefer that be seen as the successor of if that would enable blame to trace back through the rename.

paragraph already has some utility functions, including get_indent, which is similar to get_line_indent.  We might combine them in the follow-up refactoring.  There is at least one bug, mentioned in file, to fix.

Followup refactoring should include examination of docstrings and IDLE doc.  The doc should briefly define 'region'.

SimpleDialog.AskInteger should be replaced by a Query subclass both here and in EditorWindow.goto_line_event (another issue and PR).

Menu adjustments: Move Format Paragraph to top, leaving the 3 file operations together at the bottom.  ^[ also indents.  (Tab indents if more than one line is selected.)  Strip trailing whitespace should string trailing blank lines.
Date User Action Args
2019-07-11 23:37:56terry.reedysetrecipients: + terry.reedy, taleinat, cheryl.sabella
2019-07-11 23:37:56terry.reedysetmessageid: <>
2019-07-11 23:37:56terry.reedylinkissue36390 messages
2019-07-11 23:37:56terry.reedycreate