Closed Bug 1771477 Opened 3 years ago Closed 3 years ago

Can't find word on Firefox PDF viewer

Categories

(Firefox :: PDF Viewer, defect, P1)

Firefox 100
defect

Tracking

()

VERIFIED FIXED
103 Branch
Tracking Status
firefox-esr91 --- unaffected
firefox-esr102 --- fixed
firefox101 --- wontfix
firefox102 --- wontfix
firefox103 --- verified

People

(Reporter: gybeom8008, Assigned: calixte)

References

(Regression)

Details

(Keywords: regression, Whiteboard: [pdfjs-text-search] )

Attachments

(3 files)

Attached image bug.png

User Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:100.0) Gecko/20100101 Firefox/100.0

Steps to reproduce:

  1. Open a Korean PDF: https://www.korean.go.kr/nkview/nklife/1998_4/1998_0402.pdf
  2. Ctrl+F, and type, for instance: 박경래, which is apparantly the auther of this paper, written at the title.

Actual results:

It cannot locate nor highlight the right word, while it seems it can count the number of words.

Expected results:

It should be highlighted right under the title of the first chapter.

I don't know if it is Korean only issue, but it is reproduced on every Korean PDFs I have used, and failed to reproduced on any English PDFs I have.

The Bugbug bot thinks this bug should belong to the 'Firefox::PDF Viewer' component, and is moving the bug to that component. Please correct in case you think the bot is wrong.

Component: Untriaged → PDF Viewer

It's a regression from:
https://github.com/mozilla/pdf.js/commit/1f41028fcbb21bd5af98810847d1892a51862bd0

Some characters in Korean are composed of several chars which are not diacritics

"특".normalize("NFD").split("") === [ "ᄐ", "ᅳ", "ᆨ" ]

and since we now normalize the text:
https://github.com/mozilla/pdf.js/blob/e6a0a953e840a16c02f48b373efcde4a92e4f963/web/pdf_find_controller.js#L138
those composed characters induce some unexpected shifting.

Assignee: nobody → cdenizet
Severity: -- → S2
Status: UNCONFIRMED → ASSIGNED
Ever confirmed: true
Priority: -- → P1
Has Regression Range: --- → yes
Has STR: --- → yes
Regressed by: 1754585
Whiteboard: [pdfjs-text-search]
Commit merged into master by GitHub Authored by calixteman (calixteman)

Set release status flags based on info from the regressing bug 1754585

Status: ASSIGNED → RESOLVED
Closed: 3 years ago
Depends on: 1772598
Resolution: --- → FIXED
Target Milestone: --- → 103 Branch

Reproduce with Firefox 100.
Issue is no longer reproducible on Firefox Nightly 104 from 29.06.2022.

Status: RESOLVED → VERIFIED
Flags: qe-verify+

Verified with 103.0b2

You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: