1
0
Fork 0
mirror of https://github.com/futurepress/epub.js.git synced 2025-10-03 14:59:18 +02:00

Fixes for page counting

This commit is contained in:
Fred Chasen 2017-08-09 17:19:02 -04:00
parent 8bfed1593c
commit 03e7ca085c
5 changed files with 28 additions and 24 deletions

View file

@ -253,11 +253,12 @@ class IframeView {
// Get the contentWidth by resizing the iframe
// Check with a min reset of the textWidth
// width = this.contentWidth(textWidth);
// Add padding back
if (width % this.layout.width > 0) {
width += this.layout.gap / 2;
}
/*
columns = Math.ceil(width / (this.settings.layout.columnWidth));
columns = Math.ceil(width / this.settings.layout.delta);
if ( this.settings.layout.divisor > 1 &&
this.settings.layout.name === "reflowable" &&
(columns % 2 > 0)) {
@ -266,11 +267,6 @@ class IframeView {
}
*/
// Add padding back
if (width % this.layout.width > 0) {
width += this.layout.gap / 2;
}
// Save the textWdith
this._textWidth = textWidth;