[Python-ideas] A GUI for beginners and experts alike
Jonathan Fine
jfine2358 at gmail.com
Thu Aug 23 17:15:28 EDT 2018
Hi Mike
Thank you for your prompt response. You wrote
> Maybe we're on different planes?
>
> I'm talking about 5 lines of Python code to get a custom layout GUI on
the screen:
>
> import PySimpleGUI as sg
>
> form = sg.FlexForm('Simple data entry form') # begin with a blank form
>
> layout = [
> [sg.Text('Please enter your Name, Address, Phone')],
> [sg.Text('Name', size=(15, 1)), sg.InputText('1', key='name')],
> [sg.Text('Address', size=(15, 1)), sg.InputText('2',
key='address')],
> [sg.Text('Phone', size=(15, 1)), sg.InputText('3',
key='phone')],
> [sg.Submit(), sg.Cancel()]
> ]
>
> button, values = form.LayoutAndRead(layout)
The execution of this code, depends on PySimpleGUI, which in turn depends
on tkinter, which is in turn a thin layer on top of Tcl/Tk. And Tcl/Tk
provides the GUI layer.
(See https://docs.python.org/3/library/tk.html.)
I'm suggest that sometimes it may be better to use HTML5 to provide the GUI
layer. I pointed to Elm, to show how powerful HTML5 has become.
Put another way, I'm suggesting that instead of
> import PySimpleGUI as sg
we are able to use
> import HtmlSimpleGUI as sg
for a module HtmlSimpleGUI that, sadly, hasn't been written yet!
However, mine is just one voice, and I have little more to say. If you
don't mind, I'll leave this conversation now.
with best regards
Jonathan
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/python-ideas/attachments/20180823/c8ae7c0f/attachment.html>
More information about the Python-ideas
mailing list