summaryrefslogtreecommitdiffstats
path: root/Lib/idlelib/configHandler.py
diff options
context:
space:
mode:
authorSteven M. Gava <elguavas@python.net>2002-01-21 06:38:21 (GMT)
committerSteven M. Gava <elguavas@python.net>2002-01-21 06:38:21 (GMT)
commit5f28e8fbfbf9b4db8d322c685ab0341083abd1f0 (patch)
treed6d6227860e3834b12413ed5e3e59c7e57a632ab /Lib/idlelib/configHandler.py
parent7bb1c9a11db2ecdf58fed5a5e3a7cdea619d52db (diff)
downloadcpython-5f28e8fbfbf9b4db8d322c685ab0341083abd1f0.zip
cpython-5f28e8fbfbf9b4db8d322c685ab0341083abd1f0.tar.gz
cpython-5f28e8fbfbf9b4db8d322c685ab0341083abd1f0.tar.bz2
extension config reading by configDialog and
beginning of configuration saving
Diffstat (limited to 'Lib/idlelib/configHandler.py')
-rw-r--r--Lib/idlelib/configHandler.py9
1 files changed, 5 insertions, 4 deletions
diff --git a/Lib/idlelib/configHandler.py b/Lib/idlelib/configHandler.py
index 34be897..196d952 100644
--- a/Lib/idlelib/configHandler.py
+++ b/Lib/idlelib/configHandler.py
@@ -23,7 +23,7 @@ class IdleConfParser(ConfigParser):
self.file=cfgFile
ConfigParser.__init__(self,defaults=cfgDefaults)
- def Get(self, section, option, type=None): #,default=None)
+ def Get(self, section, option, type=None):
"""
Get an option value for given section/option or return default.
If type is specified, return as type.
@@ -143,9 +143,9 @@ class IdleConf:
Get a list of sections from either the user or default config for
the given config type.
configSet must be either 'user' or 'default'
- configType must be one of ('extensions','highlight','keys')
+ configType must be one of ('main','extensions','highlight','keys')
"""
- if not (configType in ('extensions','highlight','keys')):
+ if not (configType in ('main','extensions','highlight','keys')):
raise 'Invalid configType specified'
if configSet == 'user':
cfgParser=self.userCfg[configType]
@@ -224,7 +224,8 @@ class IdleConf:
if activeOnly:
activeExtns=[]
for extn in extns:
- if self.GetOption('extensions',extn,'enable',default=1,type='bool'):
+ if self.GetOption('extensions',extn,'enable',default=1,
+ type='bool'):
#the extension is enabled
activeExtns.append(extn)
return activeExtns