__  __    __   __  _____      _            _          _____ _          _ _ 
 |  \/  |   \ \ / / |  __ \    (_)          | |        / ____| |        | | |
 | \  / |_ __\ V /  | |__) | __ ___   ____ _| |_ ___  | (___ | |__   ___| | |
 | |\/| | '__|> <   |  ___/ '__| \ \ / / _` | __/ _ \  \___ \| '_ \ / _ \ | |
 | |  | | |_ / . \  | |   | |  | |\ V / (_| | ||  __/  ____) | | | |  __/ | |
 |_|  |_|_(_)_/ \_\ |_|   |_|  |_| \_/ \__,_|\__\___| |_____/|_| |_|\___V 2.1
 if you need WebShell for Seo everyday contact me on Telegram
 Telegram Address : @jackleet
        
        
For_More_Tools: Telegram: @jackleet | Bulk Smtp support mail sender | Business Mail Collector | Mail Bouncer All Mail | Bulk Office Mail Validator | Html Letter private



Upload:

Command:

aptanhua@216.73.217.122: ~ $
3

� f�(�@s�dZddlZddlmZddlZddlmZmZm	Z	ddl
mZdddd	d
ddd
ddddhZdZ
dZejd�fdd�Zdd�ZGdd�d�Zej�edkr�ddlmZedddd �dS)!a<codecontext - display the block context above the edit window

Once code has scrolled off the top of a window, it can be difficult to
determine which block you are in.  This extension implements a pane at the top
of each IDLE edit window which provides block structure hints.  These hints are
the lines which contain the block opening keywords, e.g. 'if', for the
enclosing block.  The number of hint lines is determined by the maxlines
variable in the codecontext section of config-extensions.def. Lines which do
not open blocks are not shown in the context hints pane.

�N)�maxsize)�TOP�X�SUNKEN)�idleConf�class�def�elif�else�except�finally�for�if�try�while�with�async�di�z^(\s*)(\w*)cCs|j|�j�S)z>Extract the beginning whitespace and first word from codeline.)�match�groups)�codeline�c�r�8/opt/alt/python36/lib64/python3.6/idlelib/codecontext.py�get_spaces_firstwordsrcCsFt|�\}}t|�}t|�|ks,||dkr0t}|tko:|}|||fS)z�Return tuple of (line indent value, codeline, block start keyword).

    The indentation of empty lines (or comment lines) is INFINITY.
    If the line does not start a block, the keyword value is False.
    �#)r�len�INFINITY�BLOCKOPENERS)rZspacesZ	firstword�indent�openerrrr�
get_line_infosr!c@sbeZdZdZdd�Zedd��Zdd�Zdd	d
�Zdd
d�Z	dd�Z
ddd�Zdd�Zdd�Z
dS)�CodeContextz,Display block context above the edit window.cCs^||_|j|_|jd|_tj|_d|_d|_dg|_|jj	t
|j�|_|jj	t
|j�|_dS)	a>Initialize settings for context block.

        editwin is the Editor window for the context block.
        self.text is the editor window text widget.
        self.textfont is the editor window font.

        self.context displays the code context text above the editor text.
          Initially None, it is toggled via <<toggle-code-context>>.
        self.topvisible is the number of the top text line displayed.
        self.info is a list of (line number, indent level, line text,
          block keyword) tuples for the block structure above topvisible.
          self.info[0] is initialized with a 'dummy' line which
          starts the toplevel 'block' of the module.

        self.t1 and self.t2 are two timer events on the editor text widget to
          monitor for changes to the context text or editor font.
        �fontN�r�F���)rr&r%F)�editwin�text�textfontr"�colors�
contextcolors�context�
topvisible�info�after�UPDATEINTERVAL�timer_event�t1�CONFIGUPDATEINTERVAL�config_timer_event�t2)�selfr'rrr�__init__0szCodeContext.__init__cCs,tjdddddd�|_tjtj�d�|_dS)	z!Load class variables from config.�
extensionsr"Zmaxlines�int�)�type�defaultr,N)rZ	GetOption�
context_depthZGetHighlightZCurrentThemer*)�clsrrr�reloadMszCodeContext.reloadc	Cs2y |jj|j�|jj|j�WnYnXdS)zCancel scheduled events.N)r(Zafter_cancelr2r5)r6rrr�__del__Ts
zCodeContext.__del__NcCs�|js�|jj|jjf}d}d}xP|D]H}||jj|j�d�7}||jj|jd��7}||jj|jd��7}q$Wtj	|jj
|j|jd|jddd||t
dd�
|_|jjd	|j�|jjttd
|jjd�n|jj�d|_d
S)aToggle code context display.

        If self.context doesn't exist, create it to match the size of the editor
        window text (toggle on).  If it does exist, destroy it (toggle off).
        Return 'break' to complete the processing of the binding.
        r�padx�border�
background�
foregroundr$�disabled)	r#ZbgZfg�height�widthrArBZrelief�statez<ButtonRelease-1>F)ZsideZfill�expandZbeforeN�break)r,r'r(Z
text_frameZtkZgetintZ	pack_infoZcget�tkinterZText�topr)r+rZbind�
jumptolineZpackrrZdestroy)r6�eventZwidgetsrArBZwidgetrrr�toggle_code_context_event\s*


z%CodeContext.toggle_code_context_eventr$rcCs�|dkst�g}t}x�t||dd�D]x}|jj|�d�|�d��}t|�\}}	}
||kr&|}|
dkrn|d7}|
r�||kr�||kr�|j|||	|
f�||kr&Pq&W|j�||fS)	azReturn a list of block line tuples and the 'last' indent.

        The tuple fields are (linenum, indent, text, opener).
        The list represents header lines from new_topvisible back to
        stopline with successively shorter indents > stopindent.
        The list is returned ordered by line number.
        Last indent returned is the smallest indent observed.
        rr$z.0z.endr
r	r&)r
r	)�AssertionErrorr�ranger(�getr!�append�reverse)r6�new_topvisibleZstopline�
stopindent�lines�
lastindentZlinenumrrr(r rrr�get_context�s 	zCodeContext.get_contextcCsZt|jjd�jd�d�}|j|kr(dS|j|krf|j||j�\}}x�|jdd|krb|jd=qFWn`|jddd}x,|jdd|kr�|jdd}|jd=qzW|j||jddd|�\}}|jj|�||_dd�|j|jd�D�}|d�rdnd}t	|�||j
d<d	|j
d
<|j
jdd�|j
jdd
j
||d���d|j
d
<dS)aLUpdate context information and lines visible in the context pane.

        No update is done if the text hasn't been scrolled.  If the text
        was scrolled, the lines that should be shown in the context will
        be retrieved and the context area will be updated with the code,
        up to the number of maxlines.
        z@0,0�.rNr$cSsg|]}|d�qS)�r)�.0�xrrr�
