使用 adobe 找到了解决方案 - https://answers.acrobatusers.com/How-I-fix-Tagged-Annotations-fail-error-accessibility-links-q228128.aspx
如何使用 pdfbox 添加 Link-OBJR(链接注释的对象引用)。
`PDAnnotationLink txtLink = new PDAnnotationLink();
PDRectangle position = new PDRectangle();
position.setLowerLeftX(PDFUtils.lw_lft_x);
position.setLowerLeftY(PDFUtils.lw_lft_y);
position.setUpperRightX(PDFUtils.tp_rgt_x);
position.setUpperRightY(PDFUtils.tp_rgt_y);
txtLink.setRectangle(position);
txtLink.setHidden(true);
txtLink.getCOSObject().setInt(COSName.STRUCT_PARENT,1);
PDActionURI action = new PDActionURI();
action.setURI(PDFUtils.link);
txtLink.setAction(action);
page.getAnnotations().add(txtLink);
PDObjectReference pd= new PDObjectReference();
pd.setReferencedObject(txtLink);
structureElement.appendKid(pd);
currentSection.appendKid(structureElement);
structureElement formBuilder.addContentToParent(COSName.P, null, page, structureElement, PDFUtils.mcid);`
使用上面的代码标记-
标记文档参考- https://drive.google.com/file/d/1n_T361G6LTNLycQbw-3gP2nmBV-oTJdR/view?usp=sharing
寻找以下结构