def __init__(self): self.theme = sg.theme('DarkAmber') self.layout = [[sg.Text('Search Term', size=(10,1)), sg.Input(size=(45,1), focus=True, key="TERM"), sg.Radio('Contains', group_id='choice', key='CONTAINS', default=True), sg.Radio("Starts With", group_id='choice', key="STARTSWITH"), sg.Radio("Ends With", group_id='choice', key="ENDSWITH")], [sg.Text('Root Path', size=(10,1)), sg.Input('C:/', size=(45,1), key="PATH"), sg.FolderBrowse('Browse', size=(10,1)), sg.Button('Re-Index', size=(10,1), key="_INDEX_"), sg.Button('Search', size=(10,1), bind_return_key=True, key="_SEARCH_")], [sg.Output(size=(50,100))]] self.window = sg.Window('File Search Engine').Layout(self.layout)
), sg.Text('JSON data export URL(http://)', size=(30,1), font=('Helvetica, 16')) ], [ sg.Button('Start Logging', button_color=('white', 'blue')), sg.Button('Stop Logging', button_color=('white', 'green')), sg.Button('Stop Server', button_color=('white', 'red')) ], [ sg.Multiline( 'Data Output', size=(160, 12), key='_MULTIOUT_', font='Courier 14', autoscroll=True,) ]] ''' sg.Output(size=(160,12)) ''' # create the "Window" window = sg.Window( 'VSCapture Logging Interface', layout=layout, default_element_size=(60, 2), font='Helvetica 18', web_port=WEBPORT, web_start_browser=False, web_multiple_instance=True, disable_close=True, ) print("Started VSCaptureWeb(C) 2019 VSCapture web interface server on localhost:" + str(WEBPORT)) # The "Event loop" where all events are read and processed (button clicks, etc)