EchoSVG uses the deprecated CSSValue API for CSS values. With those values and units being hardwired to CSS 2.1, this old API not only is not supported by web browsers, but also effectively freezes the support for new CSS values and units.
Goals of this PR:
A first implementation of Typed OM.
Rewrite the machinery for the notification of value changes, which was unusable outside of the monolithic CSSValue API.
Native support for the color() function in the specified gamuts, instead of converting it to rgb() values in the sRGB space as until now.
Support the vw, vh, vmin, vmax, rem and rex units.
Partial backwards compatibility with the deprecated SVG 1.1 color and paint values.
Non-goals:
To have full backwards compatibility with deprecated SVG 1.1 and 1.2 features. Provide the modern alternatives instead.
Further changes are needed before full compatibility with Typed OM can be claimed:
The computed values cannot be directly cast to sub-interfaces like CSSRGB or CSSColor, instead one has to use value.colorValue or value.rectValue.
The Javascript array behavior may be reached by writing the appropriate Rhino Context stuff, although I doubt that this will ever be done.
EchoSVG uses the deprecated
CSSValue
API for CSS values. With those values and units being hardwired to CSS 2.1, this old API not only is not supported by web browsers, but also effectively freezes the support for new CSS values and units.Goals of this PR:
A first implementation of Typed OM.
Rewrite the machinery for the notification of value changes, which was unusable outside of the monolithic
CSSValue
API.Native support for the
color()
function in the specified gamuts, instead of converting it torgb()
values in the sRGB space as until now.Support the
vw
,vh
,vmin
,vmax
,rem
andrex
units.Partial backwards compatibility with the deprecated SVG 1.1 color and paint values.
Non-goals:
Further changes are needed before full compatibility with Typed OM can be claimed:
CSSRGB
orCSSColor
, instead one has to usevalue.colorValue
orvalue.rectValue
.Closes #67.