It's not implemented. Try "SBApproved". That one is supported by Adobe
Reader, it will draw the stamp.
Tilman
Am 06.08.2019 um 12:17 schrieb Jens Bruhn-Hansel:
Hi,
using PDFBox 2.0.16 I am trying to add a simple (no image) RubberStamp
annotation to a PDF document. My current code is:
public void addSimpleStamp(PDDocument document) throws
IOException
{
PDPage page = document.getPage(0);
PDAnnotationRubberStamp rs = new PDAnnotationRubberStamp();
rs.setName(PDAnnotationRubberStamp.NAME_APPROVED);
rs.setRectangle(new PDRectangle(100, 100));
rs.setContents("A top secret note");
rs.setSubject("subject");
page.getAnnotations().add(rs);
}
After saving this pdf and opening with AdobeReader I can see one
comment, but it's only renderes as a box with a cross (error image?).
Rendering with PDFBox doesn't show this annotation at all.
There seems to be no appearance for the RubberStamp. I've tried
"rs.constructAppearances();", but this method doesn't do anything for
a RubberStamp. I saw the example with a custom image, that worked for
me. But I just want to have the stamp, it's an eyecatcher.
Thanks for your help,
jens
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@pdfbox.apache.org
For additional commands, e-mail: users-h...@pdfbox.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@pdfbox.apache.org
For additional commands, e-mail: users-h...@pdfbox.apache.org