Simplify CSS rules for cursor and composer element

The cursor node is now completely hidden when not in use, so there is no
need to touch the height or width properties of the composer or cursor.

In addition, the new overlay caret no longer requires the composer to be
displayed as an inline-block in order to function.
Provide a better caret position fallback when no visible rects are found

In the specific situation where there are no visible rectangles nearby
from which to calculate the caret position and size, the cursor node itself
will be made visible with some hidden internal text as a substitute.

This ensures the caret is correctly aligned in empty paragraphs that are
not left-aligned, or in an area surround by non-visible rects such as near
multiple annotations.
Remove another unnecessary inline-block

The cursor element is now only visible when it contains either text
or the caret-size helper. In addition, there are no longer any fixed
widths being applied to the cursor element, so the inline-block is not
necessary.
Merge pull request #611 from peitschie/cursor-visible

Provide a better caret position fallback when no visible rects are found
Only store the start node in DomUtils.getNodesInRange if within range

Fixes a regression introduced in 8b742ee. The currentNode was being
incorrectly added to the results array before it was checked to see if
it was contained inside the supplied range.
Merge pull request #612 from peitschie/range-fixup

Only store the start node in DomUtils.getNodesInRange if within range
Clean up Avatar styling and remove !important tags from webodf.css

Historically, the avatar styling was split between the avatar class,
webodf.css and the editor's own CSS. This now all lives within WebODF,
so the !important tags are no longer necessary as the style attributes
being set on the handle and image elements can simply be removed.
Keep IME character selection menu in one place during composition

f78a30a introduced a regression that caused the IME menu to appear to
follow the caret across the screen as new characters are entered, rather
than remaining anchored at the beginning of the composed text.

This patch adds some width calculations, and aligns parts of the caret
overlay to either left or right side of the container. As the caret
overlay is widened, the event trap will remain fixed to the left, and the
caret + avatar handle will remain fixed to the right.
Redraw the caret if the composition sequence is aborted

If the user abandons the composition sequence (e.g., by pressing the
escape key before choosing which word to input), the text is cleared and
no operations or other updates are required. Subscribe to this event as
well to ensure the caret is redrawn back at the proper location.
First stab at improved line boundary detection
Roughly wire new boundary detection into selection controller

Slight improvement to the selection controller to limit boundary searching to the current paragraph
Major rewrite to support advance-to-X-offset feature
Wire in caret position locator to allow proper by-line navigation
Cleanup + compilation fixes

TODO
- Unit tests
- Moar unit tests

- Fix navigate by line starting in an empty paragraph
- Cache last x offset so consecutive down/up arrows follow jagged
paragraph edges