atom feed4 messages in org.oasis-open.lists.docbook-apps[docbook-apps] OPF file for EPUB is l...
FromSent OnAttachments
Glenn McDonaldJul 13, 2010 10:59 pm 
Bob StaytonJul 14, 2010 9:47 am 
Glenn McDonaldJul 14, 2010 9:33 pm 
Keith FahlgrenJul 14, 2010 10:00 pm 
Subject:[docbook-apps] OPF file for EPUB is linking to images with different roles
From:Glenn McDonald (gmcd@vividas.com)
Date:Jul 13, 2010 10:59:00 pm
List:org.oasis-open.lists.docbook-apps

For Docbook 4.x, I was able to use the following to force PDF's to use SVG and HTML Books to use PNG's:

<mediaobject> <imageobject role="fo"> <imagedata fileref="screenshots/wizard_step_1.svg" scale="70"/> </imageobject> <imageobject role="html"> <imagedata fileref="screenshots/wizard_step_1.png" scale="70"/> </imageobject> </mediaobject>

This still works for PDF and HTML documents, however, I am finding that the epub translation causes both of these images to be referenced in the OPF file:

<manifest> ... <item id="d0e88" href="screenshots/wizard_step_1.svg" media-type="image/svg+xml"/> <item id="d0e94" href="screenshots/wizard_step_1.png" media-type="image/png"/> ... </manifest>

The raw html output of the translated epub is (correctly) only referencing the .png file

<div class="mediaobject"><img src="screenshots/wizard_step_1.png" width="378" alt="Step 1 Image Data"/>

Incidentally, what "role" should an epub document be? role="epub" does not seem to work. Is it "xhtml"?

Glenn