� ��^c @s�ddlZddlZddlZddlZddlTddlZddlZdQZdRZdSZ dTZ dUZ dZ d dVd ��YZ d �Zd �Zd �Zd�Zd�Zd�Zd�Zd�Zddddgad�Zd�Zd�Zd�Zd�Zd�Zd�Zd�Zd�Zd �Z d!�Z!d"�Z"d#�Z#d$�Z$d%�Z%d&�Z&d'�Z'd(�Z(d)�Z)d*�Z*d+�Z+d,�Z,d-�Z-id.d/6d0d16Z.id2d26d3d46d5d66d7d86d9d:6d;d<6d=d=6d>d?6d@dA6dBdC6dDdE6dFdG6dHdI6dJdK6Z/iZ0d2d4d6d=d:d<d?dAdEdCdGdIdKg e0d/FRt BalloonHelptvariable( RR tFrametRAISEDt MenubuttontpacktLEFTtRIGHTtMenut add_commandtadd_checkbuttont ToggleHelpR (RRtwtfilethelptfmthm((s+/usr/lib64/python2.7/Demo/tix/tixwidgets.pyt MkMainMenu9s !!    c Cs,|j}tj|dddddd�}|d|d<|jddd d d d |dd ��|jdddd d d |dd��|jdddd d d |dd��|jdddd d d |dd��|jdddd d d |dd��|jdddd d d |dd��|S(NtipadxitipadytoptionssC tagPadX 6 tagPadY 4 borderWidth 2 tbgtwelR,tWelcomeR&it createcmdcSs t||�S(N(t MkWelcome(R=tname((s+/usr/lib64/python2.7/Demo/tix/tixwidgets.pyR0ZRtchotChooserscSs t||�S(N(t MkChoosers(R=RK((s+/usr/lib64/python2.7/Demo/tix/tixwidgets.pyR0\RtscrsScrolled WidgetscSs t||�S(N(tMkScroll(R=RK((s+/usr/lib64/python2.7/Demo/tix/tixwidgets.pyR0^RtmgrsManager WidgetscSs t||�S(N(t MkManager(R=RK((s+/usr/lib64/python2.7/Demo/tix/tixwidgets.pyR0`RRsDirectory ListcSs t||�S(N(t MkDirList(R=RK((s+/usr/lib64/python2.7/Demo/tix/tixwidgets.pyR0bRtexpsRun Sample ProgramscSs t||�S(N(tMkSample(R=RK((s+/usr/lib64/python2.7/Demo/tix/tixwidgets.pyR0dR(RR tNoteBooktadd(RRR=((s+/usr/lib64/python2.7/Demo/tix/tixwidgets.pytMkMainNotebookOs"  c Csq|j}tj|dtjdd�}tj|dtjdd�t_tjjddddddd d �|S( NR#R"itpadxitpadytleftitrights%70( RR R3R4tLabeltSUNKENtdemoR tform(RRR=((s+/usr/lib64/python2.7/Demo/tix/tixwidgets.pyt MkMainStatusgs  !%c Cs|j}|j�}|jd�|j�dkrD|jd�n |jd�tj|�t_|j �}|j �}|j �}|j dt dt�|j dtdt�|j dt dddtd d d d �tjtjd <|jd |d��dS(NsTix Widget Demonstrationi s 790x590+10+10s 890x640+10+10R)tfilltexpandiRYiRZR tWM_DELETE_WINDOWcSs |j�S(N(R/(R((s+/usr/lib64/python2.7/Demo/tix/tixwidgets.pyR0�R(Rtwinfo_topleveltwm_titletwinfo_screenwidthtgeometryR tBalloonR_RRBRXRaR6tTOPtXtBOTTOMtBOTHR t wm_protocol(RRtztframe1tframe2tframe3((s+/usr/lib64/python2.7/Demo/tix/tixwidgets.pytbuildps       (cCs d|_dS(s@Quit our mainloop. It is up to you to call root.destroy() after.iN(R(R((s+/usr/lib64/python2.7/Demo/tix/tixwidgets.pyR/�scCsx|jdkry-x&|jdkr=|jjjt�qWWqtk r\d|_dStk r�tjdd�dkrd|_dSqqt j �\}}}d}x+t j |||�D]}||d7}q�Wytj d |�WnnXd|_td�qXqWdS( s�This is an explict replacement for _tkinter mainloop() It lets you catch keyboard interrupts easier, and avoids the 20 msec. dead sleep() which burns a constant CPU.iiNt Interrupts Really Quit?tyesRs tError(RRttkt dooneeventtTCL_ALL_EVENTSt SystemExittKeyboardInterruptt tkMessageBoxt askquestionRtexc_infot tracebacktformat_exceptiont showerror(RtttvttbR$tline((s+/usr/lib64/python2.7/Demo/tix/tixwidgets.pytloop�s.     cCs|jj�dS(N(Rtdestroy(R((s+/usr/lib64/python2.7/Demo/tix/tixwidgets.pyR��s( t__name__t __module__R!RBRXRaRsR/R�R�(((s+/usr/lib64/python2.7/Demo/tix/tixwidgets.pyRs      "cCs.t|�atj�tj�tj�dS(N(RR_RsR�R�(R((s+/usr/lib64/python2.7/Demo/tix/tixwidgets.pytRunMain�s   c Csi|j|�}t|�}t|�}|jdtdtdddd�|jdtdtdd�dS(NR)RbRYiRZRci(tpaget MkWelcomeBart MkWelcomeTextR6RjRkRm(tnbRKR=tbarR$((s+/usr/lib64/python2.7/Demo/tix/tixwidgets.pyRJ�s   "cCs�tj|dddtj�}tj|d|d��}tj|d|d��}d|jdtfunccSs%|jjdt|�dt|��S(Nt tixDoWhenIdlet attachwidget(RwtcallR�(targtrhtlist((s+/usr/lib64/python2.7/Demo/tix/tixwidgets.pyR0sN(R R3R�R"R�tScrolledListBoxtplaceR�RR�t ResizeHandleR4tButtont propagateR6RkRRmtbind(R=RtbotR�RJRItbtn((s+/usr/lib64/python2.7/Demo/tix/tixwidgets.pyR0�s0  " $ c Cs=|jdddddddd�|j�|j|�dS( NR6i2R7i�R�ixR�iP(RLtupdatet attach_widget(RIRJ((s+/usr/lib64/python2.7/Demo/tix/tixwidgets.pyRC s" c Cs�d}tjjtjdd�}tjj|�s@|d7}ntj|dddd�}tj|�}tj|dtj dd d tj d |�}tj |d d �}|j j dd|�}tj|j d|�}|jdddtj�|jdddddddd�tj|dddtjdddddd d!d�} tj|d d"d#| |d$��} |jd%�|jdtj�| jd tj�|jdddtj�|jdtj�|jd&d'd%| |d(��d)S(*s�The ScrolledWindow widget allows you to scroll any kind of Tk widget. It is more versatile than a scrolled canvas widget. s}The Tix ScrolledWindow widget allows you to scroll any kind of Tk widget. It is more versatile than a scrolled canvas widget.tbitmapsstix.gifs (Image missing)R�iJR�R#i�R�R$R�R�tphotoR>timageRciRbR6iR7i�i�ixRFR=R>iR?R@i2RARBR.cSs t||�S(N(t SWindow_reset(R=R6((s+/usr/lib64/python2.7/Demo/tix/tixwidgets.pyR0,RisRDcSs%|jjdt|�dt|��S(NRERF(RwRGR�(RHRIR�((s+/usr/lib64/python2.7/Demo/tix/tixwidgets.pyR03sN(RRtjoinR_RtisfileR R3R�R"R�R�R�t image_createR]R6RmRLRMR4RNRORkRRP( R=R$R>RRQR�R�timage1tlblRIRR((s+/usr/lib64/python2.7/Demo/tix/tixwidgets.pyR1s0   " $ c Cs=|jdddddddd�|j�|j|�dS( NR6iR7i�R�i�R�ix(RLRSRT(RIR�((s+/usr/lib64/python2.7/Demo/tix/tixwidgets.pyRX6s" cCs�tj|dddd�}tj|�}tj|dtjdddtjdd�}tj|d d �}d |jd <|jjtjd �|j dddddddd�tj |dddtj dddddddd�}tj |ddd||d��}|j d �|jd!tj�|jdtj�|jd"dd!tj�|jd!tj�|jd#d$d ||d%��d&S('s�The TixScrolledWindow widget allows you to scroll any kind of Tk widget. It is more versatile than a scrolled canvas widget.R�iJR�R#i�R�R$s}The Tix ScrolledWindow widget allows you to scroll any kind of Tk widget. It is more versatile than a scrolled canvas widget.R�R�R�twraps�When -scrollbar is set to "auto", the scrollbars are shown only when needed. Additional modifiers can be used to force a scrollbar to be shown or hidden. For example, "auto -y" means the horizontal scrollbar should be shown when needed but the vertical scrollbar should always be hidden; "auto +x" means the vertical scrollbar should be shown when needed but the horizontal scrollbar should always be shown, and so on.R6iR7i�i�idRFR=R>iR?iR@i2RARBR.cSs t||�S(N(t SText_reset(R=R6((s+/usr/lib64/python2.7/Demo/tix/tixwidgets.pyR0VRiRbRcsRDcSs%|jjdt|�dt|��S(NRERF(RwRGR�(RHRIR�((s+/usr/lib64/python2.7/Demo/tix/tixwidgets.pyR0\sN(R R3R�R"R�t ScrolledTextR$RR�RLRMR4RNROR6RkRRmRP(R=RRQR�R�RIRR((s+/usr/lib64/python2.7/Demo/tix/tixwidgets.pyR2;s(    " $ c Cs=|jdddddddd�|j�|j|�dS( NR6iR7i�R�i�R�ix(RLRSRT(RIR�((s+/usr/lib64/python2.7/Demo/tix/tixwidgets.pyR__s" c Cs�|j|�}d}tj|ddd|�}tj|ddd|�}t|j�t|j�|jddddd |d d �|jddd d d d �dS( Ns label.padX 4R,sTix.PanedWindowREs Tix.NoteBookRiR[R\R�i����(R�R R�t MkPanedWindowR�t MkNoteBookR`(R�RKR=REtpanetnote((s+/usr/lib64/python2.7/Demo/tix/tixwidgets.pyRRds  "c Cs[tj|dtjdddtjdd�}tj|ddd d �}|jjd d �tj|d d�}|jddddd�}|jddd�}tj |�}tj |�}|j jtj d�|j jtj d�|j jtj d�|j jtj d�|j jtj d�|j jtj d�|j jtj d�|j d|j dNs label.padX 4Rt horizontalR)RciRbRJR�R$t5tflatR#R,sSelect a sample program:RYiRZsSource:REshlist.width 20RKtstextstix option get fixed_fontR�R�sRun ...trunsView Source ...tviewiRFtdisabledR�R�R^iPR�it.t separatorit drawbranchi tindentt wideselectcSst|||||d�S(NR�(t Sample_Action(targsR=tslbR�R�R�((s+/usr/lib64/python2.7/Demo/tix/tixwidgets.pyR0�RR.cSst|||||d�S(Ntbrowse(R�(R�R=R�R�R�R�((s+/usr/lib64/python2.7/Demo/tix/tixwidgets.pyR0�Rt browsecmdcSst|||||d�S(NR�(R�(R�R=R�R�R�R�((s+/usr/lib64/python2.7/Demo/tix/tixwidgets.pyR0�RcSst|||||d�S(NR�(R�(R�R=R�R�R�R�((s+/usr/lib64/python2.7/Demo/tix/tixwidgets.pyR0�RR�RWR"iR�i�titemtypeR�tdata(R�R RiR6RjRmRWR�R�R�R`RRwtevalR$tconfigR3RNR7tNONEthlistRlRkR^t add_childtWINDOWtTEXTtcommentststypestselection_clear(R�RKR=RERctf1tf2tlabtlab1R�R�R�R�R�R�ttypeR6tkey((s+/usr/lib64/python2.7/Demo/tix/tixwidgets.pyRUksd"  ..(""   ((     "" !%   c Bs@|j}|j�}|s2d|ds�0 �  %   % "         '  $  / .    ^    @