diff --git a/docs/API.md b/docs/API.md index a174dd62..a5693394 100644 --- a/docs/API.md +++ b/docs/API.md @@ -1,4 +1,4 @@ -### Modules / API +# 1. Modules / API The noVNC client is a composed of several modular components that handle rendering, input, networking, etc. Each of the modules is designed to @@ -6,7 +6,7 @@ be cross-browser and be useful as a standalone library in other projects (see LICENSE.txt). -### Module List +## 1.1 Module List * **Mouse** (core/input/devices.js): Mouse input event handler with limited touch support. @@ -26,7 +26,7 @@ with transparent binary data support. protocol and stitches the other classes together. -### Configuration Attributes +## 1.2 Configuration Attributes The Mouse, Keyboard, Display and RFB classes have a similar API for configuration options. Each configuration option has a default value, @@ -52,7 +52,7 @@ made to set it. The attribute mode is one of the following: WO - write once -### Methods +## 1.3 Methods In addition to the getter and setter methods to modify configuration attributes, each of the modules has other methods that are available @@ -60,7 +60,7 @@ in the object instance. For example, the Display module has method named 'blitImage' which takes an array of pixel data and draws it to the 2D canvas. -### Callbacks +## 1.4 Callbacks Each of the modules has certain events that can be hooked with callback functions. For the Mouse, Keyboard, Display and RFB classes @@ -68,8 +68,9 @@ the callback functions are assigned to configuration attributes. The WebSock module has a method named 'on' that takes two parameters: the callback event name, and the callback function. +## 2. Modules -#### Mouse Module +## 2.1 Mouse Module