Don't crash if the requested range is outside the any document root

Fixes a crash when running the benchmark.
Merge pull request #497 from peitschie/benchmark-fix

Don't crash if the requested range is outside the any document root
Use a new ops.Canvas.getSizer instead of peeking
at the ancestry of the document root in SvgSelectionView.
Hide native selections only when virtual
selections are used.
Merge pull request #501 from adityab/native-selection-fallback

Re-enable selections for ODP and ODS documents
Use setStyle whenever selecting a new
style in the dialog.

This requires directly selecting a style
when cloning it, without waiting for onAdd.
Merge pull request #499 from adityab/pdialog

Load current style properties when opening dialog
Add test for frame position.
Add a helper function to get the bounding rectangle for an ODF page.
Improve positioning of frame that relative to page.
Add type that is a union of ClientRect and a struct with the same members.
This makes is possible to use them interchangeably.
In older browsers, positioning is only allowed on whole pixels.
The positioning test should set the allowed error higher in such browsers.
Add more supported length units.
And add a bit of documentation.
Check for null return value for getBoundingClientRect.
Slight clarification of exception.
Add tests with draw:frame directly in office:text.
This requires position: relative in office|text to get the frame positioned properly.
Simplify layout tests by having common styles.
Fix positioning for horizontal-pos="left" and vertical-pos="top".
Code cleanup and add a test for anchor="as-char".
Move getStyleElement from odf.Formatting to odf.StyleInfo.
Also add description to some functions and make convertToPx clearer.
Fix positioning of frames in ODP files.
This fixes a regression. In ODP, the location of frames is relative to the top and left of the page, but this is not explicitly specified in the styles.