+
     Bi                        ^ RI t ]R8X  d!   ] P                  R,          ] P                  R&    ^ RI5 ] P                  R8X  d   ^ RI	H
t
 ]
! 4        ^ R	IHt ^ R
IHt ^ RIt^ RIt^ RIt^ RIt^ RIHt ^ RIt^ RIt^ RIt^ RIHt ^ RIt^ RIt^ RIt^ RIt^ RIHt ^ RIHt ^ RI H!t! ^ RI"H#t# ^ RI"H$t$ ^ RI%H&t&H't' ^ RI(H)t) ^ RI*H+t+ ^ RI"H,t, ^ RI"H-t- ^ RI.H/t/H0t0H1t1 ^ RI2H3t3 Rs4Rt5^ t6 Rt7]7]8n7        ]7]9n7        ] P                  s;R4R lt<Rs=R t>]>! R4       R]P~                  3R lt@]@]n?         ! R  R!]&4      tA ! R" R#])4      tB ! R$ R%]4      tC ! R& R']34      tD ! R( R)]!4      tE ! R* R+]-P                  4      tGR, tH ! R- R.]4      tI ! R/ R0]+4      tJR1 tKR2tLR3 tM]R8X  d   ]M! 4        ]>! R4       R#   ] d    ]! R] P                  R7       ]! ^4      hi ; i  ]: d     Li ; i)5    N__main__zidlelib.pyshell)*zJ** IDLE can't import Tkinter.
Your Python may not be configured for Tk. **filewin32)fix_win_hidpi)
messagebox)InteractiveInterpreter)python_version)TextWrapper)ColorDelegator)idleConf)	Delegatordebugger)
debugger_r)EditorWindowfixwordbreaks)FileList)OutputWindow)replace)rpc)idle_formatwarningStdInputFileStdOutputFile)UndoDelegatorFz	127.0.0.1zCtrl-D (end-of-file)c           
          Vf   \         p VP                  \        WW#VR7      4       VP                  R4       R #   \        \        3 d     R # i ; i)N)linez>>> )warning_streamwriter   AttributeErrorOSError)messagecategoryfilenamelinenor   r   s   &&&&&&&/usr/lib/python3.14/idlelib/pyshell.pyidle_showwarningr(   C   sS     |

%8$@ 	A

6G$ s   .< AAc                     V '       d,   \         f"   \        P                  s \        \        n        R # R # \         e   \         \        n        R s R # R # N)_warnings_showwarningwarningsshowwarningr(   )captures   &r'   capture_warningsr/   V   sA      ($,$8$8!#3H  ) !,#8H $(! -    Tc                     \         P                  p/ p\        V4       F0  pVR ,          VRR ,           R8X  g   K  VP                  V4      W4&   K2  	  V! V 4       VP	                  V4       R# :N   NNz<>)	linecachecachelistpopupdate)r%   orig_checkcacher6   savekeys   &&   r'   extended_linecache_checkcacher=   e   s\     OOEDE{r7SX%		#DI  H	LLr0   c                   v   a  ] tR t^|t o R t. ROtRR ltR tRR ltRR lt	R t
R tR	 tR
 tR tR tRtV tR# )PyShellEditorWindowc                   . V n         \        P                  ! V .VO5!   V P                  P	                  R V P
                  4       V P                  P	                  RV P                  4       V P                  P	                  RV P                  P                  4       \        P                  P                  \        P                  R4      V n        V P                  P                   V 3R lpV P                  P#                  V4       V P                  P$                  '       d   V P'                  4        V P)                  4        R# )<<set-breakpoint>><<clear-breakpoint>>z<<open-python-shell>>zbreakpoints.lstc                 4    VP                  4        V ! 4        R # r*   )restore_file_breaks)old_hookselfs   &&r'   filename_changed_hook;PyShellEditorWindow.__init__.<locals>.filename_changed_hook   s    $$&Jr0   N)breakpointsr   __init__textbindset_breakpoint_eventclear_breakpoint_eventflist
open_shellospathjoinr   userdirbreakpointPathiofilename_change_hookset_filename_change_hookr%   rD   color_breakpoint_text)rF   argsrG   s   &* r'   rJ   PyShellEditorWindow.__init__   s    d*T*		+T-F-FG		-t/J/JK		.

0E0EF !ggll  "35 ,077+G+G'+	 	(()>?77$$&""$r0   Nc                    V P                   f   R # V'       d.   \        P                  ! 4       p\        P                  ! VR4      pMRRRR/pV P                  P                  RV4       R # )Nbreak
foreground 
backgroundBREAK)rV   r   CurrentThemeGetHighlightrK   
tag_config)rF   colorthemecfgs   &&  r'   rY   )PyShellEditorWindow.color_breakpoint_text   sS    77?))+E''w7C\26C		Wc*r0   c                   V P                   pV P                  P                  pVP                  R RV,          RV^,           ,          4        V P                  P                  V4        V P                  P                  P                  P                  pVP                  W14       R#   \         d    T P                  P                  T4        Lfi ; i    R# ; i)ra   z%d.0N)rK   rV   r%   tag_addrI   index
ValueErrorappendrO   pyshellinterpr   set_breakpoint)rF   r&   rK   r%   debugs   &&   r'   rp   "PyShellEditorWindow.set_breakpoint   s    yy77##Wfvov/BC	,""6*	JJ&&--66E  2	  	,##F+	,
	s   B% (;C %&CCCc                    V P                   pV P                  P                  pV'       g   VP                  4        R # \	        \        VP                  R4      4      4      pV P                  V4       R # )Ninsert)rK   rV   r%   bellintfloatrk   rp   )rF   eventrK   r%   r&   s   &&   r'   rM   (PyShellEditorWindow.set_breakpoint_event   sO    yy77##IIKU4::h/01F#r0   c                   V P                   pV P                  P                  pV'       g   VP                  4        R # \	        \        VP                  R4      4      4      p V P                  P                  V4       TP                  RRR4        T P                  P                  P                  P                  pTP                  Y44       R #     LU; i    R # ; i)Nrt   ra   insert linestartzinsert lineend +1char)rK   rV   r%   ru   rv   rw   rk   rI   remove
tag_removerO   rn   ro   r   clear_breakpoint)rF   rx   rK   r%   r&   rq   s   &&    r'   rN   *PyShellEditorWindow.clear_breakpoint_event   s    yy77##IIKU4::h/01	##F+ 	!3/	1	JJ&&--66E""84		s   !C ;C CCc                j   V P                   '       d   V P                  pV P                  P                  pV'       g   VP	                  4        R # . V n         VP                  RR\        4        V P                  P                  P                  P                  pVP                  V4       R # R #     R # ; i)Nra   1.0)rI   rK   rV   r%   ru   r}   ENDrO   rn   ro   r   clear_file_breaks)rF   rK   r%   rq   s   &   r'   r   %PyShellEditorWindow.clear_file_breaks   s    99Dww''H		!DOOGUC0

**11::''1 s   .;B- -B2c                   V P                   pV P                  P                  p \        V P                  4      ;_uu_ 4       pVP                  4       pR R R 4        \        T P                  R4      ;_uu_ 4       pX F4  pTP                  TR,           4      '       d   K#  TP                  T4       K6  	  T P                  4        T P                   pT'       d0   TP                  TR,           \        T4      ,           R,           4       R R R 4       R #   + '       g   i     L; i  \         d    . p Li ; i  + '       g   i     R # ; i  \         ds   p\        T P                  RR4      '       gK   RT P                  n        \        P                  ! RR\        T4      ,          T P                   R	7        R p?R #  R p?R # R p?ii ; i)
Nw=
breakpoint_error_displayedFTz
IDLE Errorz$Unable to update breakpoint list:
%s)titler#   parent)rI   rV   r%   openrU   	readlinesr"   
startswithr    update_breakpointsstrgetattrrootr   r	   	showerrorrK   )rF   breaksr%   fplinesnew_filer   errs   &       r'   store_file_breaks%PyShellEditorWindow.store_file_breaks   sU   $ !!77##	d))**b +	&d))3//8!D??8c>:: t, " '')))NN8c>CK#?$#FG 0/ +* 	E	 0//  	&499&BEJJ7;		4$$<Cc(#99& & K	&sr   D$ DD$ E 9!D78D7/D7E D!	D$ !D$ $D43D47E	E E GA!GGc                H   V P                   P                  4        V P                  f   R # V P                  P                  pVf   R # \        P
                  P                  V P                  4      '       d   \        V P                  4      ;_uu_ 4       pVP                  4       pR R R 4       X F[  pVP                  VR,           4      '       g   K#  \        V\        V4      ^,           R  4      pV F  pV P                  V4       K  	  K]  	  R # R #   + '       g   i     Lu; i)Nr   )rK   r9   rV   r%   rQ   rR   isfilerU   r   r   r   evallenrp   )rF   r%   r   r   r   breakpoint_linenumbersbreakpoint_linenumbers   &      r'   rD   'PyShellEditorWindow.restore_file_breaks  s    		77?77##77>>$--..d))**b +??8c>22-1$s8}Q7G2H-I*1G-++,AB 2H  /**s   DD!	c                n    V P                   pVP                  R 4      pV P                  V4      pW0n        R# )ra   N)rK   
