easycoder 250423.1__tar.gz → 250424.3__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Potentially problematic release.
This version of easycoder might be problematic. Click here for more details.
- {easycoder-250423.1 → easycoder-250424.3}/PKG-INFO +1 -1
- {easycoder-250423.1 → easycoder-250424.3}/config.ecs +93 -19
- {easycoder-250423.1 → easycoder-250424.3}/easycoder/__init__.py +1 -1
- {easycoder-250423.1 → easycoder-250424.3}/easycoder/ec_compiler.py +4 -4
- {easycoder-250423.1 → easycoder-250424.3}/easycoder/ec_core.py +30 -29
- {easycoder-250423.1 → easycoder-250424.3}/easycoder/ec_graphics.py +2 -2
- {easycoder-250423.1 → easycoder-250424.3}/easycoder/ec_program.py +1 -1
- {easycoder-250423.1 → easycoder-250424.3}/easycoder/ec_pyside6.py +176 -86
- easycoder-250424.3/test.py +52 -0
- easycoder-250423.1/test.py +0 -52
- {easycoder-250423.1 → easycoder-250424.3}/.gitignore +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/LICENSE +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/README.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/config.py +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/README.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/README.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/conditions/boolean.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/conditions/empty.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/conditions/ends.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/conditions/even.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/conditions/exists.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/conditions/greater.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/conditions/hasProperty.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/conditions/includes.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/conditions/is.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/conditions/less.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/conditions/list.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/conditions/none.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/conditions/not.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/conditions/numeric.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/conditions/object.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/conditions/odd.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/conditions/starts.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/conditions/string.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/keywords/add.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/keywords/append.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/keywords/assert.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/keywords/begin.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/keywords/clear.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/keywords/close.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/keywords/create.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/keywords/debug.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/keywords/decrement.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/keywords/delete.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/keywords/divide.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/keywords/exit.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/keywords/file.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/keywords/fork.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/keywords/get.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/keywords/go.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/keywords/gosub.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/keywords/if.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/keywords/import.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/keywords/increment.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/keywords/index.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/keywords/init.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/keywords/input.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/keywords/load.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/keywords/lock.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/keywords/log.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/keywords/module.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/keywords/multiply.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/keywords/negate.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/keywords/open.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/keywords/pop.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/keywords/post.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/keywords/print.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/keywords/push.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/keywords/put.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/keywords/read.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/keywords/release.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/keywords/replace.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/keywords/return.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/keywords/run.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/keywords/save.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/keywords/script.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/keywords/set.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/keywords/split.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/keywords/stack.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/keywords/stop.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/keywords/system.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/keywords/take.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/keywords/toggle.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/keywords/truncate.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/keywords/unlock.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/keywords/variable.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/keywords/wait.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/keywords/while.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/keywords/write.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/values/arg.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/values/args.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/values/cos.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/values/datime.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/values/decode.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/values/element.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/values/elements.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/values/empty.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/values/encode.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/values/error.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/values/files.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/values/float.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/values/from.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/values/hash.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/values/index.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/values/integer.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/values/json.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/values/keys.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/values/left.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/values/length.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/values/lowercase.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/values/memory.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/values/modification.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/values/modulo.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/values/newline.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/values/now.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/values/position.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/values/property.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/values/random.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/values/right.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/values/sin.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/values/stringify.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/values/tab.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/values/tan.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/values/timestamp.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/values/today.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/values/trim.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/values/type.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/values/uppercase.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/values/value.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/core/values/weekday.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/graphics/README.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/graphics/keywords/attach.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/graphics/keywords/close.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/graphics/keywords/create.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/graphics/keywords/ellipse.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/graphics/keywords/image.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/graphics/keywords/move.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/graphics/keywords/on.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/graphics/keywords/rectangle.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/graphics/keywords/render.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/graphics/keywords/run.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/graphics/keywords/set.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/graphics/keywords/text.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/graphics/values/attribute.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/doc/graphics/values/window.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/easycoder/README.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/easycoder/ec_classes.py +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/easycoder/ec_condition.py +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/easycoder/ec_gutils.py +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/easycoder/ec_handler.py +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/easycoder/ec_timestamp.py +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/easycoder/ec_value.py +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/group.py +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/images/Semoigo Dawn.jpg +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/json/graphics-demo.json +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/plugins/ec_keyboard.py +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/plugins/ec_p100.py +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/plugins/ec_pyside6.py +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/plugins/keyboards/4-function.json +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/plugins/keyboards/4-function.png +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/plugins/keyboards/qwerty-0.json +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/plugins/keyboards/qwerty-0.png +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/plugins/keyboards/qwerty-1.json +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/plugins/keyboards/qwerty-1.png +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/plugins/keyboards/qwerty-2.json +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/plugins/keyboards/qwerty-2.png +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/plugins/keyboards/qwerty-3.json +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/plugins/keyboards/qwerty-3.png +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/plugins/points.py +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/pyproject.toml +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/scripts/README.md +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/scripts/benchmark.ecs +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/scripts/config.ecg +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/scripts/connect.ecg +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/scripts/ec_keyboard.py +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/scripts/findxr.ecs +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/scripts/fizzbuzz.ecs +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/scripts/hello.ecs +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/scripts/points.ecs +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/scripts/test.ecs +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/scripts/testg.ecg +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/scripts/tests.ecs +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/test.ecg +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/test.ecs +0 -0
- {easycoder-250423.1 → easycoder-250424.3}/test.json +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.3
|
|
2
2
|
Name: easycoder
|
|
3
|
-
Version:
|
|
3
|
+
Version: 250424.3
|
|
4
4
|
Summary: Rapid scripting in English
|
|
5
5
|
Keywords: compiler,scripting,prototyping,programming,coding,python,low code,hypertalk,computer language,learn to code
|
|
6
6
|
Author-email: Graham Trott <gtanyware@gmail.com>
|
|
@@ -5,12 +5,15 @@
|
|
|
5
5
|
use graphics
|
|
6
6
|
|
|
7
7
|
window Window
|
|
8
|
+
window Dialog
|
|
8
9
|
layout MainPanel
|
|
9
10
|
layout LeftPanel
|
|
10
11
|
layout RightPanel
|
|
11
12
|
layout DeviceHPanel
|
|
12
13
|
layout OuterLayout
|
|
13
14
|
layout Layout
|
|
15
|
+
layout VLayout
|
|
16
|
+
layout HLayout
|
|
14
17
|
groupbox Group
|
|
15
18
|
label Label
|
|
16
19
|
label MasterDeviceLabel
|
|
@@ -24,12 +27,16 @@
|
|
|
24
27
|
pushbutton UpdateSlaveButton
|
|
25
28
|
pushbutton DeleteFileButton
|
|
26
29
|
pushbutton ExitButton
|
|
27
|
-
pushbutton
|
|
30
|
+
pushbutton ScanSystemsButton
|
|
28
31
|
pushbutton RemoveSystemButton
|
|
29
32
|
pushbutton SaveHostButton
|
|
30
33
|
pushbutton RelayOffButton
|
|
31
34
|
pushbutton RelayOnButton
|
|
32
35
|
pushbutton SaveWidgetDataButton
|
|
36
|
+
pushbutton SelectHostButton
|
|
37
|
+
pushbutton OKButton
|
|
38
|
+
pushbutton CancelButton
|
|
39
|
+
lineinput LineInput
|
|
33
40
|
lineinput SSIDInput
|
|
34
41
|
lineinput PasswordInput
|
|
35
42
|
lineinput DeviceNameInput
|
|
@@ -42,16 +49,12 @@
|
|
|
42
49
|
combobox SystemsCombo
|
|
43
50
|
checkbox LEDInvertCheckbox
|
|
44
51
|
checkbox RelayInvertCheckbox
|
|
45
|
-
dialog Dialog
|
|
46
52
|
messagebox MessageBox
|
|
47
|
-
variable Name
|
|
48
|
-
variable Value
|
|
49
53
|
|
|
50
54
|
! debug step
|
|
51
55
|
|
|
52
56
|
log `Starting`
|
|
53
57
|
init graphics
|
|
54
|
-
create Window title `RBR-Now configurator` size 700 500
|
|
55
58
|
create MainPanel type QHBoxLayout
|
|
56
59
|
|
|
57
60
|
! Do the left-hand panel
|
|
@@ -104,14 +107,12 @@
|
|
|
104
107
|
create Layout type QHBoxLayout
|
|
105
108
|
add Layout to Group
|
|
106
109
|
create SystemsCombo
|
|
107
|
-
add `System 1` to SystemsCombo
|
|
108
|
-
add `System 2` to SystemsCombo
|
|
109
|
-
add `System 3` to SystemsCombo
|
|
110
110
|
add stretch SystemsCombo to Layout
|
|
111
|
-
create
|
|
112
|
-
on click
|
|
113
|
-
add
|
|
111
|
+
create ScanSystemsButton text `Scan`
|
|
112
|
+
on click ScanSystemsButton go to ScanSystems
|
|
113
|
+
add ScanSystemsButton to Layout
|
|
114
114
|
create RemoveSystemButton text `Remove`
|
|
115
|
+
disable RemoveSystemButton
|
|
115
116
|
on click RemoveSystemButton go to RemoveSystem
|
|
116
117
|
add RemoveSystemButton to Layout
|
|
117
118
|
|
|
@@ -230,14 +231,29 @@
|
|
|
230
231
|
|
|
231
232
|
add stretch to RightPanel
|
|
232
233
|
|
|
233
|
-
|
|
234
|
+
create Window title `RBR-Now configurator` size 700 500 layout MainPanel
|
|
235
|
+
show Window
|
|
234
236
|
|
|
235
237
|
start graphics
|
|
236
|
-
|
|
238
|
+
|
|
239
|
+
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
|
|
240
|
+
|
|
241
|
+
variable Config
|
|
242
|
+
variable Name
|
|
243
|
+
variable Value
|
|
244
|
+
variable ReturnValue
|
|
245
|
+
variable Title
|
|
246
|
+
variable Result
|
|
247
|
+
|
|
248
|
+
LoadConfigFile:
|
|
249
|
+
log `Load the config file`
|
|
250
|
+
load Config from `~/.rbr.conf`
|
|
251
|
+
if Config is empty put json `{}` into Config
|
|
237
252
|
stop
|
|
238
253
|
|
|
239
254
|
ResetConfigFile:
|
|
240
255
|
log `Reset the configuration file`
|
|
256
|
+
put json `{}` into Config
|
|
241
257
|
stop
|
|
242
258
|
|
|
243
259
|
ScanNetwork:
|
|
@@ -269,21 +285,35 @@ Exit:
|
|
|
269
285
|
close Window
|
|
270
286
|
exit
|
|
271
287
|
|
|
272
|
-
|
|
273
|
-
log `
|
|
274
|
-
|
|
275
|
-
|
|
288
|
+
ScanSystems:
|
|
289
|
+
log `Scan systems`
|
|
290
|
+
if Config does not have property `host-ssid`
|
|
291
|
+
begin
|
|
292
|
+
put `Enter host SSID` into Title
|
|
293
|
+
gosub to GetRequestedText
|
|
294
|
+
if Result is `OK` set property `host-ssid` of Config to ReturnValue
|
|
295
|
+
if Config does not have property `host-password`
|
|
296
|
+
begin
|
|
297
|
+
put `Enter host password` into Title
|
|
298
|
+
gosub to GetRequestedText
|
|
299
|
+
if Result is `OK` set property `host-password` of Config to ReturnValue
|
|
300
|
+
end
|
|
301
|
+
end
|
|
302
|
+
log Config
|
|
303
|
+
! create Dialog title `Select a system`
|
|
304
|
+
! show Layout in Dialog
|
|
276
305
|
stop
|
|
277
306
|
|
|
278
307
|
RemoveSystem:
|
|
279
|
-
log `Remove this system?`
|
|
280
308
|
put SystemsCombo into Name
|
|
309
|
+
log `Remove ` cat Name cat `?`
|
|
281
310
|
create MessageBox on Window
|
|
282
311
|
style question
|
|
283
312
|
title `Remove system`
|
|
284
313
|
message `Are you sure you want to remove ` cat Name cat `?`
|
|
285
314
|
show MessageBox giving Value
|
|
286
|
-
|
|
315
|
+
if Value is `Yes` remove current item from SystemsCombo
|
|
316
|
+
if the count of SystemsCombo is 0 disable RemoveSystemButton
|
|
287
317
|
stop
|
|
288
318
|
|
|
289
319
|
SaveHostInfo:
|
|
@@ -302,3 +332,47 @@ RelayOn:
|
|
|
302
332
|
log `Turn the relay ON`
|
|
303
333
|
stop
|
|
304
334
|
|
|
335
|
+
! Get requested text
|
|
336
|
+
GetRequestedText:
|
|
337
|
+
create VLayout type QVBoxLayout
|
|
338
|
+
create HLayout type QHBoxLayout
|
|
339
|
+
add HLayout to VLayout
|
|
340
|
+
create LineInput size 40
|
|
341
|
+
add stretch LineInput to HLayout
|
|
342
|
+
create HLayout type QHBoxLayout
|
|
343
|
+
add HLayout to VLayout
|
|
344
|
+
create OKButton text `OK` size 6
|
|
345
|
+
on click OKButton
|
|
346
|
+
begin
|
|
347
|
+
put LineInput into ReturnValue
|
|
348
|
+
put `OK` into Result
|
|
349
|
+
close Dialog
|
|
350
|
+
return
|
|
351
|
+
end
|
|
352
|
+
add OKButton to HLayout
|
|
353
|
+
create CancelButton text `Cancel` size 6
|
|
354
|
+
on click CancelButton
|
|
355
|
+
begin
|
|
356
|
+
put `Cancel` into Result
|
|
357
|
+
close Dialog
|
|
358
|
+
return
|
|
359
|
+
end
|
|
360
|
+
add CancelButton to HLayout
|
|
361
|
+
create Dialog title Title layout VLayout size 300 80
|
|
362
|
+
center Dialog on Window
|
|
363
|
+
show Dialog
|
|
364
|
+
stop
|
|
365
|
+
|
|
366
|
+
SelectSystemFromList:
|
|
367
|
+
create Layout type QVBoxLayout
|
|
368
|
+
create SelectHostButton text `Select`
|
|
369
|
+
on click SelectHostButton
|
|
370
|
+
begin
|
|
371
|
+
log `Select Host SSID`
|
|
372
|
+
close Dialog
|
|
373
|
+
end
|
|
374
|
+
add stretch to Layout
|
|
375
|
+
add SelectHostButton to Layout
|
|
376
|
+
create Dialog title `Host SSID` layout Layout
|
|
377
|
+
show Dialog
|
|
378
|
+
return
|
|
@@ -114,10 +114,10 @@ class Compiler:
|
|
|
114
114
|
def compileLabel(self, command):
|
|
115
115
|
return self.compileSymbol(command, self.getToken(), False)
|
|
116
116
|
|
|
117
|
-
def compileVariable(self, command,
|
|
118
|
-
return self.compileSymbol(command, self.nextToken(),
|
|
117
|
+
def compileVariable(self, command, hasValue = False):
|
|
118
|
+
return self.compileSymbol(command, self.nextToken(), hasValue)
|
|
119
119
|
|
|
120
|
-
def compileSymbol(self, command, name,
|
|
120
|
+
def compileSymbol(self, command, name, hasValue):
|
|
121
121
|
try:
|
|
122
122
|
v = self.symbols[name]
|
|
123
123
|
except:
|
|
@@ -128,7 +128,7 @@ class Compiler:
|
|
|
128
128
|
self.symbols[name] = self.getPC()
|
|
129
129
|
command['program'] = self.program
|
|
130
130
|
command['type'] = 'symbol'
|
|
131
|
-
command['
|
|
131
|
+
command['hasValue'] = hasValue
|
|
132
132
|
command['name'] = name
|
|
133
133
|
command['elements'] = 1
|
|
134
134
|
command['index'] = 0
|
|
@@ -26,7 +26,7 @@ class Core(Handler):
|
|
|
26
26
|
if self.nextToken() == 'to':
|
|
27
27
|
if self.nextIsSymbol():
|
|
28
28
|
symbolRecord = self.getSymbolRecord()
|
|
29
|
-
if symbolRecord['
|
|
29
|
+
if symbolRecord['hasValue']:
|
|
30
30
|
if self.peek() == 'giving':
|
|
31
31
|
# This variable must be treated as a second value
|
|
32
32
|
command['value2'] = self.getValue()
|
|
@@ -57,7 +57,7 @@ class Core(Handler):
|
|
|
57
57
|
except:
|
|
58
58
|
value2 = None
|
|
59
59
|
target = self.getVariable(command['target'])
|
|
60
|
-
if not target['
|
|
60
|
+
if not target['hasValue']:
|
|
61
61
|
self.variableDoesNotHoldAValueError(target['name'])
|
|
62
62
|
targetValue = self.getSymbolValue(target)
|
|
63
63
|
if targetValue == None:
|
|
@@ -87,7 +87,7 @@ class Core(Handler):
|
|
|
87
87
|
if self.nextIs('to'):
|
|
88
88
|
if self.nextIsSymbol():
|
|
89
89
|
symbolRecord = self.getSymbolRecord()
|
|
90
|
-
if symbolRecord['
|
|
90
|
+
if symbolRecord['hasValue']:
|
|
91
91
|
command['target'] = symbolRecord['name']
|
|
92
92
|
self.add(command)
|
|
93
93
|
return True
|
|
@@ -149,7 +149,7 @@ class Core(Handler):
|
|
|
149
149
|
def k_clear(self, command):
|
|
150
150
|
if self.nextIsSymbol():
|
|
151
151
|
target = self.getSymbolRecord()
|
|
152
|
-
if target['
|
|
152
|
+
if target['hasValue']:
|
|
153
153
|
command['target'] = target['name']
|
|
154
154
|
self.add(command)
|
|
155
155
|
return True
|
|
@@ -245,7 +245,7 @@ class Core(Handler):
|
|
|
245
245
|
def k_decrement(self, command):
|
|
246
246
|
if self.nextIsSymbol():
|
|
247
247
|
symbolRecord = self.getSymbolRecord()
|
|
248
|
-
if symbolRecord['
|
|
248
|
+
if symbolRecord['hasValue']:
|
|
249
249
|
command['target'] = self.getToken()
|
|
250
250
|
self.add(command)
|
|
251
251
|
return True
|
|
@@ -325,7 +325,7 @@ class Core(Handler):
|
|
|
325
325
|
except:
|
|
326
326
|
value2 = None
|
|
327
327
|
target = self.getVariable(command['target'])
|
|
328
|
-
if not target['
|
|
328
|
+
if not target['hasValue']:
|
|
329
329
|
self.variableDoesNotHoldAValueError(target['name'])
|
|
330
330
|
return None
|
|
331
331
|
value = self.getSymbolValue(target)
|
|
@@ -400,7 +400,7 @@ class Core(Handler):
|
|
|
400
400
|
def k_get(self, command):
|
|
401
401
|
if self.nextIsSymbol():
|
|
402
402
|
symbolRecord = self.getSymbolRecord()
|
|
403
|
-
if symbolRecord['
|
|
403
|
+
if symbolRecord['hasValue']:
|
|
404
404
|
command['target'] = self.getToken()
|
|
405
405
|
else:
|
|
406
406
|
FatalError(self.compiler, f'Variable "{symbolRecord["name"]}" does not hold a value')
|
|
@@ -610,7 +610,7 @@ class Core(Handler):
|
|
|
610
610
|
def k_increment(self, command):
|
|
611
611
|
if self.nextIsSymbol():
|
|
612
612
|
symbolRecord = self.getSymbolRecord()
|
|
613
|
-
if symbolRecord['
|
|
613
|
+
if symbolRecord['hasValue']:
|
|
614
614
|
command['target'] = self.getToken()
|
|
615
615
|
self.add(command)
|
|
616
616
|
return True
|
|
@@ -701,7 +701,7 @@ class Core(Handler):
|
|
|
701
701
|
return True
|
|
702
702
|
elif self.isSymbol():
|
|
703
703
|
symbolRecord = self.getSymbolRecord()
|
|
704
|
-
if symbolRecord['
|
|
704
|
+
if symbolRecord['hasValue']:
|
|
705
705
|
command['target'] = symbolRecord['name']
|
|
706
706
|
if self.nextIs('from'):
|
|
707
707
|
command['file'] = self.nextValue()
|
|
@@ -717,7 +717,7 @@ class Core(Handler):
|
|
|
717
717
|
try:
|
|
718
718
|
with open(filename) as f: content = f.read()
|
|
719
719
|
except:
|
|
720
|
-
|
|
720
|
+
content = ''
|
|
721
721
|
try:
|
|
722
722
|
if filename.endswith('.json'): content = json.loads(content)
|
|
723
723
|
except:
|
|
@@ -785,7 +785,7 @@ class Core(Handler):
|
|
|
785
785
|
except:
|
|
786
786
|
value2 = None
|
|
787
787
|
target = self.getVariable(command['target'])
|
|
788
|
-
if not target['
|
|
788
|
+
if not target['hasValue']:
|
|
789
789
|
self.variableDoesNotHoldAValueError(target['name'])
|
|
790
790
|
return None
|
|
791
791
|
value = self.getSymbolValue(target)
|
|
@@ -810,7 +810,7 @@ class Core(Handler):
|
|
|
810
810
|
def k_negate(self, command):
|
|
811
811
|
if self.nextIsSymbol():
|
|
812
812
|
symbolRecord = self.getSymbolRecord()
|
|
813
|
-
if symbolRecord['
|
|
813
|
+
if symbolRecord['hasValue']:
|
|
814
814
|
command['target'] = self.getToken()
|
|
815
815
|
self.add(command)
|
|
816
816
|
return True
|
|
@@ -819,7 +819,7 @@ class Core(Handler):
|
|
|
819
819
|
|
|
820
820
|
def r_negate(self, command):
|
|
821
821
|
symbolRecord = self.getVariable(command['target'])
|
|
822
|
-
if not symbolRecord['
|
|
822
|
+
if not symbolRecord['hasValue']:
|
|
823
823
|
RuntimeError(self.program, f'{symbolRecord["name"]} does not hold a value')
|
|
824
824
|
return None
|
|
825
825
|
value = self.getSymbolValue(symbolRecord)
|
|
@@ -921,7 +921,7 @@ class Core(Handler):
|
|
|
921
921
|
|
|
922
922
|
def r_pop(self, command):
|
|
923
923
|
symbolRecord = self.getVariable(command['target'])
|
|
924
|
-
if not symbolRecord['
|
|
924
|
+
if not symbolRecord['hasValue']:
|
|
925
925
|
RuntimeError(self.program, f'{symbolRecord["name"]} does not hold a value')
|
|
926
926
|
stackRecord = self.getVariable(command['from'])
|
|
927
927
|
stack = self.getSymbolValue(stackRecord)
|
|
@@ -1060,7 +1060,7 @@ class Core(Handler):
|
|
|
1060
1060
|
if self.nextIsSymbol():
|
|
1061
1061
|
symbolRecord = self.getSymbolRecord()
|
|
1062
1062
|
command['target'] = symbolRecord['name']
|
|
1063
|
-
if '
|
|
1063
|
+
if 'hasValue' in symbolRecord and symbolRecord['hasValue'] == False:
|
|
1064
1064
|
FatalError(self.compiler, f'Symbol {symbolRecord["name"]} is not a value holder')
|
|
1065
1065
|
else:
|
|
1066
1066
|
self.add(command)
|
|
@@ -1074,7 +1074,7 @@ class Core(Handler):
|
|
|
1074
1074
|
if value == None:
|
|
1075
1075
|
return -1
|
|
1076
1076
|
symbolRecord = self.getVariable(command['target'])
|
|
1077
|
-
if not symbolRecord['
|
|
1077
|
+
if not symbolRecord['hasValue']:
|
|
1078
1078
|
RuntimeError(self.program, f'{symbolRecord["name"]} does not hold a value')
|
|
1079
1079
|
return -1
|
|
1080
1080
|
self.putSymbolValue(symbolRecord, value)
|
|
@@ -1090,7 +1090,7 @@ class Core(Handler):
|
|
|
1090
1090
|
command['line'] = False
|
|
1091
1091
|
if self.nextIsSymbol():
|
|
1092
1092
|
symbolRecord = self.getSymbolRecord()
|
|
1093
|
-
if symbolRecord['
|
|
1093
|
+
if symbolRecord['hasValue']:
|
|
1094
1094
|
if self.peek() == 'from':
|
|
1095
1095
|
self.nextToken()
|
|
1096
1096
|
if self.nextIsSymbol():
|
|
@@ -1259,7 +1259,7 @@ class Core(Handler):
|
|
|
1259
1259
|
def k_set(self, command):
|
|
1260
1260
|
if self.nextIsSymbol():
|
|
1261
1261
|
target = self.getSymbolRecord()
|
|
1262
|
-
if target['
|
|
1262
|
+
if target['hasValue']:
|
|
1263
1263
|
command['type'] = 'set'
|
|
1264
1264
|
command['target'] = target['name']
|
|
1265
1265
|
self.add(command)
|
|
@@ -1384,7 +1384,7 @@ class Core(Handler):
|
|
|
1384
1384
|
def k_split(self, command):
|
|
1385
1385
|
if self.nextIsSymbol():
|
|
1386
1386
|
symbolRecord = self.getSymbolRecord()
|
|
1387
|
-
if symbolRecord['
|
|
1387
|
+
if symbolRecord['hasValue']:
|
|
1388
1388
|
command['target'] = symbolRecord['name']
|
|
1389
1389
|
value = {}
|
|
1390
1390
|
value['type'] = 'text'
|
|
@@ -1423,7 +1423,7 @@ class Core(Handler):
|
|
|
1423
1423
|
def k_shuffle(self, command):
|
|
1424
1424
|
if self.nextIsSymbol():
|
|
1425
1425
|
symbolRecord = self.getSymbolRecord()
|
|
1426
|
-
if symbolRecord['
|
|
1426
|
+
if symbolRecord['hasValue']:
|
|
1427
1427
|
command['target'] = self.getToken()
|
|
1428
1428
|
self.add(command)
|
|
1429
1429
|
return True
|
|
@@ -1432,7 +1432,7 @@ class Core(Handler):
|
|
|
1432
1432
|
|
|
1433
1433
|
def r_shuffle(self, command):
|
|
1434
1434
|
symbolRecord = self.getVariable(command['target'])
|
|
1435
|
-
if not symbolRecord['
|
|
1435
|
+
if not symbolRecord['hasValue']:
|
|
1436
1436
|
RuntimeError(self.program, f'{symbolRecord["name"]} does not hold a value')
|
|
1437
1437
|
return None
|
|
1438
1438
|
value = self.getSymbolValue(symbolRecord)
|
|
@@ -1495,7 +1495,7 @@ class Core(Handler):
|
|
|
1495
1495
|
if self.nextToken() == 'from':
|
|
1496
1496
|
if self.nextIsSymbol():
|
|
1497
1497
|
symbolRecord = self.getSymbolRecord()
|
|
1498
|
-
if symbolRecord['
|
|
1498
|
+
if symbolRecord['hasValue']:
|
|
1499
1499
|
if self.peek() == 'giving':
|
|
1500
1500
|
# This variable must be treated as a second value
|
|
1501
1501
|
command['value2'] = self.getValue()
|
|
@@ -1530,7 +1530,7 @@ class Core(Handler):
|
|
|
1530
1530
|
except:
|
|
1531
1531
|
value2 = None
|
|
1532
1532
|
target = self.getVariable(command['target'])
|
|
1533
|
-
if not target['
|
|
1533
|
+
if not target['hasValue']:
|
|
1534
1534
|
self.variableDoesNotHoldAValueError(target['name'])
|
|
1535
1535
|
return None
|
|
1536
1536
|
value = self.getSymbolValue(target)
|
|
@@ -1552,7 +1552,7 @@ class Core(Handler):
|
|
|
1552
1552
|
def k_toggle(self, command):
|
|
1553
1553
|
if self.nextIsSymbol():
|
|
1554
1554
|
target = self.getSymbolRecord()
|
|
1555
|
-
if target['
|
|
1555
|
+
if target['hasValue']:
|
|
1556
1556
|
command['target'] = target['name']
|
|
1557
1557
|
self.add(command)
|
|
1558
1558
|
return True
|
|
@@ -1712,7 +1712,7 @@ class Core(Handler):
|
|
|
1712
1712
|
|
|
1713
1713
|
def incdec(self, command, mode):
|
|
1714
1714
|
symbolRecord = self.getVariable(command['target'])
|
|
1715
|
-
if not symbolRecord['
|
|
1715
|
+
if not symbolRecord['hasValue']:
|
|
1716
1716
|
RuntimeError(self.program, f'{symbolRecord["name"]} does not hold a value')
|
|
1717
1717
|
return None
|
|
1718
1718
|
value = self.getSymbolValue(symbolRecord)
|
|
@@ -1781,7 +1781,7 @@ class Core(Handler):
|
|
|
1781
1781
|
if self.nextToken() == 'of':
|
|
1782
1782
|
if self.nextIsSymbol():
|
|
1783
1783
|
symbolRecord = self.getSymbolRecord()
|
|
1784
|
-
if symbolRecord['
|
|
1784
|
+
if symbolRecord['hasValue']:
|
|
1785
1785
|
value['target'] = symbolRecord['name']
|
|
1786
1786
|
return value
|
|
1787
1787
|
self.warning(f'Core.compileValue: Token \'{self.getToken()}\' does not hold a value')
|
|
@@ -1792,7 +1792,7 @@ class Core(Handler):
|
|
|
1792
1792
|
if self.nextToken() == 'of':
|
|
1793
1793
|
if self.nextIsSymbol():
|
|
1794
1794
|
symbolRecord = self.getSymbolRecord()
|
|
1795
|
-
if symbolRecord['
|
|
1795
|
+
if symbolRecord['hasValue']:
|
|
1796
1796
|
value['target'] = symbolRecord['name']
|
|
1797
1797
|
return value
|
|
1798
1798
|
FatalError(self.compiler, 'Variable does not hold a value')
|
|
@@ -1838,8 +1838,9 @@ class Core(Handler):
|
|
|
1838
1838
|
if token == 'count':
|
|
1839
1839
|
if self.nextIs('of'):
|
|
1840
1840
|
if self.nextIsSymbol():
|
|
1841
|
-
|
|
1842
|
-
|
|
1841
|
+
if self.getSymbolRecord()['hasValue']:
|
|
1842
|
+
value['name'] = self.getToken()
|
|
1843
|
+
return value
|
|
1843
1844
|
return None
|
|
1844
1845
|
|
|
1845
1846
|
if token == 'index':
|
|
@@ -165,11 +165,11 @@ class Graphics(Handler):
|
|
|
165
165
|
def k_get(self, command):
|
|
166
166
|
if self.nextIsSymbol():
|
|
167
167
|
symbolRecord = self.getSymbolRecord()
|
|
168
|
-
if symbolRecord['
|
|
168
|
+
if symbolRecord['hasValue']:
|
|
169
169
|
command['target'] = self.getToken()
|
|
170
170
|
else:
|
|
171
171
|
FatalError(self.compiler, f'Variable "{symbolRecord["name"]}" does not hold a value')
|
|
172
|
-
if symbolRecord['
|
|
172
|
+
if symbolRecord['hasValue']:
|
|
173
173
|
if self.nextIs('from'):
|
|
174
174
|
if self.nextIs('popup'):
|
|
175
175
|
command['ptype'] = self.nextToken()
|
|
@@ -149,7 +149,7 @@ class Program:
|
|
|
149
149
|
elif valType == 'symbol':
|
|
150
150
|
name = value['name']
|
|
151
151
|
symbolRecord = self.getSymbolRecord(name)
|
|
152
|
-
if symbolRecord['
|
|
152
|
+
if symbolRecord['hasValue']:
|
|
153
153
|
handler = self.domainIndex[symbolRecord['domain']].valueHandler('symbol')
|
|
154
154
|
result = handler(symbolRecord)
|
|
155
155
|
else:
|