Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

export fixed layout and prospectively enhance Vivliostyle pagination algorithm #1213

Open
thomas-topway-it opened this issue Jul 26, 2023 · 1 comment

Comments

@thomas-topway-it
Copy link

thomas-topway-it commented Jul 26, 2023

Is your feature request related to a problem? Please describe.

Shouldn't an epub viewer able to paginate an epub with reflowable layout considered a publishing and design software primarily aimed to publishers ? (or advanced readers who want a digital edition tailor made on their device)

In this view most of the epub readers on the market do not appropriately distinguish between readers and publishers, and overload their apps or viewers with features aimed to publishers or advanced readers (i.e. readers that actually play the role of publishers) that aren't suitable for a protected and friction-less reading experience.

Describe the solution you'd like
Vivliostyle Viewer already includes a right sidebar where the user (mainly a publisher) can set-up their editions, based on page size, margins, widows/orphans control, additional css and so on. Vivliosyle core could therefore just feature an export api completed with an export button in the reader, so that the edition can be exported with a fixed layout corresponding to the current settings.

This also enhances the user/reading experience, since once that an user/reader (i.e. not a publisher) has chosen or also created their own edition, he/she does not play with the interface anymore (except that for reading actions, like scrolling, to highlight text, etc.) and can focus on reading.

Describe alternatives you've considered
Fixed-layout EPUBs is a new Epub3 specification and has a great potential yet to be adopted and implemented
https://idpf.org/epub/fxl/epub-fxl-20120313.html
https://www.w3.org/TR/dpub-aria-1.0/#doc-pagebreak

Additional context
Pagination is a difficult task!
If performed appropriately (see reference below) it takes a non-negligible time and there is no reason to not save a pagination result ! Also, to save a pagination result is the only way to perform pagination reasonably well with an appreciable user experience

https://www.latex-project.org/publications/2019-FMi-coin12165-final.pdf
http://www.eprg.org/G53DOC/pdfs/knuth-plass-breaking.pdf
http://www.infogridpacific.com/blog/igp-blog-20130922-epub3-accessibility-and-pagebreaks.html

@thomas-topway-it thomas-topway-it changed the title export fixed layout export fixed layout and prospectively enhance Vivliostyle pagination algorithm Jul 26, 2023
@MurakamiShinyu
Copy link
Member

I think reflowable layout in an EPUB viewer is essential for seamless reading experience on various devices. It benefits all readers, not just publishers or advanced users, by improving accessibility and customization. Whether someone is reading on a small smartphone, or a large desktop monitor, the content will adjust accordingly, providing a comfortable and readable experience for all. If users feel it too complex or frictionfull, that may be due to a not so good UI or poor performance.

The "export fixed layout" feature may be useful for publishers who want to create fixed layout EPUBs, but I doubt many people would want this feature in Vivliostyle.

Vivliostyle's pagination is not very fast, and you may feel frictionfull when you use Vivliostyle Viewer as an ebook viewer. This is due to "Pagination is a difficult task", but there is room for improvement.

Use renderAllPages=false mode for reading

Vivliostyle Viewer has renderAllPages parameter ("Render All Pages" checkbox in the settings):

true (default): for Print (all pages printable, page count works as expected)
false: for Read (quick loading with rough page count)

Specifying renderAllPages=false improves reading experience on large EPUB or web publications that consist of many HTML documents.

An example publication: Cascading Style Sheets Level 2 Revision 1 (CSS 2.1) Specification

Compare the reading experience of
https://vivliostyle.org/viewer/#src=https://www.w3.org/TR/CSS2/&renderAllPages=true
and
https://vivliostyle.org/viewer/#src=https://www.w3.org/TR/CSS2/&renderAllPages=false

When you change font size or window size during reading middle of the publication, it takes a long time to re-layout in the default mode (renderAllPages=true), but it will be much better in the renderAllPages=false mode.

Implement caching of paginated result

A page caching feature, saving paginated results to storage and restore them when reopening, will make sense to improve reading experience.

Vivliostyle Viewer currently has "Restore View" feature (Restore view settings when reopening) but it saves and restores only settings and not the paginated results and it redos the pagination processing when restoring the view.
(Example: https://vivliostyle.org/viewer/#src=https://www.w3.org/TR/CSS2/&restoreView=true)

I think we should consider adding the caching feature in the future.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants