Disable Rendered Annotation Types
The renderAnnotationTypes
property in Document
controls which annotations should be visible.
This is a bitmask of the Annotation.Kind
type.
To enable all annotations except audio, image, and video annotations, you can set the following:
Copy
1 2 3 4 5 | var annotationTypes = Annotation.Kind.all annotationTypes.remove(.screen) annotationTypes.remove(.richMedia) annotationTypes.remove(.sound) document.renderAnnotationTypes = annotationTypes |
Copy
1 | document.renderAnnotationTypes = PSPDFAnnotationTypeAll & ~(PSPDFAnnotationTypeScreen|PSPDFAnnotationTypeRichMedia|PSPDFAnnotationTypeSound|PSPDFAnnotationTypeStamp); |
ℹ️ Note: Images are rendered as stamps, but there is no simple way to differentiate between a text stamp (e.g. Approved) and an image stamp.