vimium-c icon indicating copy to clipboard operation
vimium-c copied to clipboard

Vomnibar: Search based on the keyboard layout (not actual characters), regardless of chosen language in keyboard

Open afilp opened this issue 5 years ago • 10 comments

Can we have an option to search based on the keyboard layout (not actual characters)?

Example of the problem: When I search for "Calendar", I get this (the Google Calendar tab):

image

Sometimes though, I am in Greek keyboard, so the search (reasonably) does not work: image

So, I lose time deleting the characters, changing the keyboard, writing again, then changing the keyboard back to Greek, etc.

Solution: This is what JetBrains does (it is not even an option, it is automatic): Searching for "index" (works ok obviously): image

Searching for "ινδεχ", which is "index" in Greek (still works!): image

Is this already an option? If not, can it be done somehow?

Thanks!

afilp avatar Feb 26 '20 11:02 afilp

Currently there's no option to do this.

It seems possible to implement this strategy on Vomnibar, but I have not very much rest time to add and test it. Maybe I can finish it in this year...

---Original--- From: "afilp"<[email protected]> Date: Wed, Feb 26, 2020 19:01 PM To: "gdh1995/vimium-c"<[email protected]>; Cc: "Subscribed"<[email protected]>; Subject: [gdh1995/vimium-c] Vomnibar: Search based on the keyboard layout (not actual characters), regardless of chosen language in keyboard (#131)

Can we have an option to search based on the keyboard layout (not actual characters)?

Example of the problem: When I search for "Calendar", I get this (the Google Calendar tab):

Sometimes though, I am in Greek keyboard, so the search (reasonably) does not work:

So, I lose time deleting the characters, changing the keyboard, write again, then changing the keyboard back to English, etc.

Solution: This is what JetBrains does (it is not even an option, it is automatic): Searching for "index" (works ok obviously):

Searching for "ινδεχ", which is "index" in Greek (still works!):

Is this already an option? If not, can it be done somehow?

Thanks!

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

gdh1995 avatar Feb 26 '20 11:02 gdh1995

Thank you! That would be great and a very useful feature for all international users!

(this is why Jetbrains implemented it, it happens A LOT to be on the wrong keyboard setting when you search for something)

afilp avatar Feb 27 '20 13:02 afilp

Is it enough if Vomnibar only does search using English-alphabet version, when a current query (from IME) matches nothing?

I need to know it because sometimes a user may do want to search some non-English text (like Chinese titles of web pages).

gdh1995 avatar Feb 27 '20 13:02 gdh1995

That could be OK.

This is what JetBrains does, which is even better:

image

They show both the "selected language alphabet" results and the corresponding "english alphabet" results. So, you always have the "english alphabet" results, even when no result is found on the "selected language alphabet".

You could implement it as you mentioned if that is much easier for you, it will still be a great addition!

Thanks!

afilp avatar Feb 27 '20 13:02 afilp

Not sure if this has also been reported elsewhere but it is quite similar:

Support case-insensitive search:

Works: image

Does not work: image

Thanks!

afilp avatar Apr 03 '20 16:04 afilp

@gdh1995 I have the latest version, I do not see the option to "ignore case" in options (neither does it behave as such automatically).

Can you show us where we select this?

Thanks a lot!

afilp avatar Apr 20 '20 16:04 afilp

@afilp you may add map g Vomnibar.activate icase or map g Vomnibar.activate icase=true to the "custom key mappings" option - this is a new option used in command mappings, so if you have more than one mapping of Vomnibar.activate*** and you expect they are all case-insensitive, then you need to re-map all of them.

gdh1995 avatar Apr 21 '20 02:04 gdh1995

Thanks, it worked!

Where is this process shown in the UI? It seems like hidden.

I thought that this could be a check here (that would apply to all 3 variants, T, b, g):

image

Thanks a lot, when you have time it would be perfect to also have the "find results even when typing in other language's characters). Thanks!

afilp avatar Apr 21 '20 08:04 afilp

Well, I think such a usage of icase is too small to add a visible checkbox for it. And it provides some more use cases if it's only a command option - one may have two key mappings: one with icase=false, and the other with icase=true.

As for this issue, I prefer a special checkbox for it, to let more notice it.

But it's really very hard to maintain a list of English characters corresponding to what one types. I haven't got a good idea to implement it. There're also some other features in my TODO list, so maybe "adding it into find mode" will be delayed for months or even years.

gdh1995 avatar Apr 21 '20 08:04 gdh1995

Thanks, I will try at some point to implement it up to a point (you know the internals better) in a new branch and show it to you so that you make adjustments, if possible.

afilp avatar Apr 21 '20 09:04 afilp