Create figures with graphics that both display quickly on the web and, when printed from the PDF are produced in high quality. For example in Figure��1, ���Graphic Example with both web and print quality��� the image of the glass building displays quickly at web resolution when viewing this page. But when the PDF version of the page is printed a hi-quality image that can support 300 dpi to 600 dpi is provided.
The solution is to use a DocBook feature that lets the image file to be used specific by the publishing channel. And, to provide both an image for the web publishing that is already correctly sized for the 72 dpi of screens plus a hi-resolution version of image capable of providing the detail needed for sharp print images (300 to 600 dpi).
The DocBook markup is presented below with detailed call-out
descriptions below. The <figure>
,
<title>
, and
<mediaobject>
are the same as
presented in ???? which describes the basic markup for a
numbered graphic with a title. What is different in the markup below
is the use of two <imageobject">
- one to
contain the web resolution image and the other to contain the print
resolution image.
Figure��2.��DocBook markup for multi-channel publishing of a Graphic
<figure><title>Attachments for Multi-channel Publishing</title> <mediaobject>
<imageobject role="html">
<imagedata fileref="building-w250.png" format="PNG"/>
</imageobject> <imageobject role="fo">
<imagedata fileref="building-full.png" format="PNG"
width="3in"/> </imageobject> </mediaobject> </figure>
| |
The | |
The | |
the | |
This is the second | |
This |
Listed below is a "clean" (without callout numbers) DocBook
markup fragment for presenting a multi-channel image with a
figure number and title. Just copy this markup fragment and past
into you xml file at a point where
<figure>
is a valid element.
Figure��3.��Markup Fragment for Multi-Channel Publishing of Graphic with Figure Number and Title
<figure> <title>??? figure title goes here ???</title> <mediaobject> <imageobject role="html"> <imagedata fileref="image-html???.png" format="PNG"/> </imageobject> <imageobject role="fo"> <imagedata fileref="image-print???.png" format="PNG" width="???in"/> </imageobject> </mediaobject> </figure>
Creating the multi-channel publishing markup is a three step process:
Create a graphic file for each publishing channel.
Upload the graphics files as attachments.
Create markup using the
role
attribute to select graphic image by publishing channel.
Each of these steps is discussed below.
Stuff about SnagIt, Photoshop, GIMP and right sizing here. ???
The figure below provides a graphic image that is just 250 pixels wide for the HTML publishing channel and a much higher resolution for the PDF publishing channel.
Working on multi-channel printing is often done as one of the last steps in the authoring process. A common work flow is during the early drafting of the content is to use whatever image is available with the simple markup shown in ????. Once the rough draft is complete and the editing process begins the author returns to the graphics elements annd customizes each for multi-channel publishing.
<mediaobject>
element reference in DocBook: The Definitive Guide<imageobject>
element reference in DocBook: The Definitive Guide<imagedata>
element reference in DocBook: The Definitive GuideStylesheet's selection process - Chapter 18. Graphics in DocBook XSL: The Complete Guide
This documentation present how the
role
attribute of aimageobject
is used to select which image object is displayed for each publishing channel - html or fo/PDF.