-
Notifications
You must be signed in to change notification settings - Fork 678
Closed
Description
Bug description
Hi !
I'm getting a similar issue than on this stackoverflow question.
While trying to redact some text from a relatively dense pdf, the redaction works well but it adds an extra white rectangle per redaction which covers text I don't want redacted.
How it happened
I simply ran the following lines for each rectangle I wanted redacted:
page.add_redact_annot(rect, fill=white)
page.apply_redactions()
From my attempt at debugging this issue, it seems like the add_redact_annot is working fine (it crosses off the right rectangle when commenting out the next line) and that the issue comes from the apply_redactions method.
Outputs
Below is the result redaction. The text in red is replacement text I added. On the overlined screenshot, you can see the unwanted white rectangle.
Your configuration
- Ubuntu
- Python 3.10
- PyMuPDF==1.22.3
Metadata
Metadata
Assignees
Labels
No labels

