Commit Graph

6703 Commits

Author SHA1 Message Date
Kurt B. Kaiser b976419946 Fix bug I created during merge from Python-idle.
Also, decided IDENTCHARS is better as global, after all.
2002-09-23 04:10:37 +00:00
Tony Lownds e49dd4c64b Blank line missing. 2002-09-23 01:11:57 +00:00
Tony Lownds 8b1b8d62a2 Work around Mac OS X transient window issues 2002-09-23 01:04:05 +00:00
Tony Lownds e555fc76a7 Work around Mac OS X platform encoding issues. 2002-09-23 01:01:20 +00:00
Tony Lownds f18efa5643 Added new standard keybinding set for Macs. 2002-09-23 00:57:10 +00:00
Martin v. Löwis 73b9b6679e Update Canvas before computing width. Draw turtle at end of drawing circle.
Fixes #612595. Will backport to 2.2.
2002-09-22 13:00:26 +00:00
Martin v. Löwis a6026c6a0f Back out multifile.py 1.19 and 1.20. Fixes #514676. 2002-09-22 09:01:08 +00:00
Jeremy Hylton f0cfdf7314 Fiddle comments and variable names in whichmodule(). 2002-09-19 23:00:12 +00:00
Jeremy Hylton 065a5ab8fb whichmodule() should skip dummy package entries in sys.modules.
This fixes the charming, but unhelpful error message for
>>> pickle.dumps(type.__new__)
Can't pickle <built-in method __new__ of type object at 0x812a440>: it's not the same object as datetime.math.__new__

