giuspen / cherrytree

cherrytree
https://www.giuspen.net/cherrytree/
Other
3.34k stars 457 forks source link

the dir link is gone after the CherryTree file to reopen (when non Lainn characters in the dirpath) #2320

Closed Paffnik closed 11 months ago

Paffnik commented 1 year ago

Version, Operative system v1.0.0, Windows 11 x64

Describe the bug The problem occurs when copying the directory path in Windows and then pasting it into the CherryTree file. When you reopen the CherryTree file, the link with the path to the directory becomes inactive if there was another link before it, which is overwritten with a link to the directory. If there was a simple text before the link to the directory, then when the CherryTree file is reopened, the last word of this text also becomes an active link to the directory. This problem is relevant when there are not only Latin characters in the path in particular with Cyrillic characters!!!!!!!!!!!!!!!!!! 01 02 the dir link is gone after the CherryTree file to reopen

giuspen commented 1 year ago

On my Win10 when I copy a directory with Cyrillic characters from the file manager and paste into CherryTree, the short notation (e.g. C:\PROGRA~1\INTERN~1) is found in the clipboard and pasted in CherryTree, so in the end I see only Latin characters. I don't have a Win11 right now but I will try to have one soon, maybe in the meantime you can test on a Win10 and report if this is a Win11 only issue or also affects Win10?

Paffnik commented 12 months ago

Sorry for long answer. In Win10 the same problem. I made a video with this problem.

Paffnik commented 12 months ago

https://youtu.be/7tZcq3VWx5s

Paffnik commented 12 months ago

Our copy of Windows uses cp-1251 codepage

Paffnik commented 12 months ago

In parallel with the solution of the problem I suggest making a setting in the program settings: The copied path to the directory inserts as a link or as plain text.

Paffnik commented 12 months ago

Same situation you are copy path without "C:" image image

If you are copy paste without "C" then OK because the path inserts into document as plain text. And I make the link manually. This solution is better for me now ))) image

Hope my description helps to solve that problem.

giuspen commented 11 months ago

In parallel with the solution of the problem I suggest making a setting in the program settings: The copied path to the directory inserts as a link or as plain text.

Note @Paffnik that you can paste as plain text (Ctrl+Shift+V instead of Ctrl+V) to avoid a link being created on paste.

giuspen commented 11 months ago

after watching your video I was able to reproduce the issue, I'll try and fix it, will update here

giuspen commented 11 months ago

Thanks for reporting, this has now been fixed, the fix will be in next version > 1.0.1