Support "turn" unit from CSS3 Values and Units

RESOLVED FIXED in mozilla13

Status

()

Core
CSS Parsing and Computation
P3
enhancement
RESOLVED FIXED
5 years ago
5 years ago

People

(Reporter: ayg, Assigned: bz)

Tracking

(Blocks: 1 bug, {dev-doc-complete})

Trunk
mozilla13
dev-doc-complete
Points:
---
Dependency tree / graph
Bug Flags:
in-testsuite +

Firefox Tracking Flags

(Not tracked)

Details

Attachments

(1 attachment)

"""
turn
Turns. There is 1 turn in a full circle.
"""
http://dev.w3.org/csswg/css3-values/#turn

Test case:
data:text/html,<!doctype html>
<style>div {
height:50px;
width:50px;
background:blue;
-moz-transform:rotate(0.125turn);
}</style>
<div></div>

The square should be tilted 45 degrees.  In Firefox 12.0a1 (2012-01-09), it's not.  In IE9, Chrome 17 dev, and Opera Next 12.00 alpha, if the prefix is adjusted, it is.  This causes Firefox to fail some of the 2D Transform tests I'm writing.
Created attachment 587242 [details] [diff] [review]
Implement support for 'turn' unit in CSS.

Pretty straightforward
Attachment #587242 - Flags: review?(dbaron)
Assignee: nobody → bzbarsky
Priority: -- → P3
Whiteboard: [need review]
Comment on attachment 587242 [details] [diff] [review]
Implement support for 'turn' unit in CSS.

Also adjust the switch in the SetGradient function in nsRuleNode.cpp, and add a test for the gradient angle that fails without that adjustment.

r=dbaron with that
Attachment #587242 - Flags: review?(dbaron) → review+
Gah.  I thought I'd fixed that switch....  I did hit the assert, but of course that doesn't make mochitest fail.

I'll add a test to test_computed_style.html.
https://hg.mozilla.org/integration/mozilla-inbound/rev/a096800c8f6b
Flags: in-testsuite+
Whiteboard: [need review]
Target Milestone: --- → mozilla13

Comment 5

5 years ago
https://hg.mozilla.org/mozilla-central/rev/a096800c8f6b
Status: NEW → RESOLVED
Last Resolved: 5 years ago
Resolution: --- → FIXED
Keywords: dev-doc-needed

Updated

5 years ago
Depends on: 726465
Updated 
https://developer.mozilla.org/en/CSS/angle

and
https://developer.mozilla.org/en/Firefox_13_for_developers#CSS
Keywords: dev-doc-needed → dev-doc-complete

Updated

5 years ago
Blocks: 741643
You need to log in before you can comment on or make changes to this bug.