<listcomp>�sz3CodeContext.update_code_context.<locals>.<listcomp>rFZnormalrHz1.0�end�
rEr&r&r&r&r&r&r&)r9r(�index�splitr-rYr.�extendr=rr,�delete�insert�join)r6rUrWrXrVZcontext_stringsZ	showfirstrrr�update_code_context�s0



zCodeContext.update_code_contextcCspt|j�}|dkrd}n:tt|jjd���}td||j�d}|j||d}|jj	|�d��|j
�dS)z+Show clicked context line at top of editor.r$rerz.0N)rr.r9�floatr,ra�maxr=r(Zyviewrg)r6rNrWZnewtopZcontextline�offsetrrrrM�s
zCodeContext.jumptolinecCs$|jr|j�|jjt|j�|_dS)z>Event on editor text widget triggered every UPDATEINTERVAL ms.N)r,rgr(r/r0r1r2)r6rrrr1�szCodeContext.timer_eventcCsv|jd}|jr`||jks&tj|jkr`||_tj|_|j|jd<|jd|jd<|jd|jd<|jjt|j�|_	dS)zDEvent on editor text widget triggered every CONFIGUPDATEINTERVAL ms.r#rCrDN)
r(r,r)r"r*r+r/r3r4r5)r6Znewtextfontrrrr4�s
zCodeContext.config_timer_event)N)r$r)N)�__name__�
__module__�__qualname__�__doc__r7�classmethodr?r@rOrYrgrMr1r4rrrrr"-s
&
(
r"�__main__)�mainz"idlelib.idle_test.test_codecontextr[F)�	verbosity�exit)rn�re�sysrrrKZtkinter.constantsrrrZidlelib.configrrr0r3�compilerr!r"r?rkZunittestrqrrrr�<module>s"=