tag_rangesranges_to_linenumbersrI   )rF   rK   rangeslinenumber_lists   &   r'   r   &PyShellEditorWindow.update_breakpoints  s/    yy)44V<*r0   c                &   . p\        ^ \        V4      ^4       Ft  p\        \        W,          P                  4      4      p\        \        W^,           ,          P                  4      4      pWE8  g   KZ  VP                  V4       V^,          pK$  	  V# )r   )ranger   rv   rw   stringrm   )rF   r   r   rk   r&   ends   &&    r'   r   )PyShellEditorWindow.ranges_to_linenumbers#  sq    1c&k1-Ev}3345FeF7O2234C,V$! . r0   c                R    V P                  4        \        P                  ! V 4       R # r*   )r   r   _closerF   s   &r'   r   PyShellEditorWindow._close4  s     D!r0   )rU   rI   ))Cutz<<cut>>rmenu_check_cut)Copyz<<copy>>rmenu_check_copy)Pastez	<<paste>>rmenu_check_paste)NNN)zSet BreakpointrA   N)zClear BreakpointrB   NTr*   )__name__
__module____qualname____firstlineno__rJ   rmenu_specsrY   rp   rM   rN   r   r   rD   r   r   r   __static_attributes____classdictcell____classdict__s   @r'   r?   r?   |   sJ     %(K
+$&(&TC"+"" "r0   r?   c                   2   a  ] tR tRt o ]tRtRR ltRtV t	R# )PyShellFileListi:  Nc                &   V P                   '       d1   V P                   P                  P                  4        V P                   # \        V 4      V n         V P                   '       d#   V P                   P	                  4       '       g   R # V P                   # r*   )rn   topwakeupPyShellbeginrF   rx   s   &&r'   rP   PyShellFileList.open_shellC  sc    <<<LL##% ||	 #4=DL|||||))++||r0   )rn   r*   )
r   r   r   r   r?   r   rn   rP   r   r   r   s   @r'   r   r   :  s     
 'LG r0   r   c                   ,   a  ] tR tRt o R tR tRtV tR# )ModifiedColorDelegatoriN  c                ~    V P                  R RR4       V P                  RRR4       \        P                  ! V 4       R# )TODOr   iomarkSYNCN)r}   rj   r   recolorize_mainr   s   &r'   r   &ModifiedColorDelegator.recolorize_mainP  s0    x0VUH-&&t,r0   c                R    V P                    F  pV P                  VR R4       K  	  R# )r   r   N)tagdefsr}   )rF   tags   & r'   removecolors#ModifiedColorDelegator.removecolorsU  s     <<COOC51  r0    N)r   r   r   r   r   r   r   r   r   s   @r'   r   r   N  s     -
