W3C home > Mailing lists > Public > public-css-archive@w3.org > April 2017

[csswg-drafts] [css-images] compute/round the <angle> value for image-orientation property is a bit confusing

From: Jeremy <sysbot+gh@w3.org>
Date: Tue, 11 Apr 2017 11:34:24 +0000
To: public-css-archive@w3.org
Message-ID: <issues.opened-220921970-1491910462-sysbot+gh@w3.org>
chenpighead has just created a new issue for https://github.com/w3c/csswg-drafts:

== [css-images] compute/round the <angle> value for image-orientation property is a bit confusing ==
Quote from the [spec](https://drafts.csswg.org/css-images-3/#propdef-image-orientation):

> The computed value of the property is calculated by rounding the specified angle to the nearest quarter-turn (90deg, 100grad, .25turn, etc.), rounding away from 0 (that is, 45deg is rounded to 90deg, while -45deg is rounded to -90deg), then moduloing the value by 1 turn (360deg, 400grad, etc.). 

As to the `rounding away from 0`, the example says that `-45deg is rounded to -90deg`. What about 315deg (the equivalence of -45deg)? Should we round it to 360deg (equivalence of 0deg) to align the `rounding away from 0` stuff? This is a bit confusing to me.

If we intent to always make -45deg (and 315deg) always round to -90deg, then IMO this worth some more words in the spec. Since there are only four possible rounding edges (45deg, 135deg, 225deg, 315deg), maybe we could also specify all of them in the spec. instead of just putting 2 examples.


Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/1206 using your GitHub account
Received on Tuesday, 11 April 2017 11:34:31 UTC

This archive was generated by hypermail 2.4.0 : Tuesday, 5 July 2022 06:41:11 UTC