Fix a long-standing bug in the way (the lack of) images is handled in the

'text-only' case.

Do this by explicitly setting preferred-mediaobject-notations to the
empty list.

This has only worked for so long because the source format for images in
all the documents with plain text equivalents for images has been EPS,
which isn't used in the HTML output format.  If PNG images were used
then the <textobject> element wasn't chosen.
This commit is contained in:
Nik Clayton 2002-10-28 19:35:31 +00:00
parent d53073372f
commit 66e8205da4
Notes: svn2git 2020-12-08 03:00:23 +00:00
svn path=/head/; revision=14779

View file

@ -145,6 +145,13 @@
"/pkg-descr")))
(create-link (list (list "HREF" href)) ($mono-seq$))))
(else ($mono-seq$)))))
;; Ensure that we start with no preferred mediaobject notations,
;; so that in the text-only case we don't choose any of the
;; possible images, and fallback to the most appropriate
;; textobject
(define preferred-mediaobject-notations
'())
]]>
<!-- HTML with images ............................................ -->
@ -157,9 +164,8 @@
; displaying the image.
(element mediaobject
(if (node-list-empty? (select-elements (children (current-node)) (normalize "imageobject")))
(process-children)
(process-node-list (select-elements (children (current-node)) (normalize "imageobject")))))
(make element gi: "P"
($mediaobject$)))
(define %graphic-default-extension%
"png")