Bug 706718

Summary: Inter-text distance ignored within text line
Product: MuPDF Reporter: Jorj <jorj.x.mckie>
Component: mupdfAssignee: MuPDF bugs <mupdf-bugs>
Status: RESOLVED FIXED    
Severity: major CC: robin.watts
Priority: P4    
Version: 1.22.0   
Hardware: PC   
OS: Windows 11   
Customer: Word Size: ---
Attachments: testcase

Description Jorj 2023-05-11 10:36:11 UTC
Starting with version 1.22.0, large inter-text distances within a line seem to be ignored andno longer filled with space - linebreaks.
Command "mutool draw -o 2.txt 2.pdf" with the attached test PDF produces this output in v1.21.0:

[10] Yu Guo, Qiyu Jin, Gabriele Facciolo, Tieyong Zeng, and
Jean-Michel Morel.
Residual learning for effective joint
demosaicing-denoising.
arXiv preprint arXiv:2009.06205,

But this output in version 1.22.0:

[10] Yu Guo, Qiyu Jin, Gabriele Facciolo, Tieyong Zeng, and
Jean-Michel Morel.
demosaicing-denoising.Residual learning for effective joint
arXiv preprint arXiv:2009.06205,
Comment 1 Jorj 2023-05-11 10:37:48 UTC
Created attachment 24303 [details]
testcase
Comment 2 Robin Watts 2023-05-11 14:39:53 UTC
Fixed with:

commit bc140682ab56188d0bbec06a4572be06ccb406f8
Author: Robin Watts <Robin.Watts@artifex.com>
Date:   Thu May 11 12:14:56 2023 +0100

    Bug 706718: Don't prepend text extracted lines if vertically shifted.

    The bugfix for 706426 was incorrect, in that it did not check for
    text extracted lines being vertically shifted when considering them
    for prepending.

    Fixed here.

Thanks!