EmEditor (text editor) Forum Index
   Questions and Answers about EmEditor Core
     convert special characters to english characters
Register To Post

Threaded | Newest First Previous Topic | Next Topic | Bottom
Poster Thread
user
Posted on: 2/3/2012 4:04 am
Home away from home
Joined: 9/29/2006
From:
Posts: 212
convert special characters to english characters
hello!

I currently work with turkish text and I need an automatic way to convert all special turkish characters into their corresponding english/latin characters

because I often work with other than english languages that have special characters, I need a way to convert them to their english/latin character analogue

but for now, a solution for turkish?

thanks!
ToadLoadin
Posted on: 2/3/2012 6:03 am
Just can't stay away
Joined: 7/4/2008
From: China
Posts: 119
Re: convert special characters to english characters
Hi,

I guess it could be done by macro:

- start "record macro",
- replace one special character to the corresponding latin character (replace all)
- stop record
- "edit" the macro recored, copy all code generated by emeditor and paste it else where.
- repeat the procedure above with each special character you want to replace, except append the generated macro code to the first one.
- save the cumulated code to a single macro, put it in toolbar or asign it a short-cut key.

Best regards!
Yutaka
Posted on: 2/3/2012 9:57 am
Webmaster
Joined: 9/28/2006
From: Redmond
Posts: 2401
Re: convert special characters to english characters
Hi user,

As ToadLoadin mentioned, you can use a macro to do this.

Also, you can use the Batch Replace feature of EmEditor Professional 11 to do this task easily.

http://www.emeditor.com/modules/feature1/rewrite/tc_39.html#batch_replace

Thanks!


----------------
Yutaka Emura
Developer of EmEditor
http://www.emeditor.com/

user
Posted on: 2/3/2012 10:11 am
Home away from home
Joined: 9/29/2006
From:
Posts: 212
Re: convert special characters to english characters
thanks, I will try macro, but I am interested in batch replace too

however, is it possible to save a specific batch and run it by clicking a button in the toolbar?
Yutaka
Posted on: 2/3/2012 10:19 am
Webmaster
Joined: 9/28/2006
From: Redmond
Posts: 2401
Re: convert special characters to english characters
Hi user,

Unfortunately, it is not easy to create a button from a batch you create from the Batch Replace feature. I might think about exporting as a macro from the Batch Replace dialog in future versions. Thanks!


----------------
Yutaka Emura
Developer of EmEditor
http://www.emeditor.com/

user
Posted on: 2/7/2012 12:21 am
Home away from home
Joined: 9/29/2006
From:
Posts: 212
Re: convert special characters to english characters
can anyone write a JS script or something that will do these replaces with a click of a button?

i for ı
g for ğ
s for ş
c for ç
u for ü
o for ö

case sensitive, in all document, every instance

thanks!
Yutaka
Posted on: 2/7/2012 8:08 am
Webmaster
Joined: 9/28/2006
From: Redmond
Posts: 2401
Re: convert special characters to english characters
Hello,

You could actually record a macro while doing the batch replace.

The actual script will look like:

document.selection.Replace("a","b",eeFindNext | eeFindSaveHistory | eeFindReplaceEscSeq | eeReplaceAll | eeFindReplaceQuiet);
document.selection.Replace("c","d",eeFindNext | eeFindSaveHistory | eeFindReplaceEscSeq | eeReplaceAll | eeFindReplaceQuiet);
...


Thanks,


----------------
Yutaka Emura
Developer of EmEditor
http://www.emeditor.com/

user
Posted on: 2/16/2012 1:50 am
Home away from home
Joined: 9/29/2006
From:
Posts: 212
Re: convert special characters to english characters
it seems to work very well, thanks!

but how do I specify the case-sensitive action?

ToadLoadin
Posted on: 2/16/2012 2:56 am
Just can't stay away
Joined: 7/4/2008
From: China
Posts: 119
Re: convert special characters to english characters
I guess while recording the macro, if you turned case sensitive on, it will also be recored into the macro code.
dmitryl
Posted on: 3/1/2012 9:54 am
Just can't stay away
Joined: 12/25/2009
From:
Posts: 73
Re: convert special characters to english characters
Hi all,

1) What command should be used for removing a character?

2) How to replace double (or more) empty lines with a single empty line?

Thank you!
(1) 2 »
Threaded | Newest First Previous Topic | Next Topic | Top


Register To Post
 
English čeština Deutsch español français italiano 日本語 한국어 Русский 简体中文 繁體中文