manojm321 / elfeed-dashboard

A frontend for elfeed
GNU General Public License v3.0
81 stars 9 forks source link

Feature idea: key combinations #10

Closed EFLS closed 3 years ago

EFLS commented 3 years ago

Now that I'm using elfeed-dashboard on a daily basis, I'm creating lots of shortcuts to specific queries.

One thing that might improve the package is to allow key combinations via prefixes.

For example, I would use:

[A] Academic
    [ap] Internet Policy Review     [[elfeed:+unread Policy Review][0]]
    [ad] Feeds on Data                 [[elfeed:+unread +data][0]]

And then use as keys:

#+KEYMAP: A  | elfeed-dashboard-query "+unread +academic"
#+KEYMAP: ap  | elfeed-dashboard-query "+unread +academic Policy Review"
#+KEYMAP: ad  | elfeed-dashboard-query "+unread +academic +data"

Currently, I get an error "Key sequence ap starts with non-prefix key a", as the key should be defined as a prefix command first.

I've tried evaluating (define-prefix-command 'elfeed-dashboard-academic) and then using #+KEYMAP: a | elfeed-dashboard-academic, but the error remains.

So my question is twofold: Any pointers on how to achieve this? And would you consider such a feature in elfeed-dashboard?