WIP: Add "Preserve Text (Searchable)" option with full color inversion #13
No reviewers
Labels
No labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
chizkiyahu/pdf-dark-mode-converter!13
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "copilot/fix-ctrl-f-search-issue"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Current conversion rasterizes pages to images, breaking Ctrl+F text search. This adds an optional mode that inverts colors while preserving the original PDF text/vector content, keeping text searchable.
Changes
renderPDFPreserveText(): Uses PDF blend modes to invert colors while preserving text searchabilityrenderPDFRasterized()for the default inversion modeThe preserve text mode uses PDF "Difference" blend mode to properly invert colors:
Original prompt
💬 We'd love your input! Share your thoughts on Copilot coding agent in our 2 minute survey.
@copilot the part of the files bacgorud is still w
and the text is still b in all the backgourd w and b
make sure to replace the bacgroud and the the text
about images have a checkbox to let the user decide if to change or not
Fixed in
fb24894. The "Preserve Text" mode now properly inverts colors using PDF blend modes:Pull request closed