I want my application to close whenever I press the F12 button.
F12
Here is my code for this:
stage.addEventHandler(KeyEvent.KEY_PRESSED, event -&