Support text input using the OS’s IME system

This change extends the use of the event trap to allow in-line character addition
using the OS's IME. The event trap will now be moved to within the local user's
cursor block, and will become visible when a composition start event is detected.

This has been tested on Chrome, FF & Safari on all platforms. In addition, this
enables support in FF on Android.

Known issues
- No IME support on Chrome under Linux. The compositionend event emitted by Chrome
contains no data, so the input character can't be detected.

TODO
- Test in an NV build
- Rebind canvas element on undo
Improve Opera 11 compatibility slightly
Support text input using MacOS’s option+char method

Some IMEs will stack end & start requests back to back. Code has been
added that forces the display to reset between new composition sessions,
rather than incorrectly interrupting the new composition session 0ms later
as would happen if the background task executes after the composition
start event.

One known edge case on Safari under MacOS is that if composition is ended by
pressing another text char, Safari reports a keypress event with the same value
as the last compositionend data, rather than the new key that was pressed.