Quote:
Originally Posted by JSWolf
I've taken the Nancy Drew book from StandardEBooks and edited it. I made as little changes as possible to make it work in the old version of RMSDK and still be ePub 3. Can someone have a look and see what you think of the code? I've not made many changes to get it to work.
|
I opened the epub you posted in Sigil and there are some errors. But apart from that, I would change the code to handle the cover and titlepage. For the title image (titlepage.xhtml), I would use an SVG wrapper, which is well supported by ADE Legacy and allows the image to be centered and maintain its proportions. For example, I would use the following code:
Code:
<body>
<section id="titlepage" epub:type="titlepage">
<div class="center">
<svg class="epub-type-contains-word-se-image-color-depth-black-on-transparent" xmlns="http://www.w3.org/2000/svg" height="100%" width="100%" preserveAspectRatio="xMidYMid meet" version="1.1" viewBox="0 100 698 364" xmlns:xlink="http://www.w3.org/1999/xlink"><image width="698" height="364" xlink:href="../images/titlepage.png"/></svg>
</div>
</section>
and
Code:
svg.epub-type-contains-word-se-image-color-depth-black-on-transparent {
background: #fff !important;
/* !important` is required to make sure readers respect the BG color */
height: 95%; /* This is for ADE */
height: 95vh; /* This is for epub3 and is ignored by ADE */
}
In Sigil with the above code, the title page looks as:
and with the original code, the title page looks as:
The advantage of using an SVG wrapper is obvious. Of course, it's your decision whether to adopt it or not.