Update latex docs

This commit is contained in:
jfbu 2018-07-31 16:54:25 +02:00
parent 8de8f087bd
commit b8f43e56ae

View File

@ -2005,14 +2005,6 @@ macros and environments, see also :doc:`/latex`.
Font package inclusion, default ``'\\usepackage{times}'`` (which uses Font package inclusion, default ``'\\usepackage{times}'`` (which uses
Times for text, Helvetica for sans serif and Courier for code-blocks). Times for text, Helvetica for sans serif and Courier for code-blocks).
.. hint::
Courier is much wider than Times, and Sphinx emits LaTeX command
``\small`` in code-blocks to compensate. Since ``1.5`` this is not
hard-coded anymore: ``\fvset{fontsize=auto}`` can be added to
preamble to not change font size in code-blocks. Since ``1.8`` a
separate ``'fvset'`` key is provided for this.
.. versionchanged:: 1.2 .. versionchanged:: 1.2
Defaults to ``''`` when the :confval:`language` uses the Cyrillic Defaults to ``''`` when the :confval:`language` uses the Cyrillic
script. script.
@ -2020,8 +2012,7 @@ macros and environments, see also :doc:`/latex`.
Defaults to ``''`` when :confval:`latex_engine` is ``'xelatex'``. Defaults to ``''`` when :confval:`latex_engine` is ``'xelatex'``.
.. versionchanged:: 1.6 .. versionchanged:: 1.6
Defaults to ``''`` also with ``'lualatex'``. Defaults to ``''`` also with ``'lualatex'``.
.. versionchanged:: 1.8
``'xelatex'`` and ``'lualatex'`` do ``\fvset{fontsize=auto}``.
``'fncychap'`` ``'fncychap'``
Inclusion of the "fncychap" package (which makes fancy chapter titles), Inclusion of the "fncychap" package (which makes fancy chapter titles),
default ``'\\usepackage[Bjarne]{fncychap}'`` for English documentation default ``'\\usepackage[Bjarne]{fncychap}'`` for English documentation
@ -2192,13 +2183,18 @@ macros and environments, see also :doc:`/latex`.
__ https://github.com/rtfd/readthedocs.org/issues/2857 __ https://github.com/rtfd/readthedocs.org/issues/2857
``'fvset'`` ``'fvset'``
Customization of ``fancyvrb`` LaTeX package. Defaults to Customization of ``fancyvrb`` LaTeX package. Currently, Sphinx uses
``'\\fvset{fontsize=\\small}'``, because default font (Courier) used in this key to set the fontsize in code-blocks according to the
code-blocks is wider and taller than default text font (Times). :confval:`latex_engine`.
For ``'xelatex'`` and ``'lualatex'``, defaults to - ``'pdflatex'`` uses ``'fvvset': '\\fvset{fontsize=\\small}'``,
``'\\fvset{fontsize=auto}'``, because the default fonts are part of to mitigate the size difference between the default monospaced font
one unified typeface family (Latin Modern OpenType). (Courier) and the default text font (Times). You may need to modify
this if you use custom fonts.
- ``'xelatex'`` and ``'lualatex'`` use ``'\\fvset{fontsize=auto}'``,
as there is no size difference between the regular and the
monospaced fonts used by default by Sphinx.
.. versionadded:: 1.8 .. versionadded:: 1.8