How to assign a toggle shortcut to the face selection masking for painting function?

I would like to assign a shortcut to the face selection masking for painting function.

However, I right-click on the button, the Add Shortcut menu doesn’t appear.

In this case, how can I specify a shortcut?

in user preferences

1 Like

It works!!

You helped me. Thank you very much.

Someday, I want to add new shortcuts later by myself.

I want to know what a term like ‘wm.context_toggle’ is.

I’ve been Googling after seeing your answer and then I saw a clause like ‘wm.call_menu’

So I can guess that I need to fill in different event types for each function of Blender, but I have no idea how to use them.

Also, I want to get the correct context attribute depending on the function and know the exact directory in the Keymap Editor. (In this thread, it is the Weight Paint directory.)

What should I search and study?

I haven’t used specific learning resources to learn to set those, just logic. The input settings are full of examples.

Almost the same as how I’ve learned the hotkeys already set. No cheatsheets, just using the tools and once I found myself using the tool more often, checked the hotkey from the UI. After a short while, knew the keys for most used tools. After a long while the known hotkey list is multiple times bigger than there are keys on the keyboard.

Cool… I am surprised that you studied through predefined examples.

One more thing, May I ask you a question for clarity?

I can see the String ‘.use_paint_mask’ for context attribute in the popup that appears on the button of the Face Selection function in the 3D view editor.

But how could you combine string ‘’ In front of it in the keymap editor in user preferences?

Did you just look at many examples and apply them?