This commit is contained in:
Horis
2024-08-16 21:05:48 +08:00
parent 3685431b40
commit d5b6cc3022
2 changed files with 2 additions and 4 deletions

View File

@@ -326,7 +326,7 @@ data class TextPage(
fun render(view: ContentTextView): Boolean {
if (!isCompleted) return false
return canvasRecorder.recordIfNeeded(view.width, view.height) {
return canvasRecorder.recordIfNeeded(view.width, height.toInt() + paddingTop) {
drawPage(view, this)
}
}

View File

@@ -446,9 +446,7 @@ class TextChapterLayout(
val textLine = TextLine(isTitle = isTitle)
if (durY + textHeight > visibleHeight) {
val textPage = pendingTextPage
if (textPage.height < durY) {
textPage.height = durY
}
textPage.height = textPage.lines.lastOrNull()?.lineBottom ?: 0f
if (doublePage && absStartX < viewWidth / 2) {
//当前页面左列结束
textPage.leftLineSize = textPage.lineSize