On Sun, Aug 1, 2021 at 10:21 AM [email protected] <[email protected]> wrote:
> I was thinking that the server would put up its own console window just > for this purpose. It could do this when it discovers that vs-code has gone > away (or whenever else it liked, really). > Good idea! It should be a better fallback than using Tk. Happily, monkey-patching a Qt dialog into the NullGui class is straightforward: 1: Copy LeoQtGui.runAskYesNoCancelDialog into the server, along with the necessary Qt-related imports. 2: The actual monkey-patch is: # Create a minimal qt application. g.app.use_splash_screen = False # Suppress the splash screen. qt_app = LeoQtGui() g.funcToMethod(runAskYesNoCancelDialog, NullGui) This works with zero changes to Leo's core. Edward -- You received this message because you are subscribed to the Google Groups "leo-editor" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/leo-editor/CAMF8tS22WjQBpyWq3tH%2BLdBhErVUspjOoJLRo7HaJX3JJuqxgw%40mail.gmail.com.
