%PDF- %PDF-
Mini Shell

Mini Shell

Direktori : /usr/local/lib/python2.7/idlelib/
Upload File :
Create Path :
Current File : //usr/local/lib/python2.7/idlelib/CallTipWindow.pyo

ó
Pêáac@s›dZddlmZmZmZmZmZdZdZdZ	dZ
d	Zd
Zddd„ƒYZ
d
„Zedkr—ddlmZeeƒndS(s…A CallTip window class for Tkinter/IDLE.

After ToolTip.py, which uses ideas gleaned from PySol
Used by the CallTips IDLE extension.
iÿÿÿÿ(tTopleveltLabeltLEFTtSOLIDtTclErrors<<calltipwindow-hide>>s<Key-Escape>s
<FocusOut>s<<calltipwindow-checkhide>>s<KeyRelease>s<ButtonRelease>idtcalltipwindowregion_righttCallTipcBsJeZd„Zd„Zd„Zdd„Zd„Zd„Zd„Z	RS(cCsO||_d|_|_d|_|_d|_d|_|_d|_	dS(N(
twidgettNonet	tipwindowtlabelt	parenlinetparencoltlastlinethideidtcheckhideidtcheckhide_after_id(tselfR((s1/usr/local/lib/python2.7/idlelib/CallTipWindow.pyt__init__s		cCs(t|jjdƒjdƒdƒ}||jkr8dS||_|jjdƒ||jkr…|jjd|j|jfƒ}n|jjd|ƒ}|sÐt	|jjdƒƒ}d|d<d|d<n|d|jj
ƒd}|d|d	|jjƒ}|jj
d
||fƒdS(s;Check if needs to reposition the window, and if so - do it.tinsertt.iNs%d.%ds%d.0iiis+%d+%d(tintRtindextsplitR
tseeRtbboxRtlisttwinfo_rootxtwinfo_rootyR	twm_geometry(Rtcurlinetboxtxty((s1/usr/local/lib/python2.7/idlelib/CallTipWindow.pytposition_windows %	

cCs½||_|js|jr dS|jjt|ƒtt|jj|ƒjdƒƒ\|_	|_
t|jƒ|_}|jƒ|j
dƒy#|jjdd|jddƒWntk
rÆnXt|d|jd	td
ddtd
dd|jdƒ|_|jjƒ|jƒ|jƒ|jjt|jƒ|_x!tD]}|jjt|ƒqGW|jjt |jƒ|jjt!|j"ƒ|_#x!t$D]}|jjt!|ƒqœWdS(sMShow the calltip, bind events which will close it and reposition it.
        NRis!::tk::unsupported::MacWindowStyletstylethelptnoActivatesttexttjustifyt
backgrounds#ffffe0trelieftborderwidthtfont(%R&R	Rtmark_sett
MARK_RIGHTtmapRRRRRRR"twm_overrideredirectttktcallt_wRRRRR
tpacktupdate_idletaskstlifttbindtCHECKHIDE_VIRTUAL_EVENT_NAMEtcheckhide_eventRtCHECKHIDE_SEQUENCESt	event_addtaftertCHECKHIDE_TIMEtHIDE_VIRTUAL_EVENT_NAMEt
hide_eventRtHIDE_SEQUENCES(RR&t	parenleftt
parenrightttwtseq((s1/usr/local/lib/python2.7/idlelib/CallTipWindow.pytshowtip/s:	-







cCs×|js
dStt|jjdƒjdƒƒ\}}||jks|||jkrd||jks||jjddt	ƒr‰|j
ƒnJ|jƒ|jdk	r¸|jj|jƒn|jjt|jƒ|_dS(NRRt>(R	R.RRRRRRtcompareR-thidetipR"RRtafter_cancelR;R<R8(RteventRtcurcol((s1/usr/local/lib/python2.7/idlelib/CallTipWindow.pyR8Xs	*

cCs|js
dS|jƒdS(N(R	RG(RRI((s1/usr/local/lib/python2.7/idlelib/CallTipWindow.pyR>js	cCsê|js
dSx!tD]}|jjt|ƒqW|jjt|jƒd|_x!tD]}|jjt	|ƒqWW|jjt	|j
ƒd|_
|jjƒd|_|jjƒd|_|jj
tƒd|_|_|_dS(N(R	R9Rtevent_deleteR7tunbindRRR?R=RR
tdestroyt
mark_unsetR-RRR
(RRC((s1/usr/local/lib/python2.7/idlelib/CallTipWindow.pyRGps 	
	
	
	
	cCs
t|jƒS(N(tboolR	(R((s1/usr/local/lib/python2.7/idlelib/CallTipWindow.pyt	is_active…sN(
t__name__t
__module__RR"RDRR8R>RGRP(((s1/usr/local/lib/python2.7/idlelib/CallTipWindow.pyRs			)		c	s ddlm}m}m}m}||ƒ}|jdƒ|jd|jƒd|jƒdfƒ||ƒ}|j	d|d|d	d
ƒ|j
ddƒ|jƒt|ƒ‰‡fd
†}‡fd†}|j
ddƒ|j
ddƒ|jd|ƒ|jd|ƒ|jƒdS(Niÿÿÿÿ(RtTextRtBOTHs
Test calltipss
200x100+%d+%diÈi–tsidetfilltexpandiRsstring.splitcsˆjdddƒdS(Ns(s=Hello world)Rtend(RD(RI(tcalltip(s1/usr/local/lib/python2.7/idlelib/CallTipWindow.pytcalltip_show–scsˆjƒdS(N(RG(RI(RY(s1/usr/local/lib/python2.7/idlelib/CallTipWindow.pytcalltip_hide˜ss<<calltip-show>>t(s<<calltip-hide>>t)(tTkinterRRSRRTttitletgeometryRRR3RtupdateRR:R6t	focus_set(	tparentRRSRRTttopR&RZR[((RYs1/usr/local/lib/python2.7/idlelib/CallTipWindow.pyt_calltip_window‰s""

t__main__(trunN(s<Key-Escape>s
<FocusOut>(s<KeyRelease>s<ButtonRelease>((t__doc__R^RRRRRR=R?R7R9R<R-RReRQtidlelib.idle_test.htestRg(((s1/usr/local/lib/python2.7/idlelib/CallTipWindow.pyt<module>s(y	

Zerion Mini Shell 1.0