Tryag File Manager
Home
-
Turbo Force
Current Path :
/
proc
/
self
/
root
/
usr
/
lib
/
python2.4
/
idlelib
/
Upload File :
New :
File
Dir
//proc/self/root/usr/lib/python2.4/idlelib/ParenMatch.pyc
mò ‚=5Dc @ sb d Z d k Z d k l Z l Z d k l Z d f d „ ƒ YZ d „ Z d f d „ ƒ YZ d S( sæ ParenMatch -- An IDLE extension for parenthesis matching. When you hit a right paren, the cursor should move briefly to the left paren. Paren here is used generically; the matching applies to parentheses, square brackets, and curly braces. WARNING: This extension will fight with the CallTips extension, because they both are interested in the KeyRelease-parenright event. We'll have to fix IDLE to do something reasonable when two or more extensions what to capture the same event. N( s EditorWindows index2line( s idleConft ParenMatchc B sæ t Z d Z g Z e i d d d d d ƒZ e i d d d d d d d ƒZ e i e i ƒ d ƒ Z e i d d d d d d d ƒZ d „ Z d „ Z d „ Z e d „ Z d „ Z d „ Z d „ Z d „ Z d „ Z d „ Z RS( sÌ Highlight matching parentheses There are three supported style of paren matching, based loosely on the Emacs options. The style is select based on the HILITE_STYLE attribute; it can be changed used the set_style method. The supported styles are: default -- When a right paren is typed, highlight the matching left paren for 1/2 sec. expression -- When a right paren is typed, highlight the entire expression from the left paren to the right paren. TODO: - fix interaction with CallTips - extend IDLE with configuration dialog to change options - implement rest of Emacs highlight styles (see below) - print mismatch warning in IDLE status window Note: In Emacs, there are several styles of highlight where the matching paren is highlighted whenever the cursor is immediately to the right of a right paren. I don't know how to do that in Tk, so I haven't bothered. t extensionsR t stylet defaultt expressions flash-delayt typet intiô t hilitet bellt booli c C sJ | | _ | i | _ t | ƒ | _ d | _ d | _ | i | i ƒ d S( Ni ( t editwint selft textt LastOpenBracketFindert findert countert Nonet _restoret set_stylet STYLE( R R ( ( t( /usr/lib/python2.4/idlelib/ParenMatch.pyt __init__5 s c C s_ | | _ | d j o | i | _ | i | _ n* | d j o | i | _ | i | _ n d S( NR R ( R R R t create_tag_defaultt create_tagt set_timeout_lastt set_timeoutt create_tag_expressiont set_timeout_none( R R ( ( R R = s c C s^ | i i t | i ƒ ƒ } | d j o | i ƒ d Sn d | _ | i | ƒ | i ƒ d S( Ni ( R R t findt keysym_typet eventt keysymt indexR t warn_mismatchedR R R ( R R R ( ( R t flash_open_paren_eventF s c C s+ | i o | i i d ƒ d | _ n d S( Nt paren( R R R t tag_deleteR ( R R ( ( R t check_restore_eventO s c C s&