This didnt work. when i clicked the textmarkup annotation nothing happens. this is my code
PDActionURI action = new PDActionURI(); action.setURI("https://www.google.com"); txtMark.getCOSObject().setItem(COSName.AA, action); On Sun, Dec 5, 2021 at 12:09 PM Tilman Hausherr <thaush...@t-online.de> wrote: > Am 05.12.2021 um 04:57 schrieb chitgoks: > > Hi tilman. the sample there is for PDAnnotationWidget > > PDAnnotationTextMarkup does not have a setAction() or setActions() > > method though. > > it's additional actions > > widget.setActions(annotationActions); > > but I see this is missing for other annotations. Try setting it manually > > annotation.getCOSObject().setItem(COSName.AA, actions); > > the PDF specification is unclear, in "trigger events" it mentions that > it works in annotations, but then it's only specifically mentioned in > widget annotations. > > Tilman > > > > >