Quote:
Originally Posted by roger64
Thanks you all for your replies. This comes as a real surprise to me after so many years using writer2xhtml and Sigil. I realize too that the Editor provides no safety net contrary to Sigil.
1. - So, if I still keep using writer2xhtml, I will need to correct it first by opening it with Sigil and avoid using it first with the calibre Editor. Not a big deal but good to know.
2. - The alternative choice is to manually correct it with he calibre Editor. But there is still something here that I do not get: take my broken EPUB (the one unsaved): I should be able to correct it easily. It's a fairly simple task: I know the good final structure to respect (a Fonts folder, manifest with the right path, @font-face).
I tried several times to correct manually the manifest using the calibre Editor, but I failed like if my manual changes were not taken into account. If a direct manual change in the manifest is not possible, what is the recommended way to proceed? I'll move this question to the calibre Editor thread.
@st_albert, @theducks
Single quotes are OK for fonts, provided you make a consistent use of them in your EPUB. Double quotes are probably more common.
@Toxaris
I did not know there were such thing as "social DRM". I always thought they were totally wild... 
|
First, thanks re: the info on single quotes. I've gotten into the habit of using double quotes, because at one time long ago, that is what it took to make it work for me. So, "if it ain't broke, don't fix it" as we say here in the American South.
Next, I've been playing with the files you posted, and first of all, if I convert the .odt file using the stand-alone writer2latex java program (the patch for LO didn't work for me), I don't get any embedded fonts at all. Maybe due to the fact that I don't have those fonts on my system, or due to the specific configuration I have created for writer2latex. (in general we do not embed fonts, so as to simplify our legal obligations.) So no joy there.
However, when I use the calibre ebook editor on your pristine epub, I do notice the fact that the fonts are not properly referenced. I edited not the book.opf file, but the styles.css file, and made the references to the font files match what was the real location of the files (e.g. src: url('../styles/LinLibertine_RI.otf'); and so on.
Check book also complained about improper mimetypes for the fonts, and also a non-linear item in the spine ( the cover). I had the editor correct these errors individually, and then there were only two warnings re: file too large. These I ignored. I then "saved a copy" of the file.
Opening the copy, all errors except the "file too large" errors were now gone. The copy displayed well with the Firefox epub reader, though I didn't test further.
Now, granted that OEBPS/styles is not where I would like the font files to be placed, at least it seems to me that corrections can be made in the ebook-edit app that allow a functional ebook to be produced. (BTW, did the original, untouched ebook from writer2epub display correctly? Not having the proper fonts, I couldn't tell. But I would doubt it.)
When I have the time, I may try to run your original epub thru sigil (to correct the paths) and see what I see. This may corrupt all the nbsp and nnbsp tags, but as I don't speak French very well I probably won't notice whether the correct font, or the correct spacings are preserved.
Maybe others can comment on all of this.
Albert