Add contrast ratio and relative luminescence functions in the HTMLCS utils.
This allows potential testing in SC 1.4.3 and 1.4.6 for contrast ratio messages.
Lots of changes, primarily proper colour contrast tests replacing the notices in SC 1.4.3/1.4.6.

Full list of changes:
- Added HTMLCS.util.colourStrToRGB() to refactor the conversion from colour string to R/G/B structure. This also now supports colour strings in rgb() format as computed style often returns it in this way.
- Added HTMLCS.util.RGBtoColourStr() to convert an RGB structure back to a hex string. Will convert into three digit hex string if possible, otherwise six digit.
- Added HTMLCS.util.sRGBtoHSV() to convert an RGB colour (string or structure) into a H/S/V structure. This is for easier colour recommendation in contrast tests (SC 1.4.3/1.4.6).
- Added HTMLCS.util.HSVtosRGB() to reverse the conversion from H/S/V structure into R/G/B structure. (Use RGBtoColourStr() to change to hex string.)
- Added HTMLCS.util.style() to refactor the object sniffing for computed style (used in HTMLCS.util.isHidden(), SC 2.2.2 blinking tests, et al.).
- Moved getElementWindow() from pointer to HTMLCS.util, for use in HTMLCS.util.style().
- Added colour contrast tests to AA and AAA level (SC 1.4.3/1.4.6). A common contrast test is used, passing the applicable regular and large text ratios. Will return messages with the current contrast ratio and the required ratio to pass.
- HTMLCS will no longer try to register a test file without a register() method. This allows methods with multiple SCs to use a utility testing function and return their own messages.
- Doc comment fixes, mainly param/return types, but also adding missing ones for some util functions.
Nodes should be shifted off, not popped off, so the errors come in document order.
Elements hidden off screen will now be considered "hidden" for HTMLCS purposes.
Fixed bug with pointing to elements that are "position: fixed", by making the pointer fixed itself in these circumstances.
This required a lot of unravelling of the pointer code, due to conflicts between a concept of a "global" pointer object, and having one object per document (changes made for multi-frame documents).
Now there is no pointer member object; all getting of the pointer should go through getPointer().
Contrast failures now come with a recommendation as to the colour(s) that should be changed to achieve the required contrast ratio (CR).
- Recommended colours are determined by tweaking them on a hue/saturation/value model in steps of 0.25% (value in one way, saturation the other) until they reach the required CR and/or white or black.
- HTMLCS will first try to change the colour - either background or foreground - furthest away from white/black (according to the sRGB relative luminescence values). If it gets to white or black without the CR being satisfied, it will revert to the original colours then try the other colour.
- If the other colour cannot satisfy the CR requirement by the time it gets to white or black (possible with a 7:1 ratio and initial colours both near grey), it will then start to change the first colour while keeping the other colour at white/black.
- If the colours are exactly the same distance from a 0.5 relative luminescence, it will change the foreground colour first.
- Contrast ratio messages now have the following added: "Recommendation: change text colour to #000, background to #959595" (for instance), deleting as applicable. If both needed to be changed, both will appear.
1. Fix a regression when trying to determine whether an element is in the current document (ie. it has been replaced by something else dynamically after being run).
2. Moved said code to the isPointable() function, so if it has been replaced, the pointer will be disabled.
Failure messages should state "conformance level" instead of just "level" to avoid ambiguity.
1. Source code fragments (not full docs) get placed inside a DIV tag, and the DIV is passed. This is to work around a regression introduced in pull request #23 where SC 2.4.1 treated these as full documents.
2. Fix a trailing comma in array issue which would have bitten HTMLCS when minified.
SC 1.3.1: Non-existent "for" attributes were being thrown as errors regardless of whether it was a full document. Now throw error or warning like SC 2.4.1's bypassable ID check.
1. Don't add the extra document fragment div if the body tag is found in the fragment.
2. Add an unlikely ID (that is later removed) for the extra div. This is so we can selectively remove it rather than just pulling out the first div we get.
No longer throw contrast ratio messages where there is no definition on the background colour (ie. in a document fragment).
Elements with background images but no solid background image will now emit a warning, imploring authors to check all colours in the image covered by text for contrast ratio issues.
1. Move the required ratio checks further up the test, so the "has BG image" failures have knowledge of the required ratio.
2. When there is no background image, the value of this style is "none", not a blank string. Fix tests for this.
Merge pull request #27 from lwright-sq/master

Roll-up pull for #25, #26, and regression in #22