4 ms·
I like the concept a lot, having written my own "wrapper" for Tkinter and wishing I could adapt it to Remi. My only thought is that defining the contents of a l
by analog31 5y ago
I like the concept a lot, having written my own "wrapper" for Tkinter and wishing I could adapt it to Remi. My only thought is that defining the contents of a layout as a dict instead of a list, would allow the elements to be referenced by a name rather than number. That would make it easier to read and modify one's own code.
- H8crilA 5y agoDict() is unordered.
- rmellow 5y agoAs of Python 3.6, Dictionaries are ordered.
- H8crilA 5y agoUh, nice, didn't know. That will fix a lot of bad (nondeterministic) code out there :)
- smarnach 5y agoIt's actually as of Python (the language) 3.7. The CPython implementation of Python 3.6 already has ordered dicts as an implementation detail, but it's not part of the language in that version.
- maicro 5y agoFrom Example 2 (https://github.com/PySimpleGUI/PySimpleGUI#example-2---interactive-window https://github.com/PySimpleGUI/PySimpleGUI#example-2---inter... ) it looks like you can assign names to layout elements with "key".