Closed braton closed 6 years ago
I'm not sure why it kills your terminal because all I'm doing is calling exit(0) when F10 is pressed. What OS and terminal emulator are you using? Does it also happen when pressing CTRL+C on a newest commit?
I use GNOME Terminal 3.6.2. Anyway using Ctrl-C on latest commit works flawlessly and application exits. Thanks.
Ok, so I think this may be related to exiting when UI is active vs exiting from 'normal' commandline. Can you check if F10 is working properly now?
I think the following code:
Screen.KEY_F10: lambda self: exit(0)}
is never executed as the GNOME Terminal intercepts the F10 key and handles that (automatically moving me to the File menu). I don't think there is workaround for it hence the Ctrl-C request (which works well).
Ah, ok. I've replaced exit(0) with
Screen.KEY_F10: lambda self: (_ for _ in ()).throw(KeyboardInterrupt)
but if the keypress doesn't reach my program then there's nothing I can do.
Dear Author,
Please consider implementing more convenient way of exiting the application. Currently the only available option seems to be F10, however this closes my whole terminal application. I would like to be able to exit to my previous shell. How about implement the SIGNIT (Ctrl-C) to gracefully exit this process?
Thank you and Best Regards, Bartosz Zator