2 2r0   r   c                   F   a a ] tR tRt oRR ltRR ltV 3R ltRtVtV ;t	# )ModifiedUndoDelegatori[  c                     V P                   P                  VR R4      '       d   V P                   P                  4        R#  \        P
                  ! WW#4       R#   \         d     L&i ; i<r   N)delegatecompareru   TclErrorr   rt   rF   rk   charstagss   &&&&r'   rt   ModifiedUndoDelegator.insert]  s^    	}}$$UC::""$ ;
 	T%6  		   "A A A)(A)c                     V P                   P                  VR R4      '       d   V P                   P                  4        R#  \        P
                  ! WV4       R#   \         d     L&i ; ir   )r   r   ru   r   r   delete)rF   index1index2s   &&&r'   r   ModifiedUndoDelegator.deletef  s^    	}}$$VS(;;""$ <
 	T62  		r   c                   <a V P                   P                  oV3R  lV P                   n         \        SV `  V4       SV P                   n        R#   ST P                   n        i ; i)c                    < S! WR 4      # )stdinr   )rk   r   orig_inserts   &&r'   <lambda>2ModifiedUndoDelegator.undo_event.<locals>.<lambda>v  s    U7!Cr0   N)r   rt   super
undo_event)rF   rx   r   	__class__s   &&@r'   r    ModifiedUndoDelegator.undo_evento  sN    
 mm**C 		/Gu%#.DMM ;DMM s   A A$r   r*   )
r   r   r   r   rt   r   r   r   r   __classcell__r   r   s   @@r'   r   r   [  s     73/ /r0   r   c                   *   a  ] tR tRt o RR ltRtV tR# )UserInputTaggingDelegatori}  Nc                J    Vf   RpV P                   P                  WV4       R # )Nr   )r   rt   r   s   &&&&r'   rt    UserInputTaggingDelegator.insert  s     <DU40r0   r   r*   )r   r   r   r   rt   r   r   r   s   @r'   r   r   }  s     1 1r0   r   c                   &   a  ] tR tRt o R tRtV tR# )MyRPCClienti  c                    \         hr*   )EOFErrorr   s   &r'   
handle_EOFMyRPCClient.handle_EOF  s    r0   r   N)r   r   r   r   r   r   r   r   s   @r'   r   r     s      r0   r   c                     R T;'       g    R R2pV \        V4      8  d;   \        V \        V4      ,
          ^4      w  r4W4,           R,           V VR,           2# VRR # )z= RESTART: Shellz =r   N)r   divmod)widthr%   r   divmods   &&   r'   restart_liner    se     ++G,B
/CC5#c(?Q/7C-c#gY//3Bxr0   c                      a  ] tR tRt o R tRtRtRtR tR t	R t
R!R ltR tR	 tR
 tR tR"R ltRtR tRtR tR tR tR t^ tR tR#R ltR tR tR tR#R ltR tR t R t!R t"R t#R t$R t%R t&R t'V t(R# )$ModifiedInterpreteri  c                    Wn         \        P                  R ,          P                  p\        P
                  ! WR7       RV n        RV n        \        V n	        V P                  P                  P                  V n        R# )r   )localsFN)	tkconsolesysmodules__dict__r
   rJ   
restartingsubprocess_arglistPORTportcompilecompilerflagsoriginal_compiler_flags)rF   r  r  s   && r'   rJ   ModifiedInterpreter.__init__  sW    "Z(11''<"&	'+||'<'<'B'B$r0   Nc                    V P                   f   V P                  4       V n         \        \        P                  RR7      p\
        P                  ! V P                   VR7      V n        R # )Ndumb)TERM)env)r  build_subprocess_arglistdictrQ   environ
subprocessPopen
rpcsubproc)rF   r  s   & r'   spawn_subprocess$ModifiedInterpreter.spawn_subprocess  sI    ""*&*&C&C&ED#2::F+$**4+B+BLr0   c                   \         P                   Uu. uF  pR V,           NK  	  pp\        P                  ! RRRRRR7      pRV: R2p\         P                  .V,           R	V\        V P                  4      .,           # u upi )
z-WmainGeneralzdelete-exitfuncFbool)defaulttypez#__import__('idlelib.run').run.main()-c)r  warnoptionsr   	GetOption
executabler   r  )rF   sr   	del_exitfcommands   &    r'   r  ,ModifiedInterpreter.build_subprocess_arglist  sz      #/!TAXX/ &&vy:K/46C	7	}AF!#tWc$))n&EEE 0s   A>c                b   \         V P                  3p\        ^4       F*  p\        P                  ! V4        \        V4      V n         M	  V P                  4        R# V P                  P                  P                  4       ^,          V n        \        ^ 8w  dD   V P                  P                  P                  \        P                  \        P                  ^4       V P!                  4        V P                  P                  P#                  ^
4        V P                  P%                  4        T P                  P+                  RT P,                  4       T P                  P+                  RT P,                  P.                  4       T P                  P+                  RT P,                  P0                  4       T P                  P+                  RT P,                  P2                  4       T P                  P+                  RT P,                  P4                  4       T P                  P+                  R\6        4       T P                  P+                  RT 4       T P9                  R	R
7       T P;                  4        T P                  #   \         d     EKm  i ; i  \&         d    T P)                  4         R# i ; i)   Nconsoler   stdoutstderrrO   r5   ro   Twith_cwd)HOSTr  r   timesleepr   rpccltr"   display_port_binding_errorlistening_sockgetsocknamer  
setsockoptsocket
SOL_SOCKETSO_REUSEADDRr#  
settimeoutacceptTimeoutErrordisplay_no_subprocess_errorregisterr  r   r7  r8  rO   r5   transfer_pathpoll_subprocess)rF   addris   &  r'   start_subprocess$ModifiedInterpreter.start_subprocess  s   dii qAJJqM)$/	  ++-KK..::<Q?	19
 KK&&11&2C2C+1+>+>C 	""--b1	KK  	Y7Wdnn&:&:;Xt~~'<'<=Xt~~'<'<=Wdnn&:&:;[)4Xt,D){{C  *  	,,.	s#   I<J <JJJ.-J.c                b   V P                   '       d   V P                  # R V n         V P                  4       pV'       d"    \        P                  ! V P                  4       V P                  P                  4        V P                  4        V P                  pVP                  pRVn        V P                  4         V P                  P                  4        T P                  TR7       TP                  4        TP                  P!                  RR4       TP#                  R4       TP#                  \%        TP&                  T4      4       TP                  P)                  RR4       TP                  P+                  RR4       T'       g   TP-                  4        T'       d1   \        P.                  ! T P                  4       TP1                  4        T P2                  T P4                  P6                  n        RT n         T P                  #     EL; i  \         d    T P                  4         R# i ; i)	TFNr9  r   end-1cr   restartleft)r  r>  getdebuggerr   close_subprocess_debuggercloseterminate_subprocessr  	executingr#  rG  rH  rI  rK  stop_readlinerK   r   r    r  r  mark_setmark_gravity
showpromptrestart_subprocess_debuggerload_breakpointsr  r  r  r  )rF   r:  r%   rq   r6  was_executings   &&&   r'   restart_subprocess&ModifiedInterpreter.restart_subprocess  s   ???;;  "44T[[A 	!!#..))!	KK  	H-Hh/dl7==(;<i2!!)V4 224;;?""$&*&B&B#{{A  	,,.	s    H 9H HH.-H.c                B    V P                   P                  R RR/ 4       R# )execinterrupt_the_serverNr   )r>  
remotecallr   s   &r'   __request_interrupt'ModifiedInterpreter.__request_interrupt  s    v'=r2Fr0   c                d    \         P                  ! V P                  R 7      P                  4        R# ))targetN)	threadingThread'_ModifiedInterpreter__request_interruptstartr   s   &r'   interrupt_subprocess(ModifiedInterpreter.interrupt_subprocess  s     8 89??Ar0   c                   V P                   e0   V P                  P                  P                  V P                   4        V P                  P
                  P                  4         V P                  P                  4        V P                  4        RV P                  n	        R V n        R #   \         d     LRi ; i  \         d     LHi ; i)NF)
_afteridr  rK   after_cancelr>  r@  rW  r!   rX  rY  r   s   &r'   kill_subprocess#ModifiedInterpreter.kill_subprocess  s    ==$NN,,T]];	KK&&,,.	KK 	!!##(   		  		s#   $B( $B9 (B65B69CCc                     V P                   P                  4         V P                   P                  4        R #   \         d     R # i ; i  \         d     R # i ; ir*   )r"  killwaitr"   r   s   &r'   rX  (ModifiedInterpreter.terminate_subprocess'  sQ    		OO  "
$$&   		s    A 9 AAAAc                    V'       d$   R .pVP                  \        P                  4       M\        P                  pV P                  RP	                  V4      4       R# )r_   zTif 1:
        import sys as _sys
        _sys.path = {!r}
        del _sys
        
N)extendr  rR   
runcommandformat)rF   r:  rR   s   && r'   rK  !ModifiedInterpreter.transfer_path4  sA    4DKK!88D  fTl		r0   c                   V P                   pVf   R #  VP                  V P                  RR7      pV'       d   V P                  P                  4        R V n        Vw  r4V P                  P                  pVR8X  d   Ve   \        \        V4      VR7       MjVR8X  d3   V P                  P                  R4      '       d   V P                  4        M1VR8X  d+   Rp\        Wd\        P                   R7       \        WdVR7        V P                  P#                  4        V P                  P                  '       gL   V P                  P&                  P)                  V P                  P*                  V P,                  4      V n        R # R #   \        \        \
        3 d6    T P                  P                  '       d    R # R pT P                  4         ELi ; i  \$         d     Li ; i)	Ng?)rx  OKr   	EXCEPTION<<toggle-jit-stack-viewer>>ERRORz/pyshell.ModifiedInterpreter: Subprocess ERROR:
)r>  pollresponse
active_seqr   r"   KeyboardInterruptr  closingra  resetoutputr6  printreprgetvarremote_stack_viewerr  
__stderr__endexecutingr!   rK   afterpollintervalrL  rr  )rF   cltresponsehowwhatr6  errmsgs   &      r'   rL  #ModifiedInterpreter.poll_subprocessC  s~   kk;	&''d'CH NN&&("DO ICnn,,Gd{#$t*73#>>(()FGG,,.Kf8f1++- ~~%%% NN//55++T-A-ACDM &9 '#45 	& ~~%%%H##%	&2 " s)   F G 1G9GGG G c                    Wn         R # r*   r   )rF   r   s   &&r'   setdebuggerModifiedInterpreter.setdebuggerk  s     r0   c                    V P                   # r*   r   r   s   &r'   rU  ModifiedInterpreter.getdebuggern  s    }}r0   c                f    V P                   P                  P                  R V P                  4       R# )i,  N)r  rK   r  r  r   s   &r'   open_remote_stack_viewer,ModifiedInterpreter.open_remote_stack_viewerq  s'     	!!#t'?'?@r0   c                $   ^ RI Hp V P                  P                  RRR/ 4      pVf'   V P                  P
                  P                  4        R# TP                  V P                  V4      p^ RIH	pH
p \        V P                  P
                  4      p\        P                  ! 4       p\        P                  ! VR4      R,          pV! Wh^ R7      p	V	P                  P!                  ^R	R
7       V! V	P"                  RV4      p
V
P%                  4        R# )r   )
debugobj_rrd  stackviewerN)ScrolledCanvasTreeNodenormalr`   )bghighlightthicknessboth)expandfill)rO   )idlelibr  r>  remotequeuer  r   ru   StubObjectTreeItemidlelib.treer  r  Toplevelr   rb   rc   framepackcanvasr  )rF   r  oiditemr  r  r   rf   r`   scnodes   &          r'   r  'ModifiedInterpreter.remote_stack_viewer~  s    &kk%%fmZL;NN$$&,,T[[#>9t~~**+%%'**5(;LI
C1E
QV,		4.r0   c                J    V P                  V4      pV P                  W!4       R # r*   )stuffsourceexecfilerF   sourcer%   s   && r'   
execsourceModifiedInterpreter.execsource  s    ##F+h'r0   c                ^   Vfu   \         P                  ! V4      ;_uu_ 4       pVP                  4       p\        '       d2   R\        P
                  P                  V4       R2V,           R,           pR R R 4        \        W!R4      pV P                  V4       R #   + '       g   i     L0; i  \        \        3 dp    T P                  P                  4        \        RT P                  P                  R7       \        P                   ! Y4       T P                  P#                  4         R # i ; i)Nz__file__ = r'''z'''
z
del __file__rd  zB*** Error in script or command!
Traceback (most recent call last):r   )tokenizer   readuse_subprocessrQ   rR   abspathr  runcodeOverflowErrorSyntaxErrorr  r  r  r8  r
   showsyntaxerrorr]  )rF   r%   r  r   codes   &&&  r'   r  ModifiedInterpreter.execfile  s    >x((B!> /0I/J%P &')9:F )

	6V4D LL )( {+ 	(NN&&( 6~~,,. #224BNN%%'	(s   AB:B, B)	,A<D,+D,c                R    V P                  V4      p\        P                  ! WV4      # r*   )r  r
   	runsourcer  s   && r'   r  ModifiedInterpreter.runsource  s'    ##F+
 &//hGGr0   c                    R V P                   ,          pV P                   ^,           V n         VP                  R4      p\        V4      ^,           ^ W23\        P                  V&   V# )z<pyshell#%d>r   )gidsplitr   r5   r6   )rF   r  r%   r   s   &&  r'   r  ModifiedInterpreter.stuffsource  sO    !DHH,88a<T"$'KM1e$E	!r0   c                F    V P                  R P                  V4      4       R# )a*  if 1:
            _filename = {!r}
            import sys as _sys
            from os.path import dirname as _dirname
            _dir = _dirname(_filename)
            if not _dir in _sys.path:
                _sys.path.insert(0, _dir)
            del _filename, _sys, _dirname, _dir
            
N)r|  r}  rF   r%   s   &&r'   prepend_syspath#ModifiedInterpreter.prepend_syspath  s      &"	$r0   c                >   V P                   pVP                  pVP                  R RR4       \        P                  ! 4       w  rVp\        VRR4      ;'       g    T;'       g    Rp\        VRR4      ;'       g    ^p	\        VRR4      ;'       g    ^ p
V
^ 8X  d
   V	^,          p	V	^8X  d   RV
^,
          ,          pMR	V	^,
          V
^,
          3,          pVP                  WK4       VP                  4        V P                  R
V,          4       VP                  4        R# )r  r   r   msgr_   z<no detail available>r&   offsetziomark + %d charsz&iomark linestart + %d lines + %d charszSyntaxError: %s
N)
r  rK   r}   r  exc_infor   colorize_syntax_errorr  r    r]  )rF   r%   kwargsr  rK   r*  valuetbr  r&   r  poss   &&,         r'   r  #ModifiedInterpreter.showsyntaxerror  s     NN	~~.,,.ReUB'KK5KK4K"-22"-22Q;aKFQ;%2C:!8VAX&'C''2

&,-r0   c                    V P                   P                  4        V P                  4        \        P                  ! V 4       V P                   P                  R 4      '       d   V P                   P                  4        R# R# )r  N)r  r  checklinecacher
   showtracebackr  open_stack_viewerr   s   &r'   r  !ModifiedInterpreter.showtraceback  sX    ""$,,T2>>  !>??NN,,. @r0   c                    \         P                  p\        V4       F  pVR ,          VRR ,           R8w  g   K  W K!  	  R# r2   )r5   r6   r7   )rF   r6   r<   s   &  r'   r  "ModifiedInterpreter.checklinecache  s5    ;C2wRS!T)J r0   c                    V P                   P                  '       d   V P                  4        ^ # V P                  '       d"   V P                  P	                  RRV3/ 4       ^# \        WP                  4       ^# )r   rd  r  )r  rY  display_executing_dialogr>  r  rd  r  )rF   r  s   &&r'   r|  ModifiedInterpreter.runcommand  s\     >>###))+;;;KK##FIwC  {{#r0   c                
   V P                   P                  '       d   V P                  4        V P                  4        V P                  p V P                   P                  4        V'       g4   V P                  e&   V P                  P                  RRV3/ 4      V n        M;V'       d   VP                  ! WP                  4       M\        WP                  4        \$        '       g    V P                   P+                  4        R # R #   \         df    T P                   P                  '       gH   \        P                  ! RRRT P                   P                   R7      '       d   h T P#                  4         Lh  \$        '       dN   \'        RT P                   P(                  R7       T P#                  4        T P                   P+                  4         LT P                   P,                  '       d6   R	T P                   n        \'        R
T P                   P(                  R7        ELET P#                  4         ELX; i  \.         d     R # i ; i  \$        '       g.    T P                   P+                  4        i   \.         d     i i ; ii ; i)Nrd  r  zExit?zDo you want to exit altogether?yesr)  r   z IDLE internal error in runcode()r   Fr  )r  rY  ra  r  r   beginexecutingr>  
asyncqueuer  runr  rd  
SystemExitr  r	   askyesnorK   r  r  r  r8  r  canceledr!   )rF   r  r   s   && r'   r  ModifiedInterpreter.runcode  s   >>#####%==&	NN))+ 7"&++"8"89=#ET;;/T;;'4 ">NN//1 "3  	>>)))&&5!>>..	0 0
 &&(	)~8>>002""$++->>***.3DNN+-DNN4I4IJJ&&(
 &  ">NN//1%  "s   
AD I D 'D I D I 'H5 &H2,3H2 H21I 3H2AH2I H2*2H2I H2/I 5IIJI0/J0I>;J=I>>Jc                L    V P                   P                  P                  V4      # r*   )r  r8  r    )rF   r0  s   &&r'   r    ModifiedInterpreter.write*  s    ~~$$**1--r0   c                `    \         P                  ! R RV P                  P                  R7       R# )zPort Binding ErroraA  IDLE can't bind to a TCP/IP port, which is necessary to communicate with its Python execution server.  This might be because no networking is installed on this computer.  Run IDLE with the -n command line switch to start without a subprocess and refer to Help/IDLE Help 'Running without a subprocess' for further details.r   Nr	   r   r  rK   r   s   &r'   r?  .ModifiedInterpreter.display_port_binding_error.  s'     / >>&&	(r0   c                `    \         P                  ! R RV P                  P                  R7       R# )zSubprocess Connection ErrorzIDLE's subprocess didn't make connection.
See the 'Startup failure' section of the IDLE doc, online at
https://docs.python.org/3/library/idle.html#startup-failurer  Nr  r   s   &r'   rI  /ModifiedInterpreter.display_no_subprocess_error9  s(    )J >>&&	(r0   c                `    \         P                  ! R RV P                  P                  R7       R# )zAlready executingzYThe Python Shell window is already executing a command; please wait until it is finished.r  Nr  r   s   &r'   r  ,ModifiedInterpreter.display_executing_dialogA  s%    0>>&&		(r0   )rr  r  r   r  r  r  r  r>  r"  r  r  )Fr_   )Fr*   ))r   r   r   r   rJ   rr  r>  r"  r#  r  rO  ra  rm  ro  rt  rX  rK  r  rL  r   r  rU  r  r  r  r  r  r  r  r  r  r  r  r|  r  r    r?  rI  r  r   r   r   s   @r'   r	  r	    s     C HFJM
F)V*XGB J$CL H!" C(
(H
$4/
,\.	((( (r0   r	  c            	         a a ] tR tRt o^ RIHt R]! 4       ,           t]t	]
t. R6Ot]P                  R7.,           t^]! ]! ]P$                  ! R ]4      4      4      ,           t]P)                  ]R84       ARtRt^ RIHt ^ RIHt R9R	 ltV 3R
 ltV 3R ltR tR tR t R9R lt!Rt"Rt#Rt$Rt%Rt&Rt'R t(R t)R9R lt*R t+R9R lt,R t-R t.R t/R t0R t1R t2R t3R t4R t5Rt6R t7R  t8R! t9R" t:R9R# lt;R$ t<R% t=R& t>R' t?]@P                  ! R(4      tBR) tCR9R* ltDR9R+ ltER9R, ltFR- tGR. tHR/ tIR:R0 ltJV 3R1 ltKV 3R2 ltLR9R3 ltMR4 tNR5tOVtPV ;tQ# );r   iI  )SqueezerzIDLE Shell c                    V ^ ,          R8g  # )r   r   r   )
