Register Guidelines E-Books Today's Posts Search

Go Back   MobileRead Forums > E-Book Software > Sigil

Notices

Reply
 
Thread Tools Search this Thread
Old 01-11-2016, 06:17 AM   #1
Clancolin
Member
Clancolin began at the beginning.
 
Posts: 14
Karma: 10
Join Date: Jul 2015
Location: Hampshire, UK
Device: Pocketbook Aqua 2
Epub Doctype, Schema and Metadata?

I'm trying to convert PDFs to ePub, but automatic converters produce tons of extraneous code . I'm using Sigil and checking my hand-code with Flightcrew but also trying to comply with accessibility features as much as possible.

I want to use elements like "<header>" and "<section>" and "epub:type" attributes. If possible, I'd like to have a sort of standard template, that once created, will allow me to just paste text from the PDFs into the relevant sections of the ePub.

I was ok with doctypes and schema with html4 and xhtml, but if I ignore namespace doctypes in html5 and use "<!DOCTYPE html>", that produces multiple different types of errors from Flightcrew.

I want to avoid obsolete code, so how much - if any - of this lot is needed to be able to enable the elements and attributes I want to use?

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN"
"http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<html xmlnsps=" http://www.idpf.org/2007/ops">
<?xml version="1.0" encoding="utf-8"?>

Thanks.
Clancolin is offline   Reply With Quote
Old 01-11-2016, 06:24 AM   #2
JSWolf
Resident Curmudgeon
JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.
 
JSWolf's Avatar
 
Posts: 79,183
Karma: 144286760
Join Date: Nov 2006
Location: Roslindale, Massachusetts
Device: Kobo Libra 2, Kobo Aura H2O, PRS-650, PRS-T1, nook STR, PW3
You are trying to make an ePub 3 eBook in a program that makes ePub 2 eBooks.

Do you really need to make ePub 3? Are you using any ePub 3 specific features? can what you want to do be done in ePub 2? If you do make a specific ePub 3, not many people will be able to read it. So if you aren't doing anything ePub 3 specific then just go ePub 2.
JSWolf is online now   Reply With Quote
Advert
Old 01-11-2016, 08:00 AM   #3
Clancolin
Member
Clancolin began at the beginning.
 
Posts: 14
Karma: 10
Join Date: Jul 2015
Location: Hampshire, UK
Device: Pocketbook Aqua 2
ePub3 or ePub2?

Quote:
Originally Posted by JSWolf View Post
You are trying to make an ePub 3 eBook in a program that makes ePub 2 eBooks.

Do you really need to make ePub 3? Are you using any ePub 3 specific features? can what you want to do be done in ePub 2? If you do make a specific ePub 3, not many people will be able to read it. So if you aren't doing anything ePub 3 specific then just go ePub 2.
Thanks very much for the reply.

I do realise that ePub3 is still not widespread, but
a) As you say, there are e-readers out there today that can cope with ePub3.

b) We should be encouraging them - what is the point of making a version 3 e-reader if nobody is asking for it?

c) Standards evolve to improve the reading experience. I have ePub2 e-books that look fine on e-reader app X but dreadful on e-reader Y. If ePub 3 can sort that nonsense out, then that has to be a Good Thing.

d) IMHO ePub3 is better in terms of making content accessible plus I feel the code becomes more understandable for those who may want to take what I'm doing and tweak it in the future.

e) There are new educational elements being developed. They will be really useful in the training/teaching world, so if I can add them now, ready for when they will be fully functional, then that's less work for someone to do later.

Thanks again for taking the time.

P.S. I did have a subsidiary question for Sigil buffs: when making a "New" ePub2 page in Sigil (version 0.9.2), even with no other code entered FlightCrew complains about missing "language" and "title" elements. What's the best way to sort that out?
Clancolin is offline   Reply With Quote
Old 01-11-2016, 08:24 AM   #4
DiapDealer
Grand Sorcerer
DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.DiapDealer ought to be getting tired of karma fortunes by now.
 
DiapDealer's Avatar
 