Filemanager

Name Type Size Permission Actions
__init__.cpython-36.opt-1.pyc File 509 B 0644
__init__.cpython-36.opt-2.pyc File 139 B 0644
__init__.cpython-36.pyc File 509 B 0644
__main__.cpython-36.opt-1.pyc File 270 B 0644
__main__.cpython-36.opt-2.pyc File 191 B 0644
__main__.cpython-36.pyc File 270 B 0644
_pyclbr.cpython-36.opt-1.pyc File 10.18 KB 0644
_pyclbr.cpython-36.opt-2.pyc File 6.65 KB 0644
_pyclbr.cpython-36.pyc File 10.18 KB 0644
autocomplete.cpython-36.opt-1.pyc File 7.02 KB 0644
autocomplete.cpython-36.opt-2.pyc File 5.43 KB 0644
autocomplete.cpython-36.pyc File 7.02 KB 0644
autocomplete_w.cpython-36.opt-1.pyc File 10.81 KB 0644
autocomplete_w.cpython-36.opt-2.pyc File 10.07 KB 0644
autocomplete_w.cpython-36.pyc File 10.85 KB 0644
autoexpand.cpython-36.opt-1.pyc File 2.76 KB 0644
autoexpand.cpython-36.opt-2.pyc File 2.02 KB 0644
autoexpand.cpython-36.pyc File 2.76 KB 0644
browser.cpython-36.opt-1.pyc File 9.35 KB 0644
browser.cpython-36.opt-2.pyc File 6.82 KB 0644
browser.cpython-36.pyc File 9.35 KB 0644
calltip.cpython-36.opt-1.pyc File 5.48 KB 0644
calltip.cpython-36.opt-2.pyc File 3.89 KB 0644
calltip.cpython-36.pyc File 5.48 KB 0644
calltip_w.cpython-36.opt-1.pyc File 6.02 KB 0644
calltip_w.cpython-36.opt-2.pyc File 5.1 KB 0644
calltip_w.cpython-36.pyc File 6.02 KB 0644
codecontext.cpython-36.opt-1.pyc File 7.96 KB 0644
codecontext.cpython-36.opt-2.pyc File 5.04 KB 0644
codecontext.cpython-36.pyc File 7.99 KB 0644
colorizer.cpython-36.opt-1.pyc File 8.17 KB 0644
colorizer.cpython-36.opt-2.pyc File 8 KB 0644
colorizer.cpython-36.pyc File 8.17 KB 0644
config.cpython-36.opt-1.pyc File 29.79 KB 0644
config.cpython-36.opt-2.pyc File 19.85 KB 0644
config.cpython-36.pyc File 29.79 KB 0644
config_key.cpython-36.opt-1.pyc File 13.52 KB 0644
config_key.cpython-36.opt-2.pyc File 12.47 KB 0644
config_key.cpython-36.pyc File 13.52 KB 0644
configdialog.cpython-36.opt-1.pyc File 75.72 KB 0644
configdialog.cpython-36.opt-2.pyc File 46.64 KB 0644
configdialog.cpython-36.pyc File 75.72 KB 0644
debugger.cpython-36.opt-1.pyc File 13.89 KB 0644
debugger.cpython-36.opt-2.pyc File 13.73 KB 0644
debugger.cpython-36.pyc File 13.89 KB 0644
debugger_r.cpython-36.opt-1.pyc File 13.44 KB 0644
debugger_r.cpython-36.opt-2.pyc File 11.1 KB 0644
debugger_r.cpython-36.pyc File 13.57 KB 0644
debugobj.cpython-36.opt-1.pyc File 5.05 KB 0644
debugobj.cpython-36.opt-2.pyc File 5.04 KB 0644
debugobj.cpython-36.pyc File 5.05 KB 0644
debugobj_r.cpython-36.opt-1.pyc File 1.96 KB 0644
debugobj_r.cpython-36.opt-2.pyc File 1.95 KB 0644
debugobj_r.cpython-36.pyc File 1.96 KB 0644
delegator.cpython-36.opt-1.pyc File 1.25 KB 0644
delegator.cpython-36.opt-2.pyc File 1.14 KB 0644
delegator.cpython-36.pyc File 1.25 KB 0644
dynoption.cpython-36.opt-1.pyc File 2.23 KB 0644
dynoption.cpython-36.opt-2.pyc File 1.85 KB 0644
dynoption.cpython-36.pyc File 2.23 KB 0644
editor.cpython-36.opt-1.pyc File 47.29 KB 0644
editor.cpython-36.opt-2.pyc File 45.67 KB 0644
editor.cpython-36.pyc File 47.37 KB 0644
filelist.cpython-36.opt-1.pyc File 3.29 KB 0644
filelist.cpython-36.opt-2.pyc File 3.25 KB 0644
filelist.cpython-36.pyc File 3.32 KB 0644
grep.cpython-36.opt-1.pyc File 6.59 KB 0644
grep.cpython-36.opt-2.pyc File 4.79 KB 0644
grep.cpython-36.pyc File 6.59 KB 0644
help.cpython-36.opt-1.pyc File 10.05 KB 0644
help.cpython-36.opt-2.pyc File 7.37 KB 0644
help.cpython-36.pyc File 10.05 KB 0644
help_about.cpython-36.opt-1.pyc File 7.25 KB 0644
help_about.cpython-36.opt-2.pyc File 6.15 KB 0644
help_about.cpython-36.pyc File 7.25 KB 0644
history.cpython-36.opt-1.pyc File 3.32 KB 0644
history.cpython-36.opt-2.pyc File 2.11 KB 0644
history.cpython-36.pyc File 3.32 KB 0644
hyperparser.cpython-36.opt-1.pyc File 6.62 KB 0644
hyperparser.cpython-36.opt-2.pyc File 5.33 KB 0644
hyperparser.cpython-36.pyc File 6.62 KB 0644
idle.cpython-36.opt-1.pyc File 335 B 0644
idle.cpython-36.opt-2.pyc File 327 B 0644
idle.cpython-36.pyc File 335 B 0644
iomenu.cpython-36.opt-1.pyc File 13.45 KB 0644
iomenu.cpython-36.opt-2.pyc File 13.03 KB 0644
iomenu.cpython-36.pyc File 13.45 KB 0644
macosx.cpython-36.opt-1.pyc File 7.43 KB 0644
macosx.cpython-36.opt-2.pyc File 5.29 KB 0644
macosx.cpython-36.pyc File 7.43 KB 0644
mainmenu.cpython-36.opt-1.pyc File 3.72 KB 0644
mainmenu.cpython-36.opt-2.pyc File 3.25 KB 0644
mainmenu.cpython-36.pyc File 3.72 KB 0644
multicall.cpython-36.opt-1.pyc File 14.94 KB 0644
multicall.cpython-36.opt-2.pyc File 12.63 KB 0644
multicall.cpython-36.pyc File 15 KB 0644
outwin.cpython-36.opt-1.pyc File 5.98 KB 0644
outwin.cpython-36.opt-2.pyc File 4.32 KB 0644
outwin.cpython-36.pyc File 5.98 KB 0644
paragraph.cpython-36.opt-1.pyc File 5.8 KB 0644
paragraph.cpython-36.opt-2.pyc File 3.95 KB 0644
paragraph.cpython-36.pyc File 5.8 KB 0644
parenmatch.cpython-36.opt-1.pyc File 6.23 KB 0644
parenmatch.cpython-36.opt-2.pyc File 4.71 KB 0644
parenmatch.cpython-36.pyc File 6.23 KB 0644
pathbrowser.cpython-36.opt-1.pyc File 3.66 KB 0644
pathbrowser.cpython-36.opt-2.pyc File 3.51 KB 0644
pathbrowser.cpython-36.pyc File 3.66 KB 0644
percolator.cpython-36.opt-1.pyc File 3.43 KB 0644
percolator.cpython-36.opt-2.pyc File 3.42 KB 0644
percolator.cpython-36.pyc File 3.56 KB 0644
pyparse.cpython-36.opt-1.pyc File 11.4 KB 0644
pyparse.cpython-36.opt-2.pyc File 7.9 KB 0644
pyparse.cpython-36.pyc File 11.75 KB 0644
pyshell.cpython-36.opt-1.pyc File 41.73 KB 0644
pyshell.cpython-36.opt-2.pyc File 39.24 KB 0644
pyshell.cpython-36.pyc File 41.85 KB 0644
query.cpython-36.opt-1.pyc File 10.19 KB 0644
query.cpython-36.opt-2.pyc File 8.11 KB 0644
query.cpython-36.pyc File 10.19 KB 0644
redirector.cpython-36.opt-1.pyc File 6.6 KB 0644
redirector.cpython-36.opt-2.pyc File 3.24 KB 0644
redirector.cpython-36.pyc File 6.6 KB 0644
replace.cpython-36.opt-1.pyc File 6.92 KB 0644
replace.cpython-36.opt-2.pyc File 6.27 KB 0644
replace.cpython-36.pyc File 6.92 KB 0644
rpc.cpython-36.opt-1.pyc File 19.1 KB 0644
rpc.cpython-36.opt-2.pyc File 15.63 KB 0644
rpc.cpython-36.pyc File 19.18 KB 0644
rstrip.cpython-36.opt-1.pyc File 1.05 KB 0644
rstrip.cpython-36.opt-2.pyc File 990 B 0644
rstrip.cpython-36.pyc File 1.05 KB 0644
run.cpython-36.opt-1.pyc File 14.99 KB 0644
run.cpython-36.opt-2.pyc File 13 KB 0644
run.cpython-36.pyc File 15.03 KB 0644
runscript.cpython-36.opt-1.pyc File 6.33 KB 0644
runscript.cpython-36.opt-2.pyc File 5.15 KB 0644
runscript.cpython-36.pyc File 6.33 KB 0644
scrolledlist.cpython-36.opt-1.pyc File 5.26 KB 0644
scrolledlist.cpython-36.opt-2.pyc File 5.25 KB 0644
scrolledlist.cpython-36.pyc File 5.26 KB 0644
search.cpython-36.opt-1.pyc File 3.46 KB 0644
search.cpython-36.opt-2.pyc File 3.2 KB 0644
search.cpython-36.pyc File 3.46 KB 0644
searchbase.cpython-36.opt-1.pyc File 7.79 KB 0644
searchbase.cpython-36.opt-2.pyc File 5.09 KB 0644
searchbase.cpython-36.pyc File 7.79 KB 0644
searchengine.cpython-36.opt-1.pyc File 6.68 KB 0644
searchengine.cpython-36.opt-2.pyc File 5.06 KB 0644
searchengine.cpython-36.pyc File 6.68 KB 0644
squeezer.cpython-36.opt-1.pyc File 9.67 KB 0644
squeezer.cpython-36.opt-2.pyc File 6.56 KB 0644
squeezer.cpython-36.pyc File 9.71 KB 0644
stackviewer.cpython-36.opt-1.pyc File 4.94 KB 0644
stackviewer.cpython-36.opt-2.pyc File 4.93 KB 0644
stackviewer.cpython-36.pyc File 4.94 KB 0644
statusbar.cpython-36.opt-1.pyc File 1.9 KB 0644
statusbar.cpython-36.opt-2.pyc File 1.89 KB 0644
statusbar.cpython-36.pyc File 1.9 KB 0644
textview.cpython-36.opt-1.pyc File 6.29 KB 0644
textview.cpython-36.opt-2.pyc File 4.74 KB 0644
textview.cpython-36.pyc File 6.29 KB 0644
tooltip.cpython-36.opt-1.pyc File 6.41 KB 0644
tooltip.cpython-36.opt-2.pyc File 4.82 KB 0644
tooltip.cpython-36.pyc File 6.41 KB 0644
tree.cpython-36.opt-1.pyc File 13.94 KB 0644
tree.cpython-36.opt-2.pyc File 13.18 KB 0644
tree.cpython-36.pyc File 13.94 KB 0644
undo.cpython-36.opt-1.pyc File 10.53 KB 0644
undo.cpython-36.opt-2.pyc File 10.52 KB 0644
undo.cpython-36.pyc File 10.53 KB 0644
window.cpython-36.opt-1.pyc File 3.08 KB 0644
window.cpython-36.opt-2.pyc File 3.07 KB 0644
window.cpython-36.pyc File 3.08 KB 0644
zoomheight.cpython-36.opt-1.pyc File 1.37 KB 0644
zoomheight.cpython-36.opt-2.pyc File 1.31 KB 0644
zoomheight.cpython-36.pyc File 1.37 KB 0644
zzdummy.cpython-36.opt-1.pyc File 1.18 KB 0644
zzdummy.cpython-36.opt-2.pyc File 1.1 KB 0644
zzdummy.cpython-36.pyc File 1.18 KB 0644