You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When visualizing anything and exiting the python program using control + c it doesn't close the screen and also doesn't kill the python code
It only closes after focusing & clicking in the window again with the following prompt in the terminal afterwards: Caught a Ctrl-C within python, exiting program.
Is there a way to automatically stop the visualizer after exiting the python program via the terminal?
On a custom VTK viewer we implemented using PyQT the following line seems to do the trick.
# This assures the app quits on CTRL-C (when not in focus)
signal.signal(signal.SIGINT, signal.SIG_DFL)
I just tested and putting the following snippet at the top of the plotter.py file ensures that the code terminates on control-c in the terminal.
Not sure if this would be a desired solution or if there are other options
importsignal# This assures the app quits on CTRL-C (when not in focus)signal.signal(signal.SIGINT, signal.SIG_DFL)
Hi, if you do CTRL-C focusing on the terminal that should terminate the app (maybe after some delay).
CTRL-C focusing on the rendering window will do nothing (although it would be good to have the same).
The way to close the window while focusing on it is to press q.
When visualizing anything and exiting the python program using
control + c
it doesn't close the screen and also doesn't kill the python codeIt only closes after focusing & clicking in the window again with the following prompt in the terminal afterwards:
Caught a Ctrl-C within python, exiting program.
Is there a way to automatically stop the visualizer after exiting the python program via the terminal?
On a custom VTK viewer we implemented using PyQT the following line seems to do the trick.
Visualization code example
Thanks
The text was updated successfully, but these errors were encountered: