Freebsd Laptop Support

  • Subscribe to our RSS feed.
  • Twitter
  • StumbleUpon
  • Reddit
  • Facebook
  • Digg

Saturday, 15 June 2013

Docbook and EPUB Part 2

Posted on 02:55 by Unknown
Category: Techwriter

Continued from Docbook and EPUB Part 1

Compressing and Renaming


EPUB is nothing more than a zipped file with the file extension changed to EPUB. The XSLT stylesheet creates the META-INF and OEBPS folders and the necessary toc, XHTML, and content.opf files, but it won't compress the files automatically into a zip. However, there are advantages to manually zipping the files, such as making sure all the images are in the OEBPS folder and adding a mimetype.

To zip the necessary files into an EPUB in KDE:

1. Select the META-INF, OEBPS folders and the mimetype file. Do not include the original Docbook .xml file.
2. Right-click and click Compress. Click As ZIP Archive.
3. To rename the file, right-click, then select Rename... Input an ebook name with an .epub file extension.




Editing in Sigil


It's always a good idea to validate and test the EPUB using a variety of devices and another EPUB application. The developers of Sigil knew what they were doing when they wrote the excellent ebook editor, which can examine the contents of an EPUB file and validate the EPUB for compatibility.

Open the newly created EPUB file using Sigil and use the Book Browser pane to preview the individual .xhtml files stored in the Text folder.

If the images aren't displayed when viewed using an EPUB Viewer, check the following:

1. Check if the Images folder contains all the necessary images of the document. If they aren't, manually add the images using Sigil.
2. Double-click the XHTML files in the Text folder and correct the path of the images if needed.

To check if your EPUB is valid, click Tools on the toolbar then Validate With EPUB FlightCrew. Unlike the EPUB I created using Calligra and LyX, the EPUB produced from the Docbook XML EPUB stylesheets had only one error regarding the format of the date (the metadata required the yyyy-mm-dd format).



Testing in Okular and Calibre


Open the EPUB file using an ebook reader to check if the images and formatting are consistent. The Docbook XML document converted to EPUB in this example opened properly in Calibre E-Book Viewer and EPUBViewer for Mozilla Firefox, complete with an accurate Table of Comments and proper Docbook formatting. Okular, KDE's document viewer, isn't a dedicated ebook viewer so added unnecessary bullet points in the Package Contents section. However, issues didn't appear when viewed in iOS iBooks and using Android apps.







Email ThisBlogThis!Share to XShare to FacebookShare to Pinterest
Posted in Techwriter | No comments
Newer Post Older Post Home

0 comments:

Post a Comment

Subscribe to: Post Comments (Atom)

Popular Posts

Categories

  • Linux
  • Linux - Mandriva
  • Linux - openSUSE
  • Tech Today
  • Techwriter
  • Travel Logs

Blog Archive

  • ▼  2013 (229)
    • ►  November (19)
    • ►  October (21)
    • ►  September (20)
    • ►  August (23)
    • ►  July (23)
    • ▼  June (21)
      • Using Tellico Citations/BibTex in LyX Part 1
      • Working with WMF in CorelDraw
      • Tails of Tor: Linux Access to the Dark Side of the...
      • Tails of Tor: Linux Access to the Dark Side of the...
      • The Dubious Art of the Username
      • Tails of Tor: Linux Access to the Dark Side Part 1
      • Linux on Film: Dredd (2012)
      • Apps for Hong Kong Part 3
      • Thoughts on "Booth Babes" Part 2
      • Apps for Hong Kong Part 2
      • Thoughts on "Booth Babes" Part 1
      • Apps for Hong Kong Part 1
      • Docbook and EPUB Part 2
      • Docbook and EPUB Part 1
      • Dragonair Airlines - Tech and Impressions
      • Docbook and LyX Part 2
      • Quick Fix: Can't play AC3 audio on a movie
      • Docbook and LyX Part 1
      • Quick Fix: Repair an MP3 file using VLC
      • A Short Chat and a Windows 8 Anecdote
      • Correcting EPUBs exported from Calligra Words usin...
    • ►  May (24)
    • ►  April (22)
    • ►  March (19)
    • ►  February (16)
    • ►  January (21)
  • ►  2012 (261)
    • ►  December (28)
    • ►  November (22)
    • ►  October (28)
    • ►  September (20)
    • ►  August (28)
    • ►  July (23)
    • ►  June (21)
    • ►  May (15)
    • ►  April (26)
    • ►  March (9)
    • ►  February (11)
    • ►  January (30)
  • ►  2011 (10)
    • ►  December (10)
Powered by Blogger.

About Me

Unknown
View my complete profile