import argparse

from gi.repository import GLib
from gi.repository import Gtk


if __name__ == '__main__':
    parser = argparse.ArgumentParser(description='SIGINT aka ^C test program')
    parser.add_argument('--nope', action='store_true')
    args = parser.parse_args()

    mainwindow = Gtk.Window()
    mainwindow.show()

    if not args.nope:
        mainloop = GLib.MainLoop()
        mainloop.run()
    else:
        Gtk.main()
