[vim/vim] Add diacritic-insensitive search (#8026)

37 views
Skip to first unread message

Rudolf Adamkovič

unread,
Mar 28, 2021, 9:49:50 AM3/28/21
to vim/vim, Subscribed

Is your feature request about something that is currently impossible or hard to do? Please describe the problem.

A clear and concise description of what is hard to do. Ex. It is difficult to [...] when […]

It is difficult to search in/for non-English text because Vim does not understand and ignore diacritics. See, for instance: https://vi.stackexchange.com/questions/7386/ignoring-diacritics-accents-when-searching

Describe the solution you'd like

ignorediacritics a là ignorecase

When set, /kocicka will find kočička, and /kočička will find kocicka.

Describe alternatives you've considered

A clear and concise description of any alternative solutions or features you've considered.

Using equivalence classes, e.g. [[=c=]]. This is impractical.


You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub, or unsubscribe.

Bram Moolenaar

unread,
Mar 28, 2021, 12:36:20 PM3/28/21
to vim/vim, Subscribed

A global option causes problems for plugin writers. We could add something like \c (ignore case) in the pattern itself.

JohnBeckett

unread,
Mar 30, 2021, 12:02:40 AM3/30/21
to vim_dev
If something like ignorediacritics is implemented, please make it work for :sort as well.

grr

unread,
Sep 27, 2021, 5:31:47 PM9/27/21
to vim/vim, Subscribed

I gotten used to other programs support this by default. For reference, Firefox's search in page switched to ignoring diacritics by default about 2 years ago.


You are receiving this because you are subscribed to this thread.

Reply to this email directly, view it on GitHub.
Triage notifications on the go with GitHub Mobile for iOS or Android.

Christian Brabandt

unread,
Sep 28, 2021, 6:35:28 AM9/28/21
to vim/vim, Subscribed

May be this works well for a browser, but in my text editor, I expect /Baum to only match the German word "Baum" (tree) and not the plural form "Bäume" (trees).


You are receiving this because you are subscribed to this thread.

Rodrigo Camacho

unread,
Oct 12, 2021, 4:31:45 PM10/12/21
to vim/vim, Subscribed

Did this ever get treated in one way or another?


You are receiving this because you are subscribed to this thread.

Javier Lopez

unread,
Oct 12, 2021, 5:14:45 PM10/12/21
to vim/vim, Subscribed

May be this works well for a browser, but in my text editor, I expect /Baum to only match the German word "Baum" (tree) and not the plural form "Bäume" (trees).

Some diacritics are just for accents (Spanish áéíóú), and is a common misspelling error which still means the same thing. I'm sure there's tons of other uses/languages

But I agree, being behind a flag like \c would be nice!


You are receiving this because you are subscribed to this thread.

y

unread,
Mar 26, 2022, 2:30:12 PM3/26/22
to vim/vim, Subscribed

I noticed that firefox only ignores diacritcs and not ligatures, so searching for 'ae' won't find 'æ'. I suggest using the unicode confusable mapping for completeness: http://www.unicode.org/Public/security/revision-05/confusables.txt

If there was some discussion here on implementation details, maybe a plugin author could take the first whack at it, so we'd get a proof of concept as well as support for older versions if this feature gets released.


Reply to this email directly, view it on GitHub, or unsubscribe.

You are receiving this because you are subscribed to this thread.Message ID: <vim/vim/issues/8026/1079749681@github.com>

Reply all
Reply to author
Forward
0 new messages