Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

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

Open
chenbihao opened this issue Feb 23, 2024 · 1 comment
Open

Comments

@chenbihao
Copy link

chenbihao commented Feb 23, 2024

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.

@GitHubRulesOK
Copy link
Collaborator

GitHubRulesOK commented Feb 23, 2024

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

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants