Jump Start added
This commit is contained in:
parent
385c2020f0
commit
2e27926e97
103
docs/index.md
103
docs/index.md
|
@ -16,11 +16,11 @@
|
||||||
|
|
||||||

|

|
||||||
|
|
||||||

|

|
||||||
|
|
||||||

|

|
||||||
|
|
||||||

|

|
||||||
|
|
||||||

|

|
||||||
|
|
||||||
|
@ -31,7 +31,44 @@
|
||||||
|
|
||||||
## Python GUI For Humans - Transforms tkinter, Qt, Remi, WxPython into portable people-friendly Pythonic interfaces
|
## Python GUI For Humans - Transforms tkinter, Qt, Remi, WxPython into portable people-friendly Pythonic interfaces
|
||||||
|
|
||||||
#### July-2019 Note - This readme is being generated from the PySimpleGUI.py file located on GitHub. As a result, some of the calls or parameters may not match the PySimpleGUI that you pip installed.
|
---
|
||||||
|
|
||||||
|
# Jump-Start
|
||||||
|
|
||||||
|
## Install
|
||||||
|
|
||||||
|
```
|
||||||
|
pip install pysimplegui
|
||||||
|
or
|
||||||
|
pip3 install pysimplegui
|
||||||
|
```
|
||||||
|
|
||||||
|
### This Code
|
||||||
|
|
||||||
|
```python
|
||||||
|
import PySimpleGUI as sg
|
||||||
|
# All the stuff inside your window.
|
||||||
|
layout = [ [sg.Text('Some text on Row 1')],
|
||||||
|
[sg.Text('Enter something on Row 2'), sg.InputText()],
|
||||||
|
[sg.Button('Ok'), sg.Button('Cancel')] ]
|
||||||
|
|
||||||
|
# Create the Window
|
||||||
|
window = sg.Window('Window Title', layout)
|
||||||
|
# Event Loop to process "events" and get the "values" of the inputs
|
||||||
|
while True:
|
||||||
|
event, values = window.read()
|
||||||
|
if event in (None, 'Cancel'): # if user closes window or clicks cancel
|
||||||
|
break
|
||||||
|
|
||||||
|
window.close()
|
||||||
|
```
|
||||||
|
|
||||||
|
### Makes This Window
|
||||||
|
|
||||||
|

