Wednesday, August 29, 2012

Re: ASCIIfication (removal of accent, cedilla, etc)

On 29, اگست 2012, at 22:36, Tim Chase <vim@tim.thechases.com> wrote:

> I've got some Portuguese text that I need to perform some
> transformations on to make them ASCII (7-bit). That means removing
> accent marks, cedillas, tildes, etc.
>
> Is there some fast transform in Vim that I've missed, or an easy way
> to go about this?
>
> Thanks,
>
> -tim

I don't believe there is something that will figure out the non-accented version of a given character, but you could do something similar using tr() by passing in "èéêëē" and "eeeee", for example.

Tedious, yes, but only needs to be done a few times and shouldn't be a very painful function that takes a range of lines and does this over them.

Hope this helps,

Salman

--
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

No comments: