summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGeorg Brandl <georg@python.org>2012-03-10 21:29:03 +0100
committerGeorg Brandl <georg@python.org>2012-03-10 21:29:03 +0100
commite1c220cae563aeb1b2520e4325384f0a95657873 (patch)
treecd5ea9b8aaedf6f1cae7fd881e74813ba12eda8b
parenta43db198054822fb521f4aac6fcca4cdf7c4e9b5 (diff)
downloadsphinx-e1c220cae563aeb1b2520e4325384f0a95657873.tar.gz
Add a comment explaining part of visit_image.
-rw-r--r--sphinx/writers/html.py3
1 files changed, 3 insertions, 0 deletions
diff --git a/sphinx/writers/html.py b/sphinx/writers/html.py
index b6e305f7..2051e38e 100644
--- a/sphinx/writers/html.py
+++ b/sphinx/writers/html.py
@@ -358,6 +358,9 @@ class HTMLTranslator(BaseTranslator):
return
if node.has_key('scale'):
+ # Try to figure out image height and width. Docutils does that too,
+ # but it tries the final file name, which does not necessarily exist
+ # yet at the time the HTML file is written.
if Image and not (node.has_key('width')
and node.has_key('height')):
try: