-
Notifications
You must be signed in to change notification settings - Fork 152
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
CompletionWindow doesn't work with mouse click #413
Comments
I looked at the code and found this TODO:
Shouldn't be too hard to fix. Preparing a PR now... What is the expected behavior? Do we want to insert the item on a single-click or a double-click? Most modern editors insert items with a single-click. IIRC, the original AvalonEdit used a double-click. I am going to implement single-click for now. |
Fix: #413 CompletionWindow doesn't work with mouse click
Thank you so much for quick review @danipen. |
Apologies for being difficult, resurrecting an old issue, but it would be great if the single/double click was configurable somehow. There doesn't seem to be a particularly clean way of overloading these classes to change the behaviour, as the |
What would be the motivation for using double-click instead of single-click? |
The motivation for me would be that the ListBox is a SelectingItemsControl, and the fact that the selection works with the arrow keys but not the mouse pointer breaks the affordance (had to look up the technical term there) of the control. It also doesn't seem consistent across the various interactions. And, as the action now triggers on PointerPressed rather than PointerReleased or DoubleTapped, the action occurs sooner than expected, which slightly diminishes recoverability for user input. As an example, Visual Studio uses a single-click for selecting items in the autocomplete dropdown, and double-click for activating a given autocomplete option. |
I'll look into it. |
@gebodal I don't see a simple way to support The current implementation ( |
After further digging: I was wrong about the |
Hey community,
I found strange behavior. When
CompletionWindow
opened, you can select variants by keyboard up/down and press enter - everything working as expected. But if you will open it and select option by mouse - it will just closeCompletionWindow
and do nothing.How can we make it works by mouse selection as well?
How to reproduce
AvalolinaEdit.Demo
projectasd.
to showCompletionWindow
The text was updated successfully, but these errors were encountered: