ó |G_Tc@s}dZddlTdZdZdZdZd Zd Zd dd „ƒYZd „Z e dkryddl m Z e e ƒ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ÿÿÿÿ(t*s<>s s s<>s sidtcalltipwindowregion_righttCallTipcBsJeZd„Zd„Zd„Zdd„Zd„Zd„Zd„Z RS(cCsO||_d|_|_d|_|_d|_d|_|_d|_ dS(N( twidgettNonet tipwindowtlabelt parenlinetparencoltlastlinethideidt checkhideidtcheckhide_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(RR*RRRRRRtcompareR)thidetipRR Rt after_cancelR:R;R7(R teventRtcurcol((s1/usr/local/lib/python2.7/idlelib/CallTipWindow.pyR7Ws *  cCs|js dS|jƒdS(N(RRF(R RH((s1/usr/local/lib/python2.7/idlelib/CallTipWindow.pyR=is cCsê|js dSx!tD]}|jjt|ƒqW|jjt|jƒd|_x!tD]}|jjt |ƒqWW|jjt |j ƒd|_ |j j ƒd|_ |jj ƒd|_|jj tƒd|_|_|_dS(N(RR8Rt event_deleteR6tunbindR RR>R<R Rtdestroyt mark_unsetR)RRR (R RB((s1/usr/local/lib/python2.7/idlelib/CallTipWindow.pyRFos          cCs t|jƒS(N(tboolR(R ((s1/usr/local/lib/python2.7/idlelib/CallTipWindow.pyt is_active„sN( t__name__t __module__RRRCRR7R=RFRO(((s1/usr/local/lib/python2.7/idlelib/CallTipWindow.pyRs   '   csŠtƒ‰ˆjdƒttttjd|jƒƒƒƒ\}}}}ˆjd||dfƒdd‡fd†ƒY}|ƒ}dS(Ns Test calltipss[x+]s+%d+%di–t MyEditWincs)eZ‡fd†Zd„Zd„ZRS(cs¶tˆƒ}|_|jdtdtddƒ|jddƒˆjƒt|ƒ|_|j ddƒ|j d d ƒ|j d|j ƒ|j d |j ƒ|j ƒˆjƒdS( NtsidetfilltexpandiRs string.splits<>t(s<>t)(tTextR"R4R2tBOTHRtupdateRtcalltipR9R5t calltip_showt calltip_hidet focus_settmainloop(R R"(troot(s1/usr/local/lib/python2.7/idlelib/CallTipWindow.pyRs  cSs|jjdddƒdS(Ns Hello worldRtend(R[RC(R RH((s1/usr/local/lib/python2.7/idlelib/CallTipWindow.pyR\žscSs|jjƒdS(N(R[RF(R RH((s1/usr/local/lib/python2.7/idlelib/CallTipWindow.pyR]¡s(RPRQRR\R]((R`(s1/usr/local/lib/python2.7/idlelib/CallTipWindow.pyRRŽs ((tTkttitleRR*RtreRtgeometry(tparenttwidththeightRRRRteditwin((R`s1/usr/local/lib/python2.7/idlelib/CallTipWindow.pyt_calltip_windowˆs   3t__main__(trunN(s s (s s(( t__doc__tTkinterR<R>R6R8R;R)RRjRPtidlelib.idle_test.htestRl(((s1/usr/local/lib/python2.7/idlelib/CallTipWindow.pyts w