How to use the easygui.ccbox function in easygui

To help you get started, we’ve selected a few easygui examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github kglore / llnet_color / llnet_color.py View on Github external
sda.logLayer.b.set_value(logLayer_W_and_b[1])
            print '...loading completed'
            denoise_overlapped_strides(te_noisy_image);
            print 'Completed:', te_noisy_image
            exit()

    msg = "You are currently running the image enhancement program, LLNet, developed by Akintayo, Lore, and Sarkar. What would you like to do?"
    choices = ["Train Model","Enhance Single/Multiple Images","Exit Program"]
    reply = buttonbox(msg, title="Welcome to LLNet!", choices=choices)

    if reply == "Exit Program":
        exit()

    if reply == "Train Model":

        if ccbox('You are currently training a new model. The model file might be overwritten. Continue?','Information')==True:
            tr_dataset = fileopenbox(title='Select training data.',default='*',filetypes=["*.mat"])
            test_SdA()
        else:
            msgbox("Program terminated. Goodbye!")
            exit()

    if reply == "Enhance Single/Multiple Images":

        # Present model to load
        model_to_load = fileopenbox(title='Select your model to load.',default='*',filetypes=["*.wgt","*.obj"])
        #f = file(model_to_load, 'rb')
        #sda = cPickle.load(f)
        #f.close()
        print '...initializing SDA'
        sda = SdA(
            numpy_rng= numpy.random.RandomState(89677),
github amusi / Python-From-Zero-to-One / 课时035 图形用户界面入门: EasyGui / program000_EasyGui.py View on Github external
msg = "请问你希望打开哪个功能选项呢?"
    title = "EasyGuo小程序"
    choices = ["Python入门", "Python进阶", "Python实战", "Python-AI"]

    # 获得选择的结果
    choice = eg.choicebox(msg, title, choices)

    # 弹出对话框,显示选择的结果
    eg.msgbox("你的选择是: "+ str(choice), "结果")

    msg = "你希望重新开始小程序么?"
    title = "请选择"

    # 显示一个继续、取消对话框
    if eg.ccbox(msg, title):
        pass         # 用户选择继续
    else:
        sys.exit(0)  # 用户选择取消
github MA3STR0 / kimsufi-crawler / notifiers / popup_notifier.py View on Github external
def notify(self, title, text, url=False):
        """Open popup notification window with easygui"""
        import easygui
        if easygui.ccbox(text, title, ["Open web page", "Ignore"]):
            webbrowser.open_new_tab(url)
github horstjens / ThePythonGameBook / python / goblindice / easyguiscrollbox.py View on Github external
elif action == "log":
            if  battles == 0:
                easygui.msgbox("no battles yet !") 
                continue # jump to the top of the current (while) loop
            easygi.textbox(vtext, "combat log", log)
        elif action == "edit":
            pass
        elif action == "save":
            output = open("combat_statistic","a") # a: append 
            output.write("\n- - - - -\ntext")
            output.close()
        elif action == "+1 battle":
            pass
            
            
        if easygui.ccbox(text,"combat result", image=victorimage):
            easygui.textbox(vtext, "combat log", log)
github PolyKen / 15_by_15_AlphaGomoku / AlphaGomoku / ui / renderer.py View on Github external
def ask_for_draw():
    if display_mode and use_dialog:
        return easygui.ccbox(title='Request', msg='AlphaRenju requests a draw.', choices=['draw', 'continue'])
    else:
        print('> AlphaRenju requests a draw.')
        return 0
github hologram-io / spacebridge / SpaceBridge / sbgui.py View on Github external
def prompt_for_keygen(self):
        message = ("We're going to generate a set of secure keys to protect "
        "your connection to your device. These keys will be generated by the "
        "Hologram API. The Hologram servers will only store the public key and "
        "the private key will be saved to your computer.\n"
        "If you have a key already that you want to use or want to generate "
        "one on your own hit cancel and run with the --upload-publickey and --privatekey arguments.")
        res = easygui.ccbox(msg=message, title=self.title)
        return res

easygui

EasyGUI is a module for very simple, very easy GUI programming in Python. EasyGUI is different from other GUI generators in that EasyGUI is NOT event-driven. Instead, all GUI interactions are invoked by simple function calls.

BSD-3-Clause
Latest version published 3 years ago

Package Health Score

63 / 100
Full package analysis