Patrick Walton
fec43b49bb
layout: Implement per-glyph font fallback.
...
This improves numerous pages, for example Wikipedia and Ars Technica.
Closes #177 .
2015-05-22 17:16:24 -07:00
bors-servo
77099b25d5
Auto merge of #5586 - pcwalton:no-broken-background-image-redux, r=glennw
...
r? @jdm
<!-- Reviewable:start -->
[<img src="https://reviewable.io/review_button.png " height=40 alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/servo/5586 )
<!-- Reviewable:end -->
2015-05-20 16:43:31 -05:00
Patrick Walton
7e7675c1dc
net: Don't load the placeholder image for background images, only for
...
image fragments.
This also changes the way the placeholder is handled in the image cache
task to decode it up front instead of each time an image fails to load,
both because it was more convenient to implement that way and because
it saves CPU cycles to do so.
This matches the behavior of Gecko and WebKit. It improves the look of
our cached copy of Wikipedia.
2015-05-20 12:00:33 -07:00
Patrick Walton
1a3395e077
script: Implement the width
and height
attributes for iframes per
...
HTML5 § 4.8.6.
Improves Amazon and Ars Technica.
2015-05-20 11:15:25 -07:00
Matt Brubeck
9355186fa6
Remove "experimental" from direction:rtl reftests
...
No longer needed after #6138 .
2015-05-20 08:17:02 -07:00
bors-servo
ba340ec71b
Auto merge of #5989 - pcwalton:font-color, r=jdm
...
Improves Hacker News.
r? @Ms2ger
<!-- Reviewable:start -->
[<img src="https://reviewable.io/review_button.png " height=40 alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/servo/5989 )
<!-- Reviewable:end -->
2015-05-19 18:33:03 -05:00
Patrick Walton
7d9eda916b
script: Implement the color
attribute of the <font>
element.
...
Improves Hacker News.
2015-05-19 16:31:20 -07:00
Patrick Walton
d5ca1a18dc
layout: Support percentage widths in inline-blocks.
...
Improves Twitter.
2015-05-19 13:35:02 -07:00
Matt Brubeck
0048b4f2ab
Positioning fixes for RTL floats
2015-05-18 17:25:06 -07:00
Ms2ger
391417cb44
Submit the remaining 2dcontext reftests to wpt.
2015-05-16 17:14:26 +02:00
bors-servo
3934831da3
Auto merge of #6081 - mbrubeck:table-wrapper-rtl, r=pcwalton
...
Fixes #6006 . r? @pcwalton
<!-- Reviewable:start -->
[<img src="https://reviewable.io/review_button.png " height=40 alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/servo/6081 )
<!-- Reviewable:end -->
2015-05-15 22:46:35 -05:00
bors-servo
9f2079f6ba
Auto merge of #6067 - Jinwoo-Song:backgroundclip, r=pcwalton
...
This property determines the background painting area, which determines the area
within which the background is painted.
Spec: http://dev.w3.org/csswg/css-backgrounds-3/#background-clip
Fixes #6066 .
r? @pcwalton
cc @yichoi
<!-- Reviewable:start -->
[<img src="https://reviewable.io/review_button.png " height=40 alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/servo/6067 )
<!-- Reviewable:end -->
2015-05-15 22:05:05 -05:00
Jinwoo Song
a51d5de860
Implement 'background-clip' property in CSS3 Background
...
This property determines the background painting area, which determines the area
within which the background is painted.
Spec: http://dev.w3.org/csswg/css-backgrounds-3/#background-clip
Fixes #6066 .
2015-05-16 09:43:46 +09:00
Matt Brubeck
179a70b305
Fix layout of RTL tables in LTR flow
...
Fixes #6006 .
2015-05-15 17:03:51 -07:00
bors-servo
68d135e671
Auto merge of #6033 - Jinwoo-Song:boxsizing_paddingbox, r=pcwalton
...
Spec: http://dev.w3.org/csswg/css-ui/#valdef-box-sizing-padding-box
Currently, only Firefox is supporting this value.
<!-- Reviewable:start -->
[<img src="https://reviewable.io/review_button.png " height=40 alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/servo/6033 )
<!-- Reviewable:end -->
2015-05-15 09:42:18 -05:00
bors-servo
8c40272824
Auto merge of #6046 - Jinwoo-Song:background_origin, r=pcwalton
...
This property determines the background positioning area, that is the position of
the origin of an image specified using the 'background-image' CSS property.
'background-origin' is ignored when background-attachment is fixed.
Spec: http://dev.w3.org/csswg/css-backgrounds-3/#background-origin
Fixes #6045 .
r? @pcwalton
cc @yichoi
<!-- Reviewable:start -->
[<img src="https://reviewable.io/review_button.png " height=40 alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/servo/6046 )
<!-- Reviewable:end -->
2015-05-14 20:53:02 -05:00
Jinwoo Song
b1b22c0c53
Implement 'background-origin' property in CSS3 Background
...
This property determines the background positioning area, that is the position of
the origin of an image specified using the 'background-image' CSS property.
'background-origin' is ignored when background-attachment is fixed.
Spec: http://dev.w3.org/csswg/css-backgrounds-3/#background-origin
Fixes #6045 .
2015-05-15 10:02:58 +09:00
Matt Brubeck
dc19806b15
Fix positioning of RTL blocks with margins.
...
`BaseFlow::position` is relative to the parent flow's margin box in the inline
direction. We need to use the parent's `position` as the container size when
translating it to physical coordinates, or we get incorrect results for
non-LTR content.
2015-05-14 09:23:15 -07:00
bors-servo
e25444c263
Auto merge of #6035 - Jinwoo-Song:fix_background_image_position, r=pcwalton
...
According to CSS2.1 spec, background image should be positioned on padding box.
Spec: http://www.w3.org/TR/CSS21/colors.html#propdef-background-position
Fixes #6034 .
r? @jdm
cc @yichoi
<!-- Reviewable:start -->
[<img src="https://reviewable.io/review_button.png " height=40 alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/servo/6035 )
<!-- Reviewable:end -->
2015-05-13 20:40:33 -05:00
Jinwoo Song
945adabd48
Add support for 'padding-box' value for 'box-sizing' property ( fixes #6032 )
...
Spec: http://dev.w3.org/csswg/css-ui/#valdef-box-sizing-padding-box
Currently, only Firefox is supporting this value.
2015-05-14 09:11:43 +09:00
Jinwoo Song
7283f75679
Position the background image on the padding box.
...
According to CSS2.1 spec, background image should be positioned on padding box.
Spec: http://www.w3.org/TR/CSS21/colors.html#propdef-background-position
Fixes #6034 .
2015-05-14 08:44:33 +09:00
Patrick Walton
1f0b5889da
layout: Allow inline elements to be containing blocks for
...
absolutely-positioned elements.
This also implements a little bit of the infrastructure needed to
support for fragmentation via support for multiple positioned fragments
in one flow.
Improves Google.
2015-05-13 12:00:53 -07:00
Patrick Walton
87a620e1b3
layout: Draw elements with position: relative; z-index: auto
over
...
ordinary content per CSS 2.1 Appendix E.
Improves Talking Points Memo.
2015-05-12 17:32:59 -07:00
Patrick Walton
3875c9db4a
layout: Support block-direction margins for inline-blocks.
...
Improves linux.com.
2015-05-11 17:49:12 -07:00
bors-servo
5a13cae064
Auto merge of #5991 - pcwalton:float-overflow-area, r=glennw
...
Makes qz.com visible.
In order to work around a compiler bug involving Sized, this patch moves
`store_overflow` to be a virtual method.
r? @glennw
<!-- Reviewable:start -->
[<img src="https://reviewable.io/review_button.png " height=40 alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/servo/5991 )
<!-- Reviewable:end -->
2015-05-11 16:08:46 -05:00
Patrick Walton
b026a8ecf6
layout: Store overflow for flows impacted by floats.
...
Makes qz.com visible.
In order to work around a compiler bug involving Sized, this patch moves
`store_overflow` to be a virtual method.
2015-05-11 12:59:55 -07:00
Patrick Walton
4b9cd4e65d
layout: Implement <table width>
and <center>
.
...
Improves Hacker News.
2015-05-11 12:53:45 -07:00
bors-servo
844ac2915e
Auto merge of #5997 - mbrubeck:table-direction, r=pcwalton
...
Table columns should be layed out according to the 'direction' property of the
table flow, regardless of the 'direction' property of any table-row,
table-rowgroup, etc. flows.
This fixes a number of the `direction-applies-to-*` tests in the CSS2.1 test
suite.
This also simplifies `propagate_column_inline_sizes_to_child` by separating
the code used for table cells from the code for non-cell flows.
r? @pcwalton
<!-- Reviewable:start -->
[<img src="https://reviewable.io/review_button.png " height=40 alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/servo/5997 )
<!-- Reviewable:end -->
2015-05-11 07:50:09 -05:00
Matt Brubeck
e36a498cfb
Fix direction of columns in mixed LTR/RTL tables.
...
Table columns should be layed out according to the 'direction' property of the
table flow, regardless of the 'direction' property of any table-row,
table-rowgroup, etc. flows.
This fixes a number of the `direction-applies-to-*` tests in the CSS2.1 test
suite.
This also simplifies `propagate_column_inline_sizes_to_child` by separating
the code used for table cells from the code for non-cell flows.
r? @pcwalton
2015-05-08 21:29:02 -07:00
Patrick Walton
614c877527
layout: Support vertical-align
for inline-blocks.
...
Improves Twitter.
2015-05-08 17:59:01 -07:00
Patrick Walton
7b92b99c6d
layout: Take the width
attribute of <img>
into account when
...
computing the intrinsic widths of the associated fragment.
Fixes sites that use spacer gifs for table layout, such as the comments
page on Hacker News.
2015-05-08 13:30:27 -07:00
Patrick Walton
b17b90c8df
layout: Implement inline margins.
...
Improves the Google SERPs.
We mark `html/rendering/replaced-elements/images/space.html` as failing.
This test tested whether `<img hspace>` and inline margins do the same
thing. Since this was trivially the case before (since we implemented
neither) and now is not, this test now fails.
2015-05-07 16:25:05 -07:00
James Gilbertson
455ac536af
Add a basic ref test for @viewport
2015-05-06 09:19:16 -06:00
bors-servo
7b87085c18
Auto merge of #5919 - pcwalton:inline-block-intrinsic-widths, r=mbrubeck
...
* Stop double-counting border and padding for inline-block fragments.
(Test case: `inline_block_border_intrinsic_size_a.html`.)
* Take clearance into account when determining intrinsic widths of
blocks containing floats.
Improves the Amazon headers.
r? @mbrubeck
<!-- Reviewable:start -->
[<img src="https://reviewable.io/review_button.png " height=40 alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/servo/5919 )
<!-- Reviewable:end -->
2015-05-04 13:37:24 -05:00
Ms2ger
b845ab4725
Submit the drawImage reftests to wpt.
2015-05-04 00:30:02 +02:00
Patrick Walton
33087497ac
layout: Fix a couple of issues relating to intrinsic widths of inline
...
blocks.
* Stop double-counting border and padding for inline-block fragments.
(Test case: `inline_block_border_intrinsic_size_a.html`.)
* Take clearance into account when determining intrinsic widths of
blocks containing floats.
Improves the Amazon headers.
2015-05-01 18:07:07 -07:00
Patrick Walton
986f81afa7
layout: Use the border box, not the margin box, for placement of block
...
formatting contexts.
Improves Amazon.
2015-05-01 15:11:46 -07:00
Ms2ger
bbd7cac371
Run absolute position reftests as part of test-wpt.
2015-04-30 17:44:59 +02:00
Ms2ger
031d4f0c2c
Start running reftests with wptrunner.
...
CC #5618 .
2015-04-30 14:49:06 +02:00
Matt Brubeck
50f982bb0c
Fix text-align left/right in RTL layout
2015-04-29 07:07:58 -07:00
Matt Brubeck
81e8f18662
Support text-align: start
and end
2015-04-29 07:07:58 -07:00
bors-servo
b6fc83cf2b
Auto merge of #5887 - pcwalton:border-collapse-missing-cells, r=mbrubeck
...
This was seen in Twitter and the Google SERPs (sometimes).
r? @mbrubeck
<!-- Reviewable:start -->
[<img src="https://reviewable.io/review_button.png " height=40 alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/servo/5887 )
<!-- Reviewable:end -->
2015-04-28 15:32:31 -05:00
Patrick Walton
577f1ea109
layout: Don't panic in border collapse when a row has fewer cells than
...
its previous sibling.
This was seen in Twitter and the Google SERPs (sometimes).
2015-04-28 13:16:01 -07:00
Matt Brubeck
cad5d8b670
Ignore border-spacing for tables with zero cells
2015-04-28 10:30:47 -07:00
Patrick Walton
44a30054a1
layout: Make margin: auto
work properly with tables.
...
Improves the Amazon home page.
2015-04-28 09:26:08 -07:00
bors-servo
2fd5ecf3d7
Auto merge of #5694 - pcwalton:anonymous-table-objects, r=mbrubeck
...
Improves Facebook Timeline.
r? @mbrubeck
<!-- Reviewable:start -->
[<img src="https://reviewable.io/review_button.png " height=40 alt="Review on Reviewable"/>](https://reviewable.io/reviews/servo/servo/5694 )
<!-- Reviewable:end -->
2015-04-28 07:13:53 -05:00
Patrick Walton
a92baf7683
layout: Make the style-specified width affect minimum width.
...
Improves the front page of Google.
2015-04-27 18:32:28 -07:00
Patrick Walton
f0954f8799
layout: Generate anonymous table objects as necessary per CSS 2.1 §
...
17.2.1.
Improves Facebook Timeline.
2015-04-27 14:12:44 -07:00
Patrick Walton
48299a53cb
layout: Implement most of border-collapse
per CSS 2.1 § 17.6.2.
...
Known issues:
* Collapsed borders do not correctly affect the border-box of the table
itself.
* The content widths of all cells in a column and the content height of
all cells in a row is the same in this patch, but not in Gecko and
WebKit.
* Corners are not painted well. The spec does not say what to do here.
* Column spans are not handled well. The spec does not say what to do
here either.
2015-04-27 17:12:07 +02:00
Patrick Walton
79336d21b5
style: Disregard the size
attribute for input elements other than text
...
or password fields.
HTML5 § 4.10.5.3.2 doesn't explicitly say to do this, but all other
browser engines seem to do it.
Improves the Google home page.
2015-04-24 17:33:53 -07:00