rmenu_items   &r'   r   PyShell.<lambda>a  s    :a=F2r0   Fr   )History)ShellSidebarc                4	   V P                   pV^,          ^ ,          R8w  d   VP                  ^R4       \        V 4      V n        Vf1   \	        4       p\        V4       VP                  4        \        V4      pRV n        \        P                  ! WRR4       RV n        ^V n        \        \        R4      '       d   \        P                  MRV n        V P                   P#                  R4      R,          V n        V P                   V n        V P(                  pVP+                  RR7       VP-                  R	V P.                  4       VP-                  R
V P0                  4       VP-                  RV P2                  4       VP-                  RV P4                  4       VP-                  RV P6                  4       VP-                  RV P8                  4       VP-                  RV P:                  4       VP-                  RV P<                  4       \>        '       d9   VP-                  RV P@                  4       VP-                  RV PB                  4       T PE                  V 4      V n#        VP-                  RV PH                  4       \        PJ                  V n&        \        PN                  V n(        \        PR                  V n*        ^ RI+H,p \[        V RVP\                  VP^                  4      V n)        \a        V RVP\                  VP^                  4      V n%        \a        V RVP\                  R4      V n'        \a        V RVP\                  VP^                  4      V n1        \>        '       g@   V PJ                  \        n%        V PN                  \        n'        V PR                  \        n)         ^ RI2pVPf                  Vn4        T Pm                  T P(                  4      T n7        ^2T n8        T Ps                  T 4      T n        T Pt                  Pv                  P                  T P(                  n        T Pt                  Py                  \{        4       4       \>        '       g)   T P}                  R^ R4       T P}                  R^R4       R# R#    \        Pj                  \        n'        h ; i)   shellNFps1z>>>
r   char)wrapz<<newline-and-indent>>z<<plain-newline-and-indent>>z<<interrupt-execution>>z<<end-of-file>>z<<open-stack-viewer>><<toggle-debugger>>r  <<copy-with-prompts>>z<<view-restart>>z<<restart-shell>><<squeeze-current-text>>)iomenur   r7  r8  backslashreplacer6  disabled)r  She_llr4   )?
menu_specsrt   r	  ro   Tkr   withdrawr   shell_sidebarr   rJ   usetabsindentwidthhasattrr  r  sys_ps1r  prompt_last_linepromptrK   	configurerL   enter_callbacklinefeed_callbackcancel_callbackeof_callbackr  toggle_debuggertoggle_jit_stack_viewercopy_with_prompts_callbackr  view_restart_markrestart_shellr  squeezersqueeze_current_text_eventr7  save_stdoutr8  save_stderrr   
save_stdinr  r  r   encodingerrorsr   r6  pydoc
plainpagerpagerr  r  historyr  r  perr   insertfilterr   update_menu_state)rF   rO   msr   rK   r  r+  s   &&     r'   rJ   PyShell.__init__o  sZ   __a58wIIa,-)$/=4D$MMO#D)E!d46")#u"5"5sww7 $ 2 24 8 <llyyF#		*D,?,?@		0$2H2HI		+T-A-AB		#T%6%67		)4+A+AB		')=)=>		/1M1MN		)4+J+JK>II($*@*@AII)4+=+=>d+		,11	3 ::::))"!$"(//6==B
#D($*OOV]]D#D($*OO5GI$T9%+__fmmE~CJCJ

CI	**EK
 ||DII.!..t4
  88<<..		79:~""7Az:""7Az: !	CJs   !Q; ;Rc                x   < \         SV `  4        V P                  e   V P                  P                  4        R # R # r*   )r   	ResetFontr  update_fontrF   r   s   &r'   r5  PyShell.ResetFont  s1    )**, *r0   c                  < \         SV `  4        \        P                  ! 4       pR RRRR/R\        P                  ! VR4      R\        P                  ! VR4      R\        P                  ! VR4      /pVP                  4        F"  w  r4V P                  P                  ! V3/ VB  K$  	  V P                  e   V P                  P                  4        R# R# )r   r`   Nr^   r7  r8  r6  r  )
r   ResetColorizerr   rb   rc   itemsrK   tag_configurer  update_colors)rF   rf   
tag_colorsr   tag_colors_configr   s   &    r'   r:  PyShell.ResetColorizer  s     %%'
L$d;
H))%:
H))%:
X**5(;	

 '1&6&6&8"CII##C=+<= '9 ),,. *r0   c                J    \         P                   ! V P                  R R7       R# )r   )insert_tagsr]   )r   rK   r   s   &&r'   replace_eventPyShell.replace_event  s    		w7r0   c                0    \         P                  ! R R7      # )T)
