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

Reversing range of characters? #1

Open
abuali129 opened this issue Nov 16, 2016 · 8 comments
Open

Reversing range of characters? #1

abuali129 opened this issue Nov 16, 2016 · 8 comments

Comments

@abuali129
Copy link

Could by any chance we get reversing only specific characters only. As I want to reverse the arabic letters in the file without touching the English ones

@mrt-prodz
Copy link
Owner

I guess it should be possible if we check for a specific range of character codes using the Arabic Unicode Standard 9.0 reference. Using C++ as mentioned in Scintilla reference you could find characters between 0600 and 06FF and iterate through each selection and reverse it.

I actually don't use Windows anymore so it's unfortunately really difficult for me to test and implement this.

@abuali129
Copy link
Author

Well, can I ask for the .dll plugin? I'm not familiar with the mingw or this kind of things

@abuali129
Copy link
Author

nevermind, I did it, I got the .dll
Know how do I go with the regex to reverse the desired characters only?
And BTW the characters I'm using is different from what you mentioned, it is in this range U+FE70..U+FEFF

@mrt-prodz
Copy link
Owner

Glad you found a way to get the DLL, you could also make selections manually with a regex search inside Notepad++. I didn't test it but you could check this StackOverflow reply and use the range of codes you are looking for. And then use the plugin to reverse selection.

@abuali129
Copy link
Author

oops! just check your tool by now, it messed up the arabic wirting, too bad
thats is original
arabic

that is the reversed
reversed

@mrt-prodz
Copy link
Owner

I wasn't thinking with my earlier reply, I reverse the string 1 byte at a time hence this broken result with Arabic. The plugin should check for document encoding before proceeding to reverse the content.

@mrt-prodz
Copy link
Owner

It might be easier to do that using Python Scripts for Notepad++.

@abuali129
Copy link
Author

Still i didn't get any script that do the same for unicode

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