david-vanderson / dvui

Other
346 stars 26 forks source link

Make expanders/buttons/etc interactible with keyboard when highlighted #111

Closed VisenDev closed 2 weeks ago

VisenDev commented 2 weeks ago

Pressing tab allows you to highlight different UI elements in a dvui application.

Pressing enter when a ui element is highlighted should simulation a left click. This would allow you to do basic ui navigation with a keyboard. It would also make the current tab highlighting behavior feel more useful and ergonomic

david-vanderson commented 2 weeks ago

Good point - I only implemented space to activate them. I'll add enter, and check if it needs to be added to other widgets as well.

david-vanderson commented 2 weeks ago

Pushed a fix for this. Does it work for you?

VisenDev commented 2 weeks ago

Pushed a fix for this. Does it work for you?

Yes this works now, thanks! When I made this issue I didn't even realize that space worked for this as well