shell_only)r   GetExtensionsr   s   &r'   get_standard_extension_names$PyShell.get_standard_extension_names  s    %%66r0   c                v   V P                   P                  W4      p\        \        \	        V4      4      \        \	        V4      4      4      pV Uu. uF(  pV P
                  P                  P                  V4      NK*  	  ppR P                  R \        WcP                  4       4       4       4      R ,           # u upi )r   c              3   @   "   T F  w  rVf   TMV RV 2x  K  	  R # 5i)N r   ).0r  r   s   &  r'   	<genexpr>*PyShell.get_prompt_text.<locals>.<genexpr>  s-      
 ? ND6(!D6(:: ?s   )
rK   getr   rv   rw   r  line_promptsrS   zip
splitlines)rF   firstlastrK   lineno_ranger&   promptss   &&&    r'   get_prompt_textPyShell.get_prompt_text  s    yy}}U)ed '
& ++//7& 	 
 yy 
 #G__-> ?
 
  		
s   .B6c                   V P                   pVP                  R 4      pVf   R# VP                  R4      pVR,          R8w  d   VP                  R4      pVP                  4        V P                  W44      pVP	                  V4       R# )zsel.first linestartNsel.last0zsel.last+1line linestartr4   )rK   rk   clipboard_clearrX  clipboard_append)rF   rx   rK   selfirstsellastprompt_texts   &&    r'   r!  "PyShell.copy_with_prompts_callback  sx     yy::34**Z(2;#jj!;<G**8=k*r0   c                
    Vs R # r*   r   )rF   streams   &&r'   set_warning_streamPyShell.set_warning_stream
  s    r0   c                    \         # r*   rd  r   s   &r'   get_warning_streamPyShell.get_warning_stream  s    r0   c                   V P                   '       d6   \        P                  ! R RV P                  R7       V P	                  4        R# V P
                  P                  4       pV'       d   V P                  4        R# V P                  4        R# )zDon't debug nowz*You can only toggle the debugger when idler  r]   N)	rY  r	   r   rK   set_debugger_indicatorro   rU  close_debuggeropen_debugger)rF   rx   dbs   && r'   r  PyShell.toggle_debugger  sd    >>>  !2<yy" '')((*B##%""$r0   c                f    V P                   P                  4       pV P                  R V'       4       R# )r	  N)ro   rU  setvarrF   ro  s   & r'   rl  PyShell.set_debugger_indicator  s%    [[$$&)2v6r0   c                    R # r*   r   r   s   &&r'   r   PyShell.toggle_jit_stack_viewer#  s    r0   c                   V P                   P                  4       pV'       d   V P                   P                  R 4       VP                  4        V P                   P                  '       d+   \
        P                  ! V P                   P                  4       V P                  4        V P                  P                  R4       V P                  V n        V P                  4        V P                  4        R # )Nz[DEBUG OFF]
)ro   rU  r  rW  r>  r   close_remote_debuggerr  r6  r    r  r  r]  rl  rs  s   & r'   rm  PyShell.close_debugger&  s    [[$$&KK##D)HHJ{{!!!001C1CDLL/,,DKOO##%r0   c                   V P                   P                  '       d-   \        P                  ! V P                   P                  V 4      pM\        P
                  ! V 4      pV P                   P                  V4       VP                  4        R V P                  ,           V n	        V P                  4        V P                  4        R# )z[DEBUG ON]
N)ro   r>  r   start_remote_debuggerr   Debuggerr  r_  r  r  r]  rl  )rF   dbg_guis   & r'   rn  PyShell.open_debugger3  s    ;; 66t{{7I7I;?AG ''-G(  "$t||3##%r0   c                X    V P                   '       d   R MRpV P                  RRV4       R# )r  r  rq   z*tack*iewerN)rY  r1  )rF   states   & r'   debug_menu_postcommandPyShell.debug_menu_postcommand?  s#    "nnn
(wu=r0   c                4    V P                  4        R V n        R# )TN)r  rY  r   s   &r'   r  PyShell.beginexecutingC  s    r0   c                B    R V n         R V n        V P                  4        R# )FN)rY  r  r]  r   s   &r'   r  PyShell.endexecutingH  s    r0   c                    V P                   '       d-   \        P                  ! R RRV P                  R7      pVRJ d   R# V P	                  4        RV n        RV n        \        P                  ! V 4      # )zKill?z7Your program is still running!
 Do you want to kill it?okr  FcancelT)	rY  r	   askokcancelrK   rZ  r  r  r   rW  )rF   r  s   & r'   rW  PyShell.closeN  sc    >>>!--Jyy	"H
 5 !!$''r0   c                h   V P                  4        \        '       d   V P                  P                  4        V P                  \
        n        V P                  \
        n        V P                  \
        n
        R V n        R V n        R V P                  n        R V n        \        P                   ! V 4       R # r*   )rm  r  ro   rt  r&  r  r7  r'  r8  r(  r   r6  rO   rn   r.  r   r   r   s   &r'   r   PyShell._close]  sw    >KK'')%%
%%
OO	!

D!r0   c                    R # r   r   r  s   &&r'   ispythonsourcePyShell.ispythonsourcem  s    r0   c                    V P                   # r*   )shell_titler   s   &r'   short_titlePyShell.short_titleq  s    r0   z>Enter "help" below or click "Help" above for more information.c           
         V P                   P                  R R4       V P                  4        \        '       d8   RpV P                  P                  4       pV'       g   V P                  4        R# MR	p\        P                  \        n        V P                  R\        P                  : R\        P                  : RV P                  : RV: 24       V P                   P                  4        V P                  4        ^ RIpRVn        RVn        R# )
r   rt   r_   FzPython z on r   NTz==== No Subprocess ====

WARNING: Running IDLE without a Subprocess is deprecated
and will be removed in a later version. See Help/IDLE Help
for details.

)rK   r[  r  r  ro   rO  rW  r   displayhookr  r    versionplatform
SPLASHLINEfocus_forcer]  tkinter_support_default_root_default_root)rF   nosubclientr  s   &   r'   r   PyShell.beginv  s    		8X.>E[[113F

 'E "ooCO

KKtG 	H		(,% $r0   c                p    V P                   '       g   R # RV n        V P                  P                  4        R # )NT)reading_stop_readline_flagr   quitr   s   &r'   rZ  PyShell.stop_readline  s#    |||#' r0   c                   V P                   p R V n         V P                  P                  4        Wn         V P                  '       d
   RV n        R# V P                  P                  RR4      p\        V4      ^ 8X  d   RpV P                  4        V P                  '       d   RV n        \        '       g   \        hV P                  '       d
   RV n        RpV#   Yn         i ; i)TFr_   r   rR  r   )r  r   mainloopr  rK   rP  r   r  r  r  r  	endoffile)rF   r;   r   s   &  r'   readlinePyShell.readline  s    ||	 DLHHL###',D$yy}}Xx0t9>D===!DM!>''>>>"DND  Ls   !C Cc                    R # r   r   r   s   &r'   isattyPyShell.isatty  s    r0   c                    V P                   P                  R RR4      '       d   R#  T P                  '       gP   T P                  '       g>   T P	                  4        T P
                  P                  R4       T P                  4        R# RT n        RT n	        T P                  '       dr   T P
                  P                  '       dV   T P
                  P                  4       '       d   T P
                  P                  4        MT P
                  P                  4        T P                  '       d   T P                  P                  4        R#     EL%; i)	sel.firstz!=r[  NzKeyboardInterrupt
r]   FT)rK   r   rY  r  r  ro   r    r]  r  r  r>  rU  ra  ro  r   r  r   s   &&r'   r  PyShell.cancel_callback  s    	yy  dJ?? @ $,,,KK34OONNNt{{111{{&&((..0002<<<HHMMO!	s   "E Ec                   V P                   '       d   V P                  '       g   R # V P                  P                  RRR4      '       d$   V P                  P                  RRR4      '       g   R # V P                   '       g#   V P	                  4        V P                  4        R# RV n        RV n        V P                  P                  4        R# )Nr   z==rt   rR  FTr]   )
rY  r  rK   r   r  rW  r  r  r   r  r   s   &&r'   r  PyShell.eof_callback  s    >>>$,,,		!!(D(;;		!!(D(;;~~~JJL
  "DM!DNHHMMOr0   c                    V P                   '       d:   V P                  P                  R R4       V P                  P                  R 4       R# V P	                  V4       R# )rt   r   r]   )r  rK   rt   seenewline_and_indent_eventr   s   &&r'   r  PyShell.linefeed_callback  sG    <<<IIXt,IIMM(#  ))%0r0   c                N   V P                   '       d   V P                  '       g   R #  V P                  P                  RR4      pV'       d7   V P                  P	                  RRR4      '       d   V P                  W!4       R# T P                  P	                  RRR4      '       Ed^   T P                  P                  R	R4      pT'       Edw   T P                  P	                  RRT^,          4      '       EdL   R
T P                  P                  R4      9  Ed+   T P                  P                  R
R4      pT'       dD   T P                  P	                  T^,          RT^ ,          4      '       d   T^,          T^,          3pT P                  P                  R
R4      pT'       dd   T P                  P	                  T^ ,          RT^,          4      '       d3   T^ ,          T P                  P                  T^ ,          R,           4      3pT P                  T P                  P                  T^ ,          T^,          4      T4       R# T P                  P                  R	R4      pT'       d   T P                  P	                  RRT^ ,          4      '       d   T P                  P                  R
R4      pT'       dd   T P                  P	                  T^ ,          RT^,          4      '       d3   T^ ,          T P                  P                  T^ ,          R,           4      3pT P                  T P                  P                  T^ ,          T^,          4      T4       R# T P                  P                  R
R4      pT'       d`   T P                  P	                  T^ ,          RR4      '       d6   T P                  T P                  P                  T^,          R4      T4       R# T P                  T P                  P                  RR4      T4       R# T P                  P	                  RRR4      '       d   T P                  P                  RR4       T P                  P                  RR4      pT'       d3   TP                  4       '       g   T P                  P                  RR4       T P                  P	                  RRR4      '       d   T P                  T4       R# T P                  P                  RR4       T P                  '       d9   T P                  P                  RR4       T P                  P                  R4       MT P                  T4       T P                  P!                  4        T P                  '       d   T P"                  P%                  4        R# T P'                  4        R#     EL"; i)Nr  r[  z<=r   r]   rt   r   iomark linestartr   r6  z>=z+1czinsert lineendr{   rR  zend-1c linestartr   )rY  r  rK   rP  r   recalltag_prevrange	tag_namestag_nextrangerk   r[  stripr   r  rt   r  update_idletasksr   r  runit)	rF   rx   selprev	prev_cons	next_consnextindicesr0  s	   &&       r'   r  PyShell.enter_callback  s   >>>$,,,	))--Z8C99$$Zx@@KK+" 99Xs,>??
 99**7H=DDII%%hT!W==TYY%8%8%BB II33IxH	!2!29Q<tAw!O!O%aL$q'2D II33IxH	!2!29Q<d1g!N!N GTYY__Yq\E5I%JKDDIIMM$q'47;UC99**7H=D		))*:D$q'JJ II33I?OP	!2!29Q<d1g!N!N GTYY__Yq\E5I%JKDDIIMM$q'47;UCii--i9KLGyy  T3EFFDIIMM'!*6FGO  DIIMM*<>NOQVW 99XsH55IIx2 IIMM(H-QWWYYIIXx0 99Xs,>??))%0		8X.<<<IIXt,IIMM(#))%0		""$<<<HHMMO  JJLE	s   #V "V /V V$c                   \         P                  ! R RV4      p\         P                  ! RRV4      pVP                  R4      pV P                  P	                  4         V P                  P                  RRR4       V P                  P                  RR4       V P                  P                  R	R4      pVP                  4       P                  R
