LibrePDF / OpenPDF

OpenPDF is a free Java library for creating and editing PDF files, with a LGPL and MPL open source license. OpenPDF is based on a fork of iText. We welcome contributions from other developers. Please feel free to submit pull-requests and bugreports to this GitHub repository.
Other
3.59k stars 593 forks source link

Reduce size of sticky notes #324

Open dprutean opened 4 years ago

dprutean commented 4 years ago

I use OpenPdf to generate database diagrams with column tooltips like here: image

using :

final PdfAnnotation annotation = PdfAnnotation.createStamp(writer, new Rectangle( rx, ry, rw, rh), text, "#Comment" );
annotation.setAppearance(PdfName.N, writer.getDirectContent().createTemplate(10, 10));
writer.addAnnotation( annotation );

I wrote to Adobe User Group asking how may I get rid of the yellow sticky note. Their answer is below. Do you know how may I implement their recomandation in OpenPDF ?


Try reducing the opacity of them. Or you can instead use the highlighter tool. That will make the text show through the highlight without being obscured. You can also reduce the opacity of the highlight, as well as change to a different color.

But if you really want to still use the sticky note tool, there is a free script to change sticky note size. It's written to enlarge the size, but can probably be easily adapted to reduce the size.

https://documentgeek.blogspot.com/2016/08/are-your-sticky-note-icons-too-small.html

asturio commented 3 years ago

Hi @dprutean , have you found a solution for this issue? Pull requests are welcome.

asturio commented 8 months ago

Pull requests are sill welcome.