pietie / HyperSearch

3 stars 1 forks source link

[Feature Request] #21

Open mccorkled opened 6 years ago

mccorkled commented 6 years ago

Is there any way to get "backspace" on a keyboard to function as backspace within Search, and "Enter" on a keyboard to function as "search" within Search? When I click backspace, it either deletes everything I have typed, or closes the search window, and when I click enter to submit a search, it just reenters the letter it is currently on.

Thank you.

pietie commented 6 years ago

You have Backspace bound to the Clear command so that take precedence. Set it to something else to free up Backspace and it should work.

If you press CTRL+ENTER it will initiate search. There is currently no way to do it with just ENTER

mccorkled commented 6 years ago

That's unfortunate. I am using a xbox keyboard on my controller and it's counter intuitive to type and then move back to the analog to move to search

pietie commented 6 years ago

It's easy enough to add. Try this build (just extract and overwrite your existing files)

Download

I've added a new setting called Perform search that you can find a single button to Does this work for you?

mccorkled commented 6 years ago

When I hit enter, it still selects the last letter that it is on. For instance typing "Mario" followed by Enter, Makes it "Marioo"

pietie commented 6 years ago

Did you set up the new setting call Perform search? Sounds like you are still using the Action key?

mccorkled commented 6 years ago

I forgot to clear the Action setting. When I remove that setting and try to close the window it says "no action key configured "defaulting to Enter"

I am trying to come up with a good solution to my setup and perhaps maybe you will have the idea I am looking for. On my xbox remote I have A set to enter and B set to escape so that I can navigate within Hyperspin. I would also like A to be select while in Search, and B to be backspace, but those are already mapped within Xpadder to Enter and Escape. I would like the xbox controller to be able to search when the keyboard isn't attached. I can't seem to think of the best way to make this all work.

Perhaps there would be a way to set "escape" to backspace after text is entered, and then once a search is completed "escape" goes back to the search menu. If escape is pressed when no text is entered, it just closes the search window. Would that be possible?

Thanks

pietie commented 6 years ago

Oh sorry I think I misunderstood your original request.

The escape behaviour you describe was actually the intended behaviour if I look at the code but something broke it along the way.

Try this build

The Back button should now act like Backspace until the input box is empty.

I'm still not sure what you mean with the Action/Enter button though. If A on your controller is setup as Enter on Xpadder then that is fine. Just make sure you bind Enter to the Action button in HyperSearch. This will then be what you use to 'type' on the virtual keyboard.

To then actually 'submit' the search as you call it, you will either have to move to the Search button and press A on your controller or you can bind another button on your controller to Perform search I added yesterday. But obviously you can't use your A button to both select keys and initiate the search shortcut.

mccorkled commented 6 years ago

It's nice to be able to use the virtual keyboard to select letters when a real keyboard isn't available. In that instance enter would select items on the virtual keyboard. If a real keyboard is attached, enter would initiate a search. I am trying to think of the best way to allow enter to be used to select letters, as well as initiate a search. Can you think of one?

It's quite common for A to be select and B to be back, but with search being enter, which is A for navigating Hyperspin menus, this is creating the issue.

pietie commented 6 years ago

If your A button is bound to Enter through Xpadder then that is exactly the same as pressing Enter on a physical keyboard. HyperSearch would not know the difference.

mccorkled commented 6 years ago

Can you think of a way that I may be able to make this work?

pietie commented 6 years ago

You want to select letters on the on-screen keyboard with your A button on the controller. And once you are done 'typing' you want to press A again to initiate the search?

mccorkled commented 4 years ago

Hello! Hope you are well. I am working on editing your plugin and I was hoping you could update the git. Previously you sent me a version that had a "perform search" function but when I compile the version here it does not have this option.

Thank you :)