Example #1
0
from AnyGUI.xGUI import *
import unittest
xGUI(Environment="wx")


#Functions bind to button events
def SubmitButtonClick(event=None):
    newpassword1 = newpassText1.getText()
    newpassword2 = newpassText2.getText()
    response = validatePassword(newpassword1, newpassword2)
    if (response == 0):
        storePass = newpassword1
        oldpassText.setText(rentSecure(storePass, secure))
        consoleText.setText("Password has been changed\n")
    elif (response == -1):
        consoleText.setText("Unknown error\n")
    elif (response == -2):
        consoleText.setText("Error: Both the new password are not same\n")
    elif (response == -3):
        consoleText.setText("Error: Password is less than six letter\n")
    elif (response == -4):
        consoleText.setText("Error: Password is not alphanumeric\n")
    return


storePass = "******"
secure = True


def rentSecure(password, isSecure):
    if (isSecure):
Example #2
0
from AnyGUI.xGUI import *
import unittest
xGUI(Environment="gtk")


#Functions bind to button events
def SubmitButtonClick(event=None):
    newpassword1 = newpassText1.getText()
    newpassword2 = newpassText2.getText()
    response = validatePassword(newpassword1, newpassword2)
    if (response == 0):
        storePass = newpassword1
        oldpassText.setText(rentSecure(storePass, secure))
        consoleText.setText("Password has been changed\n")
    elif (response == -1):
        consoleText.setText("Unknown error\n")
    elif (response == -2):
        consoleText.setText("Error: Both the new password are not same\n")
    elif (response == -3):
        consoleText.setText("Error: Password is less than six letter\n")
    elif (response == -4):
        consoleText.setText("Error: Password is not alphanumeric\n")
    return


storePass = "******"
secure = True


def rentSecure(password, isSecure):
    if (isSecure):
Example #3
0
from AnyGUI.xGUI import *
import unittest
xGUI(Environment = "wx")

#Functions bind to button events
def SubmitButtonClick(event=None):    
    newpassword1 = newpassText1.getText();
    newpassword2 = newpassText2.getText();
    response = validatePassword(newpassword1,newpassword2) 
    if(response == 0):
        storePass = newpassword1;
        oldpassText.setText(rentSecure(storePass,secure));
        consoleText.setText("Password has been changed\n");
    elif(response == -1):        
        consoleText.setText("Unknown error\n");
    elif(response == -2):        
        consoleText.setText("Error: Both the new password are not same\n")
    elif(response == -3):        
        consoleText.setText("Error: Password is less than six letter\n")
    elif(response == -4):
        consoleText.setText("Error: Password is not alphanumeric\n")
    return


storePass = "******"
secure = True

def rentSecure(password,isSecure):
    if(isSecure):
        for i in range(len(password)):
           password = password.replace(password[i],"*")
Example #4
0
from AnyGUI.xGUI import *
xGUI(Environment = "gtk")
'''
Package in AnyGUI
-------------------
from AnyGUI.fltkGUI import *    #FLTK GUI
from AnyGUI.tkGUI import *      #Tkinter GUI
from AnyGUI.wxGUI import *      #wxPython GUI
from AnyGUI.gtkGUI import *     #GTK GUI
from AnyGUI.qtGUI import *      #QtPy GUI

Dynamic evironment change
-------------------------
Environment will in
    wx    : wxPython            by Arink    2009cs1017
    fltk  : Fast Light Toolkit  by Kamal    2009cs1011
    gtk   : GTK Py              by Gaurav   2009cs1001
    qt    : PyQT                by Prateek  2009cs1002
    tk    : TKinter             by Pravesh  2009cs1001
'''

#Functions bind to button events
def SubmitButtonClick(event):
    report = " Your city is "+valuelist.getValue()+"\n"
    if(checkbox1.getValue()):
        report = report + " you have read the code\n"
    else:
        report = report + " you have not read the code\n"
        
    if(checkbox2.getValue()):
               report = report + " you have read the documentation\n"
Example #5
0
from AnyGUI.xGUI import *
xGUI(Environment = "qt")
'''
Package in AnyGUI
-------------------
from AnyGUI.fltkGUI import *    #FLTK GUI
from AnyGUI.tkGUI import *      #Tkinter GUI
from AnyGUI.wxGUI import *      #wxPython GUI
from AnyGUI.gtkGUI import *     #GTK GUI
from AnyGUI.qtGUI import *      #QtPy GUI

Argumented evironment change
-------------------------
xGUI(Environment = "x")
Environment x will in
    wx    : wxPython            
    fltk  : Fast Light Toolkit  
    gtk   : GTK Py              
    qt    : PyQT                
    tk    : TKinter             
'''


#Functions bind to button events
def SubmitButtonClick(event=None):
    report = " Your city is "+valuelist.getValue()+"\n"
    if(checkbox1.getValue()):
        report = report + " you have read the code\n"
    else:
        report = report + " you have not read the code\n"