Refresh of Demo applications
This commit is contained in:
parent
7e1ff1d543
commit
8f220a7ac1
9 changed files with 139 additions and 87 deletions
|
@ -7,7 +7,9 @@ import PySimpleGUI as sg
|
|||
# https://user-images.githubusercontent.com/13696193/43159403-45c9726e-8f50-11e8-9da0-0d272e20c579.jpg
|
||||
#
|
||||
def MediaPlayerGUI():
|
||||
|
||||
background = '#F0F0F0'
|
||||
# Set the backgrounds the same as the background on the buttons
|
||||
sg.SetOptions(background_color=background, element_background_color=background)
|
||||
# Images are located in a subfolder in the Demo Media Player.py folder
|
||||
image_pause = './ButtonGraphics/Pause.png'
|
||||
image_restart = './ButtonGraphics/Restart.png'
|
||||
|
@ -22,18 +24,18 @@ def MediaPlayerGUI():
|
|||
font=("Helvetica", 25))
|
||||
# define layout of the rows
|
||||
layout= [[sg.Text('Media File Player',size=(17,1), font=("Helvetica", 25))],
|
||||
[TextElem],
|
||||
[sg.ReadFormButton('Restart Song', button_color=sg.TRANSPARENT_BUTTON,
|
||||
[TextElem],
|
||||
[sg.ReadFormButton('Restart Song', button_color=(background,background),
|
||||
image_filename=image_restart, image_size=(50, 50), image_subsample=2, border_width=0),
|
||||
sg.Text(' ' * 2),
|
||||
sg.ReadFormButton('Pause', button_color=sg.TRANSPARENT_BUTTON,
|
||||
sg.ReadFormButton('Pause', button_color=(background,background),
|
||||
image_filename=image_pause, image_size=(50, 50), image_subsample=2, border_width=0),
|
||||
sg.Text(' ' * 2),
|
||||
sg.ReadFormButton('Next', button_color=sg.TRANSPARENT_BUTTON,
|
||||
sg.ReadFormButton('Next', button_color=(background,background),
|
||||
image_filename=image_next, image_size=(50, 50), image_subsample=2, border_width=0),
|
||||
sg.Text(' ' * 2),
|
||||
sg.Text(' ' * 2), sg.SimpleButton('Exit', button_color=sg.TRANSPARENT_BUTTON,
|
||||
image_filename=image_exit, image_size=(50, 50), image_subsample=2, border_width=0)],
|
||||
sg.Text(' ' * 2), sg.SimpleButton('Exit', button_color=(background,background),
|
||||
image_filename=image_exit, image_size=(50, 50), image_subsample=2, border_width=0)],
|
||||
[sg.Text('_'*30)],
|
||||
[sg.Text(' '*30)],
|
||||
[
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue