commit
8238fc74d8
234
readme.md
234
readme.md
|
@ -1,4 +1,4 @@
|
||||||
<!-- CREATED: 2019-06-19 16.12.46 -->
|
<!-- CREATED: 2019-06-23 14.19.18 -->
|
||||||
<!--
|
<!--
|
||||||
HOW DO I INSERT IMAGES ???
|
HOW DO I INSERT IMAGES ???
|
||||||
easy.
|
easy.
|
||||||
|
@ -691,11 +691,8 @@ There are Popup calls for single-item inputs. These follow the pattern of `Popup
|
||||||
- `PopupGetFolder` - get a folder name
|
- `PopupGetFolder` - get a folder name
|
||||||
|
|
||||||
Use these Popups instead of making a custom window to get one data value, call the Popup input function to get the item from the user. If you find the parameters are unable to create the kind of window you are looking for, then it's time for you to create your own window.
|
Use these Popups instead of making a custom window to get one data value, call the Popup input function to get the item from the user. If you find the parameters are unable to create the kind of window you are looking for, then it's time for you to create your own window.
|
||||||
|
|
||||||
### PopupGetText
|
### PopupGetText
|
||||||
|
|
||||||
Use this Popup to get a line of text from the user.<br>
|
Use this Popup to get a line of text from the user.<br>
|
||||||
|
|
||||||
```
|
```
|
||||||
PopupGetText(message,The message you wish to display with the input field
|
PopupGetText(message,The message you wish to display with the input field
|
||||||
default_text='', Text to initially fill into the input field
|
default_text='', Text to initially fill into the input field
|
||||||
|
@ -812,7 +809,6 @@ def PopupAnimated(image_source,
|
||||||
alpha_channel=.8,
|
alpha_channel=.8,
|
||||||
time_between_frames=0)
|
time_between_frames=0)
|
||||||
```
|
```
|
||||||
|
|
||||||
| name | meaning |
|
| name | meaning |
|
||||||
|-|-|
|
|-|-|
|
||||||
|image_source | The GIF file specified as a string filename or a base64 variable |
|
|image_source | The GIF file specified as a string filename or a base64 variable |
|
||||||
|
@ -1809,6 +1805,8 @@ Many of the main method calls and Element names have shortcuts. This enables yo
|
||||||
Basic Element. It displays text. That's it.
|
Basic Element. It displays text. That's it.
|
||||||
|
|
||||||
|
|
||||||
|
Text - Display some text in the window. Can be single or multiple lines but no scrolling if multiple lines.
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
```python
|
```python
|
||||||
|
@ -1839,11 +1837,11 @@ Text(text,
|
||||||
```
|
```
|
||||||
|
|
||||||
|
|
||||||
Parameters explained:
|
Parameters explained:
|
||||||
|
|
||||||
|Name|Meaning|
|
|Name|Meaning|
|
||||||
|-|-|
|
|-|-|
|
||||||
|text||
|
|text|The text to display (required)|
|
||||||
|size|(common_key) (w,h) w=characters-wide, h=rows-high (Default value = (None, None))|
|
|size|(common_key) (w,h) w=characters-wide, h=rows-high (Default value = (None, None))|
|
||||||
|auto_size_text|True if size should fit the text length (Default value = None)|
|
|auto_size_text|True if size should fit the text length (Default value = None)|
|
||||||
|click_submits|(Default value = False)|
|
|click_submits|(Default value = False)|
|
||||||
|
@ -1862,7 +1860,6 @@ Text(text,
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
### Methods
|
### Methods
|
||||||
|
|
||||||
|
|
||||||
|
@ -1875,7 +1872,7 @@ Update(value=None,
|
||||||
```
|
```
|
||||||
|
|
||||||
|
|
||||||
Parameters explained:
|
Parameters explained:
|
||||||
|
|
||||||
|Name|Meaning|
|
|Name|Meaning|
|
||||||
|-|-|
|
|-|-|
|
||||||
|
@ -1888,7 +1885,6 @@ Update(value=None,
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
---
|
---
|
||||||
|
|
||||||
### Fonts
|
### Fonts
|
||||||
|
@ -1958,7 +1954,7 @@ Multiline(default_text="",
|
||||||
```
|
```
|
||||||
|
|
||||||
|
|
||||||
Parameters explained:
|
Parameters explained:
|
||||||
|
|
||||||
|Name|Meaning|
|
|Name|Meaning|
|
||||||
|-|-|
|
|-|-|
|
||||||
|
@ -1985,7 +1981,6 @@ Multiline(default_text="",
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
### Methods
|
### Methods
|
||||||
|
|
||||||
|
|
||||||
|
@ -2001,7 +1996,7 @@ Update(value=None,
|
||||||
```
|
```
|
||||||
|
|
||||||
|
|
||||||
Parameters explained:
|
Parameters explained:
|
||||||
|
|
||||||
|Name|Meaning|
|
|Name|Meaning|
|
||||||
|-|-|
|
|-|-|
|
||||||
|
@ -2024,7 +2019,6 @@ Update(value=None,
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<!-- %!% -->
|
<!-- %!% -->
|
||||||
## Text Input Element | `Input == In`
|
## Text Input Element | `Input == In`
|
||||||
|
|
||||||
|
@ -2057,7 +2051,7 @@ InputText(default_text="",
|
||||||
```
|
```
|
||||||
|
|
||||||
|
|
||||||
Parameters explained:
|
Parameters explained:
|
||||||
|
|
||||||
|Name|Meaning|
|
|Name|Meaning|
|
||||||
|-|-|
|
|-|-|
|
||||||
|
@ -2082,7 +2076,6 @@ InputText(default_text="",
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<!--
|
<!--
|
||||||
```python
|
```python
|
||||||
def InputText(default_text ='',
|
def InputText(default_text ='',
|
||||||
|
@ -2149,7 +2142,7 @@ Update(value=None,
|
||||||
```
|
```
|
||||||
|
|
||||||
|
|
||||||
Parameters explained:
|
Parameters explained:
|
||||||
|
|
||||||
|Name|Meaning|
|
|Name|Meaning|
|
||||||
|-|-|
|
|-|-|
|
||||||
|
@ -2163,8 +2156,13 @@ Update(value=None,
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<br>
|
<br>
|
||||||
Get()<br>
|
|
||||||
|
Get() - method <br>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
@ -2223,7 +2221,7 @@ Combo(values,
|
||||||
```
|
```
|
||||||
|
|
||||||
|
|
||||||
Parameters explained:
|
Parameters explained:
|
||||||
|
|
||||||
|Name|Meaning|
|
|Name|Meaning|
|
||||||
|-|-|
|
|-|-|
|
||||||
|
@ -2246,7 +2244,6 @@ Combo(values,
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<!--
|
<!--
|
||||||
```
|
```
|
||||||
InputCombo(values,
|
InputCombo(values,
|
||||||
|
@ -2296,7 +2293,7 @@ Update(value=None,
|
||||||
```
|
```
|
||||||
|
|
||||||
|
|
||||||
Parameters explained:
|
Parameters explained:
|
||||||
|
|
||||||
|Name|Meaning|
|
|Name|Meaning|
|
||||||
|-|-|
|
|-|-|
|
||||||
|
@ -2311,7 +2308,6 @@ Update(value=None,
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<!-- ```python
|
<!-- ```python
|
||||||
Update(value=None, values=None, set_to_index=None, disabled=None, readonly=None)
|
Update(value=None, values=None, set_to_index=None, disabled=None, readonly=None)
|
||||||
```
|
```
|
||||||
|
@ -2333,7 +2329,10 @@ readonly - if True will make element readonly
|
||||||
The standard listbox like you'll find in most GUIs. Note that the return values from this element will be a ***list of results, not a single result***. This is because the user can select more than 1 item from the list (if you set the right mode).
|
The standard listbox like you'll find in most GUIs. Note that the return values from this element will be a ***list of results, not a single result***. This is because the user can select more than 1 item from the list (if you set the right mode).
|
||||||
|
|
||||||
A List Box. Provide a list of values for the user to choose one or more of. Returns a list of selected rows
|
A List Box. Provide a list of values for the user to choose one or more of. Returns a list of selected rows
|
||||||
when a window.Read() is executed.
|
when a window.Read() is executed.
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
```python
|
```python
|
||||||
|
@ -2364,7 +2363,7 @@ Listbox(values,
|
||||||
```
|
```
|
||||||
|
|
||||||
|
|
||||||
Parameters explained:
|
Parameters explained:
|
||||||
|
|
||||||
|Name|Meaning|
|
|Name|Meaning|
|
||||||
|-|-|
|
|-|-|
|
||||||
|
@ -2390,7 +2389,6 @@ Listbox(values,
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
The `select_mode` option can be a string or a constant value defined as a variable. Generally speaking strings are used for these kinds of options.
|
The `select_mode` option can be a string or a constant value defined as a variable. Generally speaking strings are used for these kinds of options.
|
||||||
|
|
||||||
|
|
||||||
|
@ -2406,7 +2404,7 @@ Update(values=None,
|
||||||
```
|
```
|
||||||
|
|
||||||
|
|
||||||
Parameters explained:
|
Parameters explained:
|
||||||
|
|
||||||
|Name|Meaning|
|
|Name|Meaning|
|
||||||
|-|-|
|
|-|-|
|
||||||
|
@ -2420,13 +2418,12 @@ Update(values=None,
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
```python
|
```python
|
||||||
SetValue(values)
|
SetValue(values)
|
||||||
```
|
```
|
||||||
|
|
||||||
|
|
||||||
Parameters explained:
|
Parameters explained:
|
||||||
|
|
||||||
|Name|Meaning|
|
|Name|Meaning|
|
||||||
|-|-|
|
|-|-|
|
||||||
|
@ -2437,8 +2434,13 @@ SetValue(values)
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<br>
|
<br>
|
||||||
GetListValues()<br>
|
|
||||||
|
GetListValues() - method <br>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
@ -2512,7 +2514,7 @@ Slider(range=(None, None),
|
||||||
```
|
```
|
||||||
|
|
||||||
|
|
||||||
Parameters explained:
|
Parameters explained:
|
||||||
|
|
||||||
|Name|Meaning|
|
|Name|Meaning|
|
||||||
|-|-|
|
|-|-|
|
||||||
|
@ -2539,7 +2541,6 @@ Slider(range=(None, None),
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<!--
|
<!--
|
||||||
Slider(range=(None,None),
|
Slider(range=(None,None),
|
||||||
default_value=None,
|
default_value=None,
|
||||||
|
@ -2600,7 +2601,7 @@ Update(value=None,
|
||||||
```
|
```
|
||||||
|
|
||||||
|
|
||||||
Parameters explained:
|
Parameters explained:
|
||||||
|
|
||||||
|Name|Meaning|
|
|Name|Meaning|
|
||||||
|-|-|
|
|-|-|
|
||||||
|
@ -2613,7 +2614,6 @@ Update(value=None,
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<!-- ```python
|
<!-- ```python
|
||||||
Update(self, value=None, range=(None, None), disabled=None, visible=None):
|
Update(self, value=None, range=(None, None), disabled=None, visible=None):
|
||||||
```
|
```
|
||||||
|
@ -2641,7 +2641,10 @@ disabled - if True disables element
|
||||||
## Radio Element
|
## Radio Element
|
||||||
Creates one radio button that is assigned to a group of radio buttons. Only 1 of the buttons in the group can be selected at any one time.
|
Creates one radio button that is assigned to a group of radio buttons. Only 1 of the buttons in the group can be selected at any one time.
|
||||||
Radio Button Element - Used in a group of other Radio Elements to provide user with ability to select only
|
Radio Button Element - Used in a group of other Radio Elements to provide user with ability to select only
|
||||||
1 choice in a list of choices.
|
1 choice in a list of choices.
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
```python
|
```python
|
||||||
layout = [
|
layout = [
|
||||||
|
@ -2672,7 +2675,7 @@ Radio(text,
|
||||||
```
|
```
|
||||||
|
|
||||||
|
|
||||||
Parameters explained:
|
Parameters explained:
|
||||||
|
|
||||||
|Name|Meaning|
|
|Name|Meaning|
|
||||||
|-|-|
|
|-|-|
|
||||||
|
@ -2695,7 +2698,6 @@ Radio(text,
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<!--
|
<!--
|
||||||
Radio(text,
|
Radio(text,
|
||||||
group_id,
|
group_id,
|
||||||
|
@ -2737,7 +2739,7 @@ Update(value=None,
|
||||||
```
|
```
|
||||||
|
|
||||||
|
|
||||||
Parameters explained:
|
Parameters explained:
|
||||||
|
|
||||||
|Name|Meaning|
|
|Name|Meaning|
|
||||||
|-|-|
|
|-|-|
|
||||||
|
@ -2748,7 +2750,6 @@ Update(value=None,
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<!-- ```python
|
<!-- ```python
|
||||||
Update(value=None, disabled=None, visible=None)
|
Update(value=None, disabled=None, visible=None)
|
||||||
```
|
```
|
||||||
|
@ -2791,7 +2792,7 @@ Checkbox(text,
|
||||||
```
|
```
|
||||||
|
|
||||||
|
|
||||||
Parameters explained:
|
Parameters explained:
|
||||||
|
|
||||||
|Name|Meaning|
|
|Name|Meaning|
|
||||||
|-|-|
|
|-|-|
|
||||||
|
@ -2813,7 +2814,6 @@ Checkbox(text,
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<!-- Checkbox(text,
|
<!-- Checkbox(text,
|
||||||
default=False,
|
default=False,
|
||||||
size=(None, None),
|
size=(None, None),
|
||||||
|
@ -2892,7 +2892,7 @@ Spin(values,
|
||||||
```
|
```
|
||||||
|
|
||||||
|
|
||||||
Parameters explained:
|
Parameters explained:
|
||||||
|
|
||||||
|Name|Meaning|
|
|Name|Meaning|
|
||||||
|-|-|
|
|-|-|
|
||||||
|
@ -2914,7 +2914,6 @@ Spin(values,
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<!--
|
<!--
|
||||||
Spin(values,
|
Spin(values,
|
||||||
intiial_value=None,
|
intiial_value=None,
|
||||||
|
@ -2966,7 +2965,7 @@ Update(value=None,
|
||||||
```
|
```
|
||||||
|
|
||||||
|
|
||||||
Parameters explained:
|
Parameters explained:
|
||||||
|
|
||||||
|Name|Meaning|
|
|Name|Meaning|
|
||||||
|-|-|
|
|-|-|
|
||||||
|
@ -2978,7 +2977,6 @@ Update(value=None,
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<!-- ```python
|
<!-- ```python
|
||||||
Update(value=None, values=None, disabled=None, visible=None)
|
Update(value=None, values=None, disabled=None, visible=None)
|
||||||
```
|
```
|
||||||
|
@ -3031,7 +3029,7 @@ Image(filename=None,
|
||||||
```
|
```
|
||||||
|
|
||||||
|
|
||||||
Parameters explained:
|
Parameters explained:
|
||||||
|
|
||||||
|Name|Meaning|
|
|Name|Meaning|
|
||||||
|-|-|
|
|-|-|
|
||||||
|
@ -3049,7 +3047,6 @@ Image(filename=None,
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<!--
|
<!--
|
||||||
```python
|
```python
|
||||||
Image(filename=None,
|
Image(filename=None,
|
||||||
|
@ -3093,7 +3090,7 @@ Update(filename=None,
|
||||||
```
|
```
|
||||||
|
|
||||||
|
|
||||||
Parameters explained:
|
Parameters explained:
|
||||||
|
|
||||||
|Name|Meaning|
|
|Name|Meaning|
|
||||||
|-|-|
|
|-|-|
|
||||||
|
@ -3105,7 +3102,6 @@ Update(filename=None,
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
Choose **either** a filename or in-ram data image to use to replace current image
|
Choose **either** a filename or in-ram data image to use to replace current image
|
||||||
|
|
||||||
|
|
||||||
|
@ -3122,7 +3118,7 @@ UpdateAnimation(source,
|
||||||
```
|
```
|
||||||
|
|
||||||
|
|
||||||
Parameters explained:
|
Parameters explained:
|
||||||
|
|
||||||
|Name|Meaning|
|
|Name|Meaning|
|
||||||
|-|-|
|
|-|-|
|
||||||
|
@ -3132,7 +3128,6 @@ UpdateAnimation(source,
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
You can call the method without setting the `time_between_frames` value and it will show a frame and immediately move on to the next frame. This enables you to do the inter-frame timing.
|
You can call the method without setting the `time_between_frames` value and it will show a frame and immediately move on to the next frame. This enables you to do the inter-frame timing.
|
||||||
|
|
||||||
|
|
||||||
|
@ -3241,7 +3236,7 @@ Button(button_text="",
|
||||||
```
|
```
|
||||||
|
|
||||||
|
|
||||||
Parameters explained:
|
Parameters explained:
|
||||||
|
|
||||||
|Name|Meaning|
|
|Name|Meaning|
|
||||||
|-|-|
|
|-|-|
|
||||||
|
@ -3274,7 +3269,6 @@ Button(button_text="",
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<!-- Button(button_text=''
|
<!-- Button(button_text=''
|
||||||
button_type=BUTTON_TYPE_CLOSES_WIN
|
button_type=BUTTON_TYPE_CLOSES_WIN
|
||||||
target=(None, None)
|
target=(None, None)
|
||||||
|
@ -3539,7 +3533,7 @@ Update(text=None,
|
||||||
```
|
```
|
||||||
|
|
||||||
|
|
||||||
Parameters explained:
|
Parameters explained:
|
||||||
|
|
||||||
|Name|Meaning|
|
|Name|Meaning|
|
||||||
|-|-|
|
|-|-|
|
||||||
|
@ -3555,7 +3549,6 @@ Update(text=None,
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<!-- ```python
|
<!-- ```python
|
||||||
Update(text=None, button_color=(None, None), disabled=None, image_data=None, image_filename=None, visible=None)
|
Update(text=None, button_color=(None, None), disabled=None, image_data=None, image_filename=None, visible=None)
|
||||||
|
|
||||||
|
@ -3574,8 +3567,14 @@ Update - Change the button element
|
||||||
GetText - Returns the current text shown on a button
|
GetText - Returns the current text shown on a button
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<br>
|
<br>
|
||||||
GetText()<br>
|
|
||||||
|
GetText() - method <br>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
@ -3629,7 +3628,7 @@ ButtonMenu(button_text,
|
||||||
```
|
```
|
||||||
|
|
||||||
|
|
||||||
Parameters explained:
|
Parameters explained:
|
||||||
|
|
||||||
|Name|Meaning|
|
|Name|Meaning|
|
||||||
|-|-|
|
|-|-|
|
||||||
|
@ -3654,7 +3653,6 @@ ButtonMenu(button_text,
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<!--
|
<!--
|
||||||
```python
|
```python
|
||||||
ButtonMenu( button_text,
|
ButtonMenu( button_text,
|
||||||
|
@ -3726,7 +3724,7 @@ VerticalSeparator(pad=None)
|
||||||
```
|
```
|
||||||
|
|
||||||
|
|
||||||
Parameters explained:
|
Parameters explained:
|
||||||
|
|
||||||
|Name|Meaning|
|
|Name|Meaning|
|
||||||
|-|-|
|
|-|-|
|
||||||
|
@ -3742,7 +3740,6 @@ VerticalSeparator(pad=None)
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<!-- %!% -->
|
<!-- %!% -->
|
||||||
## ProgressBar Element
|
## ProgressBar Element
|
||||||
The `ProgressBar` element is used to build custom Progress Bar windows. It is HIGHLY recommended that you use OneLineProgressMeter that provides a complete progress meter solution for you. Progress Meters are not easy to work with because the windows have to be non-blocking and they are tricky to debug.
|
The `ProgressBar` element is used to build custom Progress Bar windows. It is HIGHLY recommended that you use OneLineProgressMeter that provides a complete progress meter solution for you. Progress Meters are not easy to work with because the windows have to be non-blocking and they are tricky to debug.
|
||||||
|
@ -3805,7 +3802,7 @@ ProgressBar(max_value,
|
||||||
```
|
```
|
||||||
|
|
||||||
|
|
||||||
Parameters explained:
|
Parameters explained:
|
||||||
|
|
||||||
|Name|Meaning|
|
|Name|Meaning|
|
||||||
|-|-|
|
|-|-|
|
||||||
|
@ -3847,7 +3844,6 @@ ProgressBar(max_value,
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<!-- %!% -->
|
<!-- %!% -->
|
||||||
|
@ -3880,7 +3876,7 @@ Output(size=(None, None),
|
||||||
```
|
```
|
||||||
|
|
||||||
|
|
||||||
Parameters explained:
|
Parameters explained:
|
||||||
|
|
||||||
|Name|Meaning|
|
|Name|Meaning|
|
||||||
|-|-|
|
|-|-|
|
||||||
|
@ -3897,7 +3893,6 @@ Output(size=(None, None),
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
### Methods
|
### Methods
|
||||||
|
|
||||||
|
|
||||||
|
@ -3907,7 +3902,7 @@ Update(value=None,
|
||||||
```
|
```
|
||||||
|
|
||||||
|
|
||||||
Parameters explained:
|
Parameters explained:
|
||||||
|
|
||||||
|Name|Meaning|
|
|Name|Meaning|
|
||||||
|-|-|
|
|-|-|
|
||||||
|
@ -3917,7 +3912,6 @@ Update(value=None,
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<!-- size - Size of Output Element (width, height) in characters
|
<!-- size - Size of Output Element (width, height) in characters
|
||||||
You should be quite familiar with these parameters by now. If not, read able another element or read about common parameters.
|
You should be quite familiar with these parameters by now. If not, read able another element or read about common parameters.
|
||||||
-->
|
-->
|
||||||
|
@ -4028,7 +4022,7 @@ Column(layout,
|
||||||
```
|
```
|
||||||
|
|
||||||
|
|
||||||
Parameters explained:
|
Parameters explained:
|
||||||
|
|
||||||
|Name|Meaning|
|
|Name|Meaning|
|
||||||
|-|-|
|
|-|-|
|
||||||
|
@ -4046,7 +4040,6 @@ Column(layout,
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
---
|
---
|
||||||
|
|
||||||
```python
|
```python
|
||||||
|
@ -4117,7 +4110,7 @@ Frame(title,
|
||||||
```
|
```
|
||||||
|
|
||||||
|
|
||||||
Parameters explained:
|
Parameters explained:
|
||||||
|
|
||||||
|Name|Meaning|
|
|Name|Meaning|
|
||||||
|-|-|
|
|-|-|
|
||||||
|
@ -4139,7 +4132,6 @@ Frame(title,
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
---
|
---
|
||||||
|
|
||||||
This code creates a window with a Frame and 2 buttons.
|
This code creates a window with a Frame and 2 buttons.
|
||||||
|
@ -4190,7 +4182,7 @@ Canvas(canvas=None,
|
||||||
```
|
```
|
||||||
|
|
||||||
|
|
||||||
Parameters explained:
|
Parameters explained:
|
||||||
|
|
||||||
|Name|Meaning|
|
|Name|Meaning|
|
||||||
|-|-|
|
|-|-|
|
||||||
|
@ -4207,7 +4199,6 @@ Canvas(canvas=None,
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
### Matplotlib, Pyplot Integration
|
### Matplotlib, Pyplot Integration
|
||||||
|
|
||||||
One such integration is with Matploplib and Pyplot. There is a Demo program written that you can use as a design pattern to get an understanding of how to use the Canvas Widget once you get it.
|
One such integration is with Matploplib and Pyplot. There is a Demo program written that you can use as a design pattern to get an understanding of how to use the Canvas Widget once you get it.
|
||||||
|
@ -4310,11 +4301,12 @@ Graph(canvas_size,
|
||||||
key=None,
|
key=None,
|
||||||
tooltip=None,
|
tooltip=None,
|
||||||
right_click_menu=None,
|
right_click_menu=None,
|
||||||
visible=True)
|
visible=True,
|
||||||
|
float_values=False)
|
||||||
```
|
```
|
||||||
|
|
||||||
|
|
||||||
Parameters explained:
|
Parameters explained:
|
||||||
|
|
||||||
|Name|Meaning|
|
|Name|Meaning|
|
||||||
|-|-|
|
|-|-|
|
||||||
|
@ -4330,12 +4322,12 @@ Graph(canvas_size,
|
||||||
|tooltip|text, that will appear the you hover on (Default value = None)|
|
|tooltip|text, that will appear the you hover on (Default value = None)|
|
||||||
|right_click_menu|see "Right Click Menus" (Default value = None)|
|
|right_click_menu|see "Right Click Menus" (Default value = None)|
|
||||||
|visible|set visibility state of the element (Default value = True)|
|
|visible|set visibility state of the element (Default value = True)|
|
||||||
|
|float_values|bool: If True x,y coordinates are returned as floats, not ints|
|
||||||
|||
|
|||
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
### Methods
|
### Methods
|
||||||
|
|
||||||
`DrawLine` - draws a point, line, circle, oval, arc, rectangle, text <br>
|
`DrawLine` - draws a point, line, circle, oval, arc, rectangle, text <br>
|
||||||
|
@ -4360,7 +4352,7 @@ DrawLine(point_from,
|
||||||
```
|
```
|
||||||
|
|
||||||
|
|
||||||
Parameters explained:
|
Parameters explained:
|
||||||
|
|
||||||
|Name|Meaning|
|
|Name|Meaning|
|
||||||
|-|-|
|
|-|-|
|
||||||
|
@ -4373,7 +4365,6 @@ DrawLine(point_from,
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
```python
|
```python
|
||||||
DrawPoint(point,
|
DrawPoint(point,
|
||||||
size=2,
|
size=2,
|
||||||
|
@ -4381,7 +4372,7 @@ DrawPoint(point,
|
||||||
```
|
```
|
||||||
|
|
||||||
|
|
||||||
Parameters explained:
|
Parameters explained:
|
||||||
|
|
||||||
|Name|Meaning|
|
|Name|Meaning|
|
||||||
|-|-|
|
|-|-|
|
||||||
|
@ -4393,7 +4384,6 @@ DrawPoint(point,
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
```python
|
```python
|
||||||
DrawCircle(center_location,
|
DrawCircle(center_location,
|
||||||
radius,
|
radius,
|
||||||
|
@ -4402,7 +4392,7 @@ DrawCircle(center_location,
|
||||||
```
|
```
|
||||||
|
|
||||||
|
|
||||||
Parameters explained:
|
Parameters explained:
|
||||||
|
|
||||||
|Name|Meaning|
|
|Name|Meaning|
|
||||||
|-|-|
|
|-|-|
|
||||||
|
@ -4415,7 +4405,6 @@ DrawCircle(center_location,
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
```python
|
```python
|
||||||
DrawOval(top_left,
|
DrawOval(top_left,
|
||||||
bottom_right,
|
bottom_right,
|
||||||
|
@ -4424,7 +4413,7 @@ DrawOval(top_left,
|
||||||
```
|
```
|
||||||
|
|
||||||
|
|
||||||
Parameters explained:
|
Parameters explained:
|
||||||
|
|
||||||
|Name|Meaning|
|
|Name|Meaning|
|
||||||
|-|-|
|
|-|-|
|
||||||
|
@ -4437,7 +4426,6 @@ DrawOval(top_left,
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
```python
|
```python
|
||||||
DrawArc(top_left,
|
DrawArc(top_left,
|
||||||
bottom_right,
|
bottom_right,
|
||||||
|
@ -4448,7 +4436,7 @@ DrawArc(top_left,
|
||||||
```
|
```
|
||||||
|
|
||||||
|
|
||||||
Parameters explained:
|
Parameters explained:
|
||||||
|
|
||||||
|Name|Meaning|
|
|Name|Meaning|
|
||||||
|-|-|
|
|-|-|
|
||||||
|
@ -4463,7 +4451,6 @@ DrawArc(top_left,
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
```python
|
```python
|
||||||
DrawRectangle(top_left,
|
DrawRectangle(top_left,
|
||||||
bottom_right,
|
bottom_right,
|
||||||
|
@ -4472,7 +4459,7 @@ DrawRectangle(top_left,
|
||||||
```
|
```
|
||||||
|
|
||||||
|
|
||||||
Parameters explained:
|
Parameters explained:
|
||||||
|
|
||||||
|Name|Meaning|
|
|Name|Meaning|
|
||||||
|-|-|
|
|-|-|
|
||||||
|
@ -4485,7 +4472,6 @@ DrawRectangle(top_left,
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
```python
|
```python
|
||||||
DrawText(text,
|
DrawText(text,
|
||||||
location,
|
location,
|
||||||
|
@ -4495,7 +4481,7 @@ DrawText(text,
|
||||||
```
|
```
|
||||||
|
|
||||||
|
|
||||||
Parameters explained:
|
Parameters explained:
|
||||||
|
|
||||||
|Name|Meaning|
|
|Name|Meaning|
|
||||||
|-|-|
|
|-|-|
|
||||||
|
@ -4510,8 +4496,13 @@ DrawText(text,
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<br>
|
<br>
|
||||||
Erase()<br>
|
|
||||||
|
Erase() - method <br>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
@ -4521,7 +4512,7 @@ DeleteFigure(id)
|
||||||
```
|
```
|
||||||
|
|
||||||
|
|
||||||
Parameters explained:
|
Parameters explained:
|
||||||
|
|
||||||
|Name|Meaning|
|
|Name|Meaning|
|
||||||
|-|-|
|
|-|-|
|
||||||
|
@ -4531,14 +4522,13 @@ DeleteFigure(id)
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
```python
|
```python
|
||||||
Update(background_color,
|
Update(background_color,
|
||||||
visible=None)
|
visible=None)
|
||||||
```
|
```
|
||||||
|
|
||||||
|
|
||||||
Parameters explained:
|
Parameters explained:
|
||||||
|
|
||||||
|Name|Meaning|
|
|Name|Meaning|
|
||||||
|-|-|
|
|-|-|
|
||||||
|
@ -4549,14 +4539,13 @@ Update(background_color,
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
```python
|
```python
|
||||||
Move(x_direction,
|
Move(x_direction,
|
||||||
y_direction)
|
y_direction)
|
||||||
```
|
```
|
||||||
|
|
||||||
|
|
||||||
Parameters explained:
|
Parameters explained:
|
||||||
|
|
||||||
|Name|Meaning|
|
|Name|Meaning|
|
||||||
|-|-|
|
|-|-|
|
||||||
|
@ -4566,6 +4555,7 @@ Move(x_direction,
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
```python
|
```python
|
||||||
MoveFigure(figure,
|
MoveFigure(figure,
|
||||||
x_direction,
|
x_direction,
|
||||||
|
@ -4573,7 +4563,7 @@ MoveFigure(figure,
|
||||||
```
|
```
|
||||||
|
|
||||||
|
|
||||||
Parameters explained:
|
Parameters explained:
|
||||||
|
|
||||||
|Name|Meaning|
|
|Name|Meaning|
|
||||||
|-|-|
|
|-|-|
|
||||||
|
@ -4585,7 +4575,6 @@ MoveFigure(figure,
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
```python
|
```python
|
||||||
RelocateFigure(figure,
|
RelocateFigure(figure,
|
||||||
x,
|
x,
|
||||||
|
@ -4593,7 +4582,7 @@ RelocateFigure(figure,
|
||||||
```
|
```
|
||||||
|
|
||||||
|
|
||||||
Parameters explained:
|
Parameters explained:
|
||||||
|
|
||||||
|Name|Meaning|
|
|Name|Meaning|
|
||||||
|-|-|
|
|-|-|
|
||||||
|
@ -4604,6 +4593,8 @@ RelocateFigure(figure,
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<!--
|
<!--
|
||||||
# DrawLine(self, point_from, point_to, color='black', width=1)
|
# DrawLine(self, point_from, point_to, color='black', width=1)
|
||||||
# DrawPoint(self, point, size=2, color='black')
|
# DrawPoint(self, point, size=2, color='black')
|
||||||
|
@ -4623,6 +4614,13 @@ RelocateFigure(figure,
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<!-- %!% -->
|
<!-- %!% -->
|
||||||
## Table Element
|
## Table Element
|
||||||
|
|
||||||
|
@ -4663,7 +4661,7 @@ Table(values,
|
||||||
```
|
```
|
||||||
|
|
||||||
|
|
||||||
Parameters explained:
|
Parameters explained:
|
||||||
|
|
||||||
|Name|Meaning|
|
|Name|Meaning|
|
||||||
|-|-|
|
|-|-|
|
||||||
|
@ -4699,7 +4697,6 @@ Table(values,
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
### Read return values from Table Element
|
### Read return values from Table Element
|
||||||
|
|
||||||
The values returned from a `Window.Read` call for the Tree Element are a list of row numbers that are currently highlighted.
|
The values returned from a `Window.Read` call for the Tree Element are a list of row numbers that are currently highlighted.
|
||||||
|
@ -4718,7 +4715,7 @@ Update(values=None,
|
||||||
```
|
```
|
||||||
|
|
||||||
|
|
||||||
Parameters explained:
|
Parameters explained:
|
||||||
|
|
||||||
|Name|Meaning|
|
|Name|Meaning|
|
||||||
|-|-|
|
|-|-|
|
||||||
|
@ -4730,7 +4727,6 @@ Update(values=None,
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
---
|
---
|
||||||
### Known visualization problem....
|
### Known visualization problem....
|
||||||
|
|
||||||
|
@ -4772,7 +4768,7 @@ Tree(data=None,
|
||||||
```
|
```
|
||||||
|
|
||||||
|
|
||||||
Parameters explained:
|
Parameters explained:
|
||||||
|
|
||||||
|Name|Meaning|
|
|Name|Meaning|
|
||||||
|-|-|
|
|-|-|
|
||||||
|
@ -4803,7 +4799,6 @@ Tree(data=None,
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
Unlike Tables there is no standard format for trees. Thus the data structure passed to the Tree Element must be constructed. This is done using the TreeData class. The process is as follows:
|
Unlike Tables there is no standard format for trees. Thus the data structure passed to the Tree Element must be constructed. This is done using the TreeData class. The process is as follows:
|
||||||
* Get a TreeData Object
|
* Get a TreeData Object
|
||||||
* "Insert" data into the tree
|
* "Insert" data into the tree
|
||||||
|
@ -4869,6 +4864,8 @@ View of second tab:
|
||||||
First we have the Tab layout definitions. They mirror what you see in the screen shots. Tab 1 has 1 Text Element in it. Tab 2 has a Text and an Input Element.
|
First we have the Tab layout definitions. They mirror what you see in the screen shots. Tab 1 has 1 Text Element in it. Tab 2 has a Text and an Input Element.
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
```python
|
```python
|
||||||
tab1_layout = [[sg.T('This is inside tab 1')]]
|
tab1_layout = [[sg.T('This is inside tab 1')]]
|
||||||
|
|
||||||
|
@ -4920,7 +4917,7 @@ TabGroup(layout,
|
||||||
```
|
```
|
||||||
|
|
||||||
|
|
||||||
Parameters explained:
|
Parameters explained:
|
||||||
|
|
||||||
|Name|Meaning|
|
|Name|Meaning|
|
||||||
|-|-|
|
|-|-|
|
||||||
|
@ -4942,6 +4939,7 @@ TabGroup(layout,
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<!-- The definition of a TabGroup is -->
|
<!-- The definition of a TabGroup is -->
|
||||||
<!-- TabGroup(layout,
|
<!-- TabGroup(layout,
|
||||||
title_color=None
|
title_color=None
|
||||||
|
@ -4976,7 +4974,7 @@ Tab(title,
|
||||||
```
|
```
|
||||||
|
|
||||||
|
|
||||||
Parameters explained:
|
Parameters explained:
|
||||||
|
|
||||||
|Name|Meaning|
|
|Name|Meaning|
|
||||||
|-|-|
|
|-|-|
|
||||||
|
@ -4995,6 +4993,7 @@ Tab(title,
|
||||||
|||
|
|||
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<!--
|
<!--
|
||||||
Tab(title,
|
Tab(title,
|
||||||
layout,
|
layout,
|
||||||
|
@ -5025,7 +5024,8 @@ Update(values=None,
|
||||||
visible=None)
|
visible=None)
|
||||||
```
|
```
|
||||||
|
|
||||||
Parameters explained:
|
|
||||||
|
Parameters explained:
|
||||||
|
|
||||||
|Name|Meaning|
|
|Name|Meaning|
|
||||||
|-|-|
|
|-|-|
|
||||||
|
@ -5039,6 +5039,24 @@ Update(values=None,
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
<!-- ```python
|
||||||
|
Update(disabled = None, visible=None)
|
||||||
|
```
|
||||||
|
WARNING - This Update method may not be working correctly -->
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<!-- %!% -->
|
<!-- %!% -->
|
||||||
## Pane Element
|
## Pane Element
|
||||||
|
|
||||||
|
@ -5064,7 +5082,7 @@ Pane(pane_list,
|
||||||
```
|
```
|
||||||
|
|
||||||
|
|
||||||
Parameters explained:
|
Parameters explained:
|
||||||
|
|
||||||
|Name|Meaning|
|
|Name|Meaning|
|
||||||
|-|-|
|
|-|-|
|
||||||
|
@ -5083,7 +5101,6 @@ Pane(pane_list,
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<!--
|
<!--
|
||||||
```python
|
```python
|
||||||
|
|
||||||
|
@ -5817,7 +5834,7 @@ Update(menu_definition,
|
||||||
```
|
```
|
||||||
|
|
||||||
|
|
||||||
Parameters explained:
|
Parameters explained:
|
||||||
|
|
||||||
|Name|Meaning|
|
|Name|Meaning|
|
||||||
|-|-|
|
|-|-|
|
||||||
|
@ -5827,7 +5844,6 @@ Update(menu_definition,
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
---
|
---
|
||||||
|
|
||||||
To add a menu to a Window place the `Menu` or `MenuBar` element into your layout.
|
To add a menu to a Window place the `Menu` or `MenuBar` element into your layout.
|
||||||
|
|
Loading…
Reference in New Issue