This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Title: ParenMatch: workaround for misinterpreting of closing parens
Type: Stage:
Components: IDLE Versions: Python 2.5
Status: closed Resolution: accepted
Dependencies: Superseder:
Assigned To: kbk Nosy List: kbk, taleinat
Priority: normal Keywords: patch

Created on 2006-01-16 11:58 by taleinat, last changed 2022-04-11 14:56 by admin. This issue is now closed.

File name Uploaded Description Edit
ParenMatch_keysym_workaround.patch taleinat, 2006-01-16 11:58 Initial patch
Messages (2)
msg49328 - (view) Author: Tal Einat (taleinat) * (Python committer) Date: 2006-01-16 11:58
ParenMatch sometimes misinterprets closing parenthesis
because it is given a bad keysym. The real bug is
probably somewhere in the event handling mechanism or

Somehow the text widget gets the right signal and the
appropriate closing paren is written there.

This simple patch checks the last inserted character in
the text widget insted of the generated keysym, and
acts accordingly.

Since the function where the workaround is applied
reads text from the text widget from the same index
anyways, I think this workaround is actually much
cleaner than checking the keysym!

Works like a charm on my Python2.4 WinXP installation.
msg49329 - (view) Author: Kurt B. Kaiser (kbk) * (Python committer) Date: 2006-07-20 22:23
Logged In: YES 

Rev 50739.  Thanks for the patch!
Date User Action Args
2022-04-11 14:56:15adminsetgithub: 42800
2006-01-16 11:58:35taleinatcreate