在使用 com.github.DImuthuUpe:AndroidPdfViewer:3.1.0-beta.1 时,发现部分PDF文件中的印章只显示红色圆圈轮廓,圈内的文字(中文)无法渲染。
test.pdf
pdfView.fromFile(pdfFile)
.enableSwipe(true)
.swipeHorizontal(false)
.enableDoubletap(true)
.defaultPage(0)
.enableAntialiasing(true)
.enableAnnotationRendering(true)
.load();
期望印章内的【品检三课】【刘海涛】等文字能够正常显示出来, 目前是空的。
初步分析认为,问题可能出在 PDF 文件引用了 Android 系统未内置的字体,而 AndroidPdfViewer 基于的 Pdfium 引擎未能进行有效的字体回退。经测试,使用 com.artifex.mupdf:viewer:1.28.0a 可以正常显示同一文件,这似乎证实了是字体回退机制的问题
在使用 com.github.DImuthuUpe:AndroidPdfViewer:3.1.0-beta.1 时,发现部分PDF文件中的印章只显示红色圆圈轮廓,圈内的文字(中文)无法渲染。
test.pdf
pdfView.fromFile(pdfFile)
.enableSwipe(true)
.swipeHorizontal(false)
.enableDoubletap(true)
.defaultPage(0)
.enableAntialiasing(true)
.enableAnnotationRendering(true)
.load();
期望印章内的【品检三课】【刘海涛】等文字能够正常显示出来, 目前是空的。
初步分析认为,问题可能出在 PDF 文件引用了 Android 系统未内置的字体,而 AndroidPdfViewer 基于的 Pdfium 引擎未能进行有效的字体回退。经测试,使用 com.artifex.mupdf:viewer:1.28.0a 可以正常显示同一文件,这似乎证实了是字体回退机制的问题