File "configSectionNameDialog.cpython-34.pyc"
Full Path: /home/attunedd/public_html/byp/izo/con7ext_sym404/rintoar.txt/opt/alt/python34/lib64/python3.4/idlelib/__pycache__/configSectionNameDialog.cpython-34.pyc
File size: 3.85 KB
MIME-type: text/x-bytecode.python
Charset: 8 bit
e f @ s d Z d d l Td d l j Z Gd d d e Z e d k r d d l Z e j d d d d
d d d l
m Z e e n d S)
a
Dialog that allows user to specify a new config file section name.
Used to get new highlight theme and keybinding set names.
The 'return value' for the dialog, used two placed in configDialog.py,
is the .result attribute set in the Ok and Cancel methods.
)*Nc @ sU e Z d Z d d d Z d d Z d d Z d d d
Z d d d Z d S)
GetCfgSectionNameDialogFc C sA t j | | | j d d | j d t d t | j | | j | | j | j d | j | | _
| | _ | | _ | j
| j | j | j j d | j j | j d | j | j d | j d | j | s| j d | j d n d f | j | j d S)
z
message - string, informational message to display
used_names - string collection, names already in use for validity check
_htest - bool, change box location when running htest
borderwidth ZheightwidthZWM_DELETE_WINDOWz+%d+%d d N)Toplevel__init__Z configureZ resizableZFALSEtitleZ transientZgrab_setZprotocolCancelparentmessage
used_namescreate_widgetsZwithdrawZupdate_idletasksmessageInfoconfig frameMainZwinfo_reqwidthZgeometryZwinfo_rootxZwinfo_widthZwinfo_rootyZwinfo_heightZwinfo_reqheightZ deiconifyZwait_window)selfr
r r r Z_htest r D/opt/alt/python34/lib64/python3.4/idlelib/configSectionNameDialog.pyr
s,
0
z GetCfgSectionNameDialog.__init__c C s t | j | _ t | j | _ t | d d d t | _ | j j d t d t d t
t | j d t d t
d d
d d
d | j | _ t | j d
| j d d } | j | j j d d
d d
| j d d
d d
t | d d } | j d t t | d d d d d | j | _ | j j d t
d d
t | d d d d d | j | _ | j j d t d d
d S)Nr r ZreliefZsideexpandZfillZanchorZjustifyZpadxr ZpadytextZtextvariabler Ok Zcommandr )Z StringVarr
nameZfontSizeZFrameZSUNKENr ZpackZTOPZTRUEZBOTHZMessageWZLEFTr r ZEntryZ focus_setZBOTTOMZButtonr ZbuttonOkr ZbuttonCancelZRIGHT)r Z entryNameZframeButtonsr r r r + s$
z&GetCfgSectionNameDialog.create_widgetsc C s | j j j } | s: t j d d d d d | no t | d k ru t j d d d d d d | d } n4 | | j k r t j d d d d
d | d } n | S)z After stripping entered name, check that it is a sensible
ConfigParser file section name. Return it if it is, '' if not.
r z
Name Errorr zNo name specified.r
r z)Name too long. It should be no more than z30 characters. zThis name is already in use.)r getstriptkMessageBoxZ showerrorlenr )r r r r r name_ok@ s
zGetCfgSectionNameDialog.name_okNc C s, | j } | r( | | _ | j n d S)N)r# resultdestroy)r eventr r r r r S s zGetCfgSectionNameDialog.Okc C s d | _ | j d S)Nr )r$ r% )r r&