Lively Kernel Tutorial: (12) Modifying Objects and JavaScript Code on the Fly


Since the Lively Kernel is built with JavaScript, a highly dynamic programming language that does not require applications to be compiled ahead of time, virtually every object in the system can be modified at runtime. On this tutorial page we have included a number of textual scripts that you can execute and modify on the fly.

You can execute the scripts using the "evaluate as JavaScript code" feature that is available in the popup menu of TextMorphs.

Notes:

TextMorphs can be edited and evaluated also using the following keyboard shortcuts.
(NOTE: these shortcuts do not work on all browsers. In some browsers you may have to use the "Alt Gr" key instead):

Some additional comments on text editing:


Try it yourself! Try evaluating the scripts that have been provided in the four TextMorphs below.
Try modifying the scripts yourself to generate different kinds of graphical objects.
Note that the objects generated by these scripts are full-fledged graphical objects that can be edited using handles, menus and other features presented earlier in this tutorial.

*** Unable to load the Lively Kernel (unsupported web browser) ***