Difference between revisions of "EZUI"
Jump to navigation
Jump to search
Ben.christel (talk | contribs) (Created page) |
Ben.christel (talk | contribs) |
||
Line 9: | Line 9: | ||
== Tutorial == | == Tutorial == | ||
+ | |||
+ | ===Hello World=== | ||
+ | |||
+ | * You should use <code>system.require('std/graphics/ezui.em')</code> to ensure that the required files are included. | ||
+ | * The Emerson function <code>ezui.script()</code> takes a string containing JavaScript to be executed when the GUI loads. The code passed to <code>ezui.script()</code> is executed every time a user opens the GUI. In between invocations of the GUI, its contents are cleared. | ||
+ | * The <code>write()</code> function takes a string as a parameter. This string is appended to the GUI's HTML, similar to the way document.write() works in a plain HTML document. | ||
+ | |||
+ | ====The Code==== | ||
+ | |||
+ | <div style="font-size:120%"> | ||
+ | <source lang="javascript"> | ||
+ | system.require('std/graphics/ezui.em'); | ||
+ | ezui.script(@ | ||
+ | write('Hello, World!'); | ||
+ | @); | ||
+ | </source> | ||
+ | </div> |
Revision as of 04:14, 10 August 2011
EZUI is a user interface creation tool developed by Ben Christel. It is designed to allow an application developer to add code to an entity's script that specifies the UI's appearance and logic. The UI will then appear on a user's screen when the user interacts with one of the entity's presences.
EZUI was designed with the following goals in mind:
- Facilitating rapid development of dialog-like UIs associated with a particular presence in the world
- Enabling multiple users to interact with a presence simultaneously using the UI
- Allowing application developers to easily collect and store data input by the user
- Facilitating communication between the presence controlling the UI and the avatar interacting with it
- Automating the synchronization of data between the UI and the controlling presence
Tutorial
Hello World
- You should use
system.require('std/graphics/ezui.em')
to ensure that the required files are included. - The Emerson function
ezui.script()
takes a string containing JavaScript to be executed when the GUI loads. The code passed toezui.script()
is executed every time a user opens the GUI. In between invocations of the GUI, its contents are cleared. - The
write()
function takes a string as a parameter. This string is appended to the GUI's HTML, similar to the way document.write() works in a plain HTML document.
The Code
system.require('std/graphics/ezui.em');
ezui.script(@
write('Hello, World!');
@);