Examples in [[Jython Scripting|Jython]].
Open the "Plugins - Scripting - Jython Interpreter" (see [[Scripting Help]]) and make sure there is a TrakEM2 project open, with a display open. Then type or paste
=== Get the instance of a selected image ===
=== Access the Layer and Selection of a Display ===
In Jython, 1 is True and 0 is False
=== Lock all selected objects ===
for d in Display.getFront().
=== Setting and getting member objects in jython ===
In Jython as in Python, member objects have automatically <i>get</> and <i>set</i> functions.
For example, altough a [http://www.ini.uzh.ch/~acardona/api/ini/trakem2/display/Displayable.html Displayable] has a private <i>String title</i> member, this is valid python code for getting and setting the title of a Displayable like a Patch:
=== The properties of a Displayable: color, visibil