def tela_cadastro(): """ Tela para cadastro de novo emprestimo. :return: uma lista contento as informações inputadas. """ layout = [[Text("Cadastrar emprestimo")], [Text("Nome", size=(15, 1)), InputText()], [Text("Telefone Fixo", size=(15, 1)), InputText()], [Text("Celular", size=(15, 1)), InputText()], [Text("E-mail", size=(15, 1)), InputText()], [Text("De onde conhece", size=(15, 1)), InputText()], [ Text("Data", size=(15, 1)), InputText("ex: dia/mês/ano", do_not_clear=False) ], [Text("Item", size=(15, 1)), InputText()], [ Button("Cadastrar", button_color=('white', 'springgreen4')), Cancel(button_text="Cancelar", button_color=('white', 'firebrick3')) ]] janela = Window( "Cadastro", disable_close=True, icon=('C:\\Loans-management\\Icon\\icon-logo.ico')).Layout(layout) botao, valores = janela.Read() if botao == "Cadastrar": janela.Close() return valores elif botao == 'Cancelar' or botao is None: janela.Close()
def tela_atualizacao(informacao_antiga): """ Tela para atualizar informações de um emprestimo já cadastrado. :param informacao_antiga: um dicionário contento todas as antigas informações do emprestimo. :return: uma lista de valores, contento o conteúdo dos InputText. """ layout = [ [Text("Atualizar emprestimo")], [ Text("Nome", size=(15, 1)), InputText(default_text=informacao_antiga['nome'], do_not_clear=True) ], [ Text("Telefone Fixo", size=(15, 1)), InputText(default_text=informacao_antiga['telefone'], do_not_clear=True) ], [ Text("Celular", size=(15, 1)), InputText(default_text=informacao_antiga['celular'], do_not_clear=True) ], [ Text("E-mail", size=(15, 1)), InputText(default_text=informacao_antiga['email'], do_not_clear=True) ], [ Text("De onde conhece", size=(15, 1)), InputText(default_text=informacao_antiga['vivencia'], do_not_clear=True) ], [ Text("Data", size=(15, 1)), InputText( default_text=informacao_antiga['data'].strftime("%d/%m/%Y"), do_not_clear=True) ], [ Text("Item", size=(15, 1)), InputText(default_text=informacao_antiga['item'], do_not_clear=True) ], [ Button("Atualizar", button_color=('white', 'springgreen4')), Cancel(button_text="Cancelar", button_color=('white', 'firebrick3')) ] ] janela = Window( "Cadastro", icon=('C:\\Loans-management\\Icon\\icon-logo.ico')).Layout(layout) botao, valores = janela.Read() print(valores) if botao == "Atualizar": janela.Close() return valores elif botao == 'Cancelar': janela.Close()
def ViewGUI(): sg.theme('LightGreen') col1 = Column([ [Frame('base function',[[Column([[ Text(r'VideoFile',size=(10,1)), InputText(''*15, key="VideoFile"), FileBrowse(target='VideoFile', size=(10,1)), Button('start',key='start', size=(10,1)), Button('stop',key='stop', size=(10,1)), Button('Exit',key= 'exit', size=(10,1)),]], size=(800,45), pad=(0, 0))]])], [Frame('videoplay',[[Column([[Image(filename='', key='image',)]], size=(800,500), pad=(0, 0)) ]])] ], pad=(0,0)) col2 = Column([ [Frame('results', [[Column( [ [Image(filename='', key='image1', size=(200,100)), Button('view', size=(6,1)), Button('close', size=(6,1))], [Image(filename='', key='image2', size=(200,100)), Button('view', size=(6,1)), Button('close', size=(6,1))], [Image(filename='', key='image3', size=(200,100)), Button('view', size=(6,1)), Button('close', size=(6,1))], [Image(filename='', key='image4', size=(200,100)), Button('view', size=(6,1)), Button('close', size=(6,1))], [Image(filename='', key='image5', size=(200,100)), Button('view', size=(6,1)), Button('close', size=(6,1))], ] ,size=(400,560)) ]] )] ]) layout = [[col1,col2]] # layout = [ # [sg.Text(r'机器视觉原型系统', size=(40,1), justification='center')], # [sg.Text(r'VideoFile',size=(10,1)), sg.InputText(''*30, key="VideoFile"), sg.FileBrowse(size=(10,1)), # sg.Button('start',key='start', size=(10,1)), sg.Button('stop',key='stop', size=(10,1)), sg.Button('end', key='end', size=(10,1)), # sg.Button('Exit',key= 'exit', size=(10,1))], # [sg.Image(filename='', key='image')], # ] window = sg.Window( '机器视觉', layout, location=(100,100), finalize=True ) return window
sg.theme('BlueMono') # Add a little color to your windows # create the main window parts main_title_col = [ sg.Text(' Bloom Filter & Password Strength ', size=(40, 1), font=("Helvetica", 20)) ] col1 = Column([[ Frame( 'New Password:'******'Insert new password', enable_events=True), InputText(key='-NEW-PASSWORD-', size=(15, 1)) ], [ Button('Show complete password strength analysis', enable_events=True) ]], ) ]]) col2 = Column([[ Frame( 'Bloom Filter:', [ [ Text('#Array_Bits'), sg.InputText('0', key='-K-', size=(5, 1)), Text('#Size of Hashs'),
window['-GOALS_LIST-'].update(list_goal_titles) print("Here") window['-COMPLETED_GOALS_LIST-'].update(complete_goals_titles) # ----- sublayouts -----# # layout for the login page by Johan yeye kewl ;3 layoutthing = [ [Text(" " *48), Button("Enter", font=('Courier', 10))] ] # ---Login Column---# bottom_right_column = Column([ [Text("Username", size=(10, 2), font=('Courier', 12))], [InputText(key="-USERNAME-", size=(37, 5), background_color='#E0DEDE', font=('Courier', 10))], [Text("Password", size=(10, 2), font=('Courier', 12))], [InputText(key="-PASSWORD-", size=(37, 5), password_char='*', background_color='#E0DEDE', font=('Courier', 10))], [Column(layoutthing)] ]) # ---Login PAGE---# bot_page = [ [Text('\n\n\nTrack your progress, \nWith Cats!', size=(30, 10), font=('Courier', 20, 'bold'), justification='center'), bottom_right_column], ] login_page_layout = [ [Image(r'half_cat.png')], [Frame('', bot_page, background_color=sg.theme_input_background_color(), border_width=0)] ]
league_choice = Listbox(leagues(), size=(34, 16), font=font, enable_events=True, key='-LEAGUE-') history_choice = Slider(range=(history_min, history_max), default_value=history_max, orientation='h', font=font, key='-HISTORY-') team_radio_one = Radio('', radio_team_choice, font=font, default=True) team_radio_two = Radio('', radio_team_choice, font=font) team_choice_one = InputText(font=font, size=(30, 1), key='-TEAM1-') team_choice_two = InputText(font=font, size=(30, 1), key='-TEAM2-') team_clear_one = Button('Clear', button_color=('black', 'white'), font=font, key='-CLEAR-TEAM1-') team_clear_two = Button('Clear', button_color=('black', 'white'), font=font, key='-CLEAR-TEAM2-') venue_any = Radio(Venue.any.name.capitalize(), radio_venue, font=font, default=True) venue_home = Radio(Venue.home.name.capitalize(), radio_venue, font=font)
os.system('taskkill -f -im upc.exe & taskkill -f -im UplayWebCore.exe') accounts = os.listdir(SAVE_DIR) for account_id in accounts: path = f'{SAVE_DIR}\\{account_id}' if GAME_ID[method] not in os.listdir(path): continue path += f'\\{GAME_ID[method]}\\1.save' fs.copyfile(DATA_PATH, path) # Start UI gui.theme('DarkBlue') layout = [ [Text('EliteSkins Rainbow Six Siege Skins Installer\n')], [Text('Please ensure you have disabled Ubisoft Cloud Save and have recently opened Rainbow 6 Siege.')], [Text('Enter your License Key:'), InputText()], [Text('I installed Rainbow Six Siege using: '), Radio('Steam', 'install_method'), Radio('UPlay', 'install_method')], [Checkbox('I understand that the creators of this installer are not responsible for any damage caused by its use.')], [Button('Install'), Button('Cancel')] ] window = gui.Window('EliteSkins Installer', layout) while True: event, values = window.read() if event in (None, 'Cancel'): break if event == 'Install': key = values[0] confirm = values[3]
from password_strength_rules import password_rules import binascii import enchant # All the stuff inside your window. This is the PSG magic code compactor... # https://pysimplegui.readthedocs.io/en/latest/#layouts # https://opensource.com/article/18/8/pysimplegui # https://github.com/PySimpleGUI/PySimpleGUI/tree/master/DemoPrograms sg.theme('LightGray1') # Add a little color to your windows # create the main window parts main_title_col = [sg.Text(' Bloom Filter & Password Strength Checker' , size=(40, 1), font=("Helvetica", 20))] col1 = Column([ [Frame('New Password:'******'Insert new password', enable_events= True), InputText(key='-NEW-PASSWORD-' ,size=(15, 1))], [Button('Show complete password strength analysis', enable_events= True)]],)] ]) col2 = Column([ [Frame('Bloom Filter:', [[Text('# Bits'), sg.InputText('8', key='-K-', size=(5, 1)), Text('#Hashes'), InputText('1', key='-N-',size=(5, 1)), Button('Enter', enable_events= True)], [Button(' Show filter statistics ', enable_events= True)],],)] ]) col3 = Column([ [Frame('Password Check:', [[Text('Insert password to check'), InputText(key='-PASSWORD-TO-CHECK-',size=(15, 1))], [Button(' Check the presence of the password ', enable_events= True)]],)] ])
text_color='black') ], [ Text( "4. If your data contains biological replicates ensure there are an equal number of biological" " replicates for each sample.If your data doesn't contain biological replicates, enter \"0\" when prompted.", size=(60, 4), text_color='black') ], [Button('Next -->')] ] Change('Metabolomics', layout) event, values = window.read() layout2 = [[Text('Save Folder', size=(23, 1)), InputText(), FolderBrowse()], [Text('Dataset File', size=(23, 1)), InputText(), FileBrowse()], [Text('New File Name', size=(23, 1)), InputText()], [Button('Next -->')]] if event == ('Next -->'): window.close() del window Change('Metabolomics', layout2) layout3 = [ [Text('Blank Cutoff', size=(30, 1)), InputText()], [Text('Higher Retention Time Cutoff ', size=(30, 1)),
# Items in toolbar menu menu_def = [['File', 'Exit'], ['Edit', 'Clear Fields'], ['Help', ['Tutorial', 'About', 'My Github']]] toolbar_menu = Menu(menu_def, tearoff=True) app_title = Text('Batch File Renamer', justification='center', size=(50, 1), key='title') # Folder Chooser choose_frame = Frame(layout=[[ Text('Choose Folder:', size=(12, 1)), InputText('', enable_events=True, key='path', size=(30, 1)), FolderBrowse(target='path') ]], title='', relief='flat') # New Name name_frame = Frame(layout=[[ Text('New Name:', size=(12, 1)), InputText('', key='name', enable_events=False, size=(30, 1)) ]], title='', relief='flat', visible=False) # File Name Index
first_layout = [[ Radio('Search with EID', 'type', key='-SEID-'), Radio('Search with Offer ID', 'type', key='-SOID-') ], [Button('Submit', key='-TYPESUBMIT-')]] layout0 = [[Text('Upload the Latest Altice West Master Matrix Excel')], [In(key='-FILE0-', disabled=True), FileBrowse()], [Button('Upload', key='-UPLOAD0-')]] layout1 = [[Text('Upload the Latest EID Excel')], [In(key='-FILE-', disabled=True), FileBrowse()], [Button('Upload', key='-UPLOAD-')]] layout2 = [[Text(key='-SHEETNAME-', size=(50, 1))], [Text('Enter Offer ID'), InputText(key='-ID-')], [ Radio('QA INT', 'corp', key='-QAINT-', default=True), Radio('QA 1', 'corp', key='-QA1-'), Radio('QA 2', 'corp', key='-QA2-'), Radio('QA 3', 'corp', key='-QA3-'), Radio('Other corps', 'corp', key='-OTHERS-') ], [ Button('Submit', key='-SUBMIT-'), Button('Upload another file', key='-ANOTHER-') ]] layout3 = [[Text('Enter EID'), InputText(key='-EID-')], [Button('Submit', key='-SUBMIT1-')]]
text_color='black') ], [ Text( "4. If your data contains biological replicates ensure there are an equal number of biological" " replicates for each sample.If your data doesn't contain biological replicates, enter \"0\" when prompted.", size=(60, 4), text_color='black') ], [Button('Next -->')] ] Change('Metabolomics', layout) event, values = window.read() layout2 = [[Text('Save Folder', size=(23, 1)), InputText(), FolderBrowse()], [Text('Dataset File', size=(23, 1)), InputText(), FileBrowse()], [Text('New File Name', size=(23, 1)), InputText()], [Button('Next -->')]] if event == ('Next -->'): window.close() del window Change('Metabolomics', layout2) layout3 = [ [Text('Blank Cutoff (ex. 10000)', size=(40, 1)), InputText()], [Text('Higher Retention Time Cutoff (ex. 8) ', size=(40, 1)),