Hello.
I'm building a Python app that involves displaying a preview window. However, I don't want the user to be able to close the preview window; rather, I want to close it programmatically. I know how to do this with the main window by calling root.protocol("WM_DELETE_WINDOW", swallow_event). I want to set this callback only for the image preview window and not the root window, but the picamera2 library hides this.
I'm building a Python app that involves displaying a preview window. However, I don't want the user to be able to close the preview window; rather, I want to close it programmatically. I know how to do this with the main window by calling root.protocol("WM_DELETE_WINDOW", swallow_event). I want to set this callback only for the image preview window and not the root window, but the picamera2 library hides this.
Statistics: Posted by jmarevans — Wed Aug 14, 2024 11:32 pm