获取查看器首选项
Contents
[
Hide
]
获取当前查看器首选项
- 将源 PDF 绑定到
PdfContentEditor立面。 - 呼叫
getViewerPreference()读取当前值。 - 检查或打印返回的偏好标志。
public static void getViewerPreferences(Path inputFile) {
PdfContentEditor editor = new PdfContentEditor();
try {
editor.bindPdf(inputFile.toString());
System.out.println("Current viewer preference: " + editor.getViewerPreference());
} finally {
editor.close();
}
}