Bugfix candidate.
2002-09-19 22:57:26 +00:00
Kurt B. Kaiser 16849a7e53 SF Bug #611225.
Bring idle.pyw into alignment with idle.py, eliminate calling deleted
module IdleConf.py
2002-09-19 19:54:55 +00:00
Marc-André Lemburg 7ccd30fa43 Fix a problem in site.py which triggers in case sys.path is empty.
Bugfix candidate for 2.2.2.
2002-09-19 11:11:27 +00:00
Martin v. Löwis 01824bf50c Patch #484994: Improve PanedWindow. 2002-09-19 08:12:55 +00:00
Guido van Rossum c34c4fc3ab Suppress hex/oct constant warnings in <string> on 64-bit platforms,
because there test_grammar.py pulls them out of strings there.
2002-09-19 00:42:16 +00:00
Barry Warsaw 40363b63f0 Open the test files in binary mode so the \r\n files won't cause
failures on Windows.  Closes SF bug # 609988.
2002-09-18 22:17:57 +00:00
Kurt B. Kaiser f027eac92b Merge Py Idle:
Removing config-mac.txt, not used in Idlefork
2002-09-18 17:30:36 +00:00
Kurt B. Kaiser 628339807e Merge Py Idle changes:
Missed adding "import types" while merging PyShell by hand....
2002-09-18 17:07:05 +00:00
Kurt B. Kaiser 5fab9c67eb Merge Py Idle changes:
Rev 1.4 fdrake
Use string.ascii_letters instead of string.letters (SF bug #226706)

Rev 1.5 doerwalter
(string methods)
2002-09-18 03:30:12 +00:00
Kurt B. Kaiser 2a5e350265 Merge Py Idle changes:
Rev 1.6 GvR
Finally fix SF bug #441172, using a variant of patch ##443626:
canceling an edit operation would not revert the value of the field.
The fix takes care to destroy the Entry object, as suggested in the
patch.

Rev 1.7 Geiger Ho / GvR
(previously applied - Idlefork Rev 1.3)

Rev 1.8 doerwalter
(string methods)
2002-09-18 03:26:47 +00:00
Kurt B. Kaiser 089a64a749 Merge Py Idle changes:
Rev 1.3 nnorwitz
Remove unnecessary imports
2002-09-18 03:17:38 +00:00
Kurt B. Kaiser 7879ad0c4f Merge Py Idle changes:
Rev 1.17 doerwalter
(string methods)
2002-09-18 03:15:56 +00:00
Kurt B. Kaiser d1ec940ffc Merge PyIdle changes:
Rev 1.3 doerwalter
(string methods)
2002-09-18 03:14:11 +00:00
Kurt B. Kaiser 06a0987fa8 Merge Py Idle changes:
Rev 1.2 doerwalter
(string methods)
2002-09-18 03:12:18 +00:00
Kurt B. Kaiser 0f4402dcf7 Merge Py Idle changes:
Rev 1.3 tim_one
Convert a pile of obvious "yes/no" functions to return bool.
2002-09-18 03:10:10 +00:00
Kurt B. Kaiser 05bab1ee93 Merge Py Idle changes:
Rev 1.11 GvR
Fix for SF bug #448835.

Fix this to work with the new (still undocumented) tabnanny API.

I'm afraid Stephen will have to add this fix to the IDLE fork code
base as well.

Rev 1.12 rhettinger
(skip, done differently in Idlefork)

Rev 1.13 time_one
(skip, NA)
2002-09-18 03:05:19 +00:00
Kurt B. Kaiser ce86b10eb8 Merge Py Idle changes:
Rev 1.5 tim_one
Convert a pile of obvious "yes/no" functions to return bool

Rev 1.6 GvR
Rev 1.7 Gvr
(Already merged Idlefork ReplaceDialog.py 1.3.2.1 and 1.4)

Rev 1.8 doerwalter
(string methods)

Rev 1.9 nnorwitz
Remove unnecessary imports
2002-09-18 02:56:10 +00:00
Kurt B. Kaiser 837d15c5b5 Merge Py Idle changes:
Rev 1.35 fdrake
Use string.ascii_letters instead of string.letters (SF bug #226706).
Move computation of sets of characters out of the body of the function
that uses them.

Rev 1.36 tim_one
Convert a pile of obvious "yes/no" functions to return bool

Rev 1.37
(skip, done differently in Idlefork)

Rev 1.38 loewis
Patch #590913: PEP 263 support.

Rev 1.39 loewis
Convert characters from the locale's encoding on output.
Reject characters outside the locale's encoding on input.

Rev 1.40 doerwalter
(string methods)

Rev 1.41
(skipped, done by GvR in rpc)
2002-09-18 02:29:59 +00:00
Fred Drake d679e09970 write(): Special case the common situation of a stream that's only
being used to dump output (no seeks), so we can avoid a lot
          of extra checks being made.
2002-09-17 18:10:34 +00:00
Kurt B. Kaiser 254eb5380f Merge Py Idle changes:
Rev 1.10 doerwalter
(string methods)
2002-09-17 03:55:13 +00:00
Kurt B. Kaiser d8e20a0e6b Merge Py Idle changes:
Rev 1.6 doerwalter
(string methods)
2002-09-17 03:43:38 +00:00
Kurt B. Kaiser 7827e1707c Merge Py Idle changes:
Rev 1.7 loewis
Convert characters from the locale's encoding on output.
Reject characters outside the locale's encoding on input.
2002-09-17 03:40:47 +00:00
Kurt B. Kaiser 33931ef1a6 Merge Py Idle changes:
Rev 1.4 tim_one
Convert a pile of obvious "yes/no" functions to return bool
2002-09-16 22:16:05 +00:00
Kurt B. Kaiser 6b06f29d09 Merge Py Idle changes:
Rev 1.5  doerwalter
string methods
2002-09-16 22:09:19 +00:00
Kurt B. Kaiser 01166da85a Merge Py Idle changes:
Rev 1.5 tim_one
Convert a pile of obvious "yes/no" functions to return bool.

Rev 1.6 gvanrossum
(partially merged previously, move line outside try: block)

Provisional fix for writefile() [SF bug # 541730].

The problem was that an exception can occur in the text.get() call or
in the write() call, when the text buffer contains non-ASCII
characters.  This causes the previous contents of the file to be lost.

The provisional fix is to call str(self.text.get(...)) *before*
opening the file, so that if the exception occurs, we never open the
file.

Two orthogonal better solutions have to wait for policy decisions:

1. We could try to encode the data as Latin-1 or as UTF-8; but that
   would require IDLE to grow a notion of file encoding which requires
   more thought.

2. We could make backups before overwriting a file.  This requires
   more thought because it needs to be fast and cross-platform and
   configurable.

Rev 1.7 gvanrossum
(previously merged with modifications by Stephen M. Gava)

Add primitive printing support for Unix and Windows.

Rev 1.8 loewis
Patch #590913: PEP 263 support.

Rev 1.9 gvanrossum
(tempfile.py interface -- deferred)

Rev 1.10 tim_one
whitespace normalization

Rev 1.11 nnorwitz
(deferred pending 1.9 integration)
2002-09-16 22:03:37 +00:00
Guido van Rossum 258cba8442 When recursively attempting to find the modules imported by an
"import" statement, catch and ignore all exceptions.  add/fix some
comments about this.
2002-09-16 16:36:02 +00:00
Kurt B. Kaiser f1fe145d20 Merge Py Idle changes:
Rev 1.4 (string methods)

Rev 1.5 Remove unnecessary imports
2002-09-16 02:25:26 +00:00
Kurt B. Kaiser 75e379020e Merge Py Idle changes:
Rev 1.10 (string methods)
2002-09-16 02:22:19 +00:00
Kurt B. Kaiser 220ecbc731 Merge Py Idle changes:
Rev 1.39 GvR
Properly fix SF bug #507298 (Gregor Lingl): shellpython2.2 -Qnew smart
indent error

Use // where int division is intended.  (This breaks IDLE for use with
previous Python versions -- I don't care.)

Rev 1.40 tim_one
Convert a pile of obvious "yes/no" functions to return bool.

Rev 1.41 foffani/loewis
(already merged)  - MS html help

Rev 1.42
(skip, done differently in Idlefork)

Rev 1.43 tzot/rhettinger
Extended IDLE's open module menu item to handle hierarchical module names.
Will look at doing something similar in import.c so that the effort won't
have to be repeated elsewhere.
Closes SF patch 600152.

Rev 1.44 doerwalter
(string methods)
2002-09-16 02:13:15 +00:00
Guido van Rossum c0a0e0810b Since it tests both ntohl and ntohs, the test should not be called
testNtoHL but testNtoH.
2002-09-16 01:30:03 +00:00
Kurt B. Kaiser aae2094991 Merge Py Idle changes
Rev 1.16
(skip. The Edward K. Ream breakpoint fix has been added to bdb.py
and idlefork Debugger.py no longer overrides Bdb.set_break() )

Rev 1.17
Remove unnecessary imports
2002-09-16 01:06:52 +00:00
Kurt B. Kaiser a287644204 Merge Py Idle changes
Rev 1.13 (string methods)
2002-09-15 22:09:16 +00:00
Kurt B. Kaiser 908aece9f7 Merge Py Idle changes
Rev 1.9
Improve handling of docstrings.  I had feared this was a case of
introspection incompatibility, but in fact it's just that calltips
always gave up on a docstring that started with a newline (but
didn't realize they were giving up <wink>).

Rev 1.10
(already merged)

Rev 1.11
(whitespace normalization, skip this time)

Rev 1.12
Remove unnecessary imports
2002-09-15 22:02:58 +00:00
Kurt B. Kaiser e72f05d5fb Merge Py Idle changes
Rev 1.4
SF bug 546078:  IDLE calltips cause application error.
Assorted crashes on Windows and Linux when trying to display a very
long calltip, most likely a Tk bug.  Wormed around by clamping the
calltip display to a maximum of 79 characters (why 79? why not ...).

Bugfix candidate, for all Python releases.

Rev 1.5
Remove unnecessary imports
2002-09-15 21:43:13 +00:00
Kurt B. Kaiser c209b3dab5 Merge Py Idle's Rev 1.16 (string methods) 2002-09-15 21:38:20 +00:00
Kurt B. Kaiser 1b3c26998e Merge Py Idle's changes to AutoIndent.py into EditorWindow.py since
EditorWindow has incorporated AutoIndent

Rev 1.17
classifyws():  Fix a "/" to work under -Qnew (as well as without it).
Bugfix candidate!

Rev 1.18
(Already merged)

Rev 1.19
smart_backspace_event():  remove now-pointless int() call.
Bugfix candidate:  the current state of AutoIdent.py should be in 2.2.1.

Rev 1.20
Apply diff2.txt from SF patch http://www.python.org/sf/572113
(with one small bugfix in bgen/bgen/scantools.py)
This replaces string module functions with string methods
for the stuff in the Tools directory. Several uses of
string.letters etc. are still remaining.
2002-09-15 21:31:30 +00:00
Kurt B. Kaiser 87807a66c4 Merge Py Idle's Rev 1.5
Use string.ascii_letters instead of string.letters (SF bug #226706)
2002-09-15 20:50:02 +00:00
Guido van Rossum 7f7c3d0a9c Address SF bug #577530: del __builtins__ breaks out of rexec
Using the suggestion there: add_module() forces __builtin__ back; this
fixes r_exec, r_eval, r_execfile.  The interactive console had to be
fixed separately, because it doesn't use r_exec, but relies on the
'locals' dict having the right __builtins__.  Fixed this by
subclassing InteractiveConsole and overriding runcode(), which does
the exec.  This changes the banner output slightly: instead of
starting with *** RESTRICTED ***, a subtler (RestrictedConsole) is
printed before the first >>> prompt.

Also import readline (if it exists) when the interactive console is
used, for more convenient input editing and history.

This does not mean that rexec is now considered safe!  But for those
willing to take the risk, it's safer than before.  (Note that a safety
analysis of the code module would be wise if you plan to use the
interactive console for real -- I've only ever used it to play with
restricted mode.)

This should be backported to 2.2 and 2.1.
2002-09-15 06:00:43 +00:00
Kurt B. Kaiser ad2bf5cb44 Initial revision 2002-09-14 23:25:29 +00:00
Martin v. Löwis 1ce4ae3268 Don't test whether surrogate sequences round-trip in UTF-8. 2.2.2 candidate. 2002-09-14 09:19:53 +00:00
Martin v. Löwis 766e300eaa Use integer above sys.maxunicode for range test. Fixes #608884.
2.2.2 candidate.
2002-09-14 09:10:04 +00:00
Kurt B. Kaiser 6622eecdaa Bump to reflect final cleanup of Config system and first pass GRPC
completed
2002-09-14 04:24:43 +00:00