easycoder 250317.3__py2.py3-none-any.whl → 250403.1__py2.py3-none-any.whl

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/ec_graphics.py CHANGED
@@ -161,6 +161,41 @@ class Graphics(Handler):
161
161
  def r_frame(self, command):
162
162
  return self.nextPC()
163
163
 
164
+ # get {variable} from popup {type} {message} {title}
165
+ def k_get(self, command):
166
+ if self.nextIsSymbol():
167
+ symbolRecord = self.getSymbolRecord()
168
+ if symbolRecord['valueHolder']:
169
+ command['target'] = self.getToken()
170
+ else:
171
+ FatalError(self.compiler, f'Variable "{symbolRecord["name"]}" does not hold a value')
172
+ if symbolRecord['valueHolder']:
173
+ if self.nextIs('from'):
174
+ if self.nextIs('popup'):
175
+ command['ptype'] = self.nextToken()
176
+ command['message'] = self.nextValue()
177
+ command['title'] = self.nextValue()
178
+ self.addCommand(command)
179
+ return True
180
+ return False
181
+
182
+ def r_get(self, command):
183
+ target = self.getVariable(command['target'])
184
+ ptype = command['ptype']
185
+ if ptype == 'text':
186
+ text = psg.popup_get_text(self.getRuntimeValue(command['message']), title=self.getRuntimeValue(command['title']))
187
+ elif ptype == 'ok-cancel':
188
+ text = psg.popup_ok_cancel(self.getRuntimeValue(command['message']), title=self.getRuntimeValue(command['title']))
189
+ elif ptype == 'yes-no':
190
+ text = psg.popup_yes_no(self.getRuntimeValue(command['message']), title=self.getRuntimeValue(command['title']))
191
+ else:
192
+ return None
193
+ v = {}
194
+ v['type'] = 'text'
195
+ v['content'] = text
196
+ self.program.putSymbolValue(target, v)
197
+ return self.nextPC()
198
+
164
199
  def k_init(self, command):
165
200
  if self.nextIsSymbol():
166
201
  symbolRecord = self.getSymbolRecord()
@@ -219,13 +254,15 @@ class Graphics(Handler):
219
254
  window['eventHandlers'][key] = lambda: self.run(command['goto'])
220
255
  return self.nextPC()
221
256
 
257
+ # popup {message} {title}
222
258
  def k_popup(self, command):
223
259
  command['message'] = self.nextValue()
260
+ command['title'] = self.nextValue()
224
261
  self.addCommand(command)
225
262
  return True
226
263
 
227
264
  def r_popup(self, command):
228
- psg.popup(self.getRuntimeValue(command['message']))
265
+ psg.popup(self.getRuntimeValue(command['message']), title=self.getRuntimeValue(command['title']))
229
266
  return self.nextPC()
230
267
 
231
268
  def k_refresh(self, command):
easycoder/ec_program.py CHANGED
@@ -375,9 +375,6 @@ class Program:
375
375
  if type(v2) == int:
376
376
  if type(v1) != int:
377
377
  v2 = f'{v2}'
378
- if type(v1) == dict and type(v2) == dict:
379
- v1 = json.dumps(v1)
380
- v2 = json.dumps(v2)
381
378
  if v1 > v2:
382
379
  return 1
383
380
  if v1 < v2:
@@ -1,11 +1,12 @@
1
- Metadata-Version: 2.3
1
+ Metadata-Version: 2.4
2
2
  Name: easycoder
3
- Version: 250317.3
3
+ Version: 250403.1
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>
7
7
  Description-Content-Type: text/markdown
8
8
  Classifier: License :: OSI Approved :: MIT License
9
+ License-File: LICENSE
9
10
  Requires-Dist: pytz
10
11
  Project-URL: Home, https://github.com/easycoder/easycoder-py
11
12
 
