Exception on text selection in web environment with particular pdf

I've implemented sfPdfViewer and works fine, except with some particular pdf produced by a converter from PCL5 to PDF that comes from AS400 environment.

Trying to select text from some of these pdf, in debug I get this error:

════════ Exception caught by gesture library ═══════════════════════════════════The following IndexError was thrown while dispatching a pointer event:RangeError (index): Index out of range: no indices are valid: 0
When the exception was thrown, this was the stackdart-sdk/lib/_internal/js_dev_runtime/private/ddc_runtime/errors.dart 236:49 throw_dart-sdk/lib/_internal/js_dev_runtime/private/js_array.dart 581:7 _get]packages/syncfusion_flutter_pdf/src/pdf/implementation/exporting/pdf_text_extractor/image_renderer.dart 658:40 [_renderTextElementWithLeading]packages/syncfusion_flutter_pdf/src/pdf/implementation/exporting/pdf_text_extractor/image_renderer.dart 327:17 [_renderAsImage]packages/syncfusion_flutter_pdf/src/pdf/implementation/exporting/pdf_text_extractor/pdf_text_extractor.dart 279:13 [_getTextLine]...Event: PointerHoverEvent#48320(position: Offset(1366.7, 326.6))    position: Offset(1366.7, 326.6)Target: RenderMouseRegion#79d36 relayoutBoundary=up6    parentData: <none> (can use size)    constraints: BoxConstraints(unconstrained)    size: Size(593.3, 541.3)    listeners: hover    cursor: SystemMouseCursor(basic)════════════════════════════════════════════════════════════════════════════════
════════ Exception caught by gesture library ═══════════════════════════════════RangeError (index): Index out of range: no indices are valid: 0════════════════════════════════════════════════════════════════════════════════

The text does not be selected and when the issue is in webapp (not debug) the web app is freezed, because the "Index out of range..." error is reiterated many times.

As attachment, there's one of these pdf that produce the error.



Attachment: test.pdf_b74519.7z

8 Replies

DR Deepika Ravi Syncfusion Team August 3, 2021 12:50 PM UTC

Hi Pietro Beccegato, 
 
We can reproduce the reported issue from our side. We are analyzing on this and will update the further details on 5th August 2021. 
 
Regards,
Deepika R
 



DR Deepika Ravi Syncfusion Team August 5, 2021 08:49 AM UTC

Hi Pietro Beccegato, 
 
We have confirmed that the reported issue “Exception on text selection in web environment with particular Pdf” is a defect. The issue fix will be included in our upcoming weekly release, which is estimated to be available on 17 August 2021. The status of this issue can be tracked using the following link https://www.syncfusion.com/feedback/27626/exception-thrown-while-extracting-textline-from-particular-pdf-document
Regards, 
Deepika R 



PB Pietro Beccegato August 5, 2021 11:05 AM UTC

Many thanks for your support.

Regards,
Peter



ST Steven Tillson August 11, 2021 11:29 AM UTC

The reported issue "Exception on text selection in online environment with certain Pdf" has been confirmed as a bug. The issue will be addressed in our upcoming weekly release, which is scheduled for delivery on August 17, 2021.



DR Deepika Ravi Syncfusion Team August 11, 2021 01:37 PM UTC

Hi Steven Tillson, 
 
As we mentioned earlier, we will include the fix in our upcoming weekly NuGet release on August 17, 2021. 
 
Regards, 
Deepika R 



DR Deepika Ravi Syncfusion Team August 17, 2021 03:55 PM UTC

Hi Pietro Beccegato, 
 
we have included the fix for this issue " Exception on text selection in web environment with particular Pdf" in our latest weekly NuGet release, so kindly upgrade to the latest version v19.2.56 to get the issue resolved.  
  
  
Regards, 
Deepika R 



PB Pietro Beccegato replied to Deepika Ravi August 17, 2021 04:13 PM UTC

Many many thanks. I tried with the latest version v19.2.56 and everything works fine.

Many compliments for your awesome plugins and the efficient support.


Regards

Peter 





DR Deepika Ravi Syncfusion Team August 18, 2021 11:13 AM UTC

Hi Pietro Beccegato, 
  
Thank you for the update. We are glad to know that the issue was resolved. Please revert to us if you need any further assistance. 
  
Regards, 
Deepika R 


Loader.
Up arrow icon