Can i use the keymap editor to achieve this? (add frame irrespective of where cursor is on screen)

Id like to configure blender to use f7 to add a blank grease pencil keyframe regardless of where the cursor is on screen (similar to how adobe animate works). Is this possible with the keymap editor alone, or would I need to write an add-on to achieve this?

So far i’ve tried using the keymap editor to map F7 to ‘gpencil.blank_frame_add’ in the following groups (sometimes simultaneously) but so far I only succeeded in having the shortcut work while the cursor is in the 3dview area (not the dopesheet area).

Window
Screen > Screen Global
Grease pencil > grease pencil global
Dopesheet > Dopesheet (Global)
Frames

You can’t do it everywhere. Operator needs a Grease Pencil object as active object, in a specific mode.

But it looks like Keymap Editor is still considering Grease Pencil as a scene data and not as a regular 3D object, yet.

At least, you should be able to add a blank frame in dopesheet by pressing I.

That is generic shortcut for adding a keyframe in dopesheet. Because nature of Grease Pencil data is different : that corresponds to adding a blank frame.