| 1 |
@import url("reset-to-defaults.css"); |
| 2 |
|
| 3 |
/* One caveat that apply to cairo gradients, and make things therefor |
| 4 |
* untestable: |
| 5 |
* The start and end points must be identical when drawing |
| 6 |
* This means that you cannot: |
| 7 |
* ... add extra color stops, even if they'd be invisible |
| 8 |
* ... mirror the gradient (ie 'to left, red, lime' vs 'to right, green, red') |
| 9 |
* ... test a repeating gradient against a non repeating one |
| 10 |
* and probably a bunch of other things. |
| 11 |
* These things can cause off-by-one rounding errors in pixman (and probably |
| 12 |
* your GPU, too) and that'd trigger test failures. |
| 13 |
*/ |
| 14 |
#a { |
| 15 |
background-image: linear-gradient(to bottom, blue 0%, lime 15px, red 100%); |
| 16 |
} |
| 17 |
|
| 18 |
#reference #a { |
| 19 |
background-image: linear-gradient(blue, lime, red); |
| 20 |
} |
| 21 |
|
| 22 |
#b { |
| 23 |
background-image: linear-gradient(to left, pink 0, cyan, red 0, lime 50%, blue 40px, violet -10em); |
| 24 |
} |
| 25 |
|
| 26 |
#reference #b { |
| 27 |
background-image: linear-gradient(270deg, red, lime, blue); |
| 28 |
} |
| 29 |
|
| 30 |
#c { |
| 31 |
background-image: linear-gradient(3.5turn, red, red 10px, lime 10px, lime 20px, red 20px, red 30px, lime 30px, lime 40px, red 40px); |
| 32 |
} |
| 33 |
|
| 34 |
#reference #c { |
| 35 |
background-image: repeating-linear-gradient(to bottom, red, red 10px, lime 10px, lime 20px, red 20px); |
| 36 |
} |
| 37 |
|
| 38 |
#d { |
| 39 |
background-image: repeating-linear-gradient(180deg, red, lime 10px, red 20px); |
| 40 |
} |
| 41 |
|
| 42 |
#reference #d { |
| 43 |
background-image: repeating-linear-gradient(to bottom, red, lime 10px, red 20px); |
| 44 |
} |