[issue23220] Documents input/output effects of how IDLE runs user code

2016-03-14 Thread Akira Li
Akira Li added the comment: IDLE can implement functionality similar to what colorama [1] module does on Windows: translate ANSI escape character sequences into corresponding GUI method calls. For example, \b might be implemented using a .delete() call, \r using .mark_set(), etc. [1] https:/

[issue23220] Documents input/output effects of how IDLE runs user code

2016-03-10 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: As for StackOverflow question, there is tkinter.ttk.Progressbar. -- ___ Python tracker ___ ___ Pyt

[issue23220] Documents input/output effects of how IDLE runs user code

2016-03-10 Thread Terry J. Reedy
Terry J. Reedy added the comment: Part of this issue is the difference between typing a character at the keyboard, which produces a key event whose effect is determined by key bindings (some default, some added) and inserting a character into a Text widget, which does not produce an event (exc

[issue23220] Documents input/output effects of how IDLE runs user code

2016-03-10 Thread Terry J. Reedy
Terry J. Reedy added the comment: Different \r behavior is the gist of https://stackoverflow.com/questions/35895864/what-is-the-difference-between-cmd-and-idle-when-using-tqdm. The new section should have more on the different effect of control characters on different display devices and wind

[issue23220] Documents input/output effects of how IDLE runs user code

2015-12-03 Thread irdb
Changes by irdb : -- nosy: +irdb ___ Python tracker ___ ___ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailma

[issue23220] Documents input/output effects of how IDLE runs user code

2015-09-28 Thread Terry J. Reedy
Terry J. Reedy added the comment: Issue #21995 discussed same issue from cause side, as opposed to result. The new section is partly based on what I wrote above. I am not satisfied with it yet. New changeset ac6ade0c5927 by Terry Jan Reedy in branch '2.7': Issue 21995: Explain some difference

[issue23220] Documents input/output effects of how IDLE runs user code

2015-07-12 Thread Terry J. Reedy
Terry J. Reedy added the comment: OK. "Both are true for backspace ('\b') and return ('\r')." -- ___ Python tracker ___ ___ Python-bug

[issue23220] Documents input/output effects of how IDLE runs user code

2015-07-11 Thread Martin Panter
Martin Panter added the comment: I wouldn’t say TK ignores carriage returns, though I agree it would be better if Idle stripped them out. Currently I get a glyph displayed for them, similarly to \b. They wouldn’t copy to my clipboard, so I fudged them after pasting here: >>> _ = stdout.write(

[issue23220] Documents input/output effects of how IDLE runs user code

2015-07-11 Thread Terry J. Reedy
Terry J. Reedy added the comment: I was thinking AttributeError, as mentioned in the previous sentence. But you are correct that ImportError is possible too. Maybe I should just give the code. try: import idlelib idlelib.run running_idle = True except (ImportError, AttributeError

[issue23220] Documents input/output effects of how IDLE runs user code

2015-07-11 Thread Martin Panter
Martin Panter added the comment: “run ``import idlelib; idlelib.run`` within a try-except statement”: It might be nice to say what exceptions are expected. My guess is ImportError if Idle or TK is not available, or AttributeError if it is but Idle is not running. “Tk handling of ascii control

[issue23220] Documents input/output effects of how IDLE runs user code

2015-07-11 Thread Terry J. Reedy
Terry J. Reedy added the comment: Serhiy, thanks for the paraphrase of what I tried to say. This issue has already been changed to a doc issue to explain the input/output effects of Idle's way of running user code. I should have retitled before. Control codes are just one of the effects tha