summaryrefslogtreecommitdiffstats
path: root/Lib/idlelib/editor.py
Commit message (Collapse)AuthorAgeFilesLines
* Fix typos in warnings, docstrings, comments and text files (#123597)abstractee2024-09-031-1/+1
|
* gh-88516: show file proxy icon in IDLE editor windows on macOS (#112894)Ronald Oussoren2024-02-231-1/+10
| | | | | | | | | | | | | The platform standard on macOS is to show a proxy icon for open files in the titlebar of Windows. Make sure IDLE matches this behaviour. Don't use both the long and short names in the window title. The behaviour of other editors (such as Text Editor) is to show only the short name with the proxy icon. Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
* gh-103820: IDLE: Do not interpret buttons 4/5 as scrolling on non-X11 ↵Christopher Chavez2024-02-021-2/+3
| | | | | | | (GH-103821) Also fix test_mousewheel: do not skip a check which was broken due to incorrect delta on Aqua and XQuartz, and probably not because of `.update_idletasks()`.
* gh-66819: More IDLE htest updates(4) (#112686)Terry Jan Reedy2023-12-041-0/+1
| | | | Mostly double spacing before 'if __name__...'.
* gh-104719: IDLE - test existence of all tokenize references. (#104767)Terry Jan Reedy2023-05-241-9/+10
| | | | | | Class editor.IndentSearcher contains all editor references to tokenize module. Module io tokenize reference cover those other modules. Co-authored-by: Jelle Zijlstra <jelle.zijlstra@gmail.com>
* gh-104719: IDLE - delete useless monkeypatch of tokenize (#104726)Terry Jan Reedy2023-05-211-12/+6
|
* gh-75710: IDLE - add docstrings and comments to editor module (#104446)Terry Jan Reedy2023-05-131-25/+102
| | | | | Commit extracted from PR #3669. Will edit more later. Co-authored-by: Cheryl Sabella <cheryl.sabella@gmail.com>
* gh-103668: Run pyugrade on idlelib (#103671)Nikita Sobolev2023-04-231-6/+7
| | | | --------- Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
* gh-95841: IDLE - Revise Windows local doc url (#95845)Terry Jan Reedy2022-08-111-4/+14
| | | | | | #91242 replaced the Windows chm help file with a copy of the html docs. This PR replaces the IDLE code that fetches the Windows local help url passed to os.startfile. Co-authored-by: Steve Dower
* idlelib: replace 'while 1' with 'while True' (#94827)Terry Jan Reedy2022-07-141-1/+1
|
* bpo-45447: Add syntax highlighting for `.pyi` files in IDLE (GH-28950)Alex Waygood2022-02-131-1/+2
| | | | | | | | Also add .pyi to the python extensions in the "File-open" and "File-save" dialogues. Add util.py to contain objects that are used in multiple idlelib modules and have no dependencies on any of them. Co-authored-by: E-Paine <63801254+E-Paine@users.noreply.github.com> Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
* bpo-37903: IDLE: add shell sidebar mouse interactions (GH-25708)Tal Einat2021-05-031-1/+1
| | | | | | Left click and drag to select lines. With selection, right click for context menu with copy and copy-with-prompts. Also add copy-with-prompts to the text-box context menu. Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
* bpo-37903: IDLE: Shell sidebar with prompts (GH-22682)Tal Einat2021-04-281-15/+15
| | | | | | The first followup will change shell indents to spaces. More are expected. Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
* bpo-23544: Disable IDLE Stack Viewer when running user code (GH-17163)Zackery Spytz2021-01-281-4/+6
| | | | | Starting stack viewer when user code is running, including when Debugger is active, hangs or crashes IDLE. Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
* bpo-43013: Fix old tkinter module names in idlelib (GH-24326)Terry Jan Reedy2021-01-251-8/+8
| | | | | | Lowercase 'tkColorChooser', 'tkFileDialog', 'tkSimpleDialog', and 'tkMessageBox' and remove 'tk'. Just lowercase 'tkFont' as 'font' is already used. Adjust import.
* bpo-43013: Update idlelib code to 3.x (GH-24315)Terry Jan Reedy2021-01-241-2/+2
| | | | Remove 9 remaining '(object)' occurrences in class headers in idlelib and 25 '()' occurrences in idlelib.idle_test class headers.
* bpo-39885: Make IDLE context menu cut and copy work again (GH-18951)Terry Jan Reedy2020-05-291-4/+11
| | | | Leave selection when right click within. This exception to clearing selections when right-clicking was omitted from the previous commit, 4ca060d. I did not realize that this completely disabled the context menu entries, and I should have merged a minimal fix immediately. An automated test should follow.
* bpo-27115: Use Query subclass for IDLE editor Goto (GH-18871)Terry Jan Reedy2020-03-091-12/+10
| | | | Replace tkinter tkSimpleDialog.askinteger with a standard IDLE query dialog. The new box checks for positivity before returning.
* bpo-39885: IDLE context menu clears selection (#18859)Terry Jan Reedy2020-03-081-0/+1
| | | | | Since clicking to get an IDLE context menu moves the cursor, any text selection should be and now is cleared.
* bpo-39852: IDLE 'Go to line' deletes selection, updates status (GH-18801)Terry Jan Reedy2020-03-081-1/+4
| | | | | | It appears standard that moving the text insert cursor away from a selection clears the selection. Clearing prevents accidental deletion of a possibly off-screen bit of text. The update is for Ln and Col on the status bar.
* bpo-38792: Remove IDLE shell calltip before new prompt. (#17150)Zackery Spytz2020-01-311-1/+1
| | | | | | | Previously, a calltip might be left after SyntaxError, KeyboardInterrupt, or Shell Restart. Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu> Co-authored-by: Tal Einat <taleinat+github@gmail.com>
* bpo-32989: IDLE - fix bad editor call of pyparse method (GH-5968)Cheryl Sabella2020-01-211-21/+34
| | | | | | | | Fix comments and add tests for editor newline_and_indent_event method. Remove unused None default for function parameter of pyparse find_good_parse_start method and code triggered by that default. Co-authored-by: Terry Jan Reedy <tjreedy@udel.edu>
* bpo-38636: Fix IDLE tab toggle and file indent width (GH-17008)Terry Jan Reedy2019-11-201-2/+3
| | | | | These Format menu functions (default shortcuts Alt-T and Alt-U) were mistakenly disabled in 3.7.5 and 3.8.0.
* bpo-4630: Add cursor no-blink option for IDLE (GH-16960)Zackery Spytz2019-11-131-0/+16
| | | This immediately toggles shell, editor, and output windows, but does not affect other input widgets.
* bpo-13153: Use OS native encoding for converting between Python and Tcl. ↵Serhiy Storchaka2019-10-041-26/+3
| | | | | | | | | | | | | (GH-16545) On Windows use UTF-16 (or UTF-32 for 32-bit Tcl_UniChar) with the "surrogatepass" error handler for converting to/from Tcl Unicode objects. On Linux use UTF-8 with the "surrogateescape" error handler for converting to/from Tcl String objects. Converting strings from Tcl to Python and back now never fails (except MemoryError).
* bpo-35379: When exiting IDLE, catch any AttributeError. (GH-16212)Terry Jan Reedy2019-09-171-4/+7
| | | | | One happens when EditorWindow.close is called twice. Printing a traceback, when IDLE is run from a terminal, is useless and annoying.
* bpo-38183: Test_idle ignores user config directory GH-16198)Terry Jan Reedy2019-09-161-16/+18
| | | | | It no longer tries to create or access .idlerc or any files within. Users must run IDLE to discover problems with saving settings.
* bpo-37902: IDLE: Add scrolling for IDLE browsers. (#15368)GeeTransit2019-09-051-20/+5
| | | | Modify the wheel event handler so it can also be used for module, path, and stack browsers. Patch by George Zhang.
* bpo-37929: IDLE: avoid Squeezer-related config dialog crashes (GH-15452)Tal Einat2019-08-251-3/+22
| | | | | | | | | These were caused by keeping around a reference to the Squeezer instance and calling it's load_font() upon config changes, which sometimes happened even if the shell window no longer existed. This change completely removes that mechanism, instead having the editor window properly update its width attribute, which can then be used by Squeezer.
* bpo-29446: IDLE -- add explicit imports (GH-14919)Terry Jan Reedy2019-07-231-0/+2
| | | Stop depending on tkinter import *.
* bpo-17535: IDLE editor line numbers (GH-14030)Tal Einat2019-07-231-13/+49
|
* bpo-36390: Gather IDLE Format menu functions into format.py (#14827)Terry Jan Reedy2019-07-181-30/+4
| | | | | | Add two indent spec methods from editor and Rstrip to existing file. Tests are not added for indent methods because they need change in lights of 3.x's prohibition on mixing tabs and spaces.
* bpo-36390: IDLE: Combine region formatting methods. (GH-12481)Cheryl Sabella2019-07-171-111/+10
| | | | | Rename paragraph.py to format.py and add region formatting methods from editor.py. Add tests for the latter.
* bpo-37530: simplify, optimize and clean up IDLE code context (GH-14675)Tal Einat2019-07-171-3/+16
| | | | | | | | | | | * Only create CodeContext instances for "real" editors windows, but not e.g. shell or output windows. * Remove configuration update Tk event fired every second, by having the editor window ask its code context widget to update when necessary, i.e. upon font or highlighting updates. * When code context isn't being shown, avoid having a Tk event fired every 100ms to check whether the code context needs to be updated. * Use the editor window's getlineno() method where applicable. * Update font of the code context widget before the main text widget
* bpo-36390: simplify classifyws(), rename it and add unit tests (GH-14500)Tal Einat2019-07-111-23/+16
|
* bpo-5680: IDLE: Customize running a module (GH-13763)Cheryl Sabella2019-06-181-0/+1
| | | The initialize options are 1) add command line options, which are appended to sys.argv as if passed on a real command line, and 2) skip the shell restart. The customization dialog is accessed by a new entry on the Run menu.
* IDLE: Fix typos in docs and comments (GH-13749)Xtreak2019-06-031-1/+1
|
* bpo-35610: IDLE - Replace .context_use_ps1 with .prompt_last_line (GH-11307)Cheryl Sabella2019-06-021-6/+1
| | | | Changes in bpo- 31858 made the less informative 'context_use_ps1' redundant.
* bpo-36152: IDLE: Remove unused parameter from colorizer (GH-12109)Cheryl Sabella2019-03-011-1/+1
| | | | Remove colorizer.ColorDelegator.close_when_done and the corresponding argument of .close(). In IDLE, both have always been None or False since 2007.
* bpo-35769: Change IDLE's name for new files from 'Untitled' to 'untitled' ↵Terry Jan Reedy2019-01-181-2/+2
| | | | | (GH-11602) 'Untitled' violates the PEP 8 standard for .py files
* bpo-35196: Optimize Squeezer's write() interception (GH-10454)Tal Einat2019-01-131-3/+0
| | | | The new functionality of Squeezer.reload() is also tested, along with some general re-working of the tests in test_squeezer.py.
* IDLE: Create function to update menu item state. (GH-11343)Cheryl Sabella2018-12-281-1/+6
| | | | This will be needed for other menu items. Change outwin to call the function instead of updating the menu item directly.
* bpo-22703: IDLE: Improve Code Context and Zoom Height menu labels (GH-11214)Cheryl Sabella2018-12-221-0/+5
| | | | | | | | The Code Context menu label now toggles between Show/Hide Code Context. The Zoom Height menu now toggles between Zoom/Restore Height. Zoom Height has moved from the Window menu to the Options menu. https://bugs.python.org/issue22703
* bpo-1529353: IDLE: squeeze large output in the shell (GH-7626)Tal Einat2018-09-251-3/+4
|
* bpo-34047: IDLE: fix mousewheel scrolling direction on macOS (GH-8678)Tal Einat2018-08-101-6/+17
|
* bpo-33924: Change IDLE mainmenu.menudefs key 'windows' to 'window' (GH-7836)Terry Jan Reedy2018-06-211-3/+3
| | | | | Every other menudef key is the lowercase version of the corresponding main menu entry (in this case, 'Window').
* bpo-33906: Rename idlelib.windows as window (#7833)Terry Jan Reedy2018-06-211-7/+7
| | | | Match Window on the main menu and remove last plural module name. Change imports, test, and attribute references to match new name.
* bpo-33904: In IDLE's rstrip, rename class RstripExtension as Rstrip (GH-7811)Srinivas Reddy Thatiparthy (శ్రీనివాస్ రెడ్డి తాటిపర్తి)2018-06-201-2/+2
|
* bpo-33907: Rename an IDLE module and class. (GH-7807)Terry Jan Reedy2018-06-201-6/+6
| | | | Improve consistency and appearance. Module idlelib.calltips is now calltip. Class idlelib.calltip_w.CallTip is now Calltip.
* bpo-33855: Minimally test all IDLE modules. (GH-7689)Terry Jan Reedy2018-06-151-2/+2
| | | | Create a template for minimally testing a tkinter-using module by importing it and instantiating its class(es). Add a test file for all non-startup IDLE modules. Edit existing files and update coverage. This is part 1 of 3, covering the 21 autocomplete to help modules and touching 33 idlelib files.