Posts: 28,361
Karma: 203720150
Join Date: Jan 2010
Device: Nexus 7, Kindle Fire HD
Quote:
Originally Posted by Clancolin View Post
P.S. I did have a subsidiary question for Sigil buffs: when making a "New" ePub2 page in Sigil (version 0.9.2), even with no other code entered FlightCrew complains about missing "language" and "title" elements. What's the best way to sort that out?
The title and language elements are required by epub specs. You add/edit/remove them using the metadata editor, or by editing the opf file manually (note that it's not currently possible to edit epub3 metadata with the gui editor).

We're (Sigil) not discouraging the use creation of epub3. That's why we're trying to add more and more epub3 support all the time. Currently, though (v0.9.2), only the very simplest of edits can be made to existing epub3s--and none can be created. We hope to add the creation of, and much more in the way of editing (epub3) with the very next release.

Please note that Flightcrew is limited to validating epub2-only. You'll want to use EpubCheck for epub3 (and epub2) validation.

@jswolf: please don't assume that people don't understand the ramifications of epub3 vs epub2. And please refrain from using questions like this to try and advance your already well-noted anti-epub3 stance. Thanks.

Last edited by DiapDealer; 01-11-2016 at 08:27 AM.
DiapDealer is offline   Reply With Quote
Old 01-11-2016, 09:17 AM   #5
Doitsu
Grand Sorcerer
Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.
 
Doitsu's Avatar
 
Posts: 5,684
Karma: 24031401
Join Date: Dec 2010
Device: Kindle PW2
Quote:
Originally Posted by Clancolin View Post
I'm trying to convert PDFs to ePub, but automatic converters produce tons of extraneous code . I'm using Sigil and checking my hand-code with Flightcrew but also trying to comply with accessibility features as much as possible.
Quote:
Originally Posted by Clancolin View Post
[...] but if I ignore namespace doctypes in html5 and use "<!DOCTYPE html>", that produces multiple different types of errors from Flightcrew.
Flightcrew is an ePub2 validator and will display error messages for all ePub3 specific attributes. (ePubCheck will display similar error messages.)

Quote:
Originally Posted by Clancolin View Post
P.S. I did have a subsidiary question for Sigil buffs: when making a "New" ePub2 page in Sigil (version 0.9.2), even with no other code entered FlightCrew complains about missing "language" and "title" elements. What's the best way to sort that out?
Simply press F8, enter a book title and click OK. That'll take care of that error message.

Until the next Sigil version becomes available, I'd recommend the following ePub3 workflow:

1. Change the default doctype in XHTML files

from:

Code:
<html xmlns="http://www.w3.org/1999/xhtml">
to:

Code:
<html xmlns="http://www.w3.org/1999/xhtml" xmlns:epub="http://www.idpf.org/2007/ops">
This'll allow you to use Book View/Preview with your books.

2. Once you've finished your ePub2 book export it with the ePub3 plugin.

3. Validate your ePub3 with pagina EPUB-Checker and preview it in ADE 4.5, Azardi or Gitden Reader.
Doitsu is offline   Reply With Quote
Advert
Old 01-11-2016, 12:26 PM   #6
Clancolin
Member
Clancolin began at the beginning.
 
Posts: 14
Karma: 10
Join Date: Jul 2015
Location: Hampshire, UK
Device: Pocketbook Aqua 2
Thanks

Many thanks for the information and assistance. Very helpful.
Clancolin is offline   Reply With Quote
Old 01-12-2016, 05:35 AM   #7
Notjohn
mostly an observer
Notjohn ought to be getting tired of karma fortunes by now.Notjohn ought to be getting tired of karma fortunes by now.Notjohn ought to be getting tired of karma fortunes by now.Notjohn ought to be getting tired of karma fortunes by now.Notjohn ought to be getting tired of karma fortunes by now.Notjohn ought to be getting tired of karma fortunes by now.Notjohn ought to be getting tired of karma fortunes by now.Notjohn ought to be getting tired of karma fortunes by now.Notjohn ought to be getting tired of karma fortunes by now.Notjohn ought to be getting tired of karma fortunes by now.Notjohn ought to be getting tired of karma fortunes by now.
 
Posts: 1,518
Karma: 987654
Join Date: Dec 2012
Device: Kindle
Quote:
Originally Posted by Doitsu View Post
Flightcrew is an ePub2 validator and will display error messages for all ePub3 specific attributes. (ePubCheck will display similar error messages.)
Does that mean we can't sell an ePub3 through Apple, which requires that our books pass ePubCheck?
Notjohn is offline   Reply With Quote
Old 01-12-2016, 06:13 AM   #8
JSWolf
Resident Curmudgeon
JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.JSWolf ought to be getting tired of karma fortunes by now.
 
JSWolf's Avatar
 
Posts: 79,183
Karma: 144286760
Join Date: Nov 2006
Location: Roslindale, Massachusetts
Device: Kobo Libra 2, Kobo Aura H2O, PRS-650, PRS-T1, nook STR, PW3
Quote:
Originally Posted by Notjohn View Post
Does that mean we can't sell an ePub3 through Apple, which requires that our books pass ePubCheck?
It means that you don't use FlightCrew to validate your eBooks.
JSWolf is online now   Reply With Quote
Old 01-12-2016, 06:15 AM   #9
Doitsu
Grand Sorcerer
Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.Doitsu ought to be getting tired of karma fortunes by now.
 
Doitsu's Avatar
 
Posts: 5,684
Karma: 24031401
Join Date: Dec 2010
Device: Kindle PW2
Quote:
Originally Posted by Notjohn View Post
Quote:
Originally Posted by Doitsu View Post
Flightcrew is an ePub2 validator and will display error messages for all ePub3 specific attributes. (ePubCheck will display similar error messages.)
Does that mean we can't sell an ePub3 through Apple, which requires that our books pass ePubCheck?
Maybe I should have been more precise. What I meant to say was that if you use:

Code:
<html xmlns="http://www.w3.org/1999/xhtml" xmlns:epub="http://www.idpf.org/2007/ops">
and epub3-only attributes, for example,

Code:
<span epub:type="pagebreak" id="page1">1</span>
in an ePub2 book, both ePubCheck and Flightcrew will obviously complain about it.

If you convert an ePub2 book that passed ePubCheck with the Sigil ePub3 plugin you'll end up with a valid ePub3 book that also passes ePubCheck.

However, passing ePubCheck alone might not be sufficient for the iBook store, because Apple also requires ePub3 books to be Apple Asset Guide-compliant; moreover iBooks is not fully ePub3 compliant.
Doitsu is offline   Reply With Quote
Reply


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Bug report: Doctype removed on file merge Ryn Sigil 5 12-14-2015 06:14 AM
EPUB3 and DOCTYPE roger64 Editor 12 05-07-2015 01:35 AM
DOCTYPE ERROR Zenphobia ePub 15 09-20-2013 07:45 PM
Bad DOCTYPE declaration causes BS to crash macpablus Recipes 7 09-04-2011 03:41 PM
Any database schema changes? timlegge Kobo Reader 6 10-19-2010 08:56 PM


All times are GMT -4. The time now is 01:13 PM.


MobileRead.com is a privately owned, operated and funded community.