[cssom-view] Propose to add attrs for getting max/min value of scroll coordinate attrs

I propose adding the following readonly attributes to Window:
scrollMinX, scrollMaxX, scrollMinY, scrollMaxY, and the following
readonly attributes to Element: scrollLeftMin, scrollLeftMax,
scrollTopMin, scrollTopMax.

These attributes, as their names indicate, return the max/min possible
value can be returned from their corresponding attributes in the given
context. They can be useful for authors to implement their own
scrolling indicators.

Previous discussion about scrollMaxX/Y can be found here:
* https://lists.w3.org/Archives/Public/www-style/2012Jun/0525.html
* https://lists.w3.org/Archives/Public/www-style/2013Apr/0473.html

The previous discussion only covers scrollMax*, but given the current
spec, scrollLeft and scrollX can be negative in RTL and vertical-rl
documents, and in which case, the maximum values would always be zero,
so we would need the Min ones. Since we do not have any bottom-to-top
mode in spec, scrollMinY and scrollTopMin may not be useful, but we
could add them for completeness.

Gecko has shipped the Max ones since long ago, and we are currently
adding the Min ones for internal use (not going to expose to the web
before they get specified, though).

Thoughts?

- Xidorn

Received on Wednesday, 21 October 2015 08:12:52 UTC