In general, okular stores the annotations in a XML file somewhere in your .kde-folder. Although you may export the annotations together with the relevant file using the so called document archive, this does not help in case you want to print the decorations or in case you want to pass the file on to someone without okular.
Here is a script that stores (most of) your annotations in a new PDF: okannotate.py. Please note:
- Call the script with python okannotate.py inputfile.pdf outputfile.pdf
- You will need python.
- In contrast to the way okular displays the annotations, everything is drawn on the background. Hence, you can mark text without affecting the readability of text nearby.
- As of version 0.14.3, okular knows nine types of annotations: the supported ones are:
- Green Freehand Line
- Yellow Highlighter
- Straight Yellow Line
- Blue Polygon
- Black Underlining
- Cyan Ellipse
- While you can edit the annotations in okular for your first document, the added decoration in the new PDF will stay permanently.