summaryrefslogtreecommitdiff
path: root/doc
diff options
context:
space:
mode:
authorTakeshi KOMIYA <i.tkomiya@gmail.com>2016-02-19 09:36:43 +0900
committerTakeshi KOMIYA <i.tkomiya@gmail.com>2016-02-20 00:44:28 +0900
commit2b93e09c0ad80b3748bfe1f8f4023662eb0bbf66 (patch)
tree2a0122692e55a7b231d5aada26bcaecd0ae795d9 /doc
parentae8cbec29a8f55b5c13e2ab59b0f9c4636eb6b77 (diff)
downloadsphinx-git-2b93e09c0ad80b3748bfe1f8f4023662eb0bbf66.tar.gz
Highlighting fallbacks by default
In 423bf7b, I tried to add fallback mechanism to ``python3``. But it breaks the python3 highlighting on python2 environment. This adds ``'default'`` to highlighting languages; it works like ``'python3'``, but fallbacks if failed Highlighting. And this removes try-parse step from ``'python3'`` language. Now, it highlights regardless of runtime environments. Thanks to Yoshiki SHIBUKAWA.
Diffstat (limited to 'doc')
-rw-r--r--doc/config.rst8
1 files changed, 5 insertions, 3 deletions
diff --git a/doc/config.rst b/doc/config.rst
index 71ebb60e7..9ac9b17d4 100644
--- a/doc/config.rst
+++ b/doc/config.rst
@@ -333,9 +333,11 @@ Project information
.. versionadded:: 0.5
.. versionchanged:: 1.4
- The default is now ``'python3'``, since it is mostly a superset of
- ``'python'``. If you prefer Python 2 only highlighting, you can set
- it back to ``'python'``.
+ The default is now ``'default'``. It is similar to ``'python3'``;
+ it is mostly a superset of ``'python'``. but it fallbacks to
+ ``'none'`` without warning if failed. ``'python3'`` and other
+ languages will emit warning if failed. If you prefer Python 2
+ only highlighting, you can set it back to ``'python'``.
.. confval:: highlight_options