What to bind a global shortcut to?

For avoiding conflicts with native Anki shortcuts I usually look at the source code. Otherwise, and especially when troubleshooting conflicts with other add-ons, I sometimes do a variation of this (run via the debug console):

from aqt import mw
from aqt.qt import QShortcut

sc = mw.findChildren(QShortcut)
print([i.key().toString() for i in sc])

Though this doesn’t reflect all bindings as add-ons or native code might intercept key presses through other means as well.

For what it’s worth, u is bound to unbury (and thus only really does something when there are cards to unbury, which is why it’s a bit easy to miss).

3 Likes