richardgv / skippy-xd

A full-screen Exposé-style standalone task switcher for X11.
GNU General Public License v2.0
341 stars 78 forks source link

request: keyboard hints for window selection #59

Open dicktyr opened 9 years ago

dicktyr commented 9 years ago

please consider implementing keyboard hints to quickly and directly select a given window (instead of navigating to it with arrow keys, &c.)

https://en.wikipedia.org/wiki/Vimperator#Hint_mode

4drift commented 8 years ago

I can navigate with h,j,k,l and space for selection... I've installed it twice and always have been able to.

dicktyr commented 8 years ago

h,j,k,l just do the same as arrow keys

keyboard hints enable direct selection (see link above) ideally using characters for labels instead of numbers ordered by ease of typing rather than alphabetically

dreamcat4 commented 6 years ago

I think this is a good feature, and worthwhile implementing. However there are 3 challenges.

1) First of the challenges is that skippy holds the windows as a dynamic linked list. So there is no direct index to reference each window. Instead you have to loop through / step through each element and count them one by one.

This should not be very difficult. However it's necessary to update / redo the listing if a program closes, or new program appears. There is already some existing update / polling mechanism for handling that situation. So the re-counting must be added somewhere in there, and in the correct place before a re-draw of the screen is due.

2) Another challenge is to somehow display a number in each window preview. This requires adding some new drawing routine.

3) Then finally, there is the question about what to do if there are more than 10 windows open. Because more than 10 window previews is the point where you run out of numbers on the standard keyboard from 0-9. Perhaps an 'obvious' solution would be to then spill over into using function keys. Or modifier keys + a number (such as Shift+7, for the 17th window).

Then we still need to make sure, that the text being drawn inside (or next to) each window preview is clearly legible / easy to read.

Overall, that is a fair chunk of work needed, to implement this feature correctly.