This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import PySimpleGUI as sg | |
layout = [ | |
[sg.Image(filename=r'C:\Python\PycharmProjects\GooeyGUI\Holiday-Inn-Scheduler-master\imagebad.png')], | |
# [sg.Image(filename=r'C:\Python\PycharmProjects\GooeyGUI\Holiday-Inn-Scheduler-master\holidayinnlogo good.png')], | |
[sg.Button('Exit')] | |
] | |
window = sg.Window('My new window', layout) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import PySimpleGUI as sg | |
layout = [[sg.Text('My Text Editor')], | |
[sg.Multiline(size=(100,20))],] | |
window = sg.Window('My Text Editor', layout) | |
while True: # Event Loop | |
event, values = window.Read() | |
if event is None: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
import PySimpleGUI as sg | |
import os | |
from sys import exit as exit | |
from PIL import Image | |
import io | |
# Helper func | |
def image_file_to_bytes(filename, size): | |
try: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import PySimpleGUI as sg | |
import subprocess | |
def slider(key, initial_value): | |
return [sg.Slider((1, 200), resolution=0, default_value=initial_value, orientation='h', size=(10,15),key=key)] | |
layout = [ [sg.Text('Pitch')], slider('pitch', 64), | |
[sg.Text('Speed')], slider('speed',72), | |
[sg.Text('Mouth')], slider('mouth',128), | |
[sg.Text('Throat')],slider('throat',128), |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import PySimpleGUI as sg | |
from random import randint | |
NUM_GUESSES_ALLOWED = 3 | |
layout = [ [sg.Text('Multiplication Game', text_color='blue')], | |
[sg.Text('', size=(20,1), font='Arial 20', key='_QUESTION_', text_color='red')], | |
[sg.Input(size=(4,1), enable_events=True, key='_ANSWER_'), sg.Text('', size=(24,1), text_color='red', key='_OUTPUT_')], | |
# [sg.Button('Answer', bind_return_key=True), sg.Button('Quit')], | |
[sg.Text('Change Difficulty Level')], |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import PySimpleGUI as sg | |
from random import randint as randint | |
from random import choice as choice | |
import time | |
import string | |
""" | |
PySimpleGUI simulation of a network communications monitoring and manipulation of network connections | |
10 lines of Network connections are shown | |
Can click on a button to bring up a detailed view for the connection |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import PySimpleGUI as sg | |
sg.SetOptions(margins=(0,0), button_color=('white', 'black'), border_width=0, font='Times 14 bold') | |
top = [[sg.Button('Main Menu', font='Times 14 bold'), | |
sg.Button('Account', font='Times 14 bold'), | |
sg.Text(' '*(40), background_color='black'), | |
sg.Button('_', font='Times 14 bold'), | |
sg.Button('X', font='Times 14 bold')],] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
import sys | |
if sys.version_info[0] >= 3: | |
import PySimpleGUI as sg | |
else: | |
import PySimpleGUI27 as sg | |
from random import randint | |
import PySimpleGUI as sg | |
from matplotlib.backends.backend_tkagg import FigureCanvasTkAgg, FigureCanvasAgg |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import PySimpleGUI as sg | |
NUM_ROWS = 20 | |
NUM_COLS = 80 | |
layout = [ | |
*[[sg.T(f'{i:02} ',background_color='white', text_color = 'gray60'), sg.In(size=(NUM_COLS,1), do_not_clear=True, key=i)] for i in range(NUM_ROWS)], | |
[sg.Button('Exit')] | |
] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import sys | |
if sys.version_info[0] >= 3: | |
import PySimpleGUI as sg | |
else: | |
import PySimpleGUI27 as sg | |
import math | |
SIZE_X = 200 | |
SIZE_Y = 100 | |
NUMBER_MARKER_FREQUENCY = 25 |
NewerOlder