theming: do not warn if theme is "default"

To be compatible with old Sphinx versions we have to use "default".
This commit is contained in:
Georg Brandl 2015-05-18 14:25:20 +02:00
parent c475b1eb6b
commit 034c4e9424

View File

@ -101,11 +101,13 @@ class Theme(object):
'(missing theme.conf?)' % name) '(missing theme.conf?)' % name)
self.name = name self.name = name
if name == 'default' and warn: # Do not warn yet -- to be compatible with old Sphinxes, people *have*
warn("'default' html theme has been renamed to 'classic'. " # to use "default".
"Please change your html_theme setting either to " # if name == 'default' and warn:
"the new 'alabaster' default theme, or to 'classic' " # warn("'default' html theme has been renamed to 'classic'. "
"to keep using the old default.") # "Please change your html_theme setting either to "
# "the new 'alabaster' default theme, or to 'classic' "
# "to keep using the old default.")
tdir, tinfo = self.themes[name] tdir, tinfo = self.themes[name]
if tinfo is None: if tinfo is None: