Webnote

Webnote

This document is the API Specification for Webnote.

Summary

The code for webnote is broken up into two files, objects.js and webnote.js. objects.js contains generic classes like a Point class and a Color class while webnote.js contains the Webnote specific classes. For the most part, the javascript for Webnote is written in an object oriented way.

The classes are organized like so:

Workspace
  |
  +- "dictionary" of Note objects
  |
  +- History object
  |
  +- Mouse object

There is a single global Workspace called workspace that can be used to access any of the other objects and methods. The class also contains methods for global actions such as filtering the notes, saving the workspace, or creating new notes.

Each note contains two parts: the HTML that makes up the note and a Note object in memory. Most changes to the HTML can be done via the wrapper methods provided in the Note class. For example, note1.setText("hello world") would set the text of note1.

History is used to maintain the undo and redo stack. The add method is used to add an event to the undo stack.

Mouse is used to handle events that span time. For example, dragging a note or resizing a note are operations that use Mouse.


Webnote

Documentation generated by JSDoc on Tue May 24 23:13:22 2005