mirror of
https://github.com/sphinx-doc/sphinx.git
synced 2025-02-25 18:55:22 -06:00
Fix `width
option of figure directive does not work if
align
` option also specified (ref: #2595)
This commit is contained in:
parent
58b4f046ab
commit
da3d368961
1
CHANGES
1
CHANGES
@ -5,6 +5,7 @@ Bugs fixed
|
||||
----------
|
||||
|
||||
* #2530: got "Counter too large" error on building PDF if large numbered footnotes existed in admonitions
|
||||
* ``width`` option of figure directive does not work if ``align`` option specified at same time (ref: #2595)
|
||||
|
||||
|
||||
Release 1.4.2 (released May 29, 2016)
|
||||
|
@ -1431,8 +1431,8 @@ class LaTeXTranslator(nodes.NodeVisitor):
|
||||
node.children[0]['ids']):
|
||||
ids += self.hypertarget(node.children[0]['ids'][0], anchor=False)
|
||||
if node.get('align', '') in ('left', 'right'):
|
||||
if 'width' in node:
|
||||
length = width_to_latex_length(node['width'])
|
||||
if 'width' in node[0]:
|
||||
length = width_to_latex_length(node[0]['width'])
|
||||
else:
|
||||
length = '0pt'
|
||||
self.body.append('\\begin{wrapfigure}{%s}{%s}\n\\centering' %
|
||||
|
Loading…
Reference in New Issue
Block a user