packages.flutter icon indicating copy to clipboard operation
packages.flutter copied to clipboard

Overlaid elements in PDF don't render in native mode (iOS and Android)

Open cdhermann opened this issue 4 years ago • 0 comments

Describe the bug The attached PDF document with text overlaid by white rectangles and other text is rendered on iOS and Android without the overlayed rectangle and the overlaid text.

To Reproduce Steps to reproduce the behavior:

  1. Create a PDF document, write some text and save it
  2. Re-open PDF document and draw rectangles over the text
  3. Save the PDF
  4. Add PDF as asset to a Flutter application
  5. Build the app for web, iOS
  6. Compare rendered PDFs

Expected behavior Rendering results in iOS and Android as with PDF.js

Screenshots PDF_rendering_differences PDF_rendering_Android11

Smartphone (please complete the following information):

  • Device: iOS 13 Simulator vs. Android vs. Web

Additional context The original PDF documents and an example rendering by MacOS is attached.

pdf_rendering_test_with_overlay.pdf pdf_rendering_test_without_overlay.pdf pdf_rendering_test_with_overlay_correct

cdhermann avatar Dec 15 '21 07:12 cdhermann