foliate icon indicating copy to clipboard operation
foliate copied to clipboard

[Feature Request] Step by single page in dual page mode

Open woky opened this issue 6 years ago • 3 comments

ebook-viewer in Calibre had nice feature in dual page view where when you navigated to the next page, it actually really moved by single page only. Example:

Next in Foliate (and almost every other viewer):

[A B] C D E F
A B [C D] E F
A B C D [E F]

Next in ebook-viewer from Calibre:

[A B] C D E F
A [B C] D E F
A B [C D] E F
A B C [D E] F
A B C D [E F]

ebook-viewer's approach is awesome because it keeps you with context of what you've just read when you switch to the next page. So this feature would be awesome in Foliate as well. :-)

woky avatar Oct 05 '19 22:10 woky

I don't think this is currently supported by Epub.js, although I imagine that this won't be too hard to implement. You should open an issue upstream.

johnfactotum avatar Oct 06 '19 06:10 johnfactotum

It's actually very easy to do this in Epub.js. Just need to change one line:

diff --git a/src/assets/epub.js b/src/assets/epub.js
index 10e3370..a03096a 100644
--- a/src/assets/epub.js
+++ b/src/assets/epub.js
@@ -16350,7 +16350,7 @@ var Layout = function () {
 
                        spreadWidth = columnWidth * divisor + gap;
 
-                       delta = width;
+                       delta = width / 2;
 
                        this.width = width;
                        this.height = height;

It'll take more changes to make it optional, but for now you can try this patch and see if it fits your needs.

johnfactotum avatar May 09 '20 06:05 johnfactotum

it keeps you with context of what you've just read

I agree that the ability to not lose context while reading is very important. This can also be visually enhanced by gradually sliding a page out of the active window while a new one gradually slides into it.

digitalethics avatar May 26 '20 08:05 digitalethics