I currently have a Basic X Server with matchbox window manager with opens a nw.js (was called node-webkit) chromium browser.
matchbox has by default all hotkeys deactivated.
The only thing left ist the internal alt+f4 handling from chromium.

Is there some way to prevent the nw.js application from closing?

  • The answer to your question is "don't press ALT+F4", but I assume the real question here is how to prevent the user from closing your app no matter what keys they press. Jul 4 '19 at 11:44

Remap F4 to something else using

 xmodmap -e "keycode 70 = F3"

After that, for all progams running under X11 your keyboard will appear to have two F3 keys and no F4 key.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.