sumatrapdf icon indicating copy to clipboard operation
sumatrapdf copied to clipboard

Copying Chinese text from PDF generates block scrambling (special case)

Open chenbihao opened this issue 1 year ago • 1 comments

SumatraPDF version

3.5.2

Describe the bug

Copying Chinese text from PDF generates block scrambling (special case)

Because I am unfamiliar with PDF -related technology, it is not clear what it is caused by what caused it

To Reproduce

Copy the text and paste it into other software, there will be a ������� garbled

Expected behavior

Copy Chinese text correctly

File that reproduces the problem

Forgive me for uploading the full example, because I found that after using other software cutting examples, It returned to normal ,It seems that it will return to normal after the editor is saved

Mybatis-2021最新.pdf

Screenshots

image

Additional context

Open PDF with other software and copy and paste. The behavior is normal, for example chrome、edge、foxit pdf Etc.

chenbihao avatar Feb 23 '24 09:02 chenbihao

As you say it is a faulty file so any editor can fix it and as Acrobat reader is a trimmed down editor it should fix on opening then offer to save corrections on closure.

Before fix in an editor and bad fonts copied "as they are" in SumatraPDF

Mybatis
�������������
1.1 ��JDBC����
public static void main(String[] args) {
Connection connection = null;
PreparedStatement preparedStatement = null;
ResultSet resultSet = null;
try {
// �������
Class.forName("com.mysql.jdbc.Driver");

AFTER FIX and opened in SumatraPDF

Mybatis
第⼀部分:⾃定义持久层框架
1.1 分析JDBC操作问题
public static void main(String[] args) {
Connection connection = null;
PreparedStatement preparedStatement = null;
ResultSet resultSet = null;
try {
// 加载数据库驱动
Class.forName("com.mysql.jdbc.Driver")

No guarantee WHAT was fixed by open in eXchange editor but it generated below fixed copy. Mybatis-2021 Copy.pdf

after fix by Acrobat DC Reader (self edits corrections)

Mybatis-2021.pdf

GitHubRulesOK avatar Feb 23 '24 11:02 GitHubRulesOK