4      '       d.   V P                  V4       V P                  P                  R	R4      pV P                  P                  RV^ ,          P                  4       V P                  4       \        V4      ^8  d   \         P                  ! RV^ ,          4      P!                  ^ 4      p\         P                  ! RV4      P!                  ^ 4      pVR,           Fj  pVP#                  V4      '       d   Wg\        V4      R ,           pV P                  P                  RRVP                  4       ,           V P                  4       Kl  	  V P                  P%                  R4       V P                  P'                  4        R#   T P                  P%                  R4       T P                  P'                  4        i ; i)z^\s*\nr_   z\n\s*$r   r  r   r   rt   rR  r{   :z	^([ \t]*)r3   NNN)resubr  rK   undo_block_startr}   r[  rP  rstripendswithr  rt   r  user_input_insert_tagsr   searchgroupr   r  undo_block_stop)rF   r0  rx   r   prefixorig_base_indentnew_base_indentr   s   &&&     r'   r  PyShell.recall-  s   FF9b!$FF9b!$		""$	(II  u5IIx2YY]]#5x@F}}'',,--e4'98DIIXuQx~~'7!88:5zA~#%99\58#D#J#J1#M #%99\6#B#H#H#K!"IID'788.c:J6K6L1MMII$$Xtdkkm/C%)%@%@B	 & IIMM(#II%%' IIMM(#II%%'s   A9I EI 7Jz[ \t]*(\n[ \t]*)?\zc                   V P                   P                  R 4      pV P                   P                  RR4      pV P                  P	                  RV4      pV P
                  P                  V4      pV'       gc   V P                   P                  V4      R8X  d'   V P                   P                  V P                  V4       V P                  P                  4        R# R# )end-2cr   rR  r_   r   N)rK   rk   rP  _last_newline_rer  ro   r  r}   r  r  update_sidebar)rF   index_beforer   input_is_completes   &   r'   r  PyShell.runitJ  s    yyx0yy}}Xx0 $$((T2 KK11$7 yy}}\*d2		$$T%@%@,O--/ !r0   c                .   V P                   P                  '       d   V P                   P                  4       # ^ RIHp  V! V P
                  \        P                  V P                  4       R#    \        P                  ! RRT P                  R7        R# ; i)r   )StackBrowserzNo stack tracez:There is no stack trace yet.
(sys.last_exc is not defined)r  N)ro   r>  r  idlelib.stackviewerr  r   r  last_excrO   r	   r   rK   )rF   rx   r  s   && r'   r  PyShell.open_stack_viewerV  ss    ;;;;22444	"CLL$**= 	"  !10yy" s   ,A, ,%Bc                r    V P                   P                  R 4       V P                   P                  R4       R# )r   rS  N)rK   r  r   s   &&r'   r"  PyShell.view_restart_markd  s"    		h		i r0   c                >    V P                   P                  R R7       R# )Tr9  N)ro   ra  r   s   &&r'   r#  PyShell.restart_shellh  s    &&&5r0   c                   V P                  4        V P                  pV P                  '       d;   VP                  V P                  4      '       d   VR \	        V P                  4      )  pV P
                  P                  RR4       V P                  P                  V4       V P                  P                  4        V P
                  P                  RR4       V P                  4        V P                  P                  4        R # )Nr6  z	iomark-1crt   rR  )r  r  r  r  r   rK   rj   r6  r    r  r  r[  set_line_and_columnrV   
reset_undo)rF   r  s   & r'   r]  PyShell.showpromptl  s    <<<FOODLL99/c$,,//0F		)[16"))+		8X.  "r0   c                0   V P                   P                  P                  p\        V^RR7      pRP	                  VP                  V4      4      pVP                  R4      '       g
   VR,          pV P                  P                  P                  RVR4       R# )   T)r  tabsizeexpand_tabsr   r  r8  N)
ro   r  r  r   rS   r  r  r/  bottomrt   )rF   r  r  wrapperwrapped_msgs   &&   r'   show_warningPyShell.show_warningz  sr    %%++E1$GiiS 12##D))4K1;Ir0   c                   V P                   P                  R R4      pV P                  '       d   V P                  P                  V4       V P                   P                  R4      R8w  d   V P                   P	                  RR4       V P                   P                  R R4       V P                  4        V P                  P                  4        R# )r   rR  r  r   N)	rK   rP  r.  storert   r[  r  ctipremove_calltip_window)rF   r  s   & r'   r  PyShell.resetoutput  s    x2<<<LLv&99=="d*IIXt,		8X.  "		'')r0   c                
    V P                   P                  R R4       \        P                  ! WVR 4      pV P                   P                  R R4       T P                  '       d   RT n        \
        '       g   \        hT#    h ; i)r   rightrT  F)rK   r\  r   r    r  r  r  )rF   r0  r   counts   &&& r'   r    PyShell.write  so    	II""8W5 &&th?EII""8V4 ===!DM!>''	s   AA? ?Bc                   <  V P                   P                  R RR4      '       d   R#  \        ST `  4       #   \         d     R# i ; i)r  r   r   r  )rK   r   r   r   r   r7  s   &r'   r   PyShell.rmenu_check_cut  sM    	yy  c8<<! = w&((  		s   "7 AAc                j   < V P                   P                  R RR4      '       d   R# \        SV `  4       # )rt   r   r   r  )rK   r   r   r   r7  s   &r'   r   PyShell.rmenu_check_paste  s-    99Xc(33w(**r0   c                n    V P                   P                  4        V P                  P                  4        R # r*   )r$  squeeze_current_textr  r  r   s   &&r'   r%  "PyShell.squeeze_current_text_event  s$    **,))+r0   c                :    V P                   P                  4        R # r*   )r  r  )rF   rk   rK   r   s   &&&&r'   on_squeezed_expandPyShell.on_squeezed_expand  s    ))+r0   )r  r  r  r6  r  rY  r.  r  ro   r  r  r  r  r'  r(  r&  r  r$  r8  r   r7  r  r  ))r   _File)edit_Edit)rq   _Debug)options_Options)window_Window)help_Help)Squeezer  )zCopy with promptsr
  r   r*   )r   )Rr   r   r   r   idlelib.squeezerr  r   r  r   r   r   r   r  r   r   r   r7   	itertools	takewhile_idxrt   allow_line_numbersr  idlelib.historyr  idlelib.sidebarr  rJ   r5  r:  rC  rH  rX  r!  r  rY  r  r  r  r  rf  ri  r  rl  r   rm  rn  r  r  r  rW  r   r  r  r  r   rZ  r  r  r  r  r  r  r  r  r  r  r  r  r"  r#  r]  r  r  r    r   r   r%  r  r   r   r   r   s   @@r'   r   r   I  s    )."22K ,N)MJ **/. K s4	++2KA   D t 2 3 	$ (,P;d-/ 7"+( GIHIG %7&
&>
("   RJ4.,M^(8 zz"89
0!6J*)+
,, ,r0   r   c           
          V P                   R 8X  d6   R F-  pV P                  VRRV P                  VR4      ,           4       K/  	  R# R# )x11z	<<Paste>>z%catch {%W delete sel.first sel.last}
N)TextEntrySpinbox)_windowingsystem
bind_class)r   clss   & r'   fix_x11_paster!    sG    %-COO8[9:; . &r0   a  
USAGE: idle  [-deins] [-t title] [file]*
       idle  [-dns] [-t title] (-c cmd | -r file) [arg]*
       idle  [-dns] [-t title] - [arg]*

  -h         print this help message and exit
  -n         run IDLE without a subprocess (DEPRECATED,
             see Help/IDLE Help for details)

