Ligatures are not copiable nor searchable in Preview

Originator:asottile
Number:rdar://31065125 Date Originated:2017-03-15
Status:Open Resolved:
Product:macOS + SDK Product Version:10.11.6
Classification:Usability Reproducible:Always
 
Summary:
PDFkit fails to render ligatures (such as fi and fl) as searchable and copiable characters. This works with OS X up to Yosemite, but somehow is broken in El Capitan and Sierra. A minimal working example is attached, created with XeLaTeX. The ligatures contained in this example cannot be copied nor searched correctly by Preview. The same document works fine with other PDF readers that do not rely on PDFKit.

Steps to Reproduce:
1. open the attached PDF file with Preview
2. select and copy the text included in the PDF
3. paste the copied text into any editor, such as TextEdit

Expected Results:
The pasted text should read:
This text should be entirely copiable, but it is not: figure literature ligature final.

Actual Results:
The pasted text is:
This text should be entirely copiable, but it is not:  gure literature ligature  nal.

Version:
OS X El Capitan 10.11.6 (15G1217)
Preview 8.1 (877.7)

Attachments:
https://www.dropbox.com/s/lihs13fy794gwt6/ligatures_mwe.pdf?dl=1

Comments


Please note: Reports posted here will not necessarily be seen by Apple. All problems should be submitted at bugreport.apple.com before they are posted here. Please only post information for Radars that you have filed yourself, and please do not include Apple confidential information in your posts. Thank you!