bpo-17535: IDLE editor line numbers (GH-14030)

(cherry picked from commit 7123ea009b)

Co-authored-by: Tal Einat <taleinat@gmail.com>
This commit is contained in:
Miss Islington (bot) 2019-07-23 06:04:13 -07:00 committed by GitHub
parent bf8e82f976
commit 1da6a313dd
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
18 changed files with 891 additions and 80 deletions

View file

@ -319,6 +319,10 @@ class IdleConf:
'hit-background':'#000000',
'error-foreground':'#ffffff',
'error-background':'#000000',
'context-foreground':'#000000',
'context-background':'#ffffff',
'linenumber-foreground':'#000000',
'linenumber-background':'#ffffff',
#cursor (only foreground can be set)
'cursor-foreground':'#000000',
#shell window
@ -328,11 +332,11 @@ class IdleConf:
'stderr-background':'#ffffff',
'console-foreground':'#000000',
'console-background':'#ffffff',
'context-foreground':'#000000',
'context-background':'#ffffff',
}
for element in theme:
if not cfgParser.has_option(themeName, element):
if not (cfgParser.has_option(themeName, element) or
# Skip warning for new elements.
element.startswith(('context-', 'linenumber-'))):
# Print warning that will return a default color
warning = ('\n Warning: config.IdleConf.GetThemeDict'
' -\n problem retrieving theme element %r'