Commit Graph

82 Commits

Author SHA1 Message Date
csabella 5b59154c0d bpo-30853: IDLE: Convert font and general vars to use VarTrace (#2914)
Instance tracers manages pairs consisting of a tk variable and a
callback function.  When tracing is turned on, setting the variable
calls the function.  Test coverage for the new class is 100%.
2017-07-28 14:40:59 -04:00
Terry Jan Reedy b1660800f4 bpo-31060: IDLE: Finish regrouping ConfigDialog methods (#2908)
Finish resorting the 72 ConfigDialog methods into 7 groups that represent the dialog, action buttons, and font, highlight, keys, general, and extension pages.  This will help with continuing to add tests and improve the pages. It will enable splitting ConfigDialog into 6 or 7 more comprehensible classes.
2017-07-27 18:28:01 -04:00
Terry Jan Reedy 2bc8f0e686 bpo-31003: IDLE - Add more tests for General tab (#2859)
* In configdialog: Document causal pathways in create_page_general.
Move related functions to follow this. Simplify some attribute names.
* In test_configdialog: Add tests for load and helplist functions.
Coverage for the general tab is now complete, and 63% overall.
2017-07-26 20:54:40 -04:00
csabella 45bf723c6c bpo-30853: IDLE: Factor a VarTrace class from configdialog.ConfigDialog. (#2872)
The new class manages pairs of tk Variables and trace callbacks.
It is completely covered by new tests.
2017-07-26 19:09:58 -04:00
Terry Jan Reedy 77e97ca9ff bpo-30993: IDLE - Improve configdialog font page and tests. (#2831)
In configdialog: Document causal pathways in create_font_tab docstring.  Simplify some attribute names. Move set_samples calls to var_changed_font (idea from Cheryl Sabella).  Move related functions to positions after the create widgets function.

In test_configdialog: Fix test_font_set so not order dependent.  Fix renamed test_indent_scale so it tests the widget.  Adjust tests for movement of set_samples call.  Add tests for load functions.  Put all font tests in one class and tab indent tests in another.  Except for two lines, these tests completely cover the related functions.
2017-07-24 00:18:25 -04:00
Terry Jan Reedy 07ba305a4c bpo-30993: IDLE - Improve configdialog font page and tests. (#2818)
* Document causal event pathways in docstring.
* Simplify some attribute names.
* Rename test_bold_toggle_set_samples to make test_font_set fail.
* Fix test_font_set so not order dependent.
* Fix renamed test_indent_scale so it tests the widget.
2017-07-23 12:20:08 -04:00
Terry Jan Reedy 616ecf18f3 bpo-30981: IDLE: Augment one configdialog font page test (#2810)
Remove broken test of bold_toggle and test it along with its command, set_samples.
This has been incorporated into 3.6 backport PR-2796.
2017-07-22 00:36:13 -04:00
Terry Jan Reedy 7c5798ebfa bpo-30981: temporarity skip failing IDLE test class (#2798) 2017-07-21 03:47:01 -04:00
Terry Jan Reedy d0969d6924 bpo-30981: IDLE -- Add more configdialog font page tests. (#2794) 2017-07-21 02:20:46 -04:00
Terry Jan Reedy a54a8f188a bpo-28523: IDLE: Use 'color' instead of 'colour'. (#2787) 2017-07-21 01:06:58 -04:00
csabella 36329a4dd8 bpo-30913: IDLE: Document tk vars, attributes, and methods for ConfigDialog (#2697)
The will help writing dialog improvements and splitting the class into multiple classes.
Original patch by Cheryl Sabella.
2017-07-13 23:32:01 -04:00
Louie Lu 9b622fb903 bpo-30870: IDLE: Add configdialog fontlist selection unittest (#2666)
Initial patch by Louie Lu.
2017-07-13 20:35:48 -04:00
csabella 6d13b22e3a bpo-30779: IDLE: fix changes.delete_section calls in configdialog (#2667)
Also improve test of config.ConfigChanges.delete_section.
Original patch by Cheryl Sabella.
2017-07-11 19:09:44 -04:00
terryjreedy 5b62b35e6f bpo-30870: IDLE -- fix logic error in eae2537. (#2660) 2017-07-11 01:58:04 -04:00
csabella aa8d0a2469 bpo-30851: IDLE: Remove unused tk variables in configdialog. (#2626)
One is a duplicate, one is set but cannot be altered by users.
Patch by Cheryl Sabella.
2017-07-10 13:50:44 -04:00
Louie Lu bb2bae84d6 bpo-30870: IDLE: Change sample font when select by key-up/down (#2617)
Patch by Louie Lu.
2017-07-09 18:57:18 -04:00
terryjreedy 349abd9e37 bpo-30779: IDLE -- Factor ConfigChanges class from configdialog, put in config; test. (#2612)
* In config, put dump test code in a function; run it and unittest in 'if __name__ == '__main__'.
* Add class config.ConfigChanges based on changes_class_v4.py on bpo issue.
* Add class test_config.ChangesTest, partly based on configdialog_tests_v1.py on bpo issue.
* Revise configdialog to use ConfigChanges, mostly as specified in tracker msg297804.
* Revise test_configdialog to match configdialog changes.  All tests pass in both files.
* Remove configdialog functions unused or moved to ConfigChanges.
Cheryl Sabella contributed parts of the patch.
2017-07-07 16:00:57 -04:00
csabella 7eb5883ac5 bpo-30777: IDLE: configdialog - add docstrings and improve comments (#2440)
Patch by Cheryl Sabella.
2017-07-04 21:30:58 -04:00
wohlganger fae2c3538e bpo-30723: IDLE -- Enhance parenmatch; add style, flash, and help (#2306)
* Add 'parens' style to highlight both opener and closer.
* Make 'default' style, which is not default, a synonym for 'opener'.
* Make time-delay work the same with all styles.
* Add help for config dialog extensions tab, including parenmatch.
* Add new tests. 
Original patch by Charles Wohlganger.
2017-06-27 22:36:23 -04:00
csabella bac7d3363b bpo-30728: IDLE: Refactor configdialog to PEP8 names (#2307)
Also, change '*' in the tkinter import to an explicit list of names.
Patch by Cheryl Sabella.
2017-06-26 17:46:26 -04:00
Terry Jan Reedy f46b7823e6 Issue #28572: Add 10% to coverage of IDLE's test_configdialog.
Update and augment description of the configuration system.
2016-11-07 17:15:01 -05:00
Terry Jan Reedy bfbaa6b206 Issue #27891: Consistently group and sort imports within idlelib modules. 2016-08-31 00:50:55 -04:00
Terry Jan Reedy da0288725f Issue #17642: add larger font sizes for classroom projection. 2016-08-30 20:19:13 -04:00
Terry Jan Reedy 9bdb1edf35 Issue #27173: Add 'IDLE Modern Unix' to the built-in key sets.
Make the default key set depend on the platform.
Add tests for changes to the config module.
2016-07-10 13:46:34 -04:00
Terry Jan Reedy 8b22c0aada Issue #27380: IDLE: add query.HelpSource class and tests.
Remove modules that are combined in new module.
2016-07-08 00:22:50 -04:00
Terry Jan Reedy 68a53c5d39 Issue #27380: IDLE: add base Query dialog, with ttk widgets and subclass
SectionName.  These split class GetCfgSectionNameDialog from
configSectionNameDialog.py, temporarily renamed config_sec.py in 3.7.9a2.
More Query subclasses are planned.
2016-06-26 22:05:10 -04:00
Serhiy Storchaka 8122174af1 Issue #22115: Added methods trace_add, trace_remove and trace_info in the
tkinter.Variable class.  They replace old methods trace_variable, trace,
trace_vdelete and trace_vinfo that use obsolete Tcl commands and might
not work in future versions of Tcl.
2016-06-26 09:46:57 +03:00
Terry Jan Reedy 5cd6ea44bf Issue #27245: revert temporary rename 2016-06-14 00:55:09 -04:00
Terry Jan Reedy cdd3a99106 Issue #27245: temporary rename for merge. 2016-06-14 00:53:30 -04:00
Terry Jan Reedy 01e35754fb Issue *24750: Switch all scrollbars in IDLE to ttk versions.
Where needed, add minimal tests to cover changes.
2016-06-10 18:19:21 -04:00
Terry Jan Reedy 6fa5bdc6e8 Issue #24225: Within idlelib files, update idlelib module names.
This follows the previous patch that changed idlelib file names.
Class names that matched old module names are not changed.
Change idlelib imports in turtledemo.__main__.

Exception: config-extensions.def.  Previously, extension section
names, file names, and class names had to match.  Changing section
names would create cross-version conflicts in config-extensions.cfg
(user customizations).  Instead map old names to new file names
at point of import in editor.EditorWindow.load_extension.

Patch extensively tested with test_idle, idle_test.htest.py, a custom
import-all test, running IDLE in a console to catch messages,
and testing each menu item.  Based on a patch by Al Sweigart.
2016-05-28 13:22:31 -04:00
Terry Jan Reedy 0d9220e162 Issue #24225: Rename many idlelib/*.py and idlelib/idle_test/test_*.py files. 2016-05-22 19:10:31 -04:00