[New feature] Unlimited key presses of arbitrary duration

darktable’s shortcut system is great, but it has two obvious limitations: each key can only be pressed up to three times, and the press duration can only be short or long. These are arbitrary and unfair choices that limit our freedom to customize shortcuts as we please.

We, the users, deserve better!

For this reason, I am working on a simple change that will solve this problem once and for all. You will be able to press a key as many times as you want, and your presses can have any duration, with millisecond resolution.

Gone is the need to remember 200 different keys to control the UI. In fact, the new system is sufficiently expressive that, if you are so inclined, you can control the whole UI with just a single key!

No more finger gymnastics, everything will be easily controllable using just your one favorite finger!

For, example, you can use e[1ms] for exposure, e[2ms] for AgX contrast, and e[20ms],e[1ms],e[5ms],e[10ms],e[8ms],e[4ms] for that obscure slider that you only need once every leap year.

To make usage more intuitive (even more? you may ask - yes, even more!) handy press and millisecond counters will show up in the middle of the UI in very large, colorful fonts (enough with all this grey, already!), so that you will never miss that shortcut again!

Are you as excited as I am? We do live in wonderful times!

Stay tuned for an official PR and a binary release :heart:

10 Likes

Will that be another day … ? :wink:

Either before EOD or in exactly one year :+1:

5 Likes

Oh my god all my dreams are coming true on wait… What’s the date again?,

2 Likes

Very good! You had me until I saw “millisecond”.
Joking apart, no one talks about voice input. Is that possible? Could I say “new exposure instance called grass” ?

1 Like

You joke, but I do find it annoying that I can’t define a shortcut “mtee” for module tone equalizer enable, or “mccp” for module color calibration picker. I guess fallbacks can do this while being simpler to configure but harder to understand.

I’m too used to vim shortcuts, or visual studio where you can define chords: prefix for a category, then a second shortcut for the specific action. I seen to recall emacs actually popularized chords, though.

3 Likes

Me too. I understand that is not currently possible because there would be no way to differentiate between mtee (1 action) and m+t+e+e (4 actions, the last one repeated twice). One could have a different modality in which there is a special character designated as “commit shortcut”, but that would require one to always hit one extra key.

1 Like

ee is already distinct from e e with a pause (two actions). I noticed the pause length is very short. The way vim handles this is to commit the action after the pause length is finished, or immediately if there is no other key sequence that has the current one as a prefix. So mtee could not be understood as anything else if you haven’t defined a shortcut m (or mt or mte). If you have, it depends on how fast you type the shortcut.

To work really well, this requires a longer timeout. That might be compatible with darktable but might annoy people that have both e and ee defined as shortcuts, since it would slow their workflow slightly. Would extending the timeout before committing an action make fallbacks less comfortable to use?

1 Like

Yes, up to three times. It would be interesting to understand why repeats of a single key are treated differently from sequences of different keys. Probably it has to do with the (consistency of the) speed at which one can repeat-press the same key vs. a sequence of keys.

Oh, phew! I’m no good at remembering dates. Especially by 5pm on the day.

But I’m slightly better at it than I am at mentally counting in milliseconds :rofl:

2 Likes

Please make it work with scroll wheel. I want to be able to control everything with the scroll wheel. Each scroll direction could also control a seperate darktable instance for maximum efficiency.

This way I could type emails with my keyboard while editing my photos.

3 Likes

Thanks for making me smile. :grin:

1 Like