Closed saprentice closed 3 years ago
Hi Scott. Thorium most certainly render fixed layout EPUB publications. Could you please share the publication that is causing issues, so we can investigate? Thank you!
HI Daniel .. I'll simplify my test file and upload it later today. When I scan the code, I see no references to "pre-paginated" .. but numerous instances where "Rendition.Layout" is tested for the string "fixed" and that sets a boolean of isFixedLayout. From what I understand, the rendition:layout value that sets a Fixed layout is "pre-paginated" not "fixed". But it's very possible that I'm doing something wrong or have a misunderstanding. Will upload something in a bit. Thanks!
"fixed" is a term used in the Readium WebPub Manifest specification. Internally we transform EPUB (and other publication formats) to RWPM. We do not directly manipulate EPUB OPF etc. files in Readium applications.
Okay. I hear what you're saying .. so what I saw in the code isn't apparently the issue, but it does seem that something isn't right. I'm trying to do a single-page fixed layout .. I think the single page is the issue. Best as I can tell, the following metadata in the OPF should give me what I'm after, but it doesn't ..
<meta property="rendition:layout">pre-paginated</meta>
<meta property="rendition:page-spread">center</meta>
However, if I do this, it works ..
<meta property="rendition:layout">fixed</meta>
<meta property="rendition:page-spread">center</meta>
The problem is that "fixed" is not a valid value for "rendition:layout".
I've got two sample EPUBs that show this situation. Will upload the ZIP which contains both. two-seeds-FXL-test.zip
Mhmm, I've justed tested two-seeds-PRE-PAGINATED.epub
, it looks fine. However two-seeds-FIXED.epub
looks broken (which makes sense, as fixed
is not a valid value for <meta property="rendition:layout">...</meta>
).
I have also tested your sample EPUBs with the old Readium "web reader", and the results are consistent with Thorium. To try yourself, just drag and drop the EPUBs on the browser window: https://readium.web.app
Finally, I tested with iBooks / Books.app on MacOS, everything seems consistent there too.
Could you please clarify what you would expect to see, but don't? Thank you :)
Sorry, I wasn't clear about the goal here. I'm trying to get a single-page fixed layout. I assume that when you reviewed the two EPUBs you're seeing that the "pre-paginated" file renders a two-page layout, and the "fixed" file renders a single-page layout? (That's what I'm seeing in Thorium.) You're right though that in other readers the"pre-paginated" file rendered the same as in Thorium, so apparently my understanding of the purpose of "rendition:page-spread" = "center" is incorrect.
It seems that the "rendition:layout" = "fixed" is just a red herring, where in Thorium, (along with "rendition:page-spread" = "center") this causes it to "fail" in the way that I want (a single page). In other readers, the "fixed" rendition:layout results in definitely wonky behavior.
So .. I'll keep looking for the right combination of metadata that allows this single-page layout. I'd swear I've done it before, but am not seeing any samples of this in my test files or elsewhere. Hmm. This can't be such an unusual request. Sorry for the distraction, from your usual work! :-o
Ah, have you tried this?
<meta property="rendition:layout">pre-paginated</meta>
<meta property="rendition:spread">none</meta>
<meta property="rendition:page-spread">center</meta>
Great .. thanks! :-)
As far as I can tell, rendition:layout = "pre-paginated" is not supported in Thorium 1.6 , although "fixed" does what I'd expect "pre-paginated" to do. I believe that this is the latest spec .. https://www.w3.org/publishing/epub3/epub-packages.html#layout .. which indicates the valid values for rendition:layout are "reflowable" and "pre-paginated".
<meta property="rendition:layout">pre-paginated</meta>
Hoping this can be fixed!