mirror of
https://github.com/sphinx-doc/sphinx.git
synced 2025-02-25 18:55:22 -06:00
latex, replace `'pixelsize'
by more precise
'pxunit'
` name
This commit is contained in:
parent
f6b0ae903d
commit
fc2202fd2a
@ -1601,12 +1601,13 @@ These options influence LaTeX output. See further :doc:`latex`.
|
|||||||
``'pointsize'``
|
``'pointsize'``
|
||||||
Point size option of the document class (``'10pt'``, ``'11pt'`` or
|
Point size option of the document class (``'10pt'``, ``'11pt'`` or
|
||||||
``'12pt'``), default ``'10pt'``.
|
``'12pt'``), default ``'10pt'``.
|
||||||
``'pixelsize'``
|
``'pxunit'``
|
||||||
px unit size, default ``'49336sp'`` which achieves ``96px=1in`` (as
|
the value of the ``px`` when used in image attributes ``width`` and
|
||||||
``1in = 72.27*65536 = 4736286.72sp``, and all dimensions in TeX are
|
``height``. The default value is ``'49336sp'`` which achieves
|
||||||
internally integer multiples of ``sp``). To obtain for example
|
``96px=1in`` (``1in = 72.27*65536 = 4736286.72sp``, and all dimensions
|
||||||
``100px=1in``, one can use ``'0.01in'`` but it is more precise to issue
|
in TeX are internally integer multiples of ``sp``). To obtain for
|
||||||
``'pixelsize':'47363sp',``.
|
example ``100px=1in``, one can use ``'0.01in'`` but it is more precise
|
||||||
|
to use ``'47363sp'``.
|
||||||
|
|
||||||
.. versionadded:: 1.5
|
.. versionadded:: 1.5
|
||||||
``'babel'``
|
``'babel'``
|
||||||
|
@ -37,7 +37,7 @@ HEADER = r'''%% Generated by Sphinx.
|
|||||||
\documentclass[%(papersize)s,%(pointsize)s%(classoptions)s]{%(wrapperclass)s}
|
\documentclass[%(papersize)s,%(pointsize)s%(classoptions)s]{%(wrapperclass)s}
|
||||||
\ifdefined\pdfpxdimen
|
\ifdefined\pdfpxdimen
|
||||||
\let\sphinxpxdimen\pdfpxdimen\else\newdimen\sphinxpxdimen
|
\let\sphinxpxdimen\pdfpxdimen\else\newdimen\sphinxpxdimen
|
||||||
\fi \sphinxpxdimen=%(pixelsize)s\relax
|
\fi \sphinxpxdimen=%(pxunit)s\relax
|
||||||
\usepackage{iftex}
|
\usepackage{iftex}
|
||||||
%(passoptionstopackages)s
|
%(passoptionstopackages)s
|
||||||
%(inputenc)s
|
%(inputenc)s
|
||||||
@ -302,7 +302,7 @@ class LaTeXTranslator(nodes.NodeVisitor):
|
|||||||
default_elements = {
|
default_elements = {
|
||||||
'papersize': 'letterpaper',
|
'papersize': 'letterpaper',
|
||||||
'pointsize': '10pt',
|
'pointsize': '10pt',
|
||||||
'pixelsize': '49336sp',
|
'pxunit': '49336sp',
|
||||||
'classoptions': '',
|
'classoptions': '',
|
||||||
'extraclassoptions': '',
|
'extraclassoptions': '',
|
||||||
'passoptionstopackages': '',
|
'passoptionstopackages': '',
|
||||||
|
Loading…
Reference in New Issue
Block a user