@@ -0,0 +1,19 @@
1
+ easycoder/README.md,sha256=BVXmYphcTJ6q6RN_9L6HtQukgCnOjSLVIsTM3lk-9aM,587
2
+ easycoder/__init__.py,sha256=Rbjk_KuozfeqW33vGQ_QzqbCChEIO3CY6P48nYWx27g,262
3
+ easycoder/__init__.sync-conflict-20250331-210244-M3XB3VD.py,sha256=X9oWXDvpy4ZlAVmbFrtv3ktYGIY1K1Qt-4aAvKEiaBk,262
4
+ easycoder/ec_classes.py,sha256=xnWBNak8oKydkFoxHLlq9wo3lIsB3aMnTDrqbtCfoWo,1512
5
+ easycoder/ec_compiler.py,sha256=rtxFEWnhW0550MtWEDvYHOw9cYkeTcR0oG3t-kmgnBk,4795
6
+ easycoder/ec_condition.py,sha256=YXvSBQKEzKGCcgUGo3Qp8iHolXmm2BpEm0NimSDszIM,785
7
+ easycoder/ec_core.py,sha256=nf-XaDrRPgaJHE9mNw0_G7ZOWmhhL_3U9sA6eFJHWR4,90074
8
+ easycoder/ec_core.sync-conflict-20250331-210238-M3XB3VD.py,sha256=u4v023v26kjXU-_B46IpMeM8Lb2mUSLnpzmAs2Z83mI,88454
9
+ easycoder/ec_graphics.py,sha256=ScGLNxW_sxu0WyoO-Od-9MM0bhpVvf-vGa5UmoHYRCA,16073
10
+ easycoder/ec_gutils.py,sha256=yqu4RRQ6VdRkC5B2ADBYsXzgNu76dLnekd9aUjdEgPw,6399
11
+ easycoder/ec_handler.py,sha256=K7nBuQTH8l0k8hX1o2b4KhTnhZHGdf2fkEuX4FJXJs8,2277
12
+ easycoder/ec_program.py,sha256=BDwU7aGHiaw6WdbQvVFDhGVaHsvwQ1CWa4wb5MPmOe8,10013
13
+ easycoder/ec_timestamp.py,sha256=_3QFJPzIWZ9Rzk3SQOQJ-gwmvB07pg78k23SPntoZtY,288
14
+ easycoder/ec_value.py,sha256=zgDJTJhIg3yOvmnnKIfccIizmIhGbtvL_ghLTL1T5fg,2516
15
+ easycoder-250403.1.dist-info/entry_points.txt,sha256=JXAZbenl0TnsIft2FcGJbJ-4qoztVu2FuT8PFmWFexM,44
16
+ easycoder-250403.1.dist-info/licenses/LICENSE,sha256=xx0jnfkXJvxRnG63LTGOxlggYnIysveWIZ6H3PNdCrQ,11357
17
+ easycoder-250403.1.dist-info/WHEEL,sha256=Dyt6SBfaasWElUrURkknVFAZDHSTwxg3PaTza7RSbkY,100
18
+ easycoder-250403.1.dist-info/METADATA,sha256=f5ssxGjYex1uUM1dHwLTlIlIupypLBFfIJzESOMoUiM,6177
19
+ easycoder-250403.1.dist-info/RECORD,,
@@ -1,5 +1,5 @@
1
1
  Wheel-Version: 1.0
2
- Generator: flit 3.10.1
2
+ Generator: flit 3.12.0
3
3
  Root-Is-Purelib: true
4
4
  Tag: py2-none-any
5
5
  Tag: py3-none-any
@@ -1,17 +0,0 @@
1
- easycoder/README.md,sha256=BVXmYphcTJ6q6RN_9L6HtQukgCnOjSLVIsTM3lk-9aM,587
2
- easycoder/__init__.py,sha256=2sL5P9Yq1wRITaC08bkCLOe2zL5iJldJEuEgLYJ4hq8,262
3
- easycoder/ec_classes.py,sha256=xnWBNak8oKydkFoxHLlq9wo3lIsB3aMnTDrqbtCfoWo,1512
4
- easycoder/ec_compiler.py,sha256=rtxFEWnhW0550MtWEDvYHOw9cYkeTcR0oG3t-kmgnBk,4795
5
- easycoder/ec_condition.py,sha256=YXvSBQKEzKGCcgUGo3Qp8iHolXmm2BpEm0NimSDszIM,785
6
- easycoder/ec_core.py,sha256=FvB4XMIhN--c_fCpB-E7jQhT3q52c2_2su5kwtjNbMo,88843
7
- easycoder/ec_graphics.py,sha256=sOQlSDpMMjwilLzGkC57-iHdaRqIUWl1SJxc0NbLs1M,14377
8
- easycoder/ec_gutils.py,sha256=yqu4RRQ6VdRkC5B2ADBYsXzgNu76dLnekd9aUjdEgPw,6399
9
- easycoder/ec_handler.py,sha256=K7nBuQTH8l0k8hX1o2b4KhTnhZHGdf2fkEuX4FJXJs8,2277
10
- easycoder/ec_program.py,sha256=Ms-GOtd22TjqvxXkNtfNer725WgQmZiHXlNHLlwMGvs,10103
11
- easycoder/ec_timestamp.py,sha256=_3QFJPzIWZ9Rzk3SQOQJ-gwmvB07pg78k23SPntoZtY,288
12
- easycoder/ec_value.py,sha256=zgDJTJhIg3yOvmnnKIfccIizmIhGbtvL_ghLTL1T5fg,2516
13
- easycoder-250317.3.dist-info/entry_points.txt,sha256=JXAZbenl0TnsIft2FcGJbJ-4qoztVu2FuT8PFmWFexM,44
14
- easycoder-250317.3.dist-info/LICENSE,sha256=xx0jnfkXJvxRnG63LTGOxlggYnIysveWIZ6H3PNdCrQ,11357
15
- easycoder-250317.3.dist-info/WHEEL,sha256=ssQ84EZ5gH1pCOujd3iW7HClo_O_aDaClUbX4B8bjKY,100
16
- easycoder-250317.3.dist-info/METADATA,sha256=IQEkRp9Z6moiTe7wc-EAnna6xXnfpXQRN4dflQ0Ty40,6155
17
- easycoder-250317.3.dist-info/RECORD,,