|
||||||
|
|
||||||
|
### Any Questions?
|
||||||
|
---
|
||||||
|
|
||||||
#### Looking for a GUI package? Are you....
|
#### Looking for a GUI package? Are you....
|
||||||
|
|
||||||
|
@ -72,6 +109,8 @@
|
||||||
* 170+ Demo Programs teach you how to integrate with many popular packages like OpenCV, Matplotlib, PyGame, etc.
|
* 170+ Demo Programs teach you how to integrate with many popular packages like OpenCV, Matplotlib, PyGame, etc.
|
||||||
* 200 pages of documentation, a Cookbook, built-in help using docstrings, in short it's heavily documented
|
* 200 pages of documentation, a Cookbook, built-in help using docstrings, in short it's heavily documented
|
||||||
|
|
||||||
|
#### July-2019 Note - This readme is being generated from the PySimpleGUI.py file located on GitHub. As a result, some of the calls or parameters may not match the PySimpleGUI that you pip installed.
|
||||||
|
|
||||||
## GUI Development does not have to be difficult nor painful. It can be FUN
|
## GUI Development does not have to be difficult nor painful. It can be FUN
|
||||||
|
|
||||||
#### What users are saying about PySimpleGUI
|
#### What users are saying about PySimpleGUI
|
||||||
|
@ -5371,6 +5410,8 @@ Parameter Descriptions:
|
||||||
|
|
||||||
#### TKCanvas
|
#### TKCanvas
|
||||||
|
|
||||||
|
#### property: TKCanvas
|
||||||
|
|
||||||
### Checkbox Element
|
### Checkbox Element
|
||||||
|
|
||||||
Checkbox Element - Displays a checkbox and text next to it
|
Checkbox Element - Displays a checkbox and text next to it
|
||||||
|
@ -6201,6 +6242,8 @@ Parameter Descriptions:
|
||||||
|
|
||||||
#### TKCanvas
|
#### TKCanvas
|
||||||
|
|
||||||
|
#### property: TKCanvas
|
||||||
|
|
||||||
#### Update
|
#### Update
|
||||||
|
|
||||||
Changes some of the settings for the Graph Element. Must call `Window.Read` or `Window.Finalize` prior
|
Changes some of the settings for the Graph Element. Must call `Window.Read` or `Window.Finalize` prior
|
||||||
|
@ -6893,6 +6936,8 @@ Parameter Descriptions:
|
||||||
|
|
||||||
#### TKOut
|
#### TKOut
|
||||||
|
|
||||||
|
#### property: TKOut
|
||||||
|
|
||||||
#### Update
|
#### Update
|
||||||
|
|
||||||
Changes some of the settings for the Output Element. Must call `Window.Read` or `Window.Finalize` prior
|
Changes some of the settings for the Output Element. Must call `Window.Read` or `Window.Finalize` prior
|
||||||
|
@ -8128,7 +8173,7 @@ Parameter Descriptions:
|
||||||
|---|---|
|
|---|---|
|
||||||
|tooltip_text|(str) the text to show in tooltip.|
|
|tooltip_text|(str) the text to show in tooltip.|
|
||||||
|
|
||||||
### Window Element
|
### Window
|
||||||
|
|
||||||
Represents a single Window
|
Represents a single Window
|
||||||
|
|
||||||
|
@ -8242,6 +8287,14 @@ Parameter Descriptions:
|
||||||
|
|
||||||
#### AlphaChannel
|
#### AlphaChannel
|
||||||
|
|
||||||
|
#### property: AlphaChannel
|
||||||
|
|
||||||
|
A property that changes the current alpha channel value (internal value)
|
||||||
|
|
||||||
|
|Name|Meaning|
|
||||||
|
|---|---|
|
||||||
|
| **return** | (float) the current alpha channel setting according to self, not read directly from tkinter |
|
||||||
|
|
||||||
#### BringToFront
|
#### BringToFront
|
||||||
|
|
||||||
Brings this window to the top of all other windows (perhaps may not be brought before a window made to "stay
|
Brings this window to the top of all other windows (perhaps may not be brought before a window made to "stay
|
||||||
|
@ -8744,6 +8797,14 @@ Parameter Descriptions:
|
||||||
|
|
||||||
#### Size
|
#### Size
|
||||||
|
|
||||||
|
#### property: Size
|
||||||
|
|
||||||
|
Return the current size of the window in pixels
|
||||||
|
|
||||||
|
|Name|Meaning|
|
||||||
|
|---|---|
|
||||||
|
| **return** | Tuple[(int), (int)] the (width, height) of the window |
|
||||||
|
|
||||||
#### UnHide
|
#### UnHide
|
||||||
|
|
||||||
Used to bring back a window that was previously hidden using the Hide method
|
Used to bring back a window that was previously hidden using the Hide method
|
||||||
|
@ -11219,6 +11280,38 @@ Let's hope it doesn't all blow up in our faces!
|
||||||
* Added Window.visibility_changed to match the PySimpleGUIQt call
|
* Added Window.visibility_changed to match the PySimpleGUIQt call
|
||||||
* Fixed Debugger so that popout window shows any newly added locals
|
* Fixed Debugger so that popout window shows any newly added locals
|
||||||
|
|
||||||
|
## 4.4 PySimpleGUI Release 5-Sep-2019
|
||||||
|
|
||||||
|
* window() - "Calling" your Window object will perform a Read call
|
||||||
|
* InputText - move cursor to end following Update
|
||||||
|
* Shortcuts - trying to get a manageable and stable set of Normal, Short, Super-short
|
||||||
|
* DD - DropDown (Combo)
|
||||||
|
* LB, LBox - Listbox
|
||||||
|
* R, Rad - Radio
|
||||||
|
* ML, MLine - Multiline
|
||||||
|
* BMenu - ButtonMenu
|
||||||
|
* PBar, Prog - ProgressBar
|
||||||
|
* Col - Column
|
||||||
|
* Listbox - new method GetIndexes returns currently selected items as a list of indexes
|
||||||
|
* Output - new method Get returns the contents of the output element
|
||||||
|
* Button - For Macs don't don't allow setting button color. Previously only warned
|
||||||
|
* ButtonMenu - new Click method will click the button just like a normal Button's Click method
|
||||||
|
* Column scrolling finally works correctly with mousewheel. Shift+Mouse Scroll will scroll horizontally
|
||||||
|
* Table - Get method is a dummy version a Get because Qt port got a real Get method
|
||||||
|
* Table - Will add numerical column headers if Column Headsing is set to None when creating Table Element
|
||||||
|
* Table - FIXED the columns crazily resizing themselves bug!!
|
||||||
|
* Table - Can resize individual columns now
|
||||||
|
* Tree - was not returning Keys but instead the string representation of the key
|
||||||
|
* SetIcon will set to default base64 icon if there's an error loading icon
|
||||||
|
* Fix for duplicate key error. Was attempting to add a "unique key counter" onto end of keys if duplicate, but needed to turn into string first
|
||||||
|
* Columns
|
||||||
|
* No longer expand nor fill
|
||||||
|
* Sizing works for both scrolled and normal
|
||||||
|
* Setting focus - fixed bug when have tabs, columns, frames that have elements that can get the focus. Setting focus on top-level window
|
||||||
|
* InputText elements will now cause rows to expand due to X direction expansion
|
||||||
|
* Frame - Trying to set the size but doesn't seem to be setting it correctly
|
||||||
|
* Tabs will now expand & fill now (I hope this is OK!!!)
|
||||||
|
|
||||||
### Upcoming
|
### Upcoming
|
||||||
Make suggestions people! Future release features
|
Make suggestions people! Future release features
|
||||||
|
|
||||||
|
|
103
readme.md
103
readme.md
|
@ -16,11 +16,11 @@
|
||||||
|
|
||||||

|

|
||||||
|
|
||||||

|

|
||||||
|
|
||||||

|

|
||||||
|
|
||||||

|

|
||||||
|
|
||||||

|

|
||||||
|
|
||||||
|
@ -31,7 +31,44 @@
|
||||||
|
|
||||||
## Python GUI For Humans - Transforms tkinter, Qt, Remi, WxPython into portable people-friendly Pythonic interfaces
|
## Python GUI For Humans - Transforms tkinter, Qt, Remi, WxPython into portable people-friendly Pythonic interfaces
|
||||||
|
|
||||||
#### July-2019 Note - This readme is being generated from the PySimpleGUI.py file located on GitHub. As a result, some of the calls or parameters may not match the PySimpleGUI that you pip installed.
|
---
|
||||||
|
|
||||||
|
# Jump-Start
|
||||||
|
|
||||||
|
## Install
|
||||||
|
|
||||||
|
```
|
||||||
|
pip install pysimplegui
|
||||||
|
or
|
||||||
|
pip3 install pysimplegui
|
||||||
|
```
|
||||||
|
|
||||||
|
### This Code
|
||||||
|
|
||||||
|
```python
|
||||||
|
import PySimpleGUI as sg
|
||||||
|
# All the stuff inside your window.
|
||||||
|
layout = [ [sg.Text('Some text on Row 1')],
|
||||||
|
[sg.Text('Enter something on Row 2'), sg.InputText()],
|
||||||
|
[sg.Button('Ok'), sg.Button('Cancel')] ]
|
||||||
|
|
||||||
|
# Create the Window
|
||||||
|
window = sg.Window('Window Title', layout)
|
||||||
|
# Event Loop to process "events" and get the "values" of the inputs
|
||||||
|
while True:
|
||||||
|
event, values = window.read()
|
||||||
|
if event in (None, 'Cancel'): # if user closes window or clicks cancel
|
||||||
|
break
|
||||||
|
|
||||||
|
window.close()
|
||||||
|
```
|
||||||
|
|
||||||
|
### Makes This Window
|
||||||
|
|
||||||
|

|
||||||
|
|
||||||
|
### Any Questions?
|
||||||
|
---
|
||||||
|
|
||||||
#### Looking for a GUI package? Are you....
|
#### Looking for a GUI package? Are you....
|
||||||
|
|
||||||
|
@ -72,6 +109,8 @@
|
||||||
* 170+ Demo Programs teach you how to integrate with many popular packages like OpenCV, Matplotlib, PyGame, etc.
|
* 170+ Demo Programs teach you how to integrate with many popular packages like OpenCV, Matplotlib, PyGame, etc.
|
||||||
* 200 pages of documentation, a Cookbook, built-in help using docstrings, in short it's heavily documented
|
* 200 pages of documentation, a Cookbook, built-in help using docstrings, in short it's heavily documented
|
||||||
|
|
||||||
|
#### July-2019 Note - This readme is being generated from the PySimpleGUI.py file located on GitHub. As a result, some of the calls or parameters may not match the PySimpleGUI that you pip installed.
|
||||||
|
|
||||||
## GUI Development does not have to be difficult nor painful. It can be FUN
|
## GUI Development does not have to be difficult nor painful. It can be FUN
|
||||||
|
|
||||||
#### What users are saying about PySimpleGUI
|
#### What users are saying about PySimpleGUI
|
||||||
|
@ -5371,6 +5410,8 @@ Parameter Descriptions:
|
||||||
|
|
||||||
#### TKCanvas
|
#### TKCanvas
|
||||||
|
|
||||||
|
#### property: TKCanvas
|
||||||
|
|
||||||
### Checkbox Element
|
### Checkbox Element
|
||||||
|
|
||||||
Checkbox Element - Displays a checkbox and text next to it
|
Checkbox Element - Displays a checkbox and text next to it
|
||||||
|
@ -6201,6 +6242,8 @@ Parameter Descriptions:
|
||||||
|
|
||||||
#### TKCanvas
|
#### TKCanvas
|
||||||
|
|
||||||
|
#### property: TKCanvas
|
||||||
|
|
||||||
#### Update
|
#### Update
|
||||||
|
|
||||||
Changes some of the settings for the Graph Element. Must call `Window.Read` or `Window.Finalize` prior
|
Changes some of the settings for the Graph Element. Must call `Window.Read` or `Window.Finalize` prior
|
||||||
|
@ -6893,6 +6936,8 @@ Parameter Descriptions:
|
||||||
|
|
||||||
#### TKOut
|
#### TKOut
|
||||||
|
|
||||||
|
#### property: TKOut
|
||||||
|
|
||||||
#### Update
|
#### Update
|
||||||
|
|
||||||
Changes some of the settings for the Output Element. Must call `Window.Read` or `Window.Finalize` prior
|
Changes some of the settings for the Output Element. Must call `Window.Read` or `Window.Finalize` prior
|
||||||
|
@ -8128,7 +8173,7 @@ Parameter Descriptions:
|
||||||
|---|---|
|
|---|---|
|
||||||
|tooltip_text|(str) the text to show in tooltip.|
|
|tooltip_text|(str) the text to show in tooltip.|
|
||||||
|
|
||||||
### Window Element
|
### Window
|
||||||
|
|
||||||
Represents a single Window
|
Represents a single Window
|
||||||
|
|
||||||
|
@ -8242,6 +8287,14 @@ Parameter Descriptions:
|
||||||
|
|
||||||
#### AlphaChannel
|
#### AlphaChannel
|
||||||
|
|
||||||
|
#### property: AlphaChannel
|
||||||
|
|
||||||
|
A property that changes the current alpha channel value (internal value)
|
||||||
|
|
||||||
|
|Name|Meaning|
|
||||||
|
|---|---|
|
||||||
|
| **return** | (float) the current alpha channel setting according to self, not read directly from tkinter |
|
||||||
|
|
||||||
#### BringToFront
|
#### BringToFront
|
||||||
|
|
||||||
Brings this window to the top of all other windows (perhaps may not be brought before a window made to "stay
|
Brings this window to the top of all other windows (perhaps may not be brought before a window made to "stay
|
||||||
|
@ -8744,6 +8797,14 @@ Parameter Descriptions:
|
||||||
|
|
||||||
#### Size
|
#### Size
|
||||||
|
|
||||||
|
#### property: Size
|
||||||
|
|
||||||
|
Return the current size of the window in pixels
|
||||||
|
|
||||||
|
|Name|Meaning|
|
||||||
|
|---|---|
|
||||||
|
| **return** | Tuple[(int), (int)] the (width, height) of the window |
|
||||||
|
|
||||||
#### UnHide
|
#### UnHide
|
||||||
|
|
||||||
Used to bring back a window that was previously hidden using the Hide method
|
Used to bring back a window that was previously hidden using the Hide method
|
||||||
|
@ -11219,6 +11280,38 @@ Let's hope it doesn't all blow up in our faces!
|
||||||
* Added Window.visibility_changed to match the PySimpleGUIQt call
|
* Added Window.visibility_changed to match the PySimpleGUIQt call
|
||||||
* Fixed Debugger so that popout window shows any newly added locals
|
* Fixed Debugger so that popout window shows any newly added locals
|
||||||
|
|
||||||
|
## 4.4 PySimpleGUI Release 5-Sep-2019
|
||||||
|
|
||||||
|
* window() - "Calling" your Window object will perform a Read call
|
||||||
|
* InputText - move cursor to end following Update
|
||||||
|
* Shortcuts - trying to get a manageable and stable set of Normal, Short, Super-short
|
||||||
|
* DD - DropDown (Combo)
|
||||||
|
* LB, LBox - Listbox
|
||||||
|
* R, Rad - Radio
|
||||||
|
* ML, MLine - Multiline
|
||||||
|
* BMenu - ButtonMenu
|
||||||
|
* PBar, Prog - ProgressBar
|
||||||
|
* Col - Column
|
||||||
|
* Listbox - new method GetIndexes returns currently selected items as a list of indexes
|
||||||
|
* Output - new method Get returns the contents of the output element
|
||||||
|
* Button - For Macs don't don't allow setting button color. Previously only warned
|
||||||
|
* ButtonMenu - new Click method will click the button just like a normal Button's Click method
|
||||||
|
* Column scrolling finally works correctly with mousewheel. Shift+Mouse Scroll will scroll horizontally
|
||||||
|
* Table - Get method is a dummy version a Get because Qt port got a real Get method
|
||||||
|
* Table - Will add numerical column headers if Column Headsing is set to None when creating Table Element
|
||||||
|
* Table - FIXED the columns crazily resizing themselves bug!!
|
||||||
|
* Table - Can resize individual columns now
|
||||||
|
* Tree - was not returning Keys but instead the string representation of the key
|
||||||
|
* SetIcon will set to default base64 icon if there's an error loading icon
|
||||||
|
* Fix for duplicate key error. Was attempting to add a "unique key counter" onto end of keys if duplicate, but needed to turn into string first
|
||||||
|
* Columns
|
||||||
|
* No longer expand nor fill
|
||||||
|
* Sizing works for both scrolled and normal
|
||||||
|
* Setting focus - fixed bug when have tabs, columns, frames that have elements that can get the focus. Setting focus on top-level window
|
||||||
|
* InputText elements will now cause rows to expand due to X direction expansion
|
||||||
|
* Frame - Trying to set the size but doesn't seem to be setting it correctly
|
||||||
|
* Tabs will now expand & fill now (I hope this is OK!!!)
|
||||||
|
|
||||||
### Upcoming
|
### Upcoming
|
||||||
Make suggestions people! Future release features
|
Make suggestions people! Future release features
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue