3 2a#@sddlZddlZddlmZmZddlmZmZmZm Z m Z ddlm Z m Z m Z mZmZmZmZmZmZmZddlmZddZGdd d eZed krdd lmZed d ddddlmZeedS)N)python_version architecture)ToplevelFrameLabelButton PhotoImage) SUNKENTOPBOTTOMLEFTXBOTHWEWNSEWE)textviewcCs2tjdkrtjdkrdSdStdddSdS)Ndarwin Z64Z32rl)sysplatformmaxsizerrr//opt/alt/python36/lib64/python3.6/help_about.py build_bitss rc@sreZdZddddddZddZdd Zd d Zd d ZddZddZ ddZ ddZ dddZ dddZ dS) AboutDialogNF)_htest_utestcCstj|||jdd|jd|jd|j|s6dndfd|_d|_|j|j ddd |j |pd t d t d |j ||j|jd |j||_|jj|jd|j|jd|jd|_||_|s|j|jdS)N) borderwidthz+%d+%ddz#bbbbbbz#000000F)heightwidthz About IDLE z (z bit)ZWM_DELETE_WINDOWzz)r__init__Z configureZgeometryZ winfo_rootxZ winfo_rootybgfgcreate_widgetsZ resizabletitlerrZ transientZgrab_setZprotocolokparent button_okZ focus_setZbind_current_textviewrZ deiconifyZ wait_window)selfr,r*rrrrrr&s.     zAboutDialog.__init__cCst|dtd}t|}|jttd|jtdtdt|d|jd|_ |j jddd t||j d }|jdtd t |d |j |j d} t || t|j |j d } | j ddtd!ddd"t |d#t|j |j d } | j d$ddtddd%t |d&tdd!d't|j |j d } | j d(ddtddd%t|d)td|j d*j d+dtd!ddd"t |d,t|j |j d-} | j d.dtdddt |d/||j |j d-}|j d.d)tdddt||j d }|j dddtd0t|d1d+|j |jd2|_ |j jtddd3t|d4d+|j |j!d2|_"|j"jtddd3t|d5d+|j |j#d2|_$|j$jtddd3t|d)td|j d*j d6dtd!ddd"t |d7t|j |j d-}|j d8dtdddt||j d }|j d9dd!td0t|d:d+|j |j%d2|_&|j&jtddd3t|d;d+|j |j'd2|_(|j(jtddd3t|d5d+|j |j)d2|_*|j*jtddd3dS)?Nr)r!relief)sidefillT)r1expandr2ZClose)textcommandr )padxpady)r')r3r2ZIDLEcourierbold)r4r(r'Zfontr )rowcolumnstickyr6r7infoZ patchlevelz8.6z.pngz.gifZIconsZidle_48)Zmasterfile)Zimager')r<r=r>Zrowspanr6r7z8Python's Integrated Development and Learning Environment )r4Zjustifyr(r')r<r=r> columnspanr6r7zemail: idle-dev@python.org)r<r=rCr>r6r7zhttps://docs.python.org/z/library/idle.html)r!r0r$r'zPython version: )r4r(r' z Tk version: )r<r=rCr>ZLicense)r4r%Zhighlightbackgroundr5)r1r6r7Z CopyrightZCredits zIDLE version: ZREADMEZNEWS)r8r9r:z z=Python's Integrated Development and Learning Environment )+rr packr r r rrr+r-r'rr(ZgridrZtkZcallospathjoinabspathdirname__file__rZ_rootZ icon_imagerr rrrshow_py_licenseZ py_licenseshow_py_copyrightZ py_copyrightshow_py_creditsZ py_credits show_readmeZreadmeshow_idle_newsZ idle_newsshow_idle_creditsZ idle_credits)r/frameZ frame_buttonsZframe_backgroundheaderZ tk_patchlevelZextZiconZlogoZ byline_textZbylineZemailZdocsZpyverZtkverZ py_buttonsZidleverZ idle_buttonsrrrr)<s            zAboutDialog.create_widgetscCs|jdtdS)NzAbout - License)display_printer_textlicense)r/rrrrSszAboutDialog.show_py_licensecCs|jdtdS)NzAbout - Copyright)r[ copyright)r/rrrrTszAboutDialog.show_py_copyrightcCs|jdtdS)NzAbout - Python Credits)r[credits)r/rrrrUszAboutDialog.show_py_creditscCs|jddddS)NzAbout - Creditsz CREDITS.txtzutf-8)display_file_text)r/rrrrXszAboutDialog.show_idle_creditscCs|jddddS)NzAbout - Readmez README.txtascii)r_)r/rrrrVszAboutDialog.show_readmecCs|jddddS)Nz About - NEWSzNEWS.txtzutf-8)r_)r/rrrrWszAboutDialog.show_idle_newscCs.|jdj|j}tj||||jd|_dS)NrA)r)_Printer__setuprO_Printer__linesrZ view_textrr.)r/r*Zprinterr4rrrr[s z AboutDialog.display_printer_textcCs:tjjtjjtjjt|}tj|||||jd|_ dS)N)r) rMrNrOrPrQrRrZ view_filerr.)r/r*filenameencodingfnrrrr_szAboutDialog.display_file_textcCs|j|jdS)N)Z grab_releaseZdestroy)r/Zeventrrrr+szAboutDialog.ok)N)N)N)__name__ __module__ __qualname__r&r)rSrTrUrXrVrWr[r_r+rrrrrs"V r__main__)mainz!idlelib.idle_test.test_help_aboutrF) verbosityexit)run)rMrrrrZtkinterrrrrrr r r r r rrrrrZidlelibrrrrfZunittestrjZidlelib.idle_test.htestrmrrrrs0 5