The issue happens because PDFView doesn’t automatically refresh when annotations are added or removed, so custom or image annotations may not display correctly. I solved it by forcing a redraw of the affected page: removing and reinserting it in the PDFDocument, then calling setNeedsDisplay on the PDFView. This triggers a full page refresh, ensuring annotations appear properly while keeping it memory-efficient.
Topic:
Graphics & Games
SubTopic:
General
Tags: