File: //usr/local/lib/python3.10/idlelib/__pycache__/configdialog.cpython-310.pyc
o
�i � � @ s� d Z ddlZddlmZmZmZmZmZmZm Z m
Z
mZmZm
Z
mZmZmZmZmZmZmZmZmZmZmZmZmZmZmZmZmZmZm Z ddl!m"Z"m#Z#m$Z$m%Z%m&Z&m'Z'm(Z(m)Z)m*Z*m+Z+m,Z,m-Z-m.Z. ddlm/Z/ ddl0m1Z2 ddlm3Z3 ddl4m5Z5m6Z6 ddl7m8Z8 dd l9m:Z: dd
l;m<Z< ddl=m>Z>m?Z? ddl@mAZA dd
lBmCZC ddlDmEZE ddlFmGZG ddlHmIZI ddlJmKZK ddl@mLZL e6� ZMeCeEeGeIeKfZNG dd� de�ZOdaPG dd� de"�ZQG dd� de"�ZRG dd� de"�ZSG dd� de"�ZTG dd� de"�ZUG d d!� d!e"�ZVG d"d#� d#e#�ZWG d$d%� d%�ZXeX� ZYd&ZZd'd(d)d*d+d,�Z[d-d.� Z\G d/d0� d0e"�Z]e^d1k�rLdd2l_m`Z` e`d3d4d5d6� dd7lambZb ebeO� dS dS )8a� IDLE Configuration Dialog: support user customization of IDLE by GUI
Customize font faces, sizes, and colorization attributes. Set indentation
defaults. Customize keybindings. Colorization and keybindings can be
saved as user defined sets. Select startup options including shell/editor
and default window size. Define additional help sources.
Note that tab width in IDLE is currently fixed at eight due to Tk issues.
Refer to comments in EditorWindow autoindent code for details.
� N)�Toplevel�Listbox�Canvas� StringVar�
BooleanVar�IntVar�TRUE�FALSE�TOP�BOTTOM�RIGHT�LEFT�SOLID�GROOVE�NONE�BOTH�X�Y�W�E�EW�NS�NSEW�NW�
HORIZONTAL�VERTICAL�ANCHOR�ACTIVE�END�TclError)
�Frame�
LabelFrame�Button�Checkbutton�Entry�Label�
OptionMenu�Notebook�Radiobutton� Scrollbar�Style�Spinbox�Combobox)�colorchooser)�
messagebox)�idleConf�
ConfigChanges)�
GetKeysWindow)�
DynOptionMenu)�macosx)�SectionName�
HelpSource)� view_text)�AutoComplete)�CodeContext)�
ParenMatch)�FormatParagraph)�Squeezer)�ScrollableTextFramec sr e Zd ZdZdddd�dd�Zdd� Zd d
� Zdd� Zd
d� Zdd� Z � fdd�Z
dd� Zdd� Zdd� Z
� ZS )�ConfigDialogzConfig dialog for IDLE.
� F)�_htest�_utestc C s� t �| |� || _|ri |_|s| �� | �|pd� |�� d }|�� |s(dnd }| �d|� d|� �� | � � | j
ttd� | �|� | �
d| j� | jj�� t�� |sg| �� | �� | �� dS dS ) a� Show the tabbed dialog for user configuration.
Args:
parent - parent of this dialog
title - string which is the title of this popup dialog
_htest - bool, change box location when running htest
_utest - bool, don't wait_window when running unittest
Note: Focus set on font page fontlist.
Methods:
create_widgets
cancel: Bound to DELETE_WINDOW protocol.
zIDLE Preferences� � � �+��height�widthZWM_DELETE_WINDOWN)r �__init__�parent�
instance_dictZwithdraw�titleZwinfo_rootxZwinfo_rootyZgeometry�create_widgetsZ resizabler Z transient�protocol�cancel�fontpage�fontlistZ focus_set�tracers�attachZgrab_setZwm_deiconifyZwait_window)�selfrI rK r? r@ �x�y� rV �1/usr/local/lib/python3.10/idlelib/configdialog.pyrH 1 s*
�zConfigDialog.__init__c C s t | dd� | _}| jjdd� t|� | _}t|�| _t|| j�| _t || j�| _
t|| j�| _t
|�| _t|�| _|j| j
dd� |j| jdd� |j| jdd� |j| jd d� |j| jd
d� |j| jdd� |�� |jtttd� | �� jtd
� dS )a Create and place widgets for tabbed dialog.
Widgets Bound to self:
frame: encloses all other widgets
note: Notebook
highpage: HighPage
fontpage: FontPage
keyspage: KeysPage
winpage: WinPage
shedpage: ShedPage
extpage: ExtPage
Methods:
create_action_buttons
load_configs: Load pages except for extensions.
activate_config_changes: Tell editors to reload.
Z5px��paddingZnwes)�stickyz Fonts ��text�
Highlightsz Keys z Windows z
Shell/Ed �
Extensions��side�expand�fill�r` N)r �frame�gridr'