The following options will override the IDLE 'settings' configuration:

  -e         open an edit window
  -i         open a shell window

The following options imply -i and will open a shell:

  -c cmd     run the command in a shell, or
  -r file    run script from file

  -d         enable the debugger
  -s         run $IDLESTARTUP or $PYTHONSTARTUP before anything else
  -t title   set title of shell window

A default edit window will be bypassed when -c, -r, or - are used.

[arg]* are passed to the command (-c) or script (-r) in sys.argv[1:].

Examples:

idle
        Open an edit window or shell depending on IDLE's configuration.

idle foo.py foobar.py
        Edit the files, also open a shell if configured to start with shell.

idle -est "Baz" foo.py
        Run $IDLESTARTUP or $PYTHONSTARTUP, edit foo.py, and open a shell
        window with the title "Baz".

idle -c "import sys; print(sys.argv)" "foo"
        Open a shell window and run the command, passing "-c" in sys.argv[0]
        and "foo" in sys.argv[1].

idle -d -s -r foo.py "Hello World"
        Open a shell window, run a startup script, enable the debugger, and
        run foo.py, passing "foo.py" in sys.argv[0] and "Hello World" in
        sys.argv[1].

echo "import sys; print(sys.argv)" | idle - "foobar"
        Open a shell window, run the script piped in, passing '' in sys.argv[0]
        and "foobar" in sys.argv[1].
c            	         ^ RI p ^ RIHp ^ RIHp ^ RIHp \        R4       RsRpRpRpRpRpRp	 V P                  \        P                  R,          R4      w  rX
 EF  w  rVR8X  d   TpRpVR8X  d   RpRpVR8X  d   RpVR8X  d9   \        P                  P!                  \        4       \        P                  ! 4        VR8X  d   RpVR8X  d   \        R\        P                  R7       RsVR8X  dL   Tp\"        P$                  P'                  V4      '       d   M!\        RV4       \        P                  ! 4        RpVR8X  d   Rp	RpVR8X  g   K  V\(        n        RpEK  	  X'       d/   V^ ,          R8X  d!   \        P,                  P/                  4       pRp\1        \3        \        P$                  4      4       FH  p\"        P$                  P5                  \        P$                  V,          4      \        P$                  V&   KJ  	  V'       d+   V^ ,          R8X  d   R.VR,          ,           \        n	        EM&V'       d   R.V,           \        n	        EM	V'       d   V.V,           \        n	        MV'       d   Rp. pV F1  pVP7                  \"        P$                  P9                  V4      4       K3  	  V FY  p\"        P$                  P5                  V4      pV\        P$                  9   d   K9  \        P$                  P;                  ^ V4       K[  	  MJ\"        P<                  ! 4       pV\        P$                  9  d!   \        P$                  P;                  ^ V4       \>        P@                  ! RRRRR7      pT;'       g    TpT;'       g    V'       * p\        '       d   V'       g   \C        4        \E        RR7      s#\F        PI                  4        ^ R I%H&p V! \F        4       \"        P$                  PO                  \"        P$                  P9                  \P        4      R!4      pV! 4       R"8X  d8   \"        P$                  PO                  VR#4      p\F        PS                  VR$7       MVPU                  4       '       g   \V        R%8  d   R&pR.pMR'pR/pV Uu. uF,  p\"        P$                  PO                  VR(VV3,          4      NK.  	  ppV Uu. uF  p\Y        \F        VR)7      NK  	  pp\F        PZ                  ! R.VO5!   \]        \F        4       \_        \F        4       \a        \F        4      s1VPe                  \F        \b        4       V'       dg   V'       g_   V'       gW   VR*,           F-  p\b        Pg                  V4      e   K  VPi                  V4       K/  	  V'       g   \b        Pk                  4        V'       df   \b        Pm                  4       pV'       g   R# VPU                  4       '       d1   \b        Pn                  '       d   VPp                  Ps                  4        M\b        Pt                  pV'       d   VPw                  4        V	'       d   \"        Px                  P{                  R+4      ;'       g     \"        Px                  P{                  R,4      pV'       dA   \"        P$                  P'                  V4      '       d   VP|                  P                  V4       V'       g	   V'       d   VP|                  P                  R-P                  \        P                  4      4       V'       d   VP|                  P                  V4       MpV'       d7   VP|                  P                  V4       VP|                  P                  V4       M1V'       d*   VP                  4       pV'       d   VP                  V4       \b        P                  '       d   \F        P                  4        K,  \F        P                  4        \        R4       R#   T P                   dG   p\        R	T R
\         2\        P                  R7       \        P                  ! ^4        Rp?ELRp?ii ; iu upi u upi )0r   N)system)testing)macosxTFr  zc:deihnr:st:zError: r   r   r,  z-dz-ez-hz-iz-nz: Warning: running IDLE without a subprocess is deprecated.z-rzNo script file: z-sz-t-r_   r&  r'  zeditor-on-startupr(  )r*  Idle)	className)fix_scalingIconsWindowszidle.ico)r)  g333333!@z.pngz.gifz	idle_%d%s)masterr   :NNNIDLESTARTUPPYTHONSTARTUPzdif 1:
            import sys as _sys
            _sys.argv = {!r}
            del _sys
            
)       0      )r/  r0  r1  )Igetoptr  r#  r  r$  r%  r/   r  r  argverrorr  	usage_msgr8  exitr7  r    rQ   rR   r   r   r  r   r  r   r   r  rm   dirnamert   getcwdr   r.  NoDefaultRootr  r   r  idlelib.runr)  rS   __file__wm_iconbitmapisAquaTk	TkVersion
PhotoImagewm_iconphotor   r!  r   rO   setupAppr   r|   newrP   r  r   lowerrn   rn  r  rP  ro   r  r|  r}  r  r  preferTabsPreferenceWarningr  inversedictr  destroy)r3  r#  r$  r%  enable_shellenable_editrq   cmdscriptstartupoptsrZ   r  oarN  pathxr%   dir
edit_startr)  icondiriconfileextsizessize	iconfilesiconsr  prefer_tabs_preference_warnings                                 r'   r&  r&    s    TNLKE
CFG]]388B<@
 9CL9EL9K9JJY'HHJ9L9Nzz#"N9Fww~~f%%(&1
L9GL9"#GL? @ Q3iinn3sxx=!ggoochhqk2 "Q34$r(?	6D=	8d?	HLL23 C''//#&C#((?3' 
 iikchhHHOOAs###FI$7fFJ++K22{?L ~gDMMO' ggll277??84g>Gx977<<48,__C%EC E!&(!& WW\\';$+DE!& 	 ( "+,!*X 4h7!* 	 ,$'' $$D!E
OOD% v GG::h'/KK) $ 		  "??
 IIOO ::>>-0 3 3::>>/2 	x00LL!!(+
f ! &"		$
 LL##C(LL((0LL!!&)	 *0)K)K)M&)=>



LLNUy << uByk*<n(,s#   )` 2a)a.a& ;a!!a&)NN)Nr  r   r  r  ImportErrorr  r  r  r  idlelib.utilr   r	   r  r
   r  r5   rQ   os.pathr   r  rC  r   textwrapr   rk  r<  r  r,   idlelib.colorizerr   idlelib.configr   idlelib.delegatorr   r  r   r   idlelib.editorr   r   idlelib.filelistr   idlelib.outwinr   r   r   r;  r   r   r   idlelib.undor   r  r;  r  eofr7  r  	NameErrorr   r(   r+   r/   
checkcacher=   r?   r   r   r   r   	RPCClientr   r  r	  r   r!  r6  r&  r   r0   r'   <module>rj     s   z%([[%<CKK!" <<7*O  '   	  # 	         , # '   6 % '   G G & 	
 CDHDH "  )  +/2;2F2F( 5	 {", {"|h (
2^ 
2/M /D1	 1#-- m(0 m(`c	,l c	,L;4	lnb zF  w4  	 9?B~~O
Q-b  		s   F4 )G 4$GG%$G%