Thread: ePUB comic test
View Single Post
Old 03-19-2010, 06:53 AM   #20
Junior Member
ralphsnart began at the beginning.
Posts: 2
Karma: 10
Join Date: Feb 2010
Device: none
Originally Posted by charleski View Post
Looks good.
You might want to wrap the images in svg so that they scale and keep their aspect ratio whatever the aspect of the reader. Since your comic pages are all 449x649, try replacing the code of the body with
<svg version="1.1" xmlns="" xmlns:xlink="" width="100%" height="100%" viewBox="0 0 449 649" preserveAspectRatio="xMidYMid meet" >
<image width="449" height="649" xlink:href="images/h01.jpg" />
(Obviously change the 'h01.jpg' to point to the right image in each case.)

There are a few things you need to tidy up:
1) Change the encoding directive in your xhtml files (it's the first line) from
<?xml version="1.0" encoding="iso-8859-1"?>
<?xml version="1.0" encoding="utf-8"?>
2) Remove all the unneeded files (toc blank.ncx etc), and definitely remove page-template.xpgt
3) Your xhtml files need a <title> element in the head, even if it's just blank, so add
<title />
to the heads of them all.
4) Your xhtml files don't actually load the css file and define all their styling information individually. You certainly want to change that. Remove
<style type="text/css" title="override_css">
@page {padding: 0pt; margin:0pt}
body { text-align: center; padding:0pt; margin: 0pt; }
div { margin: 0pt; padding: 0pt; }
and replace it with
<link rel="stylesheet" href="stylesheet.css" type="text/css" />
You'll probably want to put the @page and body definitions in your stylesheet file.
5) You don't actually have a toc.ncx file. You need one, even if it only contains one navpoint. The media-type declared for it in the opf needs to be "application/x-dtbncx+xml"
6) The opf file needs to include all the jpegs in the manifest section.
I wouldn't wrap the images in SVG. Most readers won't anti-alias the images properly and it looks horrible as a result. Raster images only scale well down and not up, and even then, only when scaling down to 50% or 25% (and when you go down, the comic text is too small to read, hence the need to keep the images at same size). Why get rid of the template for ADE? Hey, is anyone bothering to validate their ePUBs?
ralphsnart is offline   Reply With Quote