Forum Archive

Hide classes

nixoid

Hi!

Using pythonista i find many good classes: Button, TextLayer etc.
Where I can read documentation of this classes (without console)?

ccc

scene.Button and scene.TextLayer are "undocumented" classes so:

  1. you will not find them in the normal Pythonista docs, and
  2. use them at your own risk as they should be considered incomplete, unsupported, and possibly buggy.

See OMZ's comments in: http://omz-forums.appspot.com/pythonista/post/5356769110917120

You can however read the source code for them...

import inspect, scene
print(inspect.getsource(scene.Button))
print(inspect.getsource(scene.TextLayer))
nixoid

Thanks!

Fantastical app ))

nixoid

And more: I don't find in docs about run() function for run scene subclasses.

omz

@nixoid: It's here: http://omz-software.com/pythonista/docs/ios/scene.html#scene.run

ccc

KeyboardHack.py rebuilt to leverage scene.Button: https://gist.github.com/cclauss/8427853