Bug 698783 - Added importing of multicol tests from CSSWG with py script and checking in these new tests + script (Step 2b from dbarons comment#12) r?dbaron draft
authorNeerja Pancholi <npancholi@mozilla.com>
Sun, 14 Aug 2016 22:52:42 -0700
changeset 400561 223cc6f1c269e43e5a7ef623a648c7e4c0da4ed8
parent 400479 bc7ed7bd9995bfd5b36879d9928647f5cf0451a1
child 528242 a3ff61eba9a9f0f85f054606284e91d03091fc54
push id26191
push userbmo:npancholi@mozilla.com
push dateMon, 15 Aug 2016 05:53:22 +0000
reviewersdbaron
bugs698783
milestone51.0a1
Bug 698783 - Added importing of multicol tests from CSSWG with py script and checking in these new tests + script (Step 2b from dbarons comment#12) r?dbaron MozReview-Commit-ID: FuX0voPWlvk
layout/reftests/w3c-css/import-tests.py
layout/reftests/w3c-css/received/css-multicol-1/multicol-basic-001.html
layout/reftests/w3c-css/received/css-multicol-1/multicol-basic-002.html
layout/reftests/w3c-css/received/css-multicol-1/multicol-basic-003.html
layout/reftests/w3c-css/received/css-multicol-1/multicol-basic-004.html
layout/reftests/w3c-css/received/css-multicol-1/multicol-basic-ref.html
layout/reftests/w3c-css/received/css-multicol-1/multicol-block-clip-001-ref.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-block-clip-001.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-block-clip-002-ref.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-block-clip-002.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-br-inside-avoidcolumn-001.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-br-inside-avoidcolumn-ref.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-break-000-ref.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-break-000.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-break-001-ref.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-break-001.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-clip-001-ref.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-clip-001.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-clip-002-ref.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-clip-002.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-collapsing-001-ref.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-collapsing-001.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-columns-001-ref.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-columns-001.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-columns-002.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-columns-003.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-columns-004.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-columns-005.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-columns-006.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-columns-007.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-columns-invalid-001-ref.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-columns-invalid-001.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-columns-invalid-002.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-columns-toolong-001.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-containing-001-ref.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-containing-001.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-containing-002-ref.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-containing-002.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-count-001.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-count-002-ref.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-count-002.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-count-computed-001.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-count-computed-002.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-count-computed-003-ref.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-count-computed-003.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-count-computed-004-ref.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-count-computed-004.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-count-computed-005.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-count-computed-2-ref.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-count-computed-ref.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-count-large-001.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-count-large-002.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-count-large-2-ref.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-count-large-ref.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-count-negative-001.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-count-negative-002.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-count-non-integer-001.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-count-non-integer-002.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-count-non-integer-003.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-fill-000-ref.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-fill-000.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-fill-001-ref.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-fill-001.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-fill-auto-001-ref.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-fill-auto-001.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-fill-auto-002-ref.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-fill-auto-002.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-fill-auto-003-ref.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-fill-auto-003.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-fill-auto-block-children-001.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-fill-auto-block-children-002-ref.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-fill-auto-block-children-002.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-fill-auto-block-children-ref.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-fill-auto.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-fill-balance-001-ref.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-fill-balance-001.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-fill-ref.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-gap-000-ref.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-gap-000.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-gap-001-ref.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-gap-001.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-gap-002-ref.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-gap-002.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-gap-003.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-gap-fraction-001-ref.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-gap-fraction-001.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-gap-large-001-ref.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-gap-large-001.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-gap-large-002-ref.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-gap-large-002.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-gap-negative-001.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-height-001-ref.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-height-001.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-height-block-child-001-ref.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-height-block-child-001.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-inherit-001-ref.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-inherit-001.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-inherit-002-ref.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-inherit-002.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-inherit-003.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-inherit-004.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-inherit-3-ref.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-inherit-4-ref.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-list-item-001-ref.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-list-item-001.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-margin-001.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-margin-002.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-margin-child-001-ref.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-margin-child-001.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-nested-002-ref.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-nested-002.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-nested-005-ref.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-nested-005.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-nested-column-rule-001-ref.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-nested-column-rule-001.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-nested-margin-001-ref.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-nested-margin-001.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-nested-margin-002-ref.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-nested-margin-002.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-nested-margin-003-ref.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-nested-margin-003.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-nested-margin-004-ref.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-nested-margin-004.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-nested-margin-005.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-overflow-000-ref.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-overflow-000.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-overflowing-001-ref.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-overflowing-001.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-red.png
layout/reftests/w3c-css/received/css-multicol-1/multicol-reduce-000-ref.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-reduce-000.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-rule-000-ref.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-rule-000.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-rule-001-ref.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-rule-001.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-rule-002.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-rule-003-ref.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-rule-003.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-rule-004-ref.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-rule-004.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-rule-color-001-ref.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-rule-color-001.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-rule-color-inherit-001-ref.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-rule-color-inherit-001.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-rule-color-inherit-002.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-rule-dashed-000-ref.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-rule-dashed-000.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-rule-dotted-000-ref.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-rule-dotted-000.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-rule-double-000-ref.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-rule-double-000.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-rule-fraction-001-ref.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-rule-fraction-001.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-rule-fraction-002-ref.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-rule-fraction-002.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-rule-fraction-003.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-rule-fraction-3-ref.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-rule-groove-000-ref.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-rule-groove-000.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-rule-hidden-000-ref.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-rule-hidden-000.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-rule-inset-000.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-rule-large-001-ref.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-rule-large-001.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-rule-none-000.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-rule-outset-000.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-rule-percent-001.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-rule-px-001.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-rule-ref.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-rule-ridge-000-ref.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-rule-ridge-000.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-rule-samelength-001-ref.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-rule-samelength-001.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-rule-shorthand-001.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-rule-solid-000-ref.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-rule-solid-000.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-rule-stacking-001.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-rule-stacking-ref.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-rule-style-groove-001-ref.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-rule-style-groove-001.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-rule-style-inset-001.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-rule-style-outset-001.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-rule-style-ridge-001-ref.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-rule-style-ridge-001.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-shorthand-001.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-span-000-ref.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-span-000.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-span-all-001-ref.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-span-all-001.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-span-all-002-ref.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-span-all-002.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-span-all-003.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-span-all-block-sibling-003.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-span-all-block-sibling-3-ref.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-span-all-child-001-ref.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-span-all-child-001.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-span-all-child-002-ref.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-span-all-child-002.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-span-all-margin-001-ref.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-span-all-margin-001.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-span-all-margin-002-ref.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-span-all-margin-002.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-span-all-margin-bottom-001-ref.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-span-all-margin-bottom-001.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-span-all-margin-nested-001-ref.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-span-all-margin-nested-001.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-span-all-margin-nested-002.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-span-all-margin-nested-003.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-span-all-margin-nested-3-ref.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-span-all-margin-nested-firstchild-001.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-span-all-margin-nested-firstchild-ref.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-span-float-001-ref.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-span-float-001.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-span-none-001-ref.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-span-none-001.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-table-cell-001-ref.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-table-cell-001.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-table-cell-height-001-ref.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-table-cell-height-001.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-table-cell-height-002.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-table-cell-vertical-align-001.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-table-cell-vertical-align-ref.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-width-001-ref.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-width-001.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-width-002-ref.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-width-002.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-width-003.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-width-count-001.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-width-count-002.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-width-ems-001.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-width-ems-ref.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-width-invalid-001-ref.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-width-invalid-001.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-width-large-001.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-width-large-002.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-width-negative-001.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-width-small-001-ref.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-width-small-001.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-zero-height-001-ref.xht
layout/reftests/w3c-css/received/css-multicol-1/multicol-zero-height-001.xht
layout/reftests/w3c-css/received/css-multicol-1/ref-filled-green-100px-square.xht
layout/reftests/w3c-css/received/css-multicol-1/support/1x1-green.png
layout/reftests/w3c-css/received/css-multicol-1/support/1x1-lime.png
layout/reftests/w3c-css/received/css-multicol-1/support/1x1-maroon.png
layout/reftests/w3c-css/received/css-multicol-1/support/1x1-navy.png
layout/reftests/w3c-css/received/css-multicol-1/support/1x1-red.png
layout/reftests/w3c-css/received/css-multicol-1/support/1x1-white.png
layout/reftests/w3c-css/received/css-multicol-1/support/60x60-gg-rr.png
layout/reftests/w3c-css/received/css-multicol-1/support/60x60-green.png
layout/reftests/w3c-css/received/css-multicol-1/support/60x60-red.png
layout/reftests/w3c-css/received/css-multicol-1/support/a-green.css
layout/reftests/w3c-css/received/css-multicol-1/support/b-green.css
layout/reftests/w3c-css/received/css-multicol-1/support/black20x20.png
layout/reftests/w3c-css/received/css-multicol-1/support/c-red.css
layout/reftests/w3c-css/received/css-multicol-1/support/cat.png
layout/reftests/w3c-css/received/css-multicol-1/support/import-green.css
layout/reftests/w3c-css/received/css-multicol-1/support/import-red.css
layout/reftests/w3c-css/received/css-multicol-1/support/pattern-grg-rgr-grg.png
layout/reftests/w3c-css/received/css-multicol-1/support/pattern-grg-rrg-rgg.png
layout/reftests/w3c-css/received/css-multicol-1/support/pattern-rgr-grg-rgr.png
layout/reftests/w3c-css/received/css-multicol-1/support/pattern-tr.png
layout/reftests/w3c-css/received/css-multicol-1/support/red20x20.png
layout/reftests/w3c-css/received/css-multicol-1/support/square-purple.png
layout/reftests/w3c-css/received/css-multicol-1/support/square-teal.png
layout/reftests/w3c-css/received/css-multicol-1/support/square-white.png
layout/reftests/w3c-css/received/css-multicol-1/support/swatch-blue.png
layout/reftests/w3c-css/received/css-multicol-1/support/swatch-gray.png
layout/reftests/w3c-css/received/css-multicol-1/support/swatch-green.png
layout/reftests/w3c-css/received/css-multicol-1/support/swatch-lime.png
layout/reftests/w3c-css/received/css-multicol-1/support/swatch-navy.png
layout/reftests/w3c-css/received/css-multicol-1/support/swatch-orange.png
layout/reftests/w3c-css/received/css-multicol-1/support/swatch-pink.png
layout/reftests/w3c-css/received/css-multicol-1/support/swatch-purple.png
layout/reftests/w3c-css/received/css-multicol-1/support/swatch-red.png
layout/reftests/w3c-css/received/css-multicol-1/support/swatch-white.png
layout/reftests/w3c-css/received/css-multicol-1/support/swatch-yellow.png
layout/reftests/w3c-css/received/css-multicol-1/support/test-bl.png
layout/reftests/w3c-css/received/css-multicol-1/support/test-br.png
layout/reftests/w3c-css/received/css-multicol-1/support/test-outer.png
layout/reftests/w3c-css/received/css-multicol-1/support/test-tl.png
layout/reftests/w3c-css/received/css-multicol-1/support/test-tr.png
layout/reftests/w3c-css/received/import.log
layout/reftests/w3c-css/received/reftest.list
--- a/layout/reftests/w3c-css/import-tests.py
+++ b/layout/reftests/w3c-css/import-tests.py
@@ -29,16 +29,17 @@ import re
 # test only once, even if it covers more than one spec.)
 
 # But for now, let's just import a few sets of tests.
 
 gSubtrees = [
     os.path.join("css-namespaces-3"),
     os.path.join("css-conditional-3"),
     os.path.join("css-values-3"),
+    os.path.join("css-multicol-1"),
 ]
 
 gPrefixedProperties = [
     "column-count",
     "column-fill",
     "column-gap",
     "column-rule",
     "column-rule-color",
@@ -159,63 +160,72 @@ def map_file(fn, spec):
     filemap[fn] = destname
     load_flags_for(fn, spec)
     copy_file(destname, fn, destname, False)
     copy_support_files(destname, os.path.dirname(fn), spec)
     return destname
 
 def load_flags_for(fn, spec):
     global gTestFlags
-    document = get_document_for(fn)
     destname = os.path.join(spec, os.path.basename(fn))
     gTestFlags[destname] = []
 
+    if not (is_html(fn) or is_xml(fn)):
+        return
+    document = get_document_for(fn)
     for meta in document.getElementsByTagName("meta"):
         name = meta.getAttribute("name")
         if name == "flags":
             gTestFlags[destname] = meta.getAttribute("content").split()
 
 def is_html(fn):
     return fn.endswith(".htm") or fn.endswith(".html")
 
+def is_xml(fn):
+    return fn.endswith(".xht") or fn.endswith(".xml")
+
 def get_document_for(fn):
     document = None # an xml.dom.minidom document
     if is_html(fn):
         # An HTML file
         f = open(fn, "rb")
         parser = html5lib.HTMLParser(tree=html5lib.treebuilders.getTreeBuilder("dom"))
         document = parser.parse(f)
         f.close()
     else:
         # An XML file
         document = xml.dom.minidom.parse(fn)
     return document
 
 def add_test_items(fn, spec):
+    if spec is None:
+        for subtree in gSubtrees:
+            if fn.startswith(subtree):
+                spec = os.path.basename(subtree)
+                break
+        else:
+            raise StandardError("Could not associate test " + fn + " with specification")
+    if not (is_html(fn) or is_xml(fn)):
+        map_file(fn, spec)
+        return None
     document = get_document_for(fn)
     refs = []
     notrefs = []
     for link in document.getElementsByTagName("link"):
         rel = link.getAttribute("rel")
         if rel == "match":
             arr = refs
         elif rel == "mismatch":
             arr = notrefs
         else:
             continue
-        arr.append(os.path.join(os.path.dirname(fn), str(link.getAttribute("href"))))
+        if str(link.getAttribute("href")) != "":
+            arr.append(os.path.join(os.path.dirname(fn), str(link.getAttribute("href"))))
     if len(refs) > 1:
         raise StandardError("Need to add code to specify which reference we want to match.")
-    if spec is None:
-        for subtree in gSubtrees:
-            if fn.startswith(subtree):
-                spec = os.path.basename(subtree)
-                break
-        else:
-            raise StandardError("Could not associate test " + fn + " with specification")
     for ref in refs:
         tests.append(["==", map_file(fn, spec), map_file(ref, spec)])
     for notref in notrefs:
         tests.append(["!=", map_file(fn, spec), map_file(notref, spec)])
     # Add chained references too
     for ref in refs:
         add_test_items(ref, spec=spec)
     for notref in notrefs:
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-basic-001.html
@@ -0,0 +1,70 @@
+<!DOCTYPE html>
+<html>
+<!-- Submitted from TestTWF Paris -->
+<head>
+	<meta charset="utf-8">
+	<title>CSS Test: Multi-column element via -moz-columns: [integer]</title>
+	<link rel="author" title="Anselm Hannemann" href="mailto:info@anselm-hannemann.com"/>
+	<link rel="author" title="Håkon Wium Lie" href="mailto:howcome@opera.com"/>
+	<link rel="help" href="http://www.w3.org/TR/css3-multicol/#-moz-columns"/>
+	<link rel="match" href="reference/multicol-basic-ref.html"/>
+	<meta name="flags" content="ahem"/>
+	<link rel="reviewer" title="Elika J Etemad" href="http://fantasai.inkedblade.net/contact">
+
+<style type="text/css">
+@font-face {
+  font-family: Ahem;
+  src: url("../../../fonts/Ahem.ttf");
+}
+</style>
+	<style type="text/css">
+		.multicol-wrapper>*{
+			font-family: Ahem;
+		}
+
+		div.multicol-wrapper{
+			border: thin solid black;
+			display: inline-block;
+			margin: 1em auto;
+			width: 360px;
+		}
+
+		.multicol-basic-ref{
+			background: yellow;
+			width: 360px;
+			-moz-columns: 3;
+			-moz-column-gap: 0;
+			-moz-column-rule: none;
+		}
+
+		.multicol-basic-ref-item{
+			background: #000;
+		}
+
+		.item-1{
+			background: purple;
+			color: purple;
+		}
+
+		.item-2{
+			background: orange;
+			color: orange;
+		}
+
+		.item-3{
+			background: blue;
+			color: blue;
+		}
+	</style>
+</head>
+<body>
+<p>Test passes if there are three vertical stripes in the yellow box below: 1st purple, 2nd orange, 3rd blue.</p>
+<div class="multicol-wrapper">
+	<div class="multicol-basic-ref">
+		<span class="multicol-basic-ref-item item-1">XXXX XXXX XXXX XXXX XXXX XXXX XXXX</span>
+		<span class="multicol-basic-ref-item item-2">XXXX XXXX XXXX XXXX XXXX XXXX XXXX</span>
+		<span class="multicol-basic-ref-item item-3">XXXX XXXX XXXX XXXX XXXX XXXX XXXX</span>
+	</div>
+</div>
+</body>
+</html>
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-basic-002.html
@@ -0,0 +1,70 @@
+<!DOCTYPE html>
+<html>
+<!-- Submitted from TestTWF Paris -->
+<head>
+	<meta charset="utf-8">
+	<title>CSS Test: Multi-column element via -moz-column-count: [integer]</title>
+	<link rel="author" title="Anselm Hannemann" href="mailto:info@anselm-hannemann.com"/>
+	<link rel="author" title="Håkon Wium Lie" href="mailto:howcome@opera.com"/>
+	<link rel="help" href="http://www.w3.org/TR/css3-multicol/#-moz-columns"/>
+	<link rel="match" href="reference/multicol-basic-ref.html"/>
+	<meta name="flags" content="ahem"/>
+	<link rel="reviewer" title="Elika J Etemad" href="http://fantasai.inkedblade.net/contact">
+
+<style type="text/css">
+@font-face {
+  font-family: Ahem;
+  src: url("../../../fonts/Ahem.ttf");
+}
+</style>
+	<style type="text/css">
+		.multicol-wrapper>*{
+			font-family: Ahem;
+		}
+
+		div.multicol-wrapper{
+			border: thin solid black;
+			display: inline-block;
+			margin: 1em auto;
+			width: 360px;
+		}
+
+		.multicol-basic-ref{
+			background: yellow;
+			width: 360px;
+			-moz-column-count: 3;
+			-moz-column-gap: 0;
+			-moz-column-rule: none;
+		}
+
+		.multicol-basic-ref-item{
+			background: #000;
+		}
+
+		.item-1{
+			background: purple;
+			color: purple;
+		}
+
+		.item-2{
+			background: orange;
+			color: orange;
+		}
+
+		.item-3{
+			background: blue;
+			color: blue;
+		}
+	</style>
+</head>
+<body>
+<p>Test passes if there are three vertical stripes in the yellow box below: 1st purple, 2nd orange, 3rd blue.</p>
+<div class="multicol-wrapper">
+	<div class="multicol-basic-ref">
+		<span class="multicol-basic-ref-item item-1">XXXX XXXX XXXX XXXX XXXX XXXX XXXX</span>
+		<span class="multicol-basic-ref-item item-2">XXXX XXXX XXXX XXXX XXXX XXXX XXXX</span>
+		<span class="multicol-basic-ref-item item-3">XXXX XXXX XXXX XXXX XXXX XXXX XXXX</span>
+	</div>
+</div>
+</body>
+</html>
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-basic-003.html
@@ -0,0 +1,70 @@
+<!DOCTYPE html>
+<html>
+<!-- Submitted from TestTWF Paris -->
+<head>
+	<meta charset="utf-8">
+	<title>CSS Test: Multi-column element via -moz-columns: [width]</title>
+	<link rel="author" title="Anselm Hannemann" href="mailto:info@anselm-hannemann.com"/>
+	<link rel="author" title="Håkon Wium Lie" href="mailto:howcome@opera.com"/>
+	<link rel="help" href="http://www.w3.org/TR/css3-multicol/#-moz-columns"/>
+	<link rel="match" href="reference/multicol-basic-ref.html"/>
+	<meta name="flags" content="ahem"/>
+	<link rel="reviewer" title="Elika J Etemad" href="http://fantasai.inkedblade.net/contact">
+
+<style type="text/css">
+@font-face {
+  font-family: Ahem;
+  src: url("../../../fonts/Ahem.ttf");
+}
+</style>
+	<style type="text/css">
+		.multicol-wrapper>*{
+			font-family: Ahem;
+		}
+
+		div.multicol-wrapper{
+			border: thin solid black;
+			display: inline-block;
+			margin: 1em auto;
+			width: 360px;
+		}
+
+		.multicol-basic-ref{
+			background: yellow;
+			width: 360px;
+			-moz-columns: 120px;
+			-moz-column-gap: 0;
+			-moz-column-rule: none;
+		}
+
+		.multicol-basic-ref-item{
+			background: #000;
+		}
+
+		.item-1{
+			background: purple;
+			color: purple;
+		}
+
+		.item-2{
+			background: orange;
+			color: orange;
+		}
+
+		.item-3{
+			background: blue;
+			color: blue;
+		}
+	</style>
+</head>
+<body>
+<p>Test passes if there are three vertical stripes in the yellow box below: 1st purple, 2nd orange, 3rd blue.</p>
+<div class="multicol-wrapper">
+	<div class="multicol-basic-ref">
+		<span class="multicol-basic-ref-item item-1">XXXX XXXX XXXX XXXX XXXX XXXX XXXX</span>
+		<span class="multicol-basic-ref-item item-2">XXXX XXXX XXXX XXXX XXXX XXXX XXXX</span>
+		<span class="multicol-basic-ref-item item-3">XXXX XXXX XXXX XXXX XXXX XXXX XXXX</span>
+	</div>
+</div>
+</body>
+</html>
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-basic-004.html
@@ -0,0 +1,70 @@
+<!DOCTYPE html>
+<html>
+<!-- Submitted from TestTWF Paris -->
+<head>
+	<meta charset="utf-8">
+	<title>CSS Test: Multi-column element via -moz-column-width: [width]</title>
+	<link rel="author" title="Anselm Hannemann" href="mailto:info@anselm-hannemann.com"/>
+	<link rel="author" title="Håkon Wium Lie" href="mailto:howcome@opera.com"/>
+	<link rel="help" href="http://www.w3.org/TR/css3-multicol/#-moz-columns"/>
+	<link rel="match" href="reference/multicol-basic-ref.html"/>
+	<meta name="flags" content="ahem"/>
+	<link rel="reviewer" title="Elika J Etemad" href="http://fantasai.inkedblade.net/contact">
+
+<style type="text/css">
+@font-face {
+  font-family: Ahem;
+  src: url("../../../fonts/Ahem.ttf");
+}
+</style>
+	<style type="text/css">
+		.multicol-wrapper>*{
+			font-family: Ahem;
+		}
+
+		div.multicol-wrapper{
+			border: thin solid black;
+			display: inline-block;
+			margin: 1em auto;
+			width: 360px;
+		}
+
+		.multicol-basic-ref{
+			background: yellow;
+			width: 360px;
+			-moz-column-width: 120px;
+			-moz-column-gap: 0;
+			-moz-column-rule: none;
+		}
+
+		.multicol-basic-ref-item{
+			background: #000;
+		}
+
+		.item-1{
+			background: purple;
+			color: purple;
+		}
+
+		.item-2{
+			background: orange;
+			color: orange;
+		}
+
+		.item-3{
+			background: blue;
+			color: blue;
+		}
+	</style>
+</head>
+<body>
+<p>Test passes if there are three vertical stripes in the yellow box below: 1st purple, 2nd orange, 3rd blue.</p>
+<div class="multicol-wrapper">
+	<div class="multicol-basic-ref">
+		<span class="multicol-basic-ref-item item-1">XXXX XXXX XXXX XXXX XXXX XXXX XXXX</span>
+		<span class="multicol-basic-ref-item item-2">XXXX XXXX XXXX XXXX XXXX XXXX XXXX</span>
+		<span class="multicol-basic-ref-item item-3">XXXX XXXX XXXX XXXX XXXX XXXX XXXX</span>
+	</div>
+</div>
+</body>
+</html>
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-basic-ref.html
@@ -0,0 +1,77 @@
+<!DOCTYPE html>
+<html>
+<!-- Submitted from TestTWF Paris -->
+<head>
+	<title>CSS Test reference</title>
+	<link rel="author" title="Anselm Hannemann" href="mailto:info@anselm-hannemann.com"/>
+	<link rel="reviewer" title="Elika J Etemad" href="http://fantasai.inkedblade.net/contact">
+	<meta name="flags" content="ahem"/>
+
+<style type="text/css">
+@font-face {
+  font-family: Ahem;
+  src: url("../../../fonts/Ahem.ttf");
+}
+</style>
+	<style type="text/css">
+		.multicol-wrapper>*{
+			font-family: Ahem;
+		}
+
+		div.multicol-wrapper{
+			border: thin solid black;
+			display: inline-block;
+			margin: 1em auto;
+			width: 360px;
+		}
+
+		.multicol-basic-ref{
+			background: yellow;
+			width: 360px;
+			border-spacing: 0;
+			border-collapse: collapse;
+			padding: 0;
+		}
+
+		.multicol-basic-ref td{
+			padding: 0;
+		}
+		.multicol-basic-ref-item{
+			padding: 0;
+			width: 120px;
+			background: #000;
+			border-spacing: 0;
+			border-collapse: collapse;
+			display: inline;
+			border: none;
+		}
+
+		.item-1{
+			background: purple;
+			color: purple;
+		}
+
+		.item-2{
+			background: orange;
+			color: orange;
+		}
+
+		.item-3{
+			background: blue;
+			color: blue;
+		}
+	</style>
+</head>
+<body>
+<p>Test passes if there are three vertical stripes in the yellow box below: 1st purple, 2nd orange, 3rd blue.</p>
+<div class="multicol-wrapper">
+	<table class="multicol-basic-ref">
+		<tr>
+			<td><div class="multicol-basic-ref-item item-1">XXXX XXXX XXXX XXXX XXXX XXXX XXXX</div></td>
+			<td><div class="multicol-basic-ref-item item-2">XXXX XXXX XXXX XXXX XXXX XXXX XXXX</div></td>
+			<td><div class="multicol-basic-ref-item item-3">XXXX XXXX XXXX XXXX XXXX XXXX XXXX</div></td>
+		</tr>
+	</table>
+</div>
+</body>
+</html>
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-block-clip-001-ref.xht
@@ -0,0 +1,33 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+  <title>CSS Reftest Reference</title>
+  <link rel="author" title="Opera Software ASA" href="http://www.opera.com/" />
+  <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2013-07-24 -->
+  <meta name="flags" content="image" />
+  <style type="text/css"><![CDATA[
+  table
+  {
+  border-spacing: 0px;
+  border: gray solid 1em;
+  font: 1.25em/1 serif;
+  }
+
+  td
+  {
+  padding: 0;
+  width: 3em;
+  }
+
+  td + td {width: 8em;}
+
+  img, td {vertical-align: top;}
+  ]]></style>
+ </head>
+ <body>
+  <table>
+    <tr>
+      <td><img src="support/swatch-blue.png" width="40" height="80" alt="Image download support must be enabled" /><img src="support/black20x20.png" width="50" height="20" alt="Image download support must be enabled" /></td><td><img src="support/swatch-orange.png" width="40" height="80" alt="Image download support must be enabled" /></td>
+    </tr></table>
+ </body>
+</html>
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-block-clip-001.xht
@@ -0,0 +1,55 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+  <title>CSS Multi-column Layout Test: Overflowed content inside multicol element</title>
+  <link rel="author" title="Opera Software ASA" href="http://www.opera.com/" />
+  <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2013-07-24 -->
+  <link rel="help" href="http://www.w3.org/TR/css3-multicol/#overflow-inside-multicol-elements" title="8.1. Overflow inside multicol elements" />
+  <link rel="match" href="multicol-block-clip-001-ref.xht"/>
+  <meta name="flags" content="ahem" />
+  <meta name="assert" content="This test checks that content in the normal flow that extends into column gaps is clipped in the middle of the column gap." />
+<style type="text/css"><![CDATA[
+@font-face {
+  font-family: Ahem;
+  src: url("../../../fonts/Ahem.ttf");
+}
+]]></style>
+  <style type="text/css"><![CDATA[
+  div
+  {
+  border: gray solid 1em;
+  font: 1.25em/1 Ahem;
+  orphans: 1;
+  widows: 1;
+  width: 11em;
+
+  -moz-column-count: 4;
+  -moz-column-gap: 1em;
+  }
+
+  h4
+  {
+  background: black;
+  color: black;
+  font: inherit;
+  margin: 0;
+  width: 11em;
+  }
+
+  #first-column {color: blue;}
+
+  #second-column {color: orange;}
+
+  #third-column, #fourth-column {color: white;}
+  ]]></style>
+ </head>
+ <body>
+  <div>
+    <span id="first-column"> ab cd ef gh </span>
+    <h4> 1234567890123 </h4>
+    <span id="second-column"> ij kl mn oq </span>
+    <span id="third-column"> ab cd ef gh </span>
+    <span id="fourth-column"> rs tu vw xy </span>
+  </div>
+ </body>
+</html>
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-block-clip-002-ref.xht
@@ -0,0 +1,54 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+  <title>CSS Reftest Reference</title>
+  <link rel="author" title="Opera Software ASA" href="http://www.opera.com/" />
+  <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2013-07-24 -->
+  <meta name="flags" content="image" />
+  <style type="text/css"><![CDATA[
+  div
+  {
+  font: 1.25em/1 serif;
+  border: 1em solid gray;
+  width: 11em;
+  height: 6em;
+  position: relative;
+  }
+
+  img {position: absolute;}
+
+  img#black {top: 4em;}
+
+  img#first-orange {top: 5em;}
+
+  img#second-orange {left: 4em;}
+
+  img#first-pink
+  {
+  left: 4em;
+  top: 3em;
+  }
+
+  img#second-pink {left: 8em;}
+
+  img#yellow
+  {
+  left: 8em;
+  top: 1em;
+  }
+  ]]></style>
+ </head>
+ <body>
+
+  <div>
+	<img id="blue" src="support/swatch-blue.png" width="40" height="80" alt="Image download support must be enabled" />
+	<img id="black" src="support/black20x20.png" width="70" height="20" alt="Image download support must be enabled" />
+	<img id="first-orange" src="support/swatch-orange.png" width="40" height="20" alt="Image download support must be enabled" />
+	<img id="second-orange" src="support/swatch-orange.png" width="40" height="60" alt="Image download support must be enabled" />
+	<img id="first-pink" src="support/swatch-pink.png" width="40" height="60" alt="Image download support must be enabled" />
+	<img id="second-pink" src="support/swatch-pink.png" width="40" height="20" alt="Image download support must be enabled" />
+	<img id="yellow" src="support/swatch-yellow.png" width="40" height="80" alt="Image download support must be enabled" />
+  </div>
+
+ </body>
+</html>
\ No newline at end of file
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-block-clip-002.xht
@@ -0,0 +1,57 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+  <title>CSS Multi-column Layout Test: Overflowed content inside and outside multicol element</title>
+  <link rel="author" title="Opera Software ASA" href="http://www.opera.com/" />
+  <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2013-07-24 -->
+  <link rel="help" href="http://www.w3.org/TR/css3-multicol/#overflow-inside-multicol-elements" title="8.1. Overflow inside multicol elements" />
+  <link rel="match" href="multicol-block-clip-002-ref.xht"/>
+  <meta name="flags" content="ahem" />
+  <meta name="assert" content="This test checks that content in the normal flow that extends into column gaps is clipped in the middle of the column gap." />
+<style type="text/css"><![CDATA[
+@font-face {
+  font-family: Ahem;
+  src: url("../../../fonts/Ahem.ttf");
+}
+]]></style>
+  <style type="text/css"><![CDATA[
+  div
+  {
+  border: gray solid 1em;
+  font: 1.25em/1 Ahem;
+  orphans: 1;
+  widows: 1;
+  width: 11em;
+
+  -moz-column-count: 3;
+  -moz-column-gap: 1em;
+  }
+
+  h4
+  {
+  background: black;
+  color: black;
+  font: inherit;
+  margin: 0;
+  width: 11em;
+  }
+
+  #first-column {color: blue;}
+
+  #second-column {color: orange;}
+
+  #third-column {color: pink;}
+
+  #fourth-column {color: yellow;}
+  ]]></style>
+ </head>
+ <body>
+  <div>
+    <span id="first-column"> ab cd ef gh </span>
+    <h4> 1234567890123 </h4>
+    <span id="second-column"> ij kl mn oq </span>
+    <span id="third-column"> ab cd ef gh </span>
+    <span id="fourth-column"> rs tu vw xy </span>
+  </div>
+ </body>
+</html>
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-br-inside-avoidcolumn-001.xht
@@ -0,0 +1,51 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
+"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+<title>multicol | break-inside: avoid-column</title>
+<link rel="author" title="Opera Software ASA" href="http://www.opera.com/"/>
+<link rel="help" href="http://www.w3.org/TR/css3-multicol/#column-breaks"/>
+<link rel="match" href="multicol-br-inside-avoidcolumn-ref.xht"/>
+<meta name="flags" content=""/>
+<style type="text/css"><![CDATA[
+html {
+	width: 800px;
+	background: white;
+}
+body {
+	background: black;
+	-moz-column-count: 3;
+	-moz-column-gap: 0;
+	-moz-column-fill: auto;
+	height: 300px;
+}
+h1 {
+	-moz-column-span: all;
+	color: white;
+}
+div { background: red;
+	height: 150px;
+	break-inside: avoid-column;
+}
+span {
+	float: left;
+}
+]]></style>
+</head>
+<body>
+<h1>You should not see the word FAIL</h1>
+
+<div>
+	<span>FAIL</span>
+</div>
+
+<div>
+	<span>FAIL</span>
+</div>
+
+<div>
+	<span>FAIL</span>
+</div>
+
+</body>
+</html>
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-br-inside-avoidcolumn-ref.xht
@@ -0,0 +1,30 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
+"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+<title>multicol | break-inside: avoid-column</title>
+<link rel="author" title="Opera Software ASA" href="http://www.opera.com/"/>
+<style type="text/css"><![CDATA[
+html {
+	width: 800px;
+	background: white;
+}
+h1 {
+	color: white;
+	margin-top: 0;
+	padding-top: 0.66em;
+}
+div {
+	height: 450px;
+	background: black;
+	height: 300px;
+}
+]]></style>
+</head>
+<body>
+<div>
+	<h1>You should not see the word FAIL</h1>
+</div>
+
+</body>
+</html>
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-break-000-ref.xht
@@ -0,0 +1,36 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+  <title>CSS Reftest Reference</title>
+  <link rel="author" title="Hakon Wium Lie" href="mailto:howcome@opera.com" />
+  <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2013-08-25 -->
+  <meta name="flags" content="ahem image" />
+<style type="text/css"><![CDATA[
+@font-face {
+  font-family: Ahem;
+  src: url("../../../fonts/Ahem.ttf");
+}
+]]></style>
+  <style type="text/css"><![CDATA[
+  div
+  {
+  background-color: yellow;
+  margin-bottom: 0.5em;
+  font: 1.25em/1 Ahem;
+  height: 3em;
+  width: 10em;
+  }
+
+  img {vertical-align: top;}
+  ]]></style>
+ </head>
+ <body>
+
+  <p>Test passes if the 2 horizontal bars are <strong>identical</strong>.</p>
+
+  <div><img src="support/black20x20.png" alt="Image download support must be enabled" /> <img src="support/black20x20.png" alt="Image download support must be enabled" /> <img src="support/black20x20.png" alt="Image download support must be enabled" /></div>
+
+  <div><img src="support/black20x20.png" alt="Image download support must be enabled" /> <img src="support/black20x20.png" alt="Image download support must be enabled" /> <img src="support/black20x20.png" alt="Image download support must be enabled" /></div>
+
+ </body>
+</html>
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-break-000.xht
@@ -0,0 +1,60 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+  <title>CSS Multi-column Layout Test: break-after: column (basic)</title>
+  <link rel="author" title="Hakon Wium Lie" href="mailto:howcome@opera.com" />
+  <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2013-08-25 -->
+  <link rel="help" href="http://www.w3.org/TR/css3-multicol/#break-before-break-after-break-inside" title="5.1. 'break-before', 'break-after', 'break-inside'" />
+  <link rel="match" href="multicol-break-000-ref.xht" />
+  <meta name="flags" content="ahem image" />
+  <meta name="assert" content="This test checks that basic support of 'break-after: column'." />
+<style type="text/css"><![CDATA[
+@font-face {
+  font-family: Ahem;
+  src: url("../../../fonts/Ahem.ttf");
+}
+]]></style>
+  <style type="text/css"><![CDATA[
+  div#test, div#reference
+  {
+  background-color: yellow;
+  margin-bottom: 0.5em;
+  font: 1.25em/1 Ahem;
+  height: 3em;
+  width: 10em;
+  }
+
+  div#test
+  {
+  -moz-column-fill: auto;
+  -moz-column-gap: 0;
+  -moz-column-width: 2em;
+
+  /*
+
+  N == 5;
+
+  W == 2em;
+
+  */
+  }
+
+  div#test > div {break-after: column;}
+
+  img {vertical-align: top;}
+  ]]></style>
+ </head>
+ <body>
+
+  <p>Test passes if the 2 horizontal bars are <strong>identical</strong>.</p>
+
+  <div id="test">
+      <div>A</div>
+      <div>B</div>
+      <div>C</div>
+  </div>
+
+  <div id="reference"><img src="support/black20x20.png" alt="Image download support must be enabled" /> <img src="support/black20x20.png" alt="Image download support must be enabled" /> <img src="support/black20x20.png" alt="Image download support must be enabled" /></div>
+
+ </body>
+</html>
\ No newline at end of file
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-break-001-ref.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+  <title>CSS Reftest Reference</title>
+  <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2013-09-14 -->
+  <meta name="flags" content="ahem image" />
+<style type="text/css"><![CDATA[
+@font-face {
+  font-family: Ahem;
+  src: url("../../../fonts/Ahem.ttf");
+}
+]]></style>
+  <style type="text/css"><![CDATA[
+  div
+  {
+  background-color: yellow;
+  margin-bottom: 0.5em;
+  font: 1.25em/1 Ahem;
+  height: 3em;
+  width: 10em;
+  }
+
+  img {vertical-align: top;}
+  ]]></style>
+ </head>
+ <body>
+
+  <p>Test passes if the 2 horizontal bars are <strong>identical</strong>.</p>
+
+  <div>&nbsp; <img src="support/black20x20.png" alt="Image download support must be enabled" /> <img src="support/black20x20.png" alt="Image download support must be enabled" /> <img src="support/black20x20.png" alt="Image download support must be enabled" /></div>
+
+  <div>&nbsp; <img src="support/black20x20.png" alt="Image download support must be enabled" /> <img src="support/black20x20.png" alt="Image download support must be enabled" /> <img src="support/black20x20.png" alt="Image download support must be enabled" /></div>
+
+ </body>
+</html>
\ No newline at end of file
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-break-001.xht
@@ -0,0 +1,59 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+  <title>CSS Multi-column Layout Test: break-before: column (basic)</title>
+  <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2013-09-14 -->
+  <link rel="help" href="http://www.w3.org/TR/css3-multicol/#break-before-break-after-break-inside" title="5.1. 'break-before', 'break-after', 'break-inside'" />
+  <link rel="match" href="multicol-break-001-ref.xht" />
+  <meta name="flags" content="ahem image" />
+  <meta name="assert" content="This test checks that basic support of 'break-before: column'." />
+<style type="text/css"><![CDATA[
+@font-face {
+  font-family: Ahem;
+  src: url("../../../fonts/Ahem.ttf");
+}
+]]></style>
+  <style type="text/css"><![CDATA[
+  div#test, div#reference
+  {
+  background-color: yellow;
+  margin-bottom: 0.5em;
+  font: 1.25em/1 Ahem;
+  height: 3em;
+  width: 10em;
+  }
+
+  div#test
+  {
+  -moz-column-fill: auto;
+  -moz-column-gap: 0;
+  -moz-column-width: 2em;
+
+  /*
+
+  N == 5;
+
+  W == 2em;
+
+  */
+  }
+
+  div#test > div {break-before: column;}
+
+  img {vertical-align: top;}
+  ]]></style>
+ </head>
+ <body>
+
+  <p>Test passes if the 2 horizontal bars are <strong>identical</strong>.</p>
+
+  <div id="test">
+      <div>A</div>
+      <div>B</div>
+      <div>C</div>
+  </div>
+
+  <div id="reference">&nbsp; <img src="support/black20x20.png" alt="Image download support must be enabled" /> <img src="support/black20x20.png" alt="Image download support must be enabled" /> <img src="support/black20x20.png" alt="Image download support must be enabled" /></div>
+
+ </body>
+</html>
\ No newline at end of file
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-clip-001-ref.xht
@@ -0,0 +1,31 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+  <title>CSS Reftest Reference</title>
+  <link rel="author" title="Opera Software ASA" href="http://www.opera.com/" />
+  <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2013-07-24 -->
+  <meta name="flags" content="image" />
+  <style type="text/css"><![CDATA[
+  div
+  {
+  border: gray solid 1em;
+  font: 1.25em/1 serif;
+  width: 11em;
+  }
+
+  img
+  {
+  position: relative;
+  vertical-align: top;
+  }
+
+  img + img {left: 3em;}
+
+  img + img + img {left: 6em;}
+  ]]></style>
+ </head>
+ <body>
+  <div><img src="support/black20x20.png" width="40" height="60" alt="Image download support must be enabled" /><img src="support/black20x20.png" width="40" height="60" alt="Image download support must be enabled" /><img src="support/swatch-blue.png" width="40" height="40" alt="Image download support must be enabled" />
+    </div>
+ </body>
+</html>
\ No newline at end of file
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-clip-001.xht
@@ -0,0 +1,50 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+  <title>CSS Multi-column Layout Test: overflowed content inside and outside multicol element</title>
+  <link rel="author" title="Opera Software ASA" href="http://www.opera.com/" />
+  <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2013-07-24 -->
+  <link rel="help" href="http://www.w3.org/TR/css3-multicol/#overflow-inside-multicol-elements" title="8.1. Overflow inside multicol elements" />
+  <link rel="match" href="multicol-clip-001-ref.xht" />
+  <meta name="flags" content="ahem" />
+  <meta name="assert" content="This test checks that content in the normal flow can extend into column gap before it reaches its middle. In this test, the 'l' and 'c' glyphs are painted into the left half of the column gap; the 'l' and 'e' glyphs extend outside the last column box at the edge of the multi-column and are therefore rendered thanks to the default 'overflow: visible' declaration." />
+<style type="text/css"><![CDATA[
+@font-face {
+  font-family: Ahem;
+  src: url("../../../fonts/Ahem.ttf");
+}
+]]></style>
+  <style type="text/css"><![CDATA[
+  div
+  {
+  background: white;
+  border: gray solid 1em;
+  color: blue;
+  font: 1.25em/1 Ahem;
+  orphans: 1;
+  widows: 1;
+  width: 11em;
+
+  -moz-column-count: 3;
+  -moz-column-gap: 4em;
+  }
+
+  span {color: black;}
+  ]]></style>
+ </head>
+ <body>
+
+  <div>
+    <span>
+    bl ac
+    bl ac
+    </span>
+
+    <span>
+    bl ac
+    </span>
+    bl ue
+  </div>
+
+ </body>
+</html>
\ No newline at end of file
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-clip-002-ref.xht
@@ -0,0 +1,31 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+  <title>CSS Reftest Reference</title>
+  <link rel="author" title="Opera Software ASA" href="http://www.opera.com/" />
+  <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2013-07-25 -->
+  <meta name="flags" content="image" />
+  <style type="text/css"><![CDATA[
+  div
+  {
+  border: gray solid 1em;
+  font: 1.25em/1 serif;
+  width: 11em;
+  }
+
+  img
+  {
+  position: relative;
+  vertical-align: top;
+  }
+
+  img + img {left: 3em;}
+
+  img + img + img {left: 6em;}
+  ]]></style>
+ </head>
+ <body>
+  <div><img src="support/black20x20.png" width="40" height="60" alt="Image download support must be enabled" /><img src="support/black20x20.png" width="40" height="60" alt="Image download support must be enabled" /><img src="support/swatch-blue.png" width="20" height="40" alt="Image download support must be enabled" />
+    </div>
+ </body>
+</html>
\ No newline at end of file
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-clip-002.xht
@@ -0,0 +1,51 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+  <title>CSS Multi-column Layout Test: overflowed content inside and outside multicol element</title>
+  <link rel="author" title="Opera Software ASA" href="http://www.opera.com/" />
+  <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2013-07-25 -->
+  <link rel="help" href="http://www.w3.org/TR/css3-multicol/#overflow-inside-multicol-elements" title="8.1. Overflow inside multicol elements" />
+  <link rel="match" href="multicol-clip-002-ref.xht" />
+  <meta name="flags" content="ahem" />
+  <meta name="assert" content="This test checks that content in the normal flow can extend into column gap before it reaches its middle. In this test, the 'l' and 'c' glyphs are painted into the left half of the column gap; the 'l' and 'e' glyphs extend outside the last column box at the edges of the multi-column and are therefore hidden thanks to the 'overflow: hidden' declaration." />
+<style type="text/css"><![CDATA[
+@font-face {
+  font-family: Ahem;
+  src: url("../../../fonts/Ahem.ttf");
+}
+]]></style>
+  <style type="text/css"><![CDATA[
+  div
+  {
+  background: white;
+  border: gray solid 1em;
+  color: blue;
+  font: 1.25em/1 Ahem;
+  orphans: 1;
+  overflow: hidden;
+  widows: 1;
+  width: 11em;
+
+  -moz-column-count: 3;
+  -moz-column-gap: 4em;
+  }
+
+  span {color: black;}
+  ]]></style>
+ </head>
+ <body>
+
+  <div>
+    <span>
+	bl ac
+	bl ac
+    </span>
+
+    <span>
+	bl ac
+    </span>
+	bl ue
+  </div>
+
+ </body>
+</html>
\ No newline at end of file
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-collapsing-001-ref.xht
@@ -0,0 +1,31 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+  <title>CSS Reftest Reference</title>
+  <link rel="author" title="Opera Software ASA" href="http://www.opera.com/" />
+  <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2013-07-25 -->
+  <meta name="flags" content="image" />
+  <style type="text/css"><![CDATA[
+  div
+  {
+  background-color: black;
+  border: black solid 1px;
+  font: 1.25em/1 serif;
+  padding: 1em;
+  width: 8em;
+  }
+
+  img
+  {
+  position: relative;
+  vertical-align: top;
+  }
+
+  img + img + img {left: 2em;}
+  ]]></style>
+ </head>
+ <body>
+  <div><img src="support/swatch-yellow.png" width="40" height="20" alt="Image download support must be enabled" /><img src="support/swatch-yellow.png" width="20" height="60" alt="Image download support must be enabled" /><img src="support/swatch-yellow.png" width="20" height="60" alt="Image download support must be enabled" />
+  </div>
+ </body>
+</html>
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-collapsing-001.xht
@@ -0,0 +1,56 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+  <title>CSS Multi-column Layout Test: no margin collapsing with its first child block box</title>
+  <link rel="author" title="Opera Software ASA" href="http://www.opera.com/" />
+  <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2013-07-25 -->
+  <link rel="help" href="http://www.w3.org/TR/css3-multicol/#the-multi-column-model" title="2. The multi-column model" />
+  <link rel="match" href="multicol-collapsing-001-ref.xht"/>
+  <meta name="flags" content="ahem" />
+  <meta name="assert" content="This test checks that the top margin of the first child block box of a multicol element does not collapse with the margin top of such multicol element." />
+<style type="text/css"><![CDATA[
+@font-face {
+  font-family: Ahem;
+  src: url("../../../fonts/Ahem.ttf");
+}
+]]></style>
+  <style type="text/css"><![CDATA[
+  body > div
+  {
+  background-color: black;
+  border: black solid 1px;
+  font: 1.25em/1 Ahem;
+  width: 10em;
+  }
+
+  div > div
+  {
+  background-color: yellow;
+  color: black;
+  margin: 1em;
+  width: 8em;
+  orphans: 1;
+  widows: 1;
+
+  -moz-column-count: 3;
+  -moz-column-gap: 1em;
+  }
+
+  h4
+  {
+  font: inherit;
+  margin: 1em 0 0;
+  }
+  ]]></style>
+ </head>
+ <body>
+  <div>
+    <div>
+	  <h4>ab cd</h4>
+      ef gh
+      ij kl
+      mn oq
+    </div>
+  </div>
+ </body>
+</html>
\ No newline at end of file
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-columns-001-ref.xht
@@ -0,0 +1,30 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+  <title>CSS Reftest Reference</title>
+  <link rel="author" title="Opera Software ASA" href="http://www.opera.com/" />
+  <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2013-07-25 -->
+  <meta name="flags" content="ahem" />
+<style type="text/css"><![CDATA[
+@font-face {
+  font-family: Ahem;
+  src: url("../../../fonts/Ahem.ttf");
+}
+]]></style>
+  <style type="text/css"><![CDATA[
+  body {width: 600px;}
+
+  div
+  {
+  background-color: yellow;
+  color: black;
+  font: 1.25em/1 Ahem;
+  orphans: 1;
+  widows: 1;
+  }
+  ]]></style>
+ </head>
+ <body>
+  <div>d da d da d da d da d da d da dam&nbsp; dam&nbsp; dam&nbsp; dam&nbsp; dam&nbsp; dam&nbsp; dame dame dame dame dame dame damerdamerdamerdamerdamerdamer<br />d da d da d da d da d da&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; dam&nbsp; dam&nbsp; dam&nbsp; dam&nbsp; dam&nbsp; &nbsp;&nbsp;&nbsp;&nbsp;&nbsp; dame dame dame dame dame &nbsp;&nbsp;&nbsp;&nbsp;&nbsp; damerdamerdamerdamerdamer &nbsp;&nbsp;&nbsp;&nbsp;</div>
+ </body>
+</html>
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-columns-001.xht
@@ -0,0 +1,48 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+  <title>CSS Multi-column Layout Test: -moz-columns shorthand (basic)</title>
+  <link rel="author" title="Opera Software ASA" href="http://www.opera.com/" />
+  <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2013-07-25 -->
+  <link rel="help" href="http://www.w3.org/TR/css3-multicol/#the-number-and-width-of--moz-columns" title="3. The number and width of -moz-columns" />
+  <link rel="match" href="multicol--moz-columns-001-ref.xht" />
+  <meta name="flags" content="ahem" />
+  <meta name="assert" content="This test checks that '-moz-columns: 100px 6' shorthand correctly set '-moz-column-width' and '-moz-column-count' properties." />
+<style type="text/css"><![CDATA[
+@font-face {
+  font-family: Ahem;
+  src: url("../../../fonts/Ahem.ttf");
+}
+]]></style>
+  <style type="text/css"><![CDATA[
+  body {width: 600px;}
+
+  div
+  {
+  background-color: yellow;
+  color: black;
+  font: 1.25em/1 Ahem;
+  orphans: 1;
+  widows: 1;
+
+  -moz-columns: 100px 6;
+  -moz-column-gap: 0;
+  }
+  ]]></style>
+ </head>
+ <body>
+  <div>
+	d da dam dame damer
+	d da dam dame damer
+	d da dam dame damer
+	d da dam dame damer
+	d da dam dame damer
+	d da dam dame damer
+	d da dam dame damer
+	d da dam dame damer
+	d da dam dame damer
+	d da dam dame damer
+	d da dam dame damer
+  </div>
+ </body>
+</html>
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-columns-002.xht
@@ -0,0 +1,48 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+  <title>CSS Multi-column Layout Test: -moz-columns shorthand (basic)</title>
+  <link rel="author" title="Opera Software ASA" href="http://www.opera.com/" />
+  <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2013-07-25 -->
+  <link rel="help" href="http://www.w3.org/TR/css3-multicol/#the-number-and-width-of--moz-columns" title="3. The number and width of -moz-columns" />
+  <link rel="match" href="multicol--moz-columns-001-ref.xht" />
+  <meta name="flags" content="ahem" />
+  <meta name="assert" content="This test checks that '-moz-columns: 6 100px' shorthand correctly set '-moz-column-width' and '-moz-column-count' properties." />
+<style type="text/css"><![CDATA[
+@font-face {
+  font-family: Ahem;
+  src: url("../../../fonts/Ahem.ttf");
+}
+]]></style>
+  <style type="text/css"><![CDATA[
+  body {width: 600px;}
+
+  div
+  {
+  background-color: yellow;
+  color: black;
+  font: 1.25em/1 Ahem;
+  orphans: 1;
+  widows: 1;
+
+  -moz-columns: 6 100px;
+  -moz-column-gap: 0;
+  }
+  ]]></style>
+ </head>
+ <body>
+  <div>
+	d da dam dame damer
+	d da dam dame damer
+	d da dam dame damer
+	d da dam dame damer
+	d da dam dame damer
+	d da dam dame damer
+	d da dam dame damer
+	d da dam dame damer
+	d da dam dame damer
+	d da dam dame damer
+	d da dam dame damer
+  </div>
+ </body>
+</html>
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-columns-003.xht
@@ -0,0 +1,48 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+  <title>CSS Multi-column Layout Test: -moz-columns shorthand (basic)</title>
+  <link rel="author" title="Opera Software ASA" href="http://www.opera.com/" />
+  <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2013-07-25 -->
+  <link rel="help" href="http://www.w3.org/TR/css3-multicol/#the-number-and-width-of--moz-columns" title="3. The number and width of -moz-columns" />
+  <link rel="match" href="multicol--moz-columns-001-ref.xht" />
+  <meta name="flags" content="ahem" />
+  <meta name="assert" content="This test checks that '-moz-columns: 100px auto' shorthand correctly set '-moz-column-width' and '-moz-column-count' properties." />
+<style type="text/css"><![CDATA[
+@font-face {
+  font-family: Ahem;
+  src: url("../../../fonts/Ahem.ttf");
+}
+]]></style>
+  <style type="text/css"><![CDATA[
+  body {width: 600px;}
+
+  div
+  {
+  background-color: yellow;
+  color: black;
+  font: 1.25em/1 Ahem;
+  orphans: 1;
+  widows: 1;
+
+  -moz-columns: 100px auto;
+  -moz-column-gap: 0;
+  }
+  ]]></style>
+ </head>
+ <body>
+  <div>
+	d da dam dame damer
+	d da dam dame damer
+	d da dam dame damer
+	d da dam dame damer
+	d da dam dame damer
+	d da dam dame damer
+	d da dam dame damer
+	d da dam dame damer
+	d da dam dame damer
+	d da dam dame damer
+	d da dam dame damer
+  </div>
+ </body>
+</html>
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-columns-004.xht
@@ -0,0 +1,48 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+  <title>CSS Multi-column Layout Test: -moz-columns shorthand (basic)</title>
+  <link rel="author" title="Opera Software ASA" href="http://www.opera.com/" />
+  <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2013-07-25 -->
+  <link rel="help" href="http://www.w3.org/TR/css3-multicol/#the-number-and-width-of--moz-columns" title="3. The number and width of -moz-columns" />
+  <link rel="match" href="multicol--moz-columns-001-ref.xht" />
+  <meta name="flags" content="ahem" />
+  <meta name="assert" content="This test checks that '-moz-columns: auto 100px' shorthand correctly set '-moz-column-width' and '-moz-column-count' properties." />
+<style type="text/css"><![CDATA[
+@font-face {
+  font-family: Ahem;
+  src: url("../../../fonts/Ahem.ttf");
+}
+]]></style>
+  <style type="text/css"><![CDATA[
+  body {width: 600px;}
+
+  div
+  {
+  background-color: yellow;
+  color: black;
+  font: 1.25em/1 Ahem;
+  orphans: 1;
+  widows: 1;
+
+  -moz-columns: auto 100px;
+  -moz-column-gap: 0;
+  }
+  ]]></style>
+ </head>
+ <body>
+  <div>
+	d da dam dame damer
+	d da dam dame damer
+	d da dam dame damer
+	d da dam dame damer
+	d da dam dame damer
+	d da dam dame damer
+	d da dam dame damer
+	d da dam dame damer
+	d da dam dame damer
+	d da dam dame damer
+	d da dam dame damer
+  </div>
+ </body>
+</html>
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-columns-005.xht
@@ -0,0 +1,48 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+  <title>CSS Multi-column Layout Test: -moz-columns shorthand (basic)</title>
+  <link rel="author" title="Opera Software ASA" href="http://www.opera.com/" />
+  <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2013-07-25 -->
+  <link rel="help" href="http://www.w3.org/TR/css3-multicol/#the-number-and-width-of--moz-columns" title="3. The number and width of -moz-columns" />
+  <link rel="match" href="multicol--moz-columns-001-ref.xht" />
+  <meta name="flags" content="ahem" />
+  <meta name="assert" content="This test checks that '-moz-columns: 6' shorthand correctly set '-moz-column-width' and '-moz-column-count' properties. '-moz-columns: 6' is equivalent to '-moz-column-width: auto' and '-moz-column-count: 6'." />
+<style type="text/css"><![CDATA[
+@font-face {
+  font-family: Ahem;
+  src: url("../../../fonts/Ahem.ttf");
+}
+]]></style>
+  <style type="text/css"><![CDATA[
+  body {width: 600px;}
+
+  div
+  {
+  background-color: yellow;
+  color: black;
+  font: 1.25em/1 Ahem;
+  orphans: 1;
+  widows: 1;
+
+  -moz-columns: 6;
+  -moz-column-gap: 0;
+  }
+  ]]></style>
+ </head>
+ <body>
+  <div>
+	d da dam dame damer
+	d da dam dame damer
+	d da dam dame damer
+	d da dam dame damer
+	d da dam dame damer
+	d da dam dame damer
+	d da dam dame damer
+	d da dam dame damer
+	d da dam dame damer
+	d da dam dame damer
+	d da dam dame damer
+  </div>
+ </body>
+</html>
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-columns-006.xht
@@ -0,0 +1,48 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+  <title>CSS Multi-column Layout Test: -moz-columns shorthand (basic)</title>
+  <link rel="author" title="Opera Software ASA" href="http://www.opera.com/" />
+  <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2013-07-25 -->
+  <link rel="help" href="http://www.w3.org/TR/css3-multicol/#the-number-and-width-of--moz-columns" title="3. The number and width of -moz-columns" />
+  <link rel="match" href="multicol--moz-columns-001-ref.xht" />
+  <meta name="flags" content="ahem" />
+  <meta name="assert" content="This test checks that '-moz-columns: 6 auto' shorthand correctly set '-moz-column-width' and '-moz-column-count' properties." />
+<style type="text/css"><![CDATA[
+@font-face {
+  font-family: Ahem;
+  src: url("../../../fonts/Ahem.ttf");
+}
+]]></style>
+  <style type="text/css"><![CDATA[
+  body {width: 600px;}
+
+  div
+  {
+  background-color: yellow;
+  color: black;
+  font: 1.25em/1 Ahem;
+  orphans: 1;
+  widows: 1;
+
+  -moz-columns: 6 auto;
+  -moz-column-gap: 0;
+  }
+  ]]></style>
+ </head>
+ <body>
+  <div>
+	d da dam dame damer
+	d da dam dame damer
+	d da dam dame damer
+	d da dam dame damer
+	d da dam dame damer
+	d da dam dame damer
+	d da dam dame damer
+	d da dam dame damer
+	d da dam dame damer
+	d da dam dame damer
+	d da dam dame damer
+  </div>
+ </body>
+</html>
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-columns-007.xht
@@ -0,0 +1,48 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+  <title>CSS Multi-column Layout Test: -moz-columns shorthand (basic)</title>
+  <link rel="author" title="Opera Software ASA" href="http://www.opera.com/" />
+  <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2013-07-25 -->
+  <link rel="help" href="http://www.w3.org/TR/css3-multicol/#the-number-and-width-of--moz-columns" title="3. The number and width of -moz-columns" />
+  <link rel="match" href="multicol--moz-columns-001-ref.xht" />
+  <meta name="flags" content="ahem" />
+  <meta name="assert" content="This test checks that '-moz-columns: auto 6' shorthand correctly set '-moz-column-width' and '-moz-column-count' properties." />
+<style type="text/css"><![CDATA[
+@font-face {
+  font-family: Ahem;
+  src: url("../../../fonts/Ahem.ttf");
+}
+]]></style>
+  <style type="text/css"><![CDATA[
+  body {width: 600px;}
+
+  div
+  {
+  background-color: yellow;
+  color: black;
+  font: 1.25em/1 Ahem;
+  orphans: 1;
+  widows: 1;
+
+  -moz-columns: auto 6;
+  -moz-column-gap: 0;
+  }
+  ]]></style>
+ </head>
+ <body>
+  <div>
+	d da dam dame damer
+	d da dam dame damer
+	d da dam dame damer
+	d da dam dame damer
+	d da dam dame damer
+	d da dam dame damer
+	d da dam dame damer
+	d da dam dame damer
+	d da dam dame damer
+	d da dam dame damer
+	d da dam dame damer
+  </div>
+ </body>
+</html>
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-columns-invalid-001-ref.xht
@@ -0,0 +1,32 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+  <title>CSS Reftest Reference</title>
+  <link rel="author" title="Opera Software ASA" href="http://www.opera.com/" />
+  <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2013-07-26 -->
+  <meta name="flags" content="image" />
+  <style type="text/css"><![CDATA[
+  table
+  {
+  background-color: yellow;
+  border-spacing: 0px;
+  border: gray solid 1em;
+  font: 1.25em/1 serif;
+  }
+
+  td {padding: 0 1em 0 0;}
+
+  img, td {vertical-align: top;}
+  ]]></style>
+ </head>
+ <body>
+  <table>
+    <tr>
+      <td><img src="support/black20x20.png" width="40" height="40" alt="Image download support must be enabled" /></td>
+      <td><img src="support/swatch-blue.png" width="40" height="40" alt="Image download support must be enabled" /></td>
+      <td><img src="support/swatch-blue.png" width="40" height="40" alt="Image download support must be enabled" /></td>
+      <td><img src="support/black20x20.png" width="40" height="40" alt="Image download support must be enabled" /></td>
+    </tr>
+  </table>
+ </body>
+</html>
\ No newline at end of file
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-columns-invalid-001.xht
@@ -0,0 +1,48 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+  <title>CSS Multi-column Layout Test: invalid -moz-columns shorthand</title>
+  <link rel="author" title="Opera Software ASA" href="http://www.opera.com/" />
+  <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2013-07-26 -->
+  <link rel="help" href="http://www.w3.org/TR/css3-multicol/#the-number-and-width-of--moz-columns" title="3. The number and width of -moz-columns" />
+  <link rel="match" href="multicol--moz-columns-invalid-001-ref.xht" />
+  <meta name="flags" content="ahem invalid" />
+  <meta name="assert" content="This test checks that '-moz-columns: 8 normal' is invalid (generating a parsing error) and therefore will be ignored." />
+<style type="text/css"><![CDATA[
+@font-face {
+  font-family: Ahem;
+  src: url("../../../fonts/Ahem.ttf");
+}
+]]></style>
+  <style type="text/css"><![CDATA[
+  div
+  {
+  background-color: yellow;
+  border: gray solid 1em;
+  color: black;
+  font: 1.25em/1 Ahem;
+  orphans: 1;
+  widows: 1;
+  width: 12em;
+
+  -moz-column-count: 4;
+  -moz-column-gap: 0;
+  -moz-columns: 8 normal;
+  }
+
+  span {color: blue;}
+  ]]></style>
+ </head>
+ <body>
+  <div>
+  bl ac
+    <span>
+    bl ue
+    </span>
+    <span>
+    bl ue
+    </span>
+  bl ac
+  </div>
+ </body>
+</html>
\ No newline at end of file
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-columns-invalid-002.xht
@@ -0,0 +1,56 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+
+  <!--
+  Original, initial filename of this test was
+  multicol--moz-columns-toolong-002.xht
+  and it should be filename-renamed
+  multicol--moz-columns-invalid-002.xht
+  -->
+
+  <title>CSS Multi-column Layout Test: invalid -moz-columns shorthand</title>
+  <link rel="author" title="Opera Software ASA" href="http://www.opera.com/" />
+  <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2013-07-26 -->
+  <link rel="help" href="http://www.w3.org/TR/css3-multicol/#the-number-and-width-of--moz-columns" title="3. The number and width of -moz-columns" />
+  <link rel="match" href="multicol--moz-columns-invalid-001-ref.xht" />
+  <meta name="flags" content="ahem invalid" />
+  <meta name="assert" content="This test checks that '-moz-columns: 8 auto 6em' is invalid (generating a parsing error) and therefore will be ignored." />
+<style type="text/css"><![CDATA[
+@font-face {
+  font-family: Ahem;
+  src: url("../../../fonts/Ahem.ttf");
+}
+]]></style>
+  <style type="text/css"><![CDATA[
+  div
+  {
+  background-color: yellow;
+  border: gray solid 1em;
+  color: black;
+  font: 1.25em/1 Ahem;
+  orphans: 1;
+  widows: 1;
+  width: 12em;
+
+  -moz-column-count: 4;
+  -moz-column-gap: 0;
+  -moz-columns: 8 auto 6em;
+  }
+
+  span {color: blue;}
+  ]]></style>
+ </head>
+ <body>
+  <div>
+  bl ac
+    <span>
+    bl ue
+    </span>
+    <span>
+    bl ue
+    </span>
+  bl ac
+  </div>
+ </body>
+</html>
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-columns-toolong-001.xht
@@ -0,0 +1,47 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+  <title>CSS Multi-column Layout Test: narrower inline content inside wider colum box</title>
+  <link rel="author" title="Opera Software ASA" href="http://www.opera.com/" />
+  <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2013-07-26 -->
+  <link rel="help" href="http://www.w3.org/TR/css3-multicol/#the-number-and-width-of--moz-columns" title="3. The number and width of -moz-columns" />
+  <link rel="match" href="multicol--moz-columns-invalid-001-ref.xht"/>
+  <meta name="flags" content="ahem" />
+  <meta name="assert" content="This test checks the rendering of inline content (2em) inside wider (3em) column boxes." />
+<style type="text/css"><![CDATA[
+@font-face {
+  font-family: Ahem;
+  src: url("../../../fonts/Ahem.ttf");
+}
+]]></style>
+  <style type="text/css"><![CDATA[
+  div
+  {
+  background-color: yellow;
+  border: gray solid 1em;
+  color: black;
+  font: 1.25em/1 Ahem;
+  orphans: 1;
+  widows: 1;
+  width: 12em;
+
+  -moz-column-count: 4;
+  -moz-column-gap: 0;
+  }
+
+  span {color: blue;}
+  ]]></style>
+ </head>
+ <body>
+  <div>
+  bl ac
+    <span>
+    bl ue
+    </span>
+    <span>
+    bl ue
+    </span>
+  bl ac
+  </div>
+ </body>
+</html>
\ No newline at end of file
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-containing-001-ref.xht
@@ -0,0 +1,31 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+  <title>CSS Reftest Reference</title>
+  <link rel="author" title="Opera Software ASA" href="http://www.opera.com/" />
+  <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2013-07-27 -->
+  <meta name="flags" content="image" />
+  <style type="text/css"><![CDATA[
+  table
+  {
+  background-color: yellow;
+  border-spacing: 0px;
+  border: gray solid 1em;
+  font: 1.25em/1 serif;
+  }
+
+  td {padding: 0 2em 0 0;}
+
+  img, td {vertical-align: top;}
+  ]]></style>
+ </head>
+ <body>
+  <table>
+    <tr>
+      <td><img src="support/black20x20.png" width="40" height="40" alt="Image download support must be enabled" /></td>
+      <td><img src="support/black20x20.png" width="40" height="40" alt="Image download support must be enabled" /></td>
+      <td><img src="support/black20x20.png" width="40" height="40" alt="Image download support must be enabled" /></td>
+    </tr>
+  </table>
+ </body>
+</html>
\ No newline at end of file
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-containing-001.xht
@@ -0,0 +1,55 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+  <title>CSS Multi-column Layout Test: a column box can not act as containing block for elements with 'position: absolute'</title>
+  <link rel="author" title="Opera Software ASA" href="http://www.opera.com/" />
+  <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2013-07-27 -->
+  <link rel="help" href="http://www.w3.org/TR/css3-multicol/#the-multi-column-model" title="2. The multi-column model" />
+  <link rel="match" href="multicol-containing-001-ref.xht"/>
+  <meta name="flags" content="ahem" />
+  <meta name="assert" content="This test checks that a column box does not establish containing block for elements with 'position: absolute'." />
+<style type="text/css"><![CDATA[
+@font-face {
+  font-family: Ahem;
+  src: url("../../../fonts/Ahem.ttf");
+}
+]]></style>
+  <style type="text/css"><![CDATA[
+  div
+  {
+  background-color: yellow;
+  border: gray solid 1em;
+  color: black;
+  font: 1.25em/1 Ahem;
+  orphans: 1;
+  widows: 1;
+  width: 12em;
+
+  -moz-column-count: 3;
+  -moz-column-gap: 0;
+  }
+
+  span
+  {
+  color: red;
+  position: absolute;
+  top: -1em;
+  }
+
+  /*
+  In this test, the initial containing block establishes containing block
+  for such red span. Therefore, the 2 short red stripes should be
+  positioned out of view, just outside the top edge of viewport.
+  */
+
+  ]]></style>
+ </head>
+ <body>
+  <div>
+  bl ac
+  <span>re dd</span>
+  bl ac
+  bl ac
+  </div>
+ </body>
+</html>
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-containing-002-ref.xht
@@ -0,0 +1,37 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+  <title>CSS Reftest Reference</title>
+  <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+  <meta name="flags" content="ahem" />
+<style type="text/css"><![CDATA[
+@font-face {
+  font-family: Ahem;
+  src: url("../../../fonts/Ahem.ttf");
+}
+]]></style>
+  <style type="text/css"><![CDATA[
+  div#inline-block
+  {
+  color: green;
+  display: inline-block;
+  font: 1.25em/1 Ahem;
+  }
+  ]]></style>
+ </head>
+ <body>
+
+  <div id="inline-block">
+
+      <div>4444 4444 4444 4444</div>
+      <div>1&nbsp;&nbsp;1 1&nbsp;&nbsp;1 1&nbsp;&nbsp;&nbsp; 1&nbsp;&nbsp;&nbsp;</div>
+      <div>1&nbsp;&nbsp;1 1&nbsp;&nbsp;1 1&nbsp;&nbsp;&nbsp; 1&nbsp;&nbsp;&nbsp;</div>
+      <div>4444 4444 4444 4444</div>
+      <div>1&nbsp;&nbsp;&nbsp; 1&nbsp;&nbsp;1 &nbsp;&nbsp;&nbsp;1 &nbsp;&nbsp;&nbsp;1</div>
+      <div>1&nbsp;&nbsp;&nbsp; 1&nbsp;&nbsp;1 &nbsp;&nbsp;&nbsp;1 &nbsp;&nbsp;&nbsp;1</div>
+      <div>1&nbsp;&nbsp;&nbsp; 1&nbsp;&nbsp;1 4444 4444</div>
+
+  </div>
+
+ </body>
+</html>
\ No newline at end of file
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-containing-002.xht
@@ -0,0 +1,44 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+  <title>CSS Multi-column Layout Test: a multi-column can act as containing block for elements with 'position: absolute'</title>
+  <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+  <link rel="help" href="http://www.w3.org/TR/css3-multicol/#the-multi-column-model" title="2. The multi-column model" />
+  <link rel="match" href="multicol-containing-002-ref.xht" />
+  <meta name="flags" content="ahem" />
+  <meta name="assert" content="This test checks that a multi-column element can establish containing block for elements with 'position: absolute'." />
+<style type="text/css"><![CDATA[
+@font-face {
+  font-family: Ahem;
+  src: url("../../../fonts/Ahem.ttf");
+}
+]]></style>
+  <style type="text/css"><![CDATA[
+  div
+  {
+  background-color: white;
+  color: green;
+  font: 1.25em/1 Ahem;
+  position: relative;
+  width: 19em;
+
+  -moz-column-count: 4;
+  -moz-column-gap: 1em;
+  }
+
+  span {color: red;}
+
+  img#white-overlapping
+  {
+  left: 11em;
+  position: absolute;
+  top: 1em;
+  }
+  ]]></style>
+ </head>
+ <body>
+
+  <div>4444 1&nbsp;&nbsp;1 1&nbsp;&nbsp;1 4444 1&nbsp;&nbsp; 1&nbsp;&nbsp; 1&nbsp;&nbsp; 4444 1&nbsp;&nbsp;1 1&nbsp;&nbsp;1 4444 1&nbsp;&nbsp;1  1&nbsp;&nbsp;1  1&nbsp;&nbsp;1 4444 1<span>RED</span> 1<span>RED</span> 4444 &nbsp;&nbsp;&nbsp;1  &nbsp;&nbsp;&nbsp;1 4444 4444 1&nbsp;&nbsp; 1&nbsp;&nbsp; 4444 &nbsp;&nbsp;&nbsp;1  &nbsp;&nbsp;&nbsp;1 4444 <img id="white-overlapping" src="support/swatch-white.png" width="60" height="40" alt="Image download support must be enabled" /></div>
+
+ </body>
+</html>
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-count-001.xht
@@ -0,0 +1,48 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+  <title>CSS Multi-column Layout Test: -moz-column-count (basic)</title>
+  <link rel="author" title="Opera Software ASA" href="http://www.opera.com/" />
+  <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2013-07-27 -->
+  <link rel="help" href="http://www.w3.org/TR/css3-multicol/#cc" title="3.2 '-moz-column-count'" />
+  <link rel="match" href="multicol--moz-columns-001-ref.xht" />
+  <meta name="flags" content="ahem" />
+  <meta name="assert" content="This test checks that setting '-moz-column-count' should accordingly create 6 column boxes. In this test, each column box should be exactly 100px wide." />
+<style type="text/css"><![CDATA[
+@font-face {
+  font-family: Ahem;
+  src: url("../../../fonts/Ahem.ttf");
+}
+]]></style>
+  <style type="text/css"><![CDATA[
+  body {width: 600px;}
+
+  div
+  {
+  background-color: yellow;
+  color: black;
+  font: 1.25em/1 Ahem;
+  orphans: 1;
+  widows: 1;
+
+  -moz-column-count: 6;
+  -moz-column-gap: 0;
+  }
+  ]]></style>
+ </head>
+ <body>
+  <div>
+	d da dam dame damer
+	d da dam dame damer
+	d da dam dame damer
+	d da dam dame damer
+	d da dam dame damer
+	d da dam dame damer
+	d da dam dame damer
+	d da dam dame damer
+	d da dam dame damer
+	d da dam dame damer
+	d da dam dame damer
+  </div>
+ </body>
+</html>
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-count-002-ref.xht
@@ -0,0 +1,40 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+  <title>CSS Reftest Reference</title>
+  <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2013-07-27 -->
+  <meta name="flags" content="image" />
+  <style type="text/css"><![CDATA[
+  div
+  {
+  background-color: yellow;
+  font: 1.25em/1 Ahem;
+  width: 21em;
+  }
+
+  img {vertical-align: top;}
+  ]]></style>
+ </head>
+ <body>
+
+ <div><img src="support/black20x20.png" width="420" height="20" alt="Image download support must be enabled" />
+
+ <img src="support/black20x20.png" width="20" height="20" alt="Image download support must be enabled" />&nbsp;&nbsp;&nbsp;&nbsp;<img src="support/black20x20.png" width="20" height="20" alt="Image download support must be enabled" />&nbsp;&nbsp;&nbsp;&nbsp;<img src="support/black20x20.png" width="20" height="20" alt="Image download support must be enabled" />&nbsp;&nbsp;&nbsp;&nbsp;<img src="support/black20x20.png" width="20" height="20" alt="Image download support must be enabled" />&nbsp;&nbsp;&nbsp;&nbsp;<img src="support/black20x20.png" width="20" height="20" alt="Image download support must be enabled" />
+
+ <img src="support/black20x20.png" width="20" height="20" alt="Image download support must be enabled" /> <img src="support/black20x20.png" width="40" height="20" alt="Image download support must be enabled" /> <img src="support/black20x20.png" width="20" height="20" alt="Image download support must be enabled" /> <img src="support/black20x20.png" width="40" height="20" alt="Image download support must be enabled" /> <img src="support/black20x20.png" width="20" height="20" alt="Image download support must be enabled" /> <img src="support/black20x20.png" width="80" height="20" alt="Image download support must be enabled" /> <img src="support/black20x20.png" width="80" height="20" alt="Image download support must be enabled" />
+
+ <img src="support/black20x20.png" width="20" height="20" alt="Image download support must be enabled" /> <img src="support/black20x20.png" width="40" height="20" alt="Image download support must be enabled" /> <img src="support/black20x20.png" width="20" height="20" alt="Image download support must be enabled" /> <img src="support/black20x20.png" width="40" height="20" alt="Image download support must be enabled" /> <img src="support/black20x20.png" width="20" height="20" alt="Image download support must be enabled" /> <img src="support/black20x20.png" width="80" height="20" alt="Image download support must be enabled" /> <img src="support/black20x20.png" width="80" height="20" alt="Image download support must be enabled" />
+
+ <img src="support/black20x20.png" width="20" height="20" alt="Image download support must be enabled" />&nbsp;&nbsp;&nbsp;&nbsp;<img src="support/black20x20.png" width="20" height="20" alt="Image download support must be enabled" />&nbsp;&nbsp;&nbsp;&nbsp;<img src="support/black20x20.png" width="20" height="20" alt="Image download support must be enabled" />&nbsp;&nbsp;&nbsp;&nbsp;<img src="support/black20x20.png" width="20" height="20" alt="Image download support must be enabled" />&nbsp;&nbsp;&nbsp;&nbsp;<img src="support/black20x20.png" width="20" height="20" alt="Image download support must be enabled" />
+
+ <img src="support/black20x20.png" width="20" height="20" alt="Image download support must be enabled" /> <img src="support/black20x20.png" width="80" height="20" alt="Image download support must be enabled" /> <img src="support/black20x20.png" width="40" height="20" alt="Image download support must be enabled" /> <img src="support/black20x20.png" width="80" height="20" alt="Image download support must be enabled" /> <img src="support/black20x20.png" width="80" height="20" alt="Image download support must be enabled" /> <img src="support/black20x20.png" width="20" height="20" alt="Image download support must be enabled" />
+
+ <img src="support/black20x20.png" width="20" height="20" alt="Image download support must be enabled" /> <img src="support/black20x20.png" width="80" height="20" alt="Image download support must be enabled" /> <img src="support/black20x20.png" width="40" height="20" alt="Image download support must be enabled" /> <img src="support/black20x20.png" width="80" height="20" alt="Image download support must be enabled" /> <img src="support/black20x20.png" width="80" height="20" alt="Image download support must be enabled" /> <img src="support/black20x20.png" width="20" height="20" alt="Image download support must be enabled" />
+
+ <img src="support/black20x20.png" width="20" height="20" alt="Image download support must be enabled" /> <img src="support/black20x20.png" width="80" height="20" alt="Image download support must be enabled" /> <img src="support/black20x20.png" width="40" height="20" alt="Image download support must be enabled" /> <img src="support/black20x20.png" width="20" height="20" alt="Image download support must be enabled" />&nbsp;&nbsp;&nbsp;&nbsp;<img src="support/black20x20.png" width="20" height="20" alt="Image download support must be enabled" />&nbsp;&nbsp;&nbsp;&nbsp;<img src="support/black20x20.png" width="20" height="20" alt="Image download support must be enabled" />
+
+ <img src="support/black20x20.png" width="420" height="20" alt="Image download support must be enabled" />
+ </div>
+
+ </body>
+</html>
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-count-002.xht
@@ -0,0 +1,42 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+  <title>CSS Multi-column Layout Test: -moz-column-count (basic)</title>
+  <link rel="author" title="Opera Software ASA" href="http://www.opera.com/" />
+  <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2013-07-27 -->
+  <link rel="help" href="http://www.w3.org/TR/css3-multicol/#cc" title="3.2 '-moz-column-count'" />
+  <link rel="match" href="multicol-count-002-ref.xht" />
+  <meta name="flags" content="ahem" />
+  <meta name="assert" content="This test checks that setting '-moz-column-count' should accordingly create 4 column boxes. In this test, each column box should be exactly 5em wide." />
+<style type="text/css"><![CDATA[
+@font-face {
+  font-family: Ahem;
+  src: url("../../../fonts/Ahem.ttf");
+}
+]]></style>
+  <style type="text/css"><![CDATA[
+  html {background-color: white;}
+
+  body
+  {
+  background-color: black;
+  font: 1.25em/1 Ahem;
+  padding-right: 1em;
+  width: 20em;
+  }
+
+  div
+  {
+  background-color: yellow;
+  color: black;
+
+  -moz-column-count: 4;
+  -moz-column-gap: 0;
+  }
+  ]]></style>
+ </head>
+ <body>
+  <div>55555 1&nbsp;&nbsp;&nbsp; 1 22&nbsp; 1 22&nbsp; 1&nbsp;&nbsp;&nbsp; 1 333 1 333 1 333 55555 55555 1&nbsp;&nbsp;&nbsp; 1 22&nbsp; 1 22&nbsp; 1&nbsp;&nbsp;&nbsp; 1 22&nbsp; 1 22&nbsp; 1 22&nbsp; 55555 55555 1&nbsp;&nbsp;&nbsp; 1 333 1 333 1&nbsp;&nbsp;&nbsp; 4444 4444 1&nbsp;&nbsp;&nbsp; 55555 55555 1&nbsp;&nbsp;&nbsp; 1 333 1 333 1&nbsp;&nbsp;&nbsp; 4444 4444 1&nbsp;&nbsp;&nbsp; 55555
+  </div>
+ </body>
+</html>
\ No newline at end of file
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-count-computed-001.xht
@@ -0,0 +1,56 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
+"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+<title>multicolumn | -moz-column-rule</title>
+<link rel="author" title="Opera Software ASA" href="http://www.opera.com/"/>
+<link rel="help" href="http://www.w3.org/TR/css3-multicol/#the-number-and-width-of--moz-columns"/>
+<link rel="help" href="http://www.w3.org/TR/css3-multicol/#-moz-column-gaps-and-rules"/>
+<link rel="match" href="multicol-count-computed-ref.xht"/>
+<meta name="flags" content="ahem"/>
+<style type="text/css"><![CDATA[
+@font-face {
+  font-family: Ahem;
+  src: url("../../../fonts/Ahem.ttf");
+}
+]]></style>
+<style type="text/css"><![CDATA[
+body {
+	margin: 0;
+}
+div {
+	font-family: ahem;
+	font-size: 1em;
+	line-height: 1em;
+	color: black;
+	background: yellow;
+	margin: 1em;
+	border: 1em solid gray;
+	width: 12em;
+	widows: 1;
+	orphans: 1;
+
+	-moz-column-count: 3;
+	-moz-column-gap: 6em;
+	-moz--moz-column-rule-color: blue;
+	-moz--moz-column-rule-width: 1.5em;
+	-moz--moz-column-rule-style: solid;
+}
+#pink {color: pink;}
+#orange {color: orange;}
+#purple {color: purple;}
+#grey {color: grey;}
+]]></style>
+</head>
+
+<body>
+
+<div>
+	<span id="pink">xxxx</span>
+	<span id="orange">xxxx</span>
+	<span id="purple">xxxx</span>
+	<span id="grey">xxxx</span>
+</div>
+
+</body>
+</html>
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-count-computed-002.xht
@@ -0,0 +1,56 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
+"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+<title>multicolumn | -moz-column-rule</title>
+<link rel="author" title="Opera Software ASA" href="http://www.opera.com/"/>
+<link rel="help" href="http://www.w3.org/TR/css3-multicol/#the-number-and-width-of--moz-columns"/>
+<link rel="help" href="http://www.w3.org/TR/css3-multicol/#-moz-column-gaps-and-rules"/>
+<link rel="match" href="multicol-count-computed-2-ref.xht"/>
+<meta name="flags" content="ahem"/>
+<style type="text/css"><![CDATA[
+@font-face {
+  font-family: Ahem;
+  src: url("../../../fonts/Ahem.ttf");
+}
+]]></style>
+<style type="text/css"><![CDATA[
+body {
+	margin: 0;
+}
+div {
+	font-family: ahem;
+	font-size: 1em;
+	line-height: 1em;
+	color: black;
+	background: yellow;
+	margin: 1em;
+	border: 1em solid gray;
+	width: 12em;
+	widows: 1;
+	orphans: 1;
+
+	-moz-column-count: 3;
+	-moz-column-gap: 7em;
+	-moz--moz-column-rule-color: red;
+	-moz--moz-column-rule-width: 1.5em;
+	-moz--moz-column-rule-style: solid;
+}
+#pink {color: pink;}
+#orange {color: orange;}
+#purple {color: purple;}
+#grey {color: grey;}
+]]></style>
+</head>
+
+<body>
+
+<div>
+	<span id="pink">xxxx</span>
+	<span id="orange">xxxx</span>
+	<span id="purple">xxxx</span>
+	<span id="grey">xxxx</span>
+</div>
+
+</body>
+</html>
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-count-computed-003-ref.xht
@@ -0,0 +1,25 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+  <title>CSS Reftest Reference</title>
+  <link rel="author" title="Opera Software ASA" href="http://www.opera.com/" />
+  <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2013-07-29 -->
+  <meta name="flags" content="image" />
+
+  <style type="text/css"><![CDATA[
+  img {vertical-align: top;}
+  ]]></style>
+ </head>
+
+ <body>
+
+  <div><img src="support/swatch-gray.png" width="300" height="20" alt="Image download support must be enabled" /></div>
+
+  <div><img src="support/swatch-gray.png" width="20" height="20" alt="Image download support must be enabled" /><img src="support/swatch-pink.png" width="70" height="20" alt="Image download support must be enabled" /><img src="support/swatch-blue.png" width="15" height="20" alt="Image download support must be enabled" /><img src="support/swatch-yellow.png" width="35" height="20" alt="Image download support must be enabled" /><img src="support/swatch-purple.png" width="80" height="20" alt="Image download support must be enabled" /><img src="support/swatch-yellow.png" width="60" height="20" alt="Image download support must be enabled" /><img src="support/swatch-gray.png" width="20" height="20" alt="Image download support must be enabled" /></div>
+
+  <div><img src="support/swatch-gray.png" width="20" height="20" alt="Image download support must be enabled" /><img src="support/swatch-orange.png" width="70" height="20" alt="Image download support must be enabled" /><img src="support/swatch-blue.png" width="15" height="20" alt="Image download support must be enabled" /><img src="support/swatch-yellow.png" width="35" height="20" alt="Image download support must be enabled" /><img src="support/swatch-gray.png" width="80" height="20" alt="Image download support must be enabled" /><img src="support/swatch-yellow.png" width="60" height="20" alt="Image download support must be enabled" /><img src="support/swatch-gray.png" width="20" height="20" alt="Image download support must be enabled" /></div>
+
+  <div><img src="support/swatch-gray.png" width="300" height="20" alt="Image download support must be enabled" /></div>
+
+ </body>
+</html>
\ No newline at end of file
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-count-computed-003.xht
@@ -0,0 +1,93 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+  <title>CSS Multi-column Layout Test: -moz-column-rule and overflow inside (complex test)</title>
+  <link rel="author" title="Opera Software ASA" href="http://www.opera.com/" />
+  <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2013-07-29 -->
+  <link rel="help" href="http://www.w3.org/TR/css3-multicol/#the-number-and-width-of--moz-columns" title="3. The number and width of -moz-columns" />
+  <link rel="match" href="multicol-count-computed-003-ref.xht" />
+  <meta name="flags" content="ahem" />
+  <meta name="assert" content="This test checks that if one of 2 adjacent column boxes (2nd and 3rd colum box in this test) does not have any content, then the column rule separating those should not be drawn. In this test, the 3rd colum box should have no inline content. This test also checks that inline content in the normal flow that extends into a column gap should be clipped in the middle of the column gap. So, in this test, inline content in 1st column box should be partially clipped and overlapped partially by 1st -moz-column-rule." />
+<style type="text/css"><![CDATA[
+@font-face {
+  font-family: Ahem;
+  src: url("../../../fonts/Ahem.ttf");
+}
+]]></style>
+  <style type="text/css"><![CDATA[
+  div
+  {
+  background: yellow;
+  border: gray solid 1em;
+  color: black;
+  font: 1.25em/1 Ahem;
+  orphans: 1;
+  widows: 1;
+  width: 13em;
+
+  -moz-column-count: 3;
+  -moz-column-gap: 5em;
+  -moz--moz-column-rule-color: blue;
+  -moz--moz-column-rule-style: solid;
+  -moz--moz-column-rule-width: 1.5em;
+  }
+
+  /*
+  (11)  if (-moz-column-width = auto) and (-moz-column-count != auto) then
+  (12)    N := -moz-column-count;
+  (13)    W := max(0, (available-width - ((N - 1) * -moz-column-gap)) / N);
+  (14)  exit;
+
+  So, the used -moz-column-count in this test is 3.
+
+  W := max(0, (available-width - ((N - 1) * -moz-column-gap)) / N);
+  W == max(0, (13em - ((3 - 1) * 5em)) / 3);
+  W == max(0, (13em - (2 * 5em)) / 3);
+  W == max(0, (13em - (10em)) / 3);
+  W == max(0, (3em) / 3);
+  W == max(0, 1em);
+  W == 1em;
+
+  So, the used -moz-column-width in this test is 1em.
+  */
+
+  #pink {color: pink;}
+  #orange {color: orange;}
+  #purple {color: purple;}
+  #gray {color: gray;}
+
+  /*
+  Since
+  "
+  Content in the normal flow that extends into
+  column gaps (e.g., long words or images) is
+  clipped in the middle of the column gap.
+  "
+  http://www.w3.org/TR/css3-multicol/#overflow-inside-multicol-elements
+  this causes the right-half (0.5em) of the 'K' glyph to
+  be overlapped by the right-half (0.75em) of the 1st blue -moz-column-rule.
+  Same thing should happen to the 'N' glyph of 'ORAN'.
+
+  Because no inline content should be rendered into the
+  3rd column box, this causes the 2nd column rule not
+  been rendered because
+  "
+  Column rules are only drawn between two -moz-columns that
+  both have content.
+  "
+  http://www.w3.org/TR/css3-multicol/#-moz-column-gaps-and-rules
+  */
+  ]]></style>
+ </head>
+
+ <body>
+
+  <div>
+	<span id="pink">PINK</span>
+	<span id="orange">ORAN</span>
+	<span id="purple">PURP</span>
+	<span id="gray">GRAY</span>
+  </div>
+
+ </body>
+</html>
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-count-computed-004-ref.xht
@@ -0,0 +1,25 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+  <title>CSS Reftest Reference</title>
+  <link rel="author" title="Opera Software ASA" href="http://www.opera.com/" />
+  <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2013-07-29 -->
+  <meta name="flags" content="image" />
+
+  <style type="text/css"><![CDATA[
+  img {vertical-align: top;}
+  ]]></style>
+ </head>
+
+ <body>
+
+  <div><img src="support/swatch-gray.png" width="280" height="20" alt="Image download support must be enabled" /></div>
+
+  <div><img src="support/swatch-gray.png" width="20" height="20" alt="Image download support must be enabled" /><img src="support/swatch-pink.png" width="80" height="20" alt="Image download support must be enabled" /><img src="support/swatch-yellow.png" width="20" height="20" alt="Image download support must be enabled" /><img src="support/swatch-orange.png" width="80" height="20" alt="Image download support must be enabled" /><img src="support/swatch-yellow.png" width="60" height="20" alt="Image download support must be enabled" /><img src="support/swatch-gray.png" width="20" height="20" alt="Image download support must be enabled" /></div>
+
+  <div><img src="support/swatch-gray.png" width="20" height="20" alt="Image download support must be enabled" /><img src="support/swatch-purple.png" width="80" height="20" alt="Image download support must be enabled" /><img src="support/swatch-yellow.png" width="20" height="20" alt="Image download support must be enabled" /><img src="support/swatch-gray.png" width="80" height="20" alt="Image download support must be enabled" /><img src="support/swatch-yellow.png" width="60" height="20" alt="Image download support must be enabled" /><img src="support/swatch-gray.png" width="20" height="20" alt="Image download support must be enabled" /></div>
+
+  <div><img src="support/swatch-gray.png" width="280" height="20" alt="Image download support must be enabled" /></div>
+
+ </body>
+</html>
\ No newline at end of file
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-count-computed-004.xht
@@ -0,0 +1,52 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+  <title>CSS Multi-column Layout Test: both '-moz-column-width' and '-moz-column-count' are 'auto'</title>
+  <link rel="author" title="Opera Software ASA" href="http://www.opera.com/" />
+  <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />  <!-- 2013-07-29 -->
+  <link rel="help" href="http://www.w3.org/TR/css3-multicol/#pseudo-algorithm" title="3.4 Pseudo-algorithm" />
+  <link rel="match" href="multicol-count-computed-004-ref.xht" />
+  <meta name="flags" content="ahem" />
+  <meta name="assert" content="This test checks that if '-moz-column-width' is 'auto' and if '-moz-column-count' is 'auto', then such element will not behave like a multi-column element and -moz-column-gap and -moz-column-rule declarations will be ignored." />
+<style type="text/css"><![CDATA[
+@font-face {
+  font-family: Ahem;
+  src: url("../../../fonts/Ahem.ttf");
+}
+]]></style>
+  <style type="text/css"><![CDATA[
+  div
+  {
+  background: yellow;
+  border: gray solid 1em;
+  color: black;
+  font: 1.25em/1 Ahem;
+  orphans: 1;
+  widows: 1;
+  width: 12em;
+
+  -moz-column-count: auto;
+  -moz-column-gap: 7em;
+  -moz--moz-column-rule-color: red;
+  -moz--moz-column-rule-width: 1.5em;
+  -moz--moz-column-rule-style: solid;
+  }
+
+  #pink {color: pink;}
+  #orange {color: orange;}
+  #purple {color: purple;}
+  #gray {color: gray;}
+  ]]></style>
+ </head>
+
+ <body>
+
+  <div>
+	<span id="pink">Pink</span>
+	<span id="orange">oran</span>
+	<span id="purple">PurP</span>
+	<span id="gray">gray</span>
+  </div>
+
+ </body>
+</html>
\ No newline at end of file
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-count-computed-005.xht
@@ -0,0 +1,97 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+  <title>CSS Multi-column Layout Test: -moz-column-rule and overflow inside (complex test)</title>
+  <link rel="author" title="Opera Software ASA" href="http://www.opera.com/" />
+  <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2013-08-03 -->
+  <link rel="help" href="http://www.w3.org/TR/css3-multicol/#the-number-and-width-of--moz-columns" title="3. The number and width of -moz-columns" />
+  <link rel="match" href="multicol-count-computed-003-ref.xht" />
+  <meta name="flags" content="ahem" />
+  <meta name="assert" content="This test checks that if one of 2 adjacent column boxes (2nd and 3rd colum box in this test) does not have any content, then the column rule separating those should not be drawn. In this test, the 3rd colum box should have no inline content. This test also checks that inline content in the normal flow that extends into a column gap should be clipped in the middle of the column gap. So, in this test, inline content in 1st column box should be partially clipped and overlapped partially by 1st -moz-column-rule." />
+<style type="text/css"><![CDATA[
+@font-face {
+  font-family: Ahem;
+  src: url("../../../fonts/Ahem.ttf");
+}
+]]></style>
+  <style type="text/css"><![CDATA[
+  div
+  {
+  background: yellow;
+  border: gray solid 1em;
+  color: black;
+  font: 1.25em/1 Ahem;
+  orphans: 1;
+  widows: 1;
+  width: 13em;
+
+  -moz-column-gap: 5em;
+  -moz--moz-column-rule-color: blue;
+  -moz--moz-column-rule-style: solid;
+  -moz--moz-column-rule-width: 1.5em;
+  -moz-column-width: 1em;
+  }
+
+  /*
+  (15)  if (-moz-column-width != auto) and (-moz-column-count = auto) then
+  (16)    N := max(1, floor((available-width + -moz-column-gap) / (-moz-column-width + -moz-column-gap)));
+  (17)    W := ((available-width + -moz-column-gap) / N) - -moz-column-gap;
+  (18)  exit;
+
+  N := max(1, floor((available-width + -moz-column-gap) / (-moz-column-width + -moz-column-gap)));
+  N == max(1, floor((13em + 5em) / (1em + 5em)));
+  N == max(1, floor(18em / 6em));
+  N == max(1, floor(3));
+  N == 3;
+
+  So, the used -moz-column-count in this test is 3.
+
+  W := ((available-width + -moz-column-gap) / N) - -moz-column-gap;
+  W == ((13em + 5em) / 3) - 5em;
+  W == ((18em) / 3) - 5em;
+  W == (6em) - 5em;
+  W == 1em;
+
+  So, the used -moz-column-width in this test is 1em.
+  */
+
+  #pink {color: pink;}
+  #orange {color: orange;}
+  #purple {color: purple;}
+  #gray {color: gray;}
+
+  /*
+  Since
+  "
+  Content in the normal flow that extends into
+  column gaps (e.g., long words or images) is
+  clipped in the middle of the column gap.
+  "
+  http://www.w3.org/TR/css3-multicol/#overflow-inside-multicol-elements
+  this causes the right-half (0.5em) of the 'K' glyph to
+  be overlapped by the right-half (0.75em) of the 1st blue -moz-column-rule.
+  Same thing should happen to the 'N' glyph of 'ORAN'.
+
+  Because no inline content should be rendered into the
+  3rd column box, this causes the 2nd column rule not
+  been rendered because
+  "
+  Column rules are only drawn between two -moz-columns that
+  both have content.
+  "
+  http://www.w3.org/TR/css3-multicol/#-moz-column-gaps-and-rules
+  */
+  ]]></style>
+ </head>
+
+ <body>
+
+  <div>
+	<span id="pink">PINK</span>
+	<span id="orange">ORAN</span>
+	<span id="purple">PURP</span>
+	<span id="gray">GRAY</span>
+  </div>
+
+ </body>
+</html>
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-count-computed-2-ref.xht
@@ -0,0 +1,58 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
+"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+<title>multicolumn | -moz-column-rule</title>
+<link rel="author" title="Opera Software ASA" href="http://www.opera.com/"/>
+<style type="text/css"><![CDATA[
+body {
+	margin: 0;
+}
+div {
+	font-family: ahem;
+	font-size: 1em;
+	line-height: 1em;
+	color: black;
+	background: yellow;
+	margin: 1em;
+	border: 1em solid gray;
+	width: 12em;
+	height: 2em;
+	position: relative;
+	widows: 1;
+	orphans: 1;
+}
+#pink {color: pink;}
+#orange {color: orange;}
+#purple {color: purple;}
+#grey {color: grey;}
+span {
+	display: block;
+	position: absolute;
+}
+#orange {
+	left: 5em;
+	top: 0;
+}
+#purple {
+	left: 0;
+	top: 1em;
+}
+#grey {
+	left: 5em;
+	top: 1em;
+}
+]]></style>
+</head>
+
+<body>
+
+<div>
+	<span id="purple">xxxx</span>
+	<span id="orange">xxxx</span>
+	<span id="grey">xxxx</span>
+	<span id="pink">xxxx</span>
+</div>
+
+</body>
+</html>
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-count-computed-ref.xht
@@ -0,0 +1,69 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
+"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+<title>multicolumn | -moz-column-rule</title>
+<link rel="author" title="Opera Software ASA" href="http://www.opera.com/"/>
+<style type="text/css"><![CDATA[
+body {
+	margin: 0;
+}
+div {
+	font-family: ahem;
+	font-size: 1em;
+	line-height: 1em;
+	color: black;
+	background: yellow;
+	margin: 1em;
+	border: 1em solid gray;
+	width: 12em;
+	height: 2em;
+	position: relative;
+	widows: 1;
+	orphans: 1;
+
+}
+span {
+	display: block;
+	position: absolute;
+}
+#pink {
+	color: pink;
+}
+#orange {
+	color: orange;
+	left: 0;
+	top: 1em;
+}
+#purple {
+	color: purple;
+	left: 9em;
+	top: 0;
+}
+#grey {
+	color: grey;
+	left: 9em;
+	top: 1em;
+}
+#blue {
+	left: 5.25em;
+	top: 0;
+	width: 1.5em;
+	height: 2em;
+	background: blue;
+}
+]]></style>
+</head>
+
+<body>
+
+<div>
+	<span id="pink">xxxx</span>
+	<span id="orange">xxxx</span>
+	<span id="purple">xxxx</span>
+	<span id="grey">xxxx</span>
+	<span id="blue"></span>
+</div>
+
+</body>
+</html>
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-count-large-001.xht
@@ -0,0 +1,48 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
+"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+<title>multicolumn | -moz-column-count</title>
+<link rel="author" title="Opera Software ASA" href="http://www.opera.com/"/>
+<link rel="help" href="http://www.w3.org/TR/css3-multicol/#the-number-and-width-of--moz-columns"/>
+<link rel="match" href="multicol-count-large-ref.xht"/>
+<meta name="flags" content="ahem"/>
+<style type="text/css"><![CDATA[
+@font-face {
+  font-family: Ahem;
+  src: url("../../../fonts/Ahem.ttf");
+}
+]]></style>
+<style type="text/css"><![CDATA[
+body>div {
+	font-family: ahem;
+	font-size: 1em;
+	line-height: 1em;
+	color: red;
+	background: yellow;
+	margin: 1em;
+	border: 1em solid gray;
+	width: 12em;
+	orphans: 1;
+	widows: 1;
+
+	-moz-column-count: 1000;
+	-moz-column-gap: 0;
+}
+span {
+	color: black;
+}
+]]></style>
+</head>
+
+<body>
+
+<div>
+	xx xx
+	xx xx
+	xx xx
+	<span>xx xx</span>
+</div>
+
+</body>
+</html>
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-count-large-002.xht
@@ -0,0 +1,48 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
+"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+<title>multicolumn | -moz-column-count</title>
+<link rel="author" title="Opera Software ASA" href="http://www.opera.com/"/>
+<link rel="help" href="http://www.w3.org/TR/css3-multicol/#the-number-and-width-of--moz-columns"/>
+<link rel="match" href="multicol-count-large-2-ref.xht"/>
+<meta name="flags" content="ahem"/>
+<style type="text/css"><![CDATA[
+@font-face {
+  font-family: Ahem;
+  src: url("../../../fonts/Ahem.ttf");
+}
+]]></style>
+<style type="text/css"><![CDATA[
+body>div {
+	font-family: ahem;
+	font-size: 1em;
+	line-height: 1em;
+	color: black;
+	background: yellow;
+	margin: 1em;
+	border: 1em solid gray;
+	width: 12em;
+	orphans: 1;
+	widows: 1;
+
+	-moz-column-count: 1000;
+	-moz-column-gap: 0;
+}
+span {
+	color: blue;
+}
+]]></style>
+</head>
+
+<body>
+
+<div>
+	xx xx
+	<span>xx xx</span>
+	xx xx
+	<span>xx xx</span>
+</div>
+
+</body>
+</html>
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-count-large-2-ref.xht
@@ -0,0 +1,40 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
+"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+<title>multicolumn | -moz-column-count</title>
+<link rel="author" title="Opera Software ASA" href="http://www.opera.com/"/>
+<style type="text/css"><![CDATA[
+body>div {
+	font-family: ahem;
+	font-size: 1em;
+	line-height: 1em;
+	color: black;
+	background: yellow;
+	margin: 1em;
+	border: 1em solid gray;
+	width: 12em;
+	height: 1em;
+	position: relative;
+	orphans: 1;
+	widows: 1;
+}
+span {
+	color: blue;
+	background: blue;
+	width: 2em;
+	position: absolute;
+	left: 0;
+	top: 0;
+}
+]]></style>
+</head>
+
+<body>
+
+<div>
+	<span>x</span>
+</div>
+
+</body>
+</html>
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-count-large-ref.xht
@@ -0,0 +1,30 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
+"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+<title>multicolumn | -moz-column-count</title>
+<link rel="author" title="Opera Software ASA" href="http://www.opera.com/"/>
+<style type="text/css"><![CDATA[
+body>div {
+	font-family: ahem;
+	font-size: 1em;
+	line-height: 1em;
+	color: black;
+	background: yellow;
+	margin: 1em;
+	border: 1em solid gray;
+	width: 12em;
+	height: 1em;
+	orphans: 1;
+	widows: 1;
+
+}
+]]></style>
+</head>
+
+<body>
+
+<div>xx</div>
+
+</body>
+</html>
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-count-negative-001.xht
@@ -0,0 +1,51 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+  <title>CSS Multi-column Layout Test: negative '-moz-column-count' value</title>
+  <link rel="author" title="Opera Software ASA" href="http://www.opera.com/" />
+  <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2013-07-30 -->
+  <link rel="help" href="http://www.w3.org/TR/css3-multicol/#the-number-and-width-of--moz-columns" title="3. The number and width of -moz-columns" />
+  <link rel="match" href="multicol--moz-columns-invalid-001-ref.xht" />
+  <meta name="flags" content="ahem invalid" />
+  <meta name="assert" content="This test checks that a specified negative '-moz-column-count' value is invalid and ignored." />
+<style type="text/css"><![CDATA[
+@font-face {
+  font-family: Ahem;
+  src: url("../../../fonts/Ahem.ttf");
+}
+]]></style>
+  <style type="text/css"><![CDATA[
+  div
+  {
+  background: yellow;
+  border: gray solid 1em;
+  color: black;
+  font: 1.25em/1 Ahem;
+  orphans: 1;
+  widows: 1;
+  width: 12em;
+
+  -moz-column-count: 4;
+  -moz-column-count: -1;
+  -moz-column-gap: 0;
+  }
+
+  span {color: blue;}
+  ]]></style>
+ </head>
+
+ <body>
+
+  <div>
+	bl ac
+  <span>
+	bl ue
+  </span>
+  <span>
+	bl ue
+  </span>
+	bl ac
+  </div>
+
+ </body>
+</html>
\ No newline at end of file
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-count-negative-002.xht
@@ -0,0 +1,51 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+  <title>CSS Multi-column Layout Test: zero '-moz-column-count' value</title>
+  <link rel="author" title="Opera Software ASA" href="http://www.opera.com/" />
+  <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2013-07-30 -->
+  <link rel="help" href="http://www.w3.org/TR/css3-multicol/#the-number-and-width-of--moz-columns" title="3. The number and width of -moz-columns" />
+  <link rel="match" href="multicol--moz-columns-invalid-001-ref.xht" />
+  <meta name="flags" content="ahem invalid" />
+  <meta name="assert" content="This test checks that a specified 0 '-moz-column-count' value is invalid and ignored." />
+<style type="text/css"><![CDATA[
+@font-face {
+  font-family: Ahem;
+  src: url("../../../fonts/Ahem.ttf");
+}
+]]></style>
+  <style type="text/css"><![CDATA[
+  div
+  {
+  background: yellow;
+  border: gray solid 1em;
+  color: black;
+  font: 1.25em/1 Ahem;
+  orphans: 1;
+  widows: 1;
+  width: 12em;
+
+  -moz-column-count: 4;
+  -moz-column-count: 0; /* invalid; must be a greater-than-zero integer */
+  -moz-column-gap: 0;
+  }
+
+  span {color: blue;}
+  ]]></style>
+ </head>
+
+ <body>
+
+  <div>
+	bl ac
+  <span>
+	bl ue
+  </span>
+  <span>
+	bl ue
+  </span>
+	bl ac
+  </div>
+
+ </body>
+</html>
\ No newline at end of file
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-count-non-integer-001.xht
@@ -0,0 +1,51 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+  <title>CSS Multi-column Layout Test: non-integer '-moz-column-count' value</title>
+  <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+  <link rel="help" href="http://www.w3.org/TR/css3-multicol/#the-number-and-width-of--moz-columns" title="3. The number and width of -moz-columns" />
+  <link rel="help" href="http://www.w3.org/TR/css3-values/#integers" title="4.1. Integers: the '&lt;integer&gt;' type" />
+  <link rel="match" href="multicol--moz-columns-invalid-001-ref.xht" />
+  <meta name="flags" content="ahem invalid" />
+  <meta name="assert" content="This test checks that a specified real '-moz-column-count' value is invalid and ignored." />
+<style type="text/css"><![CDATA[
+@font-face {
+  font-family: Ahem;
+  src: url("../../../fonts/Ahem.ttf");
+}
+]]></style>
+  <style type="text/css"><![CDATA[
+  div
+  {
+  background: yellow;
+  border: gray solid 1em;
+  color: black;
+  font: 1.25em/1 Ahem;
+  orphans: 1;
+  widows: 1;
+  width: 12em;
+
+  -moz-column-count: 4;
+  -moz-column-count: 2.1; /* invalid; must be an integer */
+  -moz-column-gap: 0;
+  }
+
+  span {color: blue;}
+  ]]></style>
+ </head>
+
+ <body>
+
+  <div>
+	bl ac
+  <span>
+	bl ue
+  </span>
+  <span>
+	bl ue
+  </span>
+	bl ac
+  </div>
+
+ </body>
+</html>
\ No newline at end of file
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-count-non-integer-002.xht
@@ -0,0 +1,51 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+  <title>CSS Multi-column Layout Test: non-integer '-moz-column-count' value</title>
+  <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+  <link rel="help" href="http://www.w3.org/TR/css3-multicol/#the-number-and-width-of--moz-columns" title="3. The number and width of -moz-columns" />
+  <link rel="help" href="http://www.w3.org/TR/css3-values/#integers" title="4.1. Integers: the '&lt;integer&gt;' type" />
+  <link rel="match" href="multicol--moz-columns-invalid-001-ref.xht" />
+  <meta name="flags" content="ahem invalid" />
+  <meta name="assert" content="This test checks that a specified real '-moz-column-count' value is invalid and ignored." />
+<style type="text/css"><![CDATA[
+@font-face {
+  font-family: Ahem;
+  src: url("../../../fonts/Ahem.ttf");
+}
+]]></style>
+  <style type="text/css"><![CDATA[
+  div
+  {
+  background: yellow;
+  border: gray solid 1em;
+  color: black;
+  font: 1.25em/1 Ahem;
+  orphans: 1;
+  widows: 1;
+  width: 12em;
+
+  -moz-column-count: 4;
+  -moz-column-count: 1.9; /* invalid; must be an integer */
+  -moz-column-gap: 0;
+  }
+
+  span {color: blue;}
+  ]]></style>
+ </head>
+
+ <body>
+
+  <div>
+	bl ac
+  <span>
+	bl ue
+  </span>
+  <span>
+	bl ue
+  </span>
+	bl ac
+  </div>
+
+ </body>
+</html>
\ No newline at end of file
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-count-non-integer-003.xht
@@ -0,0 +1,51 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+  <title>CSS Multi-column Layout Test: non-integer '-moz-column-count' value</title>
+  <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" />
+  <link rel="help" href="http://www.w3.org/TR/css3-multicol/#the-number-and-width-of--moz-columns" title="3. The number and width of -moz-columns" />
+  <link rel="help" href="http://www.w3.org/TR/css3-values/#integers" title="4.1. Integers: the '&lt;integer&gt;' type" />
+  <link rel="match" href="multicol--moz-columns-invalid-001-ref.xht" />
+  <meta name="flags" content="ahem invalid" />
+  <meta name="assert" content="This test checks that a specified real '-moz-column-count' value is invalid and ignored." />
+<style type="text/css"><![CDATA[
+@font-face {
+  font-family: Ahem;
+  src: url("../../../fonts/Ahem.ttf");
+}
+]]></style>
+  <style type="text/css"><![CDATA[
+  div
+  {
+  background: yellow;
+  border: gray solid 1em;
+  color: black;
+  font: 1.25em/1 Ahem;
+  orphans: 1;
+  widows: 1;
+  width: 12em;
+
+  -moz-column-count: 4;
+  -moz-column-count: 2.0; /* invalid; must be an integer */
+  -moz-column-gap: 0;
+  }
+
+  span {color: blue;}
+  ]]></style>
+ </head>
+
+ <body>
+
+  <div>
+	bl ac
+  <span>
+	bl ue
+  </span>
+  <span>
+	bl ue
+  </span>
+	bl ac
+  </div>
+
+ </body>
+</html>
\ No newline at end of file
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-fill-000-ref.xht
@@ -0,0 +1,58 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+  <title>CSS Reftest Reference</title>
+  <link rel="author" title="Hakon Wium Lie" href="mailto:howcome@opera.com" />
+  <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2013-08-25 -->
+  <meta name="flags" content="ahem" />
+<style type="text/css"><![CDATA[
+@font-face {
+  font-family: Ahem;
+  src: url("../../../fonts/Ahem.ttf");
+}
+]]></style>
+  <style type="text/css"><![CDATA[
+  table
+  {
+  background-color: yellow;
+  border-spacing: 0em;
+  color: lime;
+  margin: 1em 0em;
+  font: 1.25em/1 Ahem;
+  table-layout: fixed;
+  width: 18em;
+  }
+
+  td {padding: 0em;}
+  ]]></style>
+ </head>
+ <body>
+
+  <p>Test passes if the 3 horizontal bars are <strong>identical</strong>.</p>
+
+  <table>
+    <tr>
+      <td>G</td>
+      <td>H</td>
+      <td>I</td>
+    </tr>
+  </table>
+
+  <table>
+    <tr>
+      <td>G</td>
+      <td>H</td>
+      <td>I</td>
+    </tr>
+  </table>
+
+  <table>
+    <tr>
+      <td>G</td>
+      <td>H</td>
+      <td>I</td>
+    </tr>
+  </table>
+
+ </body>
+</html>
\ No newline at end of file
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-fill-000.xht
@@ -0,0 +1,77 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+  <title>CSS Multi-column Layout Test: -moz-column-fill: balance (basic)</title>
+  <link rel="author" title="Hakon Wium Lie" href="mailto:howcome@opera.com" />
+  <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2013-08-25 -->
+  <link rel="help" href="http://www.w3.org/TR/css3-multicol/#cf" title="7.1 '-moz-column-fill'" />
+  <link rel="match" href="multicol-fill-000-ref.xht" />
+  <meta name="flags" content="ahem" />
+  <meta name="assert" content="This test checks that content is balanced into all -moz-columns thanks to '-moz-column-fill: balance'." />
+<style type="text/css"><![CDATA[
+@font-face {
+  font-family: Ahem;
+  src: url("../../../fonts/Ahem.ttf");
+}
+]]></style>
+  <style type="text/css"><![CDATA[
+  div.test, table#reference
+  {
+  background-color: yellow;
+  color: lime;
+  margin: 1em 0em;
+  font: 1.25em/1 Ahem;
+  width: 18em;
+  }
+
+  div.test
+  {
+  -moz-columns: 3;
+  -moz-column-fill: balance;
+  -moz-column-gap: 0em;
+
+  /*
+
+  N == 3;
+
+  W == 6em;
+
+  */
+
+  orphans: 1;
+  widows: 1;
+  }
+
+  div.test > p {margin: 0em;}
+
+  table
+  {
+  border-spacing: 0em;
+  table-layout: fixed;
+  }
+
+  td {padding: 0em;}
+  ]]></style>
+ </head>
+ <body>
+
+  <p>Test passes if the 3 horizontal bars are <strong>identical</strong>.</p>
+
+  <div class="test">
+      <p>A</p>
+      <p>B</p>
+      <p>C</p>
+  </div>
+
+  <div class="test">D<br />E<br />F</div>
+
+  <table id="reference">
+    <tr>
+      <td>G</td>
+      <td>H</td>
+      <td>I</td>
+    </tr>
+  </table>
+
+ </body>
+</html>
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-fill-001-ref.xht
@@ -0,0 +1,53 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+  <title>CSS Reftest Reference</title>
+  <link rel="author" title="Hakon Wium Lie" href="mailto:howcome@opera.com" />
+  <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2013-08-25 -->
+  <meta name="flags" content="ahem" />
+<style type="text/css"><![CDATA[
+@font-face {
+  font-family: Ahem;
+  src: url("../../../fonts/Ahem.ttf");
+}
+]]></style>
+  <style type="text/css"><![CDATA[
+  table
+  {
+  background-color: yellow;
+  border-spacing: 0em;
+  color: lime;
+  font: 1.25em/1 Ahem;
+  height: 5em;
+  margin: 1em 0em;
+  table-layout: fixed;
+  width: 20em;
+  }
+
+  td
+  {
+  padding: 0em;
+  vertical-align: top;
+  }
+  ]]></style>
+ </head>
+ <body>
+
+  <p>Test passes if the 2 rectangles are <strong>identical</strong>.</p>
+
+  <table>
+    <tr>
+      <td>G<br />H<br />I</td>
+      <td>J<br />K<br />L</td>
+    </tr>
+  </table>
+
+  <table>
+    <tr>
+      <td>G<br />H<br />I</td>
+      <td>J<br />K<br />L</td>
+    </tr>
+  </table>
+
+ </body>
+</html>
\ No newline at end of file
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-fill-001.xht
@@ -0,0 +1,70 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+  <title>CSS Multi-column Layout Test: -moz-column-fill: balance with set height (basic)</title>
+  <link rel="author" title="Hakon Wium Lie" href="mailto:howcome@opera.com" />
+  <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2013-08-25 -->
+  <link rel="help" href="http://www.w3.org/TR/css3-multicol/#cf" title="7.1 '-moz-column-fill'" />
+  <link rel="match" href="multicol-fill-001-ref.xht" />
+  <meta name="flags" content="ahem" />
+  <meta name="assert" content="This test checks that content is balanced into all -moz-columns of a multi-column element with a set height thanks to '-moz-column-fill: balance'." />
+<style type="text/css"><![CDATA[
+@font-face {
+  font-family: Ahem;
+  src: url("../../../fonts/Ahem.ttf");
+}
+]]></style>
+  <style type="text/css"><![CDATA[
+  div#test, table#reference
+  {
+  background-color: yellow;
+  color: lime;
+  font: 1.25em/1 Ahem;
+  height: 5em;
+  margin: 1em 0em;
+  width: 20em;
+  }
+
+  div#test
+  {
+  -moz-columns: 2;
+  -moz-column-fill: balance;
+  -moz-column-gap: 0em;
+
+  /*
+
+  N == 2;
+
+  W == 10em;
+
+  */
+  }
+
+  table
+  {
+  border-spacing: 0em;
+  table-layout: fixed;
+  }
+
+  td
+  {
+  padding: 0em;
+  vertical-align: top;
+  }
+  ]]></style>
+ </head>
+ <body>
+
+  <p>Test passes if the 2 rectangles are <strong>identical</strong>.</p>
+
+  <div id="test">A<br />B<br />C<br />D<br />E<br />F</div>
+
+  <table id="reference">
+    <tr>
+      <td>G<br />H<br />I</td>
+      <td>J<br />K<br />L</td>
+    </tr>
+  </table>
+
+ </body>
+</html>
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-fill-auto-001-ref.xht
@@ -0,0 +1,45 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+  <title>CSS Reftest Reference</title>
+  <link rel="author" title="Opera Software ASA" href="http://www.opera.com/" />
+  <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2013-07-30 -->
+  <meta name="flags" content="ahem" />
+<style type="text/css"><![CDATA[
+@font-face {
+  font-family: Ahem;
+  src: url("../../../fonts/Ahem.ttf");
+}
+]]></style>
+  <style type="text/css"><![CDATA[
+  div
+  {
+  color: black;
+  font: 1.25em/1 Ahem;
+  float: left;
+  width: 10em;
+  margin-right: 1em;
+  }
+  ]]></style>
+ </head>
+ <body>
+
+  <div>1 22 333
+  4444 55555
+  666666
+  7777777
+  999999999
+  1 22 333
+  4444 55555
+  666666
+  7777777
+  999999999</div>
+
+  <div>1 22 333
+  4444 55555
+  666666
+  7777777
+  999999999</div>
+
+ </body>
+</html>
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-fill-auto-001.xht
@@ -0,0 +1,39 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+  <title>CSS Multi-column Layout Test: '-moz-column-fill: auto' (basic)</title>
+  <link rel="author" title="Opera Software ASA" href="http://www.opera.com/" />
+  <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2013-07-30 -->
+  <link rel="help" href="http://www.w3.org/TR/css3-multicol/#cf" title="7.1 '-moz-column-fill'" />
+  <link rel="match" href="multicol-fill-auto-001-ref.xht" />
+  <meta name="flags" content="ahem" />
+  <meta name="assert" content="This test checks that '-moz-column-fill: auto' fills the column boxes of a multi-colum element sequentially with inline content and does not bother about balancing content of column boxes." />
+<style type="text/css"><![CDATA[
+@font-face {
+  font-family: Ahem;
+  src: url("../../../fonts/Ahem.ttf");
+}
+]]></style>
+  <style type="text/css"><![CDATA[
+  div
+  {
+  color: black;
+  font: 1.25em/1 Ahem;
+  height: 10em;
+  orphans: 1;
+  widows: 1;
+  width: 32em;
+
+  -moz-column-count: 3;
+  -moz-column-fill: auto;
+  -moz-column-gap: 1em;
+  }
+  ]]></style>
+ </head>
+
+ <body>
+
+  <div>1 22 333 4444 55555 666666 7777777 999999999 1 22 333 4444 55555 666666 7777777 999999999 1 22 333 4444 55555 666666 7777777 999999999</div>
+
+ </body>
+</html>
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-fill-auto-002-ref.xht
@@ -0,0 +1,49 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
+"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+<title>multicolumn | -moz-column-fill-auto</title>
+<link rel="author" title="howcome@opera.com" href="http://www.opera.com/"/>
+<meta name="flags" content="ahem"/>
+<style type="text/css"><![CDATA[
+@font-face {
+  font-family: Ahem;
+  src: url("../../../fonts/Ahem.ttf");
+}
+]]></style>
+<style type="text/css"><![CDATA[
+body>div {
+	font-family: ahem;
+	font-size: 1.25em;
+	line-height: 1em;
+	color: green;
+	height: 3em;
+	width: 2em;
+	orphans: 1;
+	widows: 1;
+	position: relative;
+	margin: 1em;
+}
+div.col {
+	-moz-column-count: 2;
+	-moz-column-fill: auto;
+	-moz-column-gap: 0;
+}
+div.red {
+	background: red; position: absolute; z-index: -1;
+}
+]]></style>
+</head>
+
+<body>
+
+<div class='ref'>
+oo<br/>t<br/>o
+</div>
+
+<div class='ref'>
+oo<br/>t<br/>o
+</div>
+
+</body>
+</html>
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-fill-auto-002.xht
@@ -0,0 +1,55 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
+"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+<title>multicolumn | -moz-column-fill-auto</title>
+<meta name="assert" content="This test checks that -moz-columns are not balanced when '-moz-column-fill: auto' is set"/>
+<link rel="author" title="howcome@opera.com" href="http://www.opera.com/"/>
+<link rel="help" href="http://www.w3.org/TR/css3-multicol/#filling--moz-columns"/>
+<link rel="match" href="multicol-fill-auto-002-ref.xht"/>
+<meta name="flags" content="ahem"/>
+<style type="text/css"><![CDATA[
+@font-face {
+  font-family: Ahem;
+  src: url("../../../fonts/Ahem.ttf");
+}
+]]></style>
+<style type="text/css"><![CDATA[
+body>div {
+	font-family: ahem;
+	font-size: 1.25em;
+	line-height: 1em;
+	color: green;
+	height: 3em;
+	width: 2em;
+	orphans: 1;
+	widows: 1;
+	position: relative;
+	margin: 1em;
+}
+div.col {
+	-moz-column-count: 2;
+	-moz-column-fill: auto;
+	-moz-column-gap: 0;
+}
+div.red {
+	background: red; position: absolute; z-index: -1;
+}
+]]></style>
+</head>
+
+<body>
+
+<div class='col'>
+<div class='red' style="top: 0; left: 0; height: 3em; width: 1em;"></div>
+<div class='red' style="top: 0; left: 0; height: 1em; width: 2em;"></div>
+o<br/>t<br/>
+o<br/>t<br/>
+</div>
+
+<div class='ref'>
+oo<br/>t<br/>o
+</div>
+
+</body>
+</html>
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-fill-auto-003-ref.xht
@@ -0,0 +1,39 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+  <title>CSS Reftest Reference</title>
+  <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2013-08-01 -->
+  <meta name="flags" content="ahem image" />
+<style type="text/css"><![CDATA[
+@font-face {
+  font-family: Ahem;
+  src: url("../../../fonts/Ahem.ttf");
+}
+]]></style>
+  <style type="text/css"><![CDATA[
+  div {font: 1.25em/1 Ahem;}
+  img {vertical-align: top;}
+  ]]></style>
+ </head>
+ <body>
+
+  <p>Test passes if there is <strong>no red</strong>.</p>
+
+  <div><img src="support/swatch-green.png" width="460" height="20" alt="Image download support must be enabled" /></div>
+
+  <div><img src="support/swatch-green.png" width="220" height="20" alt="Image download support must be enabled" /><img src="support/swatch-yellow.png" width="20" height="20" alt="Image download support must be enabled" /><img src="support/swatch-green.png" width="60" height="20" alt="Image download support must be enabled" /> <img src="support/swatch-green.png" width="40" height="20" alt="Image download support must be enabled" /> <img src="support/swatch-green.png" width="80" height="20" alt="Image download support must be enabled" /></div>
+
+  <div><img src="support/swatch-green.png" width="60" height="20" alt="Image download support must be enabled" /> <img src="support/swatch-green.png" width="80" height="20" alt="Image download support must be enabled" /> <img src="support/swatch-green.png" width="40" height="20" alt="Image download support must be enabled" /><img src="support/swatch-yellow.png" width="20" height="20" alt="Image download support must be enabled" /><img src="support/swatch-green.png" width="60" height="20" alt="Image download support must be enabled" /> <img src="support/swatch-green.png" width="40" height="20" alt="Image download support must be enabled" />&nbsp;&nbsp;&nbsp; <img src="support/swatch-green.png" width="20" height="20" alt="Image download support must be enabled" /></div>
+
+  <div><img src="support/swatch-green.png" width="80" height="20" alt="Image download support must be enabled" /> <img src="support/swatch-green.png" width="40" height="20" alt="Image download support must be enabled" /> <img src="support/swatch-green.png" width="60" height="20" alt="Image download support must be enabled" /><img src="support/swatch-yellow.png" width="20" height="20" alt="Image download support must be enabled" />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <img src="support/swatch-green.png" width="20" height="20" alt="Image download support must be enabled" /></div>
+
+  <div><img src="support/swatch-green.png" width="80" height="20" alt="Image download support must be enabled" /> <img src="support/swatch-green.png" width="100" height="20" alt="Image download support must be enabled" /> <img src="support/swatch-yellow.png" width="20" height="20" alt="Image download support must be enabled" />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <img src="support/swatch-green.png" width="20" height="20" alt="Image download support must be enabled" /></div>
+
+  <div><img src="support/swatch-green.png" width="40" height="20" alt="Image download support must be enabled" /> <img src="support/swatch-green.png" width="100" height="20" alt="Image download support must be enabled" /> <img src="support/swatch-green.png" width="40" height="20" alt="Image download support must be enabled" /><img src="support/swatch-yellow.png" width="20" height="20" alt="Image download support must be enabled" /> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <img src="support/swatch-green.png" width="20" height="20" alt="Image download support must be enabled" /></div>
+
+  <div><img src="support/swatch-green.png" width="60" height="20" alt="Image download support must be enabled" /> <img src="support/swatch-green.png" width="80" height="20" alt="Image download support must be enabled" /> <img src="support/swatch-green.png" width="40" height="20" alt="Image download support must be enabled" /><img src="support/swatch-yellow.png" width="20" height="20" alt="Image download support must be enabled" /> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <img src="support/swatch-green.png" width="20" height="20" alt="Image download support must be enabled" /></div>
+
+  <div><img src="support/swatch-green.png" width="460" height="20" alt="Image download support must be enabled" /></div>
+
+ </body>
+</html>
\ No newline at end of file
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-fill-auto-003.xht
@@ -0,0 +1,65 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+  <title>CSS Multi-column Layout Test: '-moz-column-fill: auto' (basic)</title>
+  <link rel="author" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2013-08-01 -->
+  <link rel="help" href="http://www.w3.org/TR/css3-multicol/#cf" title="7.1 '-moz-column-fill'" />
+  <link rel="match" href="multicol-fill-auto-003-ref.xht" />
+  <meta name="flags" content="ahem" />
+  <meta name="assert" content="This test checks if inline content fills column boxes sequentially when '-moz-column-fill' is set to 'auto'." />
+<style type="text/css"><![CDATA[
+@font-face {
+  font-family: Ahem;
+  src: url("../../../fonts/Ahem.ttf");
+}
+]]></style>
+  <style type="text/css"><![CDATA[
+  div
+  {
+  background-image: url("support/red20x20.png");
+  background-repeat: no-repeat;
+  background-position: 2em 4em;
+  border: green solid 1em;
+  color: green;
+  font: 1.25em/1 Ahem;
+  height: 6em;
+  width: 21em;
+
+  -moz-column-count: 2;
+  -moz-column-fill: auto;
+  -moz-column-gap: 1em;
+  -moz-column-rule: yellow solid 1em;
+  }
+  ]]></style>
+ </head>
+
+ <body>
+
+  <p>Test passes if there is <strong>no red</strong>.</p>
+
+  <div>1234567890 12 4567 90 123 56 890 123 56789 1 34567 90 12 4567 90
+123 56 890 123 56</div>
+
+  <!--
+
+  Expected result:
+
+  ************  ************
+  |1234567890|  |123 56 890|
+  |12 4567 90|  |123 56    |
+  |123 56 890|  |          |
+  |123 56789 |  |          |
+  |1 34567 90|  |          |
+  |12 4567 90|  |          |
+  ************  ************
+
+  The digits are the green squares, the white squares
+  are the blank white spaces. The yellow vertical stripe
+  represent both the -moz-column-gap and the -moz-column-rule.
+  The "3" glyph at line 5 of 1st column box should be
+  overlapping the red square.
+
+  -->
+
+ </body>
+</html>
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-fill-auto-block-children-001.xht
@@ -0,0 +1,94 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
+"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+<title>multicol | -moz-column-span: all | -moz-column-fill: auto</title>
+<link rel="author" title="Opera Software ASA" href="http://www.opera.com/"/>
+<link rel="help" href="http://www.w3.org/TR/css3-multicol/#filling--moz-columns"/>
+<link rel="match" href="multicol-fill-auto-block-children-ref.xht"/>
+<meta name="flags" content=""/>
+<style type="text/css"><![CDATA[
+html {
+	background: white;
+}
+body {
+	background: blue;
+	width: 1200px;
+	height: 492px;
+	-moz-column-count: 3;
+	-moz-column-gap: 2em;
+	-moz-column-fill: auto;
+}
+h1 {
+	-moz-column-span: all;
+	font-size: 2em;
+	height: 70px;
+}
+dl {
+	font-size: 70%;
+	color: blue;
+	padding: 5px 10px 3px;
+	margin: 0 0 15px;
+	border: 2px solid blue;
+	height: 72px;
+}
+dt {
+	font-weight: bold;
+	font-style: normal;
+	width: 47%;
+	height: 100%;
+	float: left;
+}
+dd {
+	line-height: 120%;
+	padding: 0;
+	margin: 0 0 5px 47%;
+	width: 50%;
+}
+]]></style>
+</head>
+
+<body>
+<h1>you should not see the word fail</h1>
+
+<dl>
+	<dt>block1</dt>
+	<dd>block1 block1</dd>
+	<dd>block1 block1</dd>
+	<dd>block1 block1 block1</dd>
+	<dd>damer block1 block1</dd>
+</dl>
+
+<dl>
+	<dt>block2</dt>
+	<dd>block2 block2</dd>
+	<dd>block2 block2</dd>
+	<dd>block2 block2 block2</dd>
+	<dd>damer block2 block2</dd>
+</dl>
+
+<dl>
+	<dt>block3</dt>
+	<dd>block3 block3</dd>
+	<dd>block3 block3</dd>
+	<dd>block3 block3 block3</dd>
+	<dd>damer block3 block3</dd>
+</dl>
+
+<dl>
+	<dt>block4</dt>
+	<dd>block4 block4</dd>
+	<dd>block4 block4</dd>
+	<dd>block4 block4 block4</dd>
+	<dd>damer block4 block4</dd>
+</dl>
+
+<dl>
+	<dt>fail</dt>
+	<dd>fail fail</dd>
+	<dd>fail fail</dd>
+	<dd>fail fail fail</dd>
+	<dd>fail fail fail</dd>
+</dl>
+</body>
+</html>
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-fill-auto-block-children-002-ref.xht
@@ -0,0 +1,79 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+  <title>CSS Reftest Reference</title>
+  <link rel="author" title="Opera Software ASA" href="http://www.opera.com/" />
+  <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2013-08-16 -->
+  <meta name="flags" content="" />
+  <style type="text/css"><![CDATA[
+  body {margin: 8px;}
+
+  div
+  {
+  background-color: blue;
+  height: 200px;
+  width: 680px;
+  }
+
+  h1
+  {
+  color: white;
+  font-size: 2em;
+  line-height: 1.25; /* or 1.21875 to achieve a 39px tall line box */
+  margin-top: 8px; /* The margin-top of body and h1 will collapse into an 8px gap */
+  margin-bottom: 21px;
+  padding-top: 21px;
+  }
+
+  span#pass
+  {
+  color: blue;
+  font-size: 1.5em;
+  font-weight: bolder;
+  left: 698px;
+
+  /*
+
+  Expected result:
+
+  8px                                           688px
+  v                                              v
+  ************************************************
+  *                                              *
+  *  <h1>Test passes if the word "PASS!" is<br />*  1st line box
+  *  on the right &#8600;</h1>                   *  2nd line box
+  *                                              *
+  ************************************************
+  *                                              *
+  * <h2>nbsp;<h2>  <h2>nbsp;<h2>  <h2>nbsp;<h2>  *  <h2>PASS!</h2>
+  *                                              *
+  ************************************************
+                ^              ^
+               228px          458px
+
+  */
+
+  line-height: 1;
+  position: absolute;
+  top: 130px;
+
+  /*
+    8px : margin-top of body element
+   21px : margin-top of h1 element which must not collapse with body's margin-top
+   80px : content height: 2 line boxes required to render the "Test passes if ..." sentence
+   21px : margin-bottom of h1 element
+ ====================================
+  130px : top position of span#pass in document box
+  */
+  }
+  ]]></style>
+ </head>
+ <body>
+
+  <div>
+    <h1>Test passes if "PASS!" is<br />on the right &#8600;</h1>
+    <span id="pass">PASS!</span>
+  </div>
+
+ </body>
+</html>
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-fill-auto-block-children-002.xht
@@ -0,0 +1,99 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+  <title>CSS Multi-column Layout Test: '-moz-column-fill: auto' and '-moz-column-span: all' (complex)</title>
+  <link rel="author" title="Opera Software ASA" href="http://www.opera.com/" />
+  <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2013-08-16 -->
+  <link rel="help" href="http://www.w3.org/TR/css3-multicol/#-moz-column-span" title="6.1. '-moz-column-span'" />
+  <link rel="help" href="http://www.w3.org/TR/css3-multicol/#pagination-and-overflow-outside-multicol" title="8.2. Pagination and overflow outside multicol elements" />
+  <link rel="match" href="multicol-fill-auto-block-children-002-ref.xht" />
+
+  <meta name="flags" content="" />
+  <meta name="assert" content="This test checks that if '-moz-column-fill' is set to 'auto' and a multicolumn element content is solely made of block container boxes, then it should fill column boxes sequentially with such content and, in this test, it should overflow outside of it. This test relies on the idea that a '-moz-column-span: all' element will occupy more space in a multi-column element than a '-moz-column-span: none' element, therefore reducing available space for content in column boxes." />
+  <style type="text/css"><![CDATA[
+  html {background-color: white;}
+
+  body
+  {
+  background-color: blue;
+  height: 200px;
+  margin: 8px;
+  width: 680px;
+
+  -moz-column-count: 3;
+  -moz-column-fill: auto;
+  -moz-column-gap: 10px;
+
+  /*
+  So, each column box should be
+  [680px minus (2 mult 10px)] divided by 3 == 220px wide
+  */
+  }
+
+  h1
+  {
+  color: white;
+  -moz-column-span: all;
+  font-size: 2em;
+  line-height: 1.25; /* or 1.21875 to achieve a 39px tall line box */
+  margin: 21px 0em;
+  /*
+   21px : margin-top of h1 element which must not collapse with body's margin-top
+   80px : content height: 2 line boxes required to render the "Test passes if ..." sentence
+   21px : margin-bottom of h1 element
+ ====================================
+  122px : margin box height of h1 element
+  */
+  }
+
+  h2
+  {
+  color: blue;
+  font-size: 1.5em;
+  line-height: 1;
+  margin: 0 0 2.25em;
+  /*
+    0px : margin-top of h2 element
+   24px : content height: 1 line box required to render all the nbsp; and PASS! word
+   54px : margin-bottom of h2 element
+ ====================================
+   78px : margin box height of h2 element
+  */
+  }
+  ]]></style>
+ </head>
+
+ <body>
+
+  <h1>Test passes if "PASS!" is<br />on the right &#8600;</h1>
+
+  <h2>&nbsp;</h2>
+
+  <h2>&nbsp;</h2>
+
+  <h2>&nbsp;</h2>
+
+  <h2>PASS!</h2>
+
+  <!--
+
+  Expected result:
+
+  8px                                           688px
+  v                                              v
+  ************************************************
+  *                                              *
+  *  <h1>Test passes if the word "PASS!" is<br />*  1st line box
+  *  on the right &#8600;</h1>                   *  2nd line box
+  *                                              *
+  ************************************************
+  *                                              *
+  * <h2>nbsp;<h2>  <h2>nbsp;<h2>  <h2>nbsp;<h2>  *  <h2>PASS!</h2>
+  *                                              *
+  ************************************************
+                ^              ^
+               228px          458px
+  -->
+
+ </body>
+</html>
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-fill-auto-block-children-ref.xht
@@ -0,0 +1,28 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
+"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+<title>multicol | -moz-column-span: all | -moz-column-fill: auto</title>
+<link rel="author" title="Opera Software ASA" href="http://www.opera.com/"/>
+<style type="text/css"><![CDATA[
+html {
+	background: white;
+}
+body {
+	background: blue;
+	width: 1200px;
+	height: 492px;
+}
+h1 {
+	font-size: 2em;
+	margin: 0;
+	padding-top: 0.66em;
+}
+]]></style>
+</head>
+
+<body>
+<h1>you should not see the word fail</h1>
+
+</body>
+</html>
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-fill-auto.xht
@@ -0,0 +1,55 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
+"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+<title>multicolumn | -moz-column-fill-auto</title>
+<meta name="assert" content="This test checks that -moz-columns are properly balanced when '-moz-column-fill: auto' is set"/>
+<link rel="author" title="howcome@opera.com" href="http://www.opera.com/"/>
+<link rel="help" href="http://www.w3.org/TR/css3-multicol/#filling--moz-columns"/>
+<link rel="match" href="multicol-fill-ref.xht"/>
+<meta name="flags" content="ahem"/>
+<style type="text/css"><![CDATA[
+@font-face {
+  font-family: Ahem;
+  src: url("../../../fonts/Ahem.ttf");
+}
+]]></style>
+<style type="text/css"><![CDATA[
+body>div {
+	font-family: ahem;
+	font-size: 1.25em;
+	line-height: 1em;
+	color: green;
+	height: 3em;
+	width: 2em;
+	orphans: 1;
+	widows: 1;
+	position: relative;
+	margin: 1em;
+}
+div.col {
+	-moz-column-count: 2;
+	-moz-column-fill: auto;
+	-moz-column-gap: 0;
+}
+div.red {
+	background: red; position: absolute; z-index: -1;
+}
+]]></style>
+</head>
+
+<body>
+
+<div class='col'>
+<div class='red' style="top: 0; left: 0; height: 3em; width: 1em;"></div>
+<div class='red' style="top: 0; left: 0; height: 1em; width: 2em;"></div>
+o<br/>t<br/>
+o<br/>t<br/>
+</div>
+
+<div class='ref'>
+oo<br/>t<br/>o
+</div>
+
+</body>
+</html>
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-fill-balance-001-ref.xht
@@ -0,0 +1,49 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
+"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+<title>multicolumn | -moz-column-fill</title>
+<link rel="author" title="howcome@opera.com" href="http://www.opera.com/"/>
+<meta name="flags" content="ahem"/>
+<style type="text/css"><![CDATA[
+@font-face {
+  font-family: Ahem;
+  src: url("../../../fonts/Ahem.ttf");
+}
+]]></style>
+<style type="text/css"><![CDATA[
+body>div {
+	font-family: ahem;
+	font-size: 1.25em;
+	line-height: 1em;
+	color: green;
+	height: 3em;
+	width: 2em;
+	orphans: 1;
+	widows: 1;
+	position: relative;
+	margin: 1em;
+}
+div.col {
+	-moz-column-count: 2;
+	-moz-column-fill: balance;
+	-moz-column-gap: 0;
+}
+div.red {
+	background: red; position: absolute; z-index: -1;
+}
+]]></style>
+</head>
+
+<body>
+
+<div class='ref'>
+oo<br/>tt
+</div>
+
+<div class='ref'>
+oo<br/>tt
+</div>
+
+</body>
+</html>
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-fill-balance-001.xht
@@ -0,0 +1,54 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
+"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+<title>multicolumn | -moz-column-fill</title>
+<meta name="assert" content="This test checks that -moz-columns are properly balanced when '-moz-column-fill: balance' is set"/>
+<link rel="author" title="howcome@opera.com" href="http://www.opera.com/"/>
+<link rel="help" href="http://www.w3.org/TR/css3-multicol/#filling--moz-columns"/>
+<link rel="match" href="multicol-fill-balance-001-ref.xht"/>
+<meta name="flags" content="ahem"/>
+<style type="text/css"><![CDATA[
+@font-face {
+  font-family: Ahem;
+  src: url("../../../fonts/Ahem.ttf");
+}
+]]></style>
+<style type="text/css"><![CDATA[
+body>div {
+	font-family: ahem;
+	font-size: 1.25em;
+	line-height: 1em;
+	color: green;
+	height: 3em;
+	width: 2em;
+	orphans: 1;
+	widows: 1;
+	position: relative;
+	margin: 1em;
+}
+div.col {
+	-moz-column-count: 2;
+	-moz-column-fill: balance;
+	-moz-column-gap: 0;
+}
+div.red {
+	background: red; position: absolute; z-index: -1;
+}
+]]></style>
+</head>
+
+<body>
+
+<div class='col'>
+<div class='red' style="top: 0; left: 0; height: 2em; width: 2em;"></div>
+o<br/>t<br/>
+o<br/>t<br/>
+</div>
+
+<div class='ref'>
+oo<br/>tt
+</div>
+
+</body>
+</html>
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-fill-ref.xht
@@ -0,0 +1,21 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
+"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+<title>multicolumn | -moz-column-gap</title>
+<link rel="author" title="Opera Software ASA" href="http://www.opera.com/"/>
+<style type="text/css"><![CDATA[
+div {
+	background: yellow;
+	height: 5em;
+	width: 30em;
+}
+]]></style>
+</head>
+
+<body>
+
+<div></div>
+
+</body>
+</html>
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-gap-000-ref.xht
@@ -0,0 +1,34 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+  <title>CSS Reftest Reference</title>
+  <link rel="author" title="Hakon Wium Lie" href="mailto:howcome@opera.com" />
+  <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2013-08-25 -->
+  <meta name="flags" content="ahem" />
+<style type="text/css"><![CDATA[
+@font-face {
+  font-family: Ahem;
+  src: url("../../../fonts/Ahem.ttf");
+}
+]]></style>
+  <style type="text/css"><![CDATA[
+  div
+  {
+  font: 1.25em/1 Ahem;
+  margin: 1em 0;
+  width: 30em;
+  }
+
+  span {color: yellow;}
+  ]]></style>
+ </head>
+ <body>
+
+  <p>Test passes if the 2 horizontal bars are <strong>identical</strong>.</p>
+
+  <div>1234567890<span>1234567890</span>1234567890</div>
+
+  <div>1234567890<span>1234567890</span>1234567890</div>
+
+ </body>
+</html>
\ No newline at end of file
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-gap-000.xht
@@ -0,0 +1,47 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+  <title>CSS Multi-column Layout Test: -moz-column-gap (basic)</title>
+  <link rel="author" title="Hakon Wium Lie" href="mailto:howcome@opera.com" />
+  <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2013-08-25 -->
+  <link rel="help" href="http://www.w3.org/TR/css3-multicol/#-moz-column-gap" title="4.1 '-moz-column-gap'" />
+  <link rel="match" href="multicol-gap-000-ref.xht" />
+  <meta name="flags" content="ahem" />
+  <meta name="assert" content="This test checks that column gap appears between two -moz-columns." />
+<style type="text/css"><![CDATA[
+@font-face {
+  font-family: Ahem;
+  src: url("../../../fonts/Ahem.ttf");
+}
+]]></style>
+  <style type="text/css"><![CDATA[
+  div
+  {
+  font: 1.25em/1 Ahem;
+  margin: 1em 0;
+  width: 30em;
+  }
+
+  div#test
+  {
+  background-color: yellow;
+  orphans: 1;
+  widows: 1;
+
+  -moz-column-width: 10em;
+  -moz-column-gap: 10em;
+  }
+
+  span {color: yellow;}
+  ]]></style>
+ </head>
+ <body>
+
+  <p>Test passes if the 2 horizontal bars are <strong>identical</strong>.</p>
+
+  <div id="test">1234567890<br />1234567890</div>
+
+  <div id="reference">1234567890<span>1234567890</span>1234567890</div>
+
+ </body>
+</html>
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-gap-001-ref.xht
@@ -0,0 +1,22 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+  <title>CSS Reftest Reference</title>
+  <link rel="author" title="Opera Software ASA" href="http://www.opera.com/" />
+  <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2013-08-05 -->
+  <meta name="flags" content="image" />
+  <style type="text/css"><![CDATA[
+  div {margin: 1.25em;}
+
+  img {vertical-align: top;}
+  ]]></style>
+ </head>
+ <body>
+  <p>Test passes if the 2 stripes are <strong>identical</strong>.</p>
+
+  <div><img src="support/black20x20.png" alt="Image download support must be enabled" /><img src="support/swatch-yellow.png" width="20" height="20" alt="Image download support must be enabled" /><img src="support/black20x20.png" alt="Image download support must be enabled" /></div>
+
+  <div><img src="support/black20x20.png" alt="Image download support must be enabled" /><img src="support/swatch-yellow.png" width="20" height="20" alt="Image download support must be enabled" /><img src="support/black20x20.png" alt="Image download support must be enabled" /></div>
+
+ </body>
+</html>
\ No newline at end of file
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-gap-001.xht
@@ -0,0 +1,44 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+  <title>CSS Multi-column Layout Test: '-moz-column-gap: normal'</title>
+  <link rel="author" title="Opera Software ASA" href="http://www.opera.com/" />
+  <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2013-08-05 -->
+  <link rel="help" href="http://www.w3.org/TR/css3-multicol/#-moz-column-gap" title="4.1. '-moz-column-gap'" />
+  <link rel="match" href="multicol-gap-001-ref.xht" />
+  <meta name="flags" content="ahem may" />
+  <meta name="assert" content="This test checks that the 'normal' column gap is 1em, which is suggested -- and not prescribed -- by the specification." />
+<style type="text/css"><![CDATA[
+@font-face {
+  font-family: Ahem;
+  src: url("../../../fonts/Ahem.ttf");
+}
+]]></style>
+  <style type="text/css"><![CDATA[
+  div
+  {
+  background-color: yellow;
+  color: black;
+  font: 1.25em/1 Ahem;
+  margin: 1em;
+  orphans: 1;
+  widows: 1;
+  width: 3em;
+  }
+
+  div.multicol
+  {
+  -moz-column-gap: normal;
+  -moz-column-width: 1em;
+  }
+
+  span {padding-right: 1em;}
+  ]]></style>
+ </head>
+ <body>
+  <p>Test passes if the 2 stripes are <strong>identical</strong>.</p>
+
+  <div class="multicol">x<br />x</div>
+  <div><span>x</span>x</div>
+ </body>
+</html>
\ No newline at end of file
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-gap-002-ref.xht
@@ -0,0 +1,31 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+  <title>CSS Reftest Reference</title>
+  <link rel="author" title="Opera Software ASA" href="http://www.opera.com/" />
+  <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2013-08-05 -->
+  <meta name="flags" content="image" />
+  <style type="text/css"><![CDATA[
+  table
+  {
+  background-color: yellow;
+  border-spacing: 0px;
+  border: gray solid 1em;
+  font: 1.25em/1 serif;
+  }
+
+  td {padding: 0 1em 0 0;}
+
+  img, td {vertical-align: top;}
+
+  td#last-cell {padding-right: 0;}
+  ]]></style>
+ </head>
+ <body>
+ <table>
+   <tr>
+     <td><img src="support/black20x20.png" width="40" height="40" alt="Image download support must be enabled" /></td><td><img src="support/swatch-blue.png" width="40" height="40" alt="Image download support must be enabled" /></td><td><img src="support/swatch-blue.png" width="40" height="40" alt="Image download support must be enabled" /></td><td id="last-cell"><img src="support/black20x20.png" width="40" height="40" alt="Image download support must be enabled" /></td>
+    </tr>
+  </table>
+ </body>
+</html>
\ No newline at end of file
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-gap-002.xht
@@ -0,0 +1,46 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+  <title>CSS Multi-column Layout Test: -moz-column-gap (basic)</title>
+  <link rel="author" title="Opera Software ASA" href="http://www.opera.com/" />
+  <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2013-08-05 -->
+  <link rel="help" href="http://www.w3.org/TR/css3-multicol/#-moz-column-gap" title="4.1. '-moz-column-gap'" />
+  <link rel="match" href="multicol-gap-002-ref.xht" />
+  <meta name="flags" content="ahem" />
+<style type="text/css"><![CDATA[
+@font-face {
+  font-family: Ahem;
+  src: url("../../../fonts/Ahem.ttf");
+}
+]]></style>
+  <style type="text/css"><![CDATA[
+  div
+  {
+  background-color: yellow;
+  border: gray solid 1em;
+  color: black;
+  font: 1.25em/1 Ahem;
+  orphans: 1;
+  widows: 1;
+  width: 11em;
+
+  -moz-column-count: 4;
+  -moz-column-gap: 1em;
+  }
+
+  span {color: blue;}
+  ]]></style>
+ </head>
+ <body>
+  <div>
+	bl ac
+  <span>
+	bl ue
+  </span>
+  <span>
+	bl ue
+  </span>
+	bl ac
+  </div>
+ </body>
+</html>
\ No newline at end of file
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-gap-003.xht
@@ -0,0 +1,46 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+  <title>CSS Multi-column Layout Test: '-moz-column-gap: normal'</title>
+  <link rel="author" title="Opera Software ASA" href="http://www.opera.com/" />
+  <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2013-08-05 -->
+  <link rel="help" href="http://www.w3.org/TR/css3-multicol/#-moz-column-gap" title="4.1. '-moz-column-gap'" />
+  <link rel="match" href="multicol-gap-002-ref.xht" />
+  <meta name="flags" content="ahem may" />
+<style type="text/css"><![CDATA[
+@font-face {
+  font-family: Ahem;
+  src: url("../../../fonts/Ahem.ttf");
+}
+]]></style>
+  <style type="text/css"><![CDATA[
+  div
+  {
+  background-color: yellow;
+  border: gray solid 1em;
+  color: black;
+  font: 1.25em/1 Ahem;
+  orphans: 1;
+  widows: 1;
+  width: 11em;
+
+  -moz-column-count: 4;
+  -moz-column-gap: normal;
+  }
+
+  span {color: blue;}
+  ]]></style>
+ </head>
+ <body>
+  <div>
+	bl ac
+  <span>
+	bl ue
+  </span>
+  <span>
+	bl ue
+  </span>
+	bl ac
+  </div>
+ </body>
+</html>
\ No newline at end of file
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-gap-fraction-001-ref.xht
@@ -0,0 +1,73 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+  <title>CSS Reftest Reference</title>
+  <link rel="author" title="Opera Software ASA" href="http://www.opera.com/" />
+  <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2013-08-05 -->
+  <meta name="flags" content="ahem" />
+<style type="text/css"><![CDATA[
+@font-face {
+  font-family: Ahem;
+  src: url("../../../fonts/Ahem.ttf");
+}
+]]></style>
+  <style type="text/css"><![CDATA[
+  body > div
+  {
+  background-color: gray;
+  font: 1.25em/1 Ahem;
+  height: 4em;
+  position: relative;
+  width: 14.5em;
+  }
+
+  p, div > div
+  {
+  background-color: blue;
+  height: 1em;
+  left: 0;
+  margin: 0;
+  position: absolute;
+  top: 0;
+  width: 4em;
+  }
+
+  div > div
+  {
+  background-color: black;
+  height: 4em;
+  }
+
+  p {left: 7.5em;}
+
+  p + p
+  {
+  left: 8.5em;
+  top: 1em;
+  }
+
+  p + p + p
+  {
+  left: 9.5em;
+  top: 2em;
+  }
+
+  p + p + p + p
+  {
+  left: 10.5em;
+  top: 3em;
+  }
+  ]]></style>
+ </head>
+ <body>
+
+  <div>
+	<div></div>
+	<p></p>
+	<p></p>
+	<p></p>
+	<p></p>
+  </div>
+
+ </body>
+</html>
\ No newline at end of file
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-gap-fraction-001.xht
@@ -0,0 +1,61 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+  <title>CSS Multi-column Layout Test: '-moz-column-gap' with increasing values</title>
+  <link rel="author" title="Opera Software ASA" href="http://www.opera.com/" />
+  <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2013-08-05 -->
+  <link rel="help" href="http://www.w3.org/TR/css3-multicol/#-moz-column-gap" title="4.1. '-moz-column-gap'" />
+  <link rel="match" href="multicol-gap-fraction-001-ref.xht" />
+  <meta name="flags" content="ahem" />
+<style type="text/css"><![CDATA[
+@font-face {
+  font-family: Ahem;
+  src: url("../../../fonts/Ahem.ttf");
+}
+]]></style>
+  <style type="text/css"><![CDATA[
+  div
+  {
+  background-color: gray;
+  font: 1.25em/1 Ahem;
+  width: 14.5em;
+  orphans: 1;
+  widows: 1;
+
+  -moz-column-count: 2;
+  -moz-column-gap: 0.5em;
+  }
+
+  #two {-moz-column-gap: 2.5em;}
+
+  #three {-moz-column-gap: 4.5em;}
+
+  #four {-moz-column-gap: 6.5em;}
+
+  span {color: blue;}
+  ]]></style>
+ </head>
+ <body>
+
+  <div id="one">
+	blac
+	<span>blue</span>
+  </div>
+
+  <div id="two">
+	blac
+	<span>blue</span>
+  </div>
+
+  <div id="three">
+	blac
+	<span>blue</span>
+  </div>
+
+  <div id="four">
+	blac
+	<span>blue</span>
+  </div>
+
+ </body>
+</html>
\ No newline at end of file
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-gap-large-001-ref.xht
@@ -0,0 +1,21 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+  <title>CSS Reftest Reference</title>
+  <link rel="author" title="Opera Software ASA" href="http://www.opera.com/" />
+  <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2013-08-06 -->
+  <meta name="flags" content="image" />
+  <style type="text/css"><![CDATA[
+  img {vertical-align: top;}
+  ]]></style>
+ </head>
+ <body>
+    <div><img src="support/swatch-gray.png" width="260" height="20" alt="Image download support must be enabled" /></div>
+
+  <div><img src="support/swatch-gray.png" width="20" height="40" alt="Image download support must be enabled" /><img src="support/black20x20.png" width="40" height="40" alt="Image download support must be enabled" /><img src="support/swatch-yellow.png" width="40" height="40" alt="Image download support must be enabled" /><img src="support/swatch-blue.png" width="40" height="40" alt="Image download support must be enabled" /><img src="support/swatch-yellow.png" width="40" height="40" alt="Image download support must be enabled" /><img src="support/swatch-blue.png" width="40" height="40" alt="Image download support must be enabled" /><img src="support/swatch-yellow.png" width="20" height="40" alt="Image download support must be enabled" /><img src="support/swatch-gray.png" width="20" height="40"
+alt="Image download support must be enabled" /><img src="support/black20x20.png" width="40" height="40" alt="Image download support must be enabled" /></div>
+
+  <div><img src="support/swatch-gray.png" width="260" height="20" alt="Image download support must be enabled" /></div>
+
+ </body>
+</html>
\ No newline at end of file
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-gap-large-001.xht
@@ -0,0 +1,61 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+  <title>CSS Multi-column Layout Test: '-moz-column-gap' with large value</title>
+  <link rel="author" title="Opera Software ASA" href="http://www.opera.com/" />
+  <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2013-08-06 -->
+  <link rel="help" href="http://www.w3.org/TR/css3-multicol/#-moz-column-gap" title="4.1 '-moz-column-gap" />
+  <link rel="match" href="multicol-gap-large-001-ref.xht" />
+  <meta name="flags" content="ahem" />
+  <meta name="assert" content="This test checks that when '-moz-column-gap' is large and when used '-moz-column-width' is narrow, then content extends into -moz-column-gap until its middle and content can extend, overflow outside the edges of the multi-colum element if 'overflow' is set to 'visible'." />
+<style type="text/css"><![CDATA[
+@font-face {
+  font-family: Ahem;
+  src: url("../../../fonts/Ahem.ttf");
+}
+]]></style>
+  <style type="text/css"><![CDATA[
+  div
+  {
+  background-color: yellow;
+  border: gray solid 1em;
+  color: black;
+  font: 1.25em/1 Ahem;
+  orphans: 1;
+  widows: 1;
+  width: 11em;
+
+  -moz-column-count: 4;
+  -moz-column-gap: 4em;
+
+  /*
+  N == 4;
+  W == 0em;
+  */
+
+  /*
+  In this test, the content of first 3 column
+  boxes extend into middle of -moz-column-gap and
+  content of the 4th column box extend outside the
+  right edge of multi-column. The gray border-right of
+  multi-column elemen overlaps partially the 3rd
+  -moz-column-gap.
+  */
+  }
+
+  span {color: blue;}
+  ]]></style>
+ </head>
+ <body>
+  <div>
+  bl ac
+  <span>
+  bl ue
+  </span>
+  <span>
+  bl ue
+  </span>
+  bl ac
+  </div>
+ </body>
+</html>
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-gap-large-002-ref.xht
@@ -0,0 +1,24 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+  <title>CSS Reftest Reference</title>
+  <link rel="author" title="Opera Software ASA" href="http://www.opera.com/" />
+  <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2013-08-06 -->
+  <meta name="flags" content="image" />
+  <style type="text/css"><![CDATA[
+  div {font: 1.25em/1 serif;}
+
+  img {vertical-align: top;}
+  ]]></style>
+ </head>
+ <body>
+    <div><img src="support/swatch-gray.png" width="260" height="20" alt="Image download support must be enabled" /></div>
+
+  <div><img src="support/swatch-gray.png" width="20" height="40" alt="Image download support must be enabled" /><img src="support/black20x20.png" width="40" height="40" alt="Image download support must be enabled" /><img src="support/swatch-yellow.png" width="110" height="40" alt="Image download support must be enabled" /><img src="support/swatch-blue.png" width="40" height="40" alt="Image download support must be enabled" /><img src="support/swatch-yellow.png" width="30" height="40" alt="Image download support must be enabled" /><img src="support/swatch-gray.png" width="20" height="40" alt="Image download support must be enabled" /></div>
+
+  <div><img src="support/swatch-gray.png" width="20" height="40" alt="Image download support must be enabled" /><img src="support/swatch-blue.png" width="40" height="40" alt="Image download support must be enabled" /><img src="support/swatch-yellow.png" width="110" height="40" alt="Image download support must be enabled" /><img src="support/black20x20.png" width="40" height="40" alt="Image download support must be enabled" /><img src="support/swatch-yellow.png" width="30" height="40" alt="Image download support must be enabled" /><img src="support/swatch-gray.png" width="20" height="40" alt="Image download support must be enabled" /></div>
+
+  <div><img src="support/swatch-gray.png" width="260" height="20" alt="Image download support must be enabled" /></div>
+
+ </body>
+</html>
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-gap-large-002.xht
@@ -0,0 +1,51 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+  <title>CSS Multi-column Layout Test: '-moz-column-gap' with large value</title>
+  <link rel="author" title="Opera Software ASA" href="http://www.opera.com/" />
+  <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2013-08-06 -->
+  <link rel="help" href="http://www.w3.org/TR/css3-multicol/#-moz-column-gap" title="4.1 '-moz-column-gap" />
+  <link rel="match" href="multicol-gap-large-002-ref.xht" />
+  <meta name="flags" content="ahem" />
+<style type="text/css"><![CDATA[
+@font-face {
+  font-family: Ahem;
+  src: url("../../../fonts/Ahem.ttf");
+}
+]]></style>
+  <style type="text/css"><![CDATA[
+  div
+  {
+  background-color: yellow;
+  border: gray solid 1em;
+  color: black;
+  font: 1.25em/1 Ahem;
+  orphans: 1;
+  widows: 1;
+  width: 11em;
+
+  -moz-column-count: 2;
+  -moz-column-gap: 4em;
+
+  /*
+  N == 2;
+  W == 3.5em;
+  */
+  }
+
+  span {color: blue;}
+  ]]></style>
+ </head>
+ <body>
+  <div>
+  bl ac
+  <span>
+  bl ue
+  </span>
+  <span>
+  bl ue
+  </span>
+  bl ac
+  </div>
+ </body>
+</html>
\ No newline at end of file
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-gap-negative-001.xht
@@ -0,0 +1,47 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+  <title>CSS Multi-column Layout Test: -moz-column-gap with negative value</title>
+  <link rel="author" title="Opera Software ASA" href="http://www.opera.com/" />
+  <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2013-08-06 -->
+  <link rel="help" href="http://www.w3.org/TR/css3-multicol/#-moz-column-gap" title="4.1. '-moz-column-gap'" />
+  <link rel="match" href="multicol-gap-002-ref.xht" />
+  <meta name="flags" content="ahem invalid" />
+<style type="text/css"><![CDATA[
+@font-face {
+  font-family: Ahem;
+  src: url("../../../fonts/Ahem.ttf");
+}
+]]></style>
+  <style type="text/css"><![CDATA[
+  div
+  {
+  background-color: yellow;
+  border: gray solid 1em;
+  color: black;
+  font: 1.25em/1 Ahem;
+  orphans: 1;
+  widows: 1;
+  width: 11em;
+
+  -moz-column-count: 4;
+  -moz-column-gap: 1em;
+  -moz-column-gap: -1em;
+  }
+
+  span {color: blue;}
+  ]]></style>
+ </head>
+ <body>
+  <div>
+	bl ac
+  <span>
+	bl ue
+  </span>
+  <span>
+	bl ue
+  </span>
+	bl ac
+  </div>
+ </body>
+</html>
\ No newline at end of file
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-height-001-ref.xht
@@ -0,0 +1,28 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+  <title>CSS Reftest Reference</title>
+  <link rel="author" title="Opera Software ASA" href="http://www.opera.com/" />
+  <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2013-08-06 -->
+  <meta name="flags" content="image" />
+  <style type="text/css"><![CDATA[
+  img
+  {
+  left: 135px;
+  /* 6em + (2em/2) - (10px/2) == 135px */
+  position: relative;
+  vertical-align: top;
+  }
+
+  img + img {left: 285px;}
+  /* 6em + 2em + 6em + (2em/2) - (10px/2) - 10px == 285px */
+  ]]></style>
+ </head>
+ <body>
+
+  <p>Test passes if there are 2 blue vertical stripes of equal height.</p>
+
+  <div><img src="support/swatch-blue.png" width="10" height="160" alt="Image download support must be enabled" /><img src="support/swatch-blue.png" width="10" height="160" alt="Image download support must be enabled" /></div>
+
+ </body>
+</html>
\ No newline at end of file
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-height-001.xht
@@ -0,0 +1,42 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+  <title>CSS Multi-column Layout Test: -moz-column-count and height</title>
+  <link rel="author" title="Opera Software ASA" href="http://www.opera.com/" />
+  <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2013-08-06 -->
+  <link rel="help" href="http://www.w3.org/TR/css3-multicol/#-moz-column-gap" title="4.1. '-moz-column-gap'" />
+  <link rel="match" href="multicol-height-001-ref.xht" />
+  <meta name="flags" content="ahem" />
+  <meta name="assert" content="This test checks that length of column rules is equal to the length of the -moz-columns and if a nth column box overflows outside the available width of a multi-column element, then an (n-1)th column rule should be drawn. In this test, a 3rd column box is created outside the content edge of the multi-column element: therefore, a 2nd blue column rule should be drawn accordingly." />
+<style type="text/css"><![CDATA[
+@font-face {
+  font-family: Ahem;
+  src: url("../../../fonts/Ahem.ttf");
+}
+]]></style>
+  <style type="text/css"><![CDATA[
+  div
+  {
+  color: white;
+  font: 1.25em/1 Ahem;
+  height: 8em;
+  width: 14em;
+
+  -moz-column-count: 2;
+  -moz-column-fill: auto;
+  -moz-column-gap: 2em;
+  -moz-column-rule: blue solid 10px;
+  }
+  ]]></style>
+ </head>
+ <body>
+  <p>Test passes if there are 2 blue vertical stripes of equal height.</p>
+
+  <div>
+  1st col 1st col 1st col
+  1st col 2nd col 2nd col
+  2nd col 2nd col 3rd col
+  3rd col 3rd col 3rd col
+  </div>
+ </body>
+</html>
\ No newline at end of file
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-height-block-child-001-ref.xht
@@ -0,0 +1,55 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+  <title>CSS Reftest Reference</title>
+  <link rel="author" title="Opera Software ASA" href="http://www.opera.com/" />
+  <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2013-08-08 -->
+  <meta name="flags" content="image" />
+  <style type="text/css"><![CDATA[
+  div
+  {
+  background-color: blue;
+  font: 1.25em/1 serif;
+  }
+
+  div#top
+  {
+  height: 5em;
+  width: 22em;
+  }
+
+  div#bottom
+  {
+  height: 3em;
+  width: 14em;
+  }
+
+  img {vertical-align: top;}
+  ]]></style>
+ </head>
+ <body>
+    <div id="top"><img src="support/black20x20.png" width="60" height="100" alt="Image download support must be enabled" /></div>
+
+  <div id="bottom"><img src="support/swatch-orange.png" width="60" height="60" alt="Image download support must be enabled" /></div>
+
+  <!--
+
+  Expected results:
+
+ 0em                        14em            22em
+  v                           v               v
+0 *********************************************
+  * bla                       |               *
+  * bla                       |               *
+  * bla                       |               *
+  * bla                       |               *
+5 * bla                       |               *
+6 * orn                       |****************
+7 * orn                       |
+8 * orn                       |
+  *****************************
+
+  -->
+
+ </body>
+</html>
\ No newline at end of file
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-height-block-child-001.xht
@@ -0,0 +1,102 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+  <title>CSS Multi-column Layout Test: multi-column element with child block (complex)</title>
+  <link rel="author" title="Opera Software ASA" href="http://www.opera.com/" />
+  <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2013-08-08 -->
+  <link rel="help" href="http://www.w3.org/TR/css3-multicol/#the-multi-column-model" title="2. The multi-column model" />
+  <link rel="bookmark" href="http://lists.w3.org/Archives/Public/www-style/2013Aug/0091.html" title="[css3-multicol] Nested multicolumn elements rendering" />
+  <link rel="match" href="multicol-height-block-child-001-ref.xht" />
+  <meta name="flags" content="ahem" />
+  <meta name="assert" content="This test checks that a nested multi-column element's inline content could be clipped horizontally." />
+<style type="text/css"><![CDATA[
+@font-face {
+  font-family: Ahem;
+  src: url("../../../fonts/Ahem.ttf");
+}
+]]></style>
+  <style type="text/css"><![CDATA[
+  div
+  {
+  background-color: blue;
+  font: 20px/1 Ahem;
+  height: 8em;
+  width: 14em;
+
+  -moz-column-count: 2;
+  -moz-column-gap: 2em;
+
+  /*
+
+  N == 2;
+
+  W == 6em;
+
+  H == 8em;
+
+  */
+  }
+
+  div#outer
+  {
+  color: black;
+  -moz-column-fill: auto;
+  }
+
+  div#inner
+  {
+  color: orange;
+  -moz-column-fill: balance;
+  }
+  ]]></style>
+ </head>
+ <body>
+
+  <div id="outer">
+  bla bla bla bla bla
+
+    <div id="inner">orn orn orn zzz zzz zzz</div>
+
+  </div>
+
+  <!--
+  Both column boxes of div#inner start in the 1st
+  column box of div#outer multi-column element.
+  The first 3 lines boxes of 1st
+  column box of div#inner will be rendered inside the
+  1st column box of div#outer but not its 2nd.
+  Because 1st column box of div#outer is
+  6em wide while the div#inner multi-column element
+  is 14em wide, this makes the first 3 line boxes
+  (with the 'z' trios) of 2nd column box of div#inner
+  clipped.
+
+  Then, at this point, the div#inner multi-column
+  element should be fragmented in order to continue to
+  render the 5 empty line boxes it has into the
+  2nd column box of div#outer. Since those 5 line
+  boxes are empty, we only see the extension it
+  creates horizontally, which is
+  14em - 6em == 8em horizontally and
+  5 lines boxes == 5em tall
+
+
+  Expected results:
+
+ 0em                        14em            22em
+  v                           v               v
+0 *********************************************
+  * bla                       |               *
+  * bla                       |               *
+  * bla                       |               *
+  * bla                       |               *
+5 * bla                       |               *
+6 * orn                       |****************
+7 * orn                       |
+8 * orn                       |
+  *****************************
+
+  -->
+
+ </body>
+</html>
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-inherit-001-ref.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+  <title>CSS Reftest Reference</title>
+  <link rel="author" title="Opera Software ASA" href="http://www.opera.com/" />
+  <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2013-08-08 -->
+  <meta name="flags" content="image" />
+  <style type="text/css"><![CDATA[
+  div
+  {
+  background-color: yellow;
+  font: 1.25em/1 serif;
+  margin: 0em 1em;
+  padding: 0em 1em 1em;
+  width: 30em;
+  }
+
+  img
+  {
+  padding-right: 1em;
+  vertical-align: top;
+  }
+
+  img.-moz-column-gap {margin-right: 2em;}
+
+  img#last {padding-right: 0em;}
+  ]]></style>
+ </head>
+ <body>
+
+  <div><img src="support/black20x20.png" width="40" height="60" alt="Image download support must be enabled" /><img src="support/black20x20.png" width="40" height="60" alt="Image download support must be enabled" /><img class="-moz-column-gap" src="support/black20x20.png" width="40" height="40" alt="Image download support must be enabled" /><img src="support/black20x20.png" width="40" height="60" alt="Image download support must be enabled" /><img src="support/black20x20.png" width="40" height="60" alt="Image download support must be enabled" /><img class="-moz-column-gap" src="support/black20x20.png" width="40" height="40" alt="Image download support must be enabled" /><img src="support/black20x20.png" width="40" height="60" alt="Image download support must be enabled" /><img src="support/black20x20.png"
+width="40" height="60" alt="Image download support must be enabled" /><img id="last" src="support/black20x20.png" width="40" height="40" alt="Image download support must be enabled" /></div>
+
+ </body>
+</html>
\ No newline at end of file
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-inherit-001.xht
@@ -0,0 +1,81 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+  <title>CSS Multi-column Layout Test: multicolumn and inheritance</title>
+  <link rel="author" title="Opera Software ASA" href="http://www.opera.com/" />
+  <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2013-08-08 -->
+  <link rel="help" href="http://www.w3.org/TR/css3-multicol/#pseudo-algorithm" title="3.4 Pseudo-algorithm" />
+  <link rel="match" href="multicol-inherit-001-ref.xht" />
+  <meta name="flags" content="ahem" />
+<style type="text/css"><![CDATA[
+@font-face {
+  font-family: Ahem;
+  src: url("../../../fonts/Ahem.ttf");
+}
+]]></style>
+  <style type="text/css"><![CDATA[
+  body
+  {
+  font: 1.25em/1 Ahem;
+  width: 34em;
+  }
+
+  body > div
+  {
+  -moz-column-count: 3;
+  -moz-column-gap: 1em;
+
+  /*
+  N == 3;
+
+    34em : available width
+  -  2em : horizontal margin of external div
+  -  2em : 2 column gaps
+ ==========
+    30em
+
+  So, W == 10em;
+
+    30em
+  -  6em : 3 mult by 2em: horizontal margin of 3 internal divs
+ ==========
+    24em : 8em for each of the 3 column boxes without their horizontal margins
+
+  */
+  }
+
+  div
+  {
+  background-color: yellow;
+  color: black;
+  margin: 0 1em 1em;
+  orphans: 1;
+  widows: 1;
+  }
+  ]]></style>
+ </head>
+ <body>
+
+  <div>
+	<div>
+		aa aa
+		aa aa
+		aa aa
+		aa aa
+	</div>
+	<div>
+		mm mm
+		mm mm
+		mm mm
+		mm mm
+	</div>
+	<div>
+		xx xx
+		xx xx
+		xx xx
+		xx xx
+	</div>
+  </div>
+
+ </body>
+</html>
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-inherit-002-ref.xht
@@ -0,0 +1,39 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+  <title>CSS Reftest Reference</title>
+  <link rel="author" title="Opera Software ASA" href="http://www.opera.com/" />
+  <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2013-08-08 -->
+  <meta name="flags" content="image" />
+  <style type="text/css"><![CDATA[
+  div
+  {
+  background-color: blue;
+  font: 1.25em/1 serif;
+  margin: 1em;
+  padding: 0em 1em 1em;
+  width: 30em;
+  }
+
+  img {vertical-align: top;}
+
+  img.-moz-column-gap
+  {
+  margin-left: -2em;
+  margin-right: 3em;
+  vertical-align: bottom;
+  }
+
+  img#last
+  {
+  margin-left: -2em;
+  vertical-align: bottom;
+  }
+  ]]></style>
+ </head>
+ <body>
+
+  <div><img src="support/black20x20.png" width="40" height="60" alt="Image download support must be enabled" /><img src="support/swatch-yellow.png" width="20" height="60" alt="Image download support must be enabled" /><img src="support/black20x20.png" width="40" height="60" alt="Image download support must be enabled" /><img src="support/swatch-yellow.png" width="20" height="60" alt="Image download support must be enabled" /><img src="support/black20x20.png" width="40" height="40" alt="Image download support must be enabled" /><img  class="-moz-column-gap" src="support/swatch-yellow.png" width="40" height="20" alt="Image download support must be enabled" /><img src="support/black20x20.png" width="40" height="60" alt="Image download support must be enabled" /><img src="support/swatch-yellow.png" width="20" height="60" alt="Image download support must be enabled" /><img src="support/black20x20.png" width="40" height="60" alt="Image download support must be enabled" /><img src="support/swatch-yellow.png" width="20" height="60" alt="Image download support must be enabled" /><img src="support/black20x20.png" width="40" height="40" alt="Image download support must be enabled" /><img  class="-moz-column-gap" src="support/swatch-yellow.png" width="40" height="20" alt="Image download support must be enabled" /><img src="support/black20x20.png" width="40" height="60" alt="Image download support must be enabled" /><img src="support/swatch-yellow.png" width="20" height="60" alt="Image download support must be enabled" /><img src="support/black20x20.png" width="40" height="60" alt="Image download support must be enabled" /><img src="support/swatch-yellow.png" width="20" height="60" alt="Image download support must be enabled" /><img src="support/black20x20.png" width="40" height="40" alt="Image download support must be enabled" /><img id="last" src="support/swatch-yellow.png" width="40" height="20" alt="Image download support must be enabled" /></div>
+
+ </body>
+</html>
\ No newline at end of file
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-inherit-002.xht
@@ -0,0 +1,88 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+  <title>CSS Multi-column Layout Test: '-moz-column-count' and inherit</title>
+  <link rel="author" title="Opera Software ASA" href="http://www.opera.com/" />
+  <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2013-08-08 -->
+  <link rel="help" href="http://www.w3.org/TR/css3-multicol/#cc" title="3.2 '-moz-column-count'" />
+  <link rel="help" href="http://www.w3.org/TR/css3-values/#common-keywords" title="3.1.1. CSS-wide keywords: 'initial' and 'inherit'" />
+  <link rel="match" href="multicol-inherit-002-ref.xht" />
+  <meta name="flags" content="ahem" />
+  <meta name="assert" content="This test checks that '-moz-column-count' can be inherited by setting it with the CSS-wide keyword 'inherit'." />
+<style type="text/css"><![CDATA[
+@font-face {
+  font-family: Ahem;
+  src: url("../../../fonts/Ahem.ttf");
+}
+]]></style>
+  <style type="text/css"><![CDATA[
+  body > div
+  {
+  background-color: blue;
+  -moz-column-count: 3;
+  -moz-column-gap: 1em;
+  font: 1.25em/1 Ahem;
+  width: 32em;
+
+  /*
+  N == 3;
+
+    32em
+  -  2em : 2 column gaps
+ ==========
+    30em : available width of the 3 inner multi-column elements
+
+  So, W == 10em;
+
+    30em
+  -  6em : 3 mult by 2em: horizontal margin of 3 inner multi-column elements
+  -  6em : 3 mult by 2em: horizontal -moz-column-gaps of all 3 inner multi-column elements
+ ==========
+    18em : 6em for each of the 3 column boxes without their own horizontal margins
+    So, each column boxes of inner multi-column elements is 2em wide.
+  */
+  }
+
+  div
+  {
+  color: black;
+  margin: 1em;
+  orphans: 1;
+  widows: 1;
+  }
+
+  div > div
+  {
+  background-color: yellow;
+  -moz-column-count: inherit;
+  -moz-column-gap: 1em;
+  }
+
+  div > div:first-child {margin-top: 0;}
+  ]]></style>
+ </head>
+ <body>
+
+  <div>
+	<div>
+		aa aa
+		aa aa
+		aa aa
+		aa aa
+	</div>
+	<div>
+		mm mm
+		mm mm
+		mm mm
+		mm mm
+	</div>
+	<div>
+		xx xx
+		xx xx
+		xx xx
+		xx xx
+	</div>
+  </div>
+
+ </body>
+</html>
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-inherit-003.xht
@@ -0,0 +1,69 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
+"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+<title>multicolumn | inheritance</title>
+<link rel="author" title="Opera Software ASA" href="http://www.opera.com/"/>
+<link rel="help" href="http://www.w3.org/TR/css3-multicol/#the-number-and-width-of--moz-columns"/>
+<link rel="match" href="multicol-inherit-3-ref.xht"/>
+<meta name="flags" content="ahem"/>
+<style type="text/css"><![CDATA[
+@font-face {
+  font-family: Ahem;
+  src: url("../../../fonts/Ahem.ttf");
+}
+]]></style>
+<style type="text/css"><![CDATA[
+body {
+	width: 75em;
+}
+body>div {
+	height: 2em;
+	-moz-column-width: 8em;
+}
+div {
+	font-family: ahem;
+	font-size: 1em;
+	line-height: 1em;
+	color: black;
+	background: yellow;
+	orphans: 1;
+	widows: 1;
+}
+div>div {
+	margin: 0 1em 1em;
+}
+div+div {
+	color: blue;
+}
+div+div+div {
+	color: pink;
+}
+]]></style>
+</head>
+
+<body>
+
+<div>
+	<div>
+		xx xx
+		xx xx
+		xx xx
+		xx xx
+	</div>
+	<div>
+		xx xx
+		xx xx
+		xx xx
+		xx xx
+	</div>
+	<div>
+		xx xx
+		xx xx
+		xx xx
+		xx xx
+	</div>
+</div>
+
+</body>
+</html>
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-inherit-004.xht
@@ -0,0 +1,61 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
+"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+<title>multicolumn | inheritance</title>
+<link rel="author" title="Opera Software ASA" href="http://www.opera.com/"/>
+<link rel="help" href="http://www.w3.org/TR/css3-multicol/#-moz-column-gaps-and-rules"/>
+<link rel="match" href="multicol-inherit-4-ref.xht"/>
+<meta name="flags" content="ahem"/>
+<style type="text/css"><![CDATA[
+@font-face {
+  font-family: Ahem;
+  src: url("../../../fonts/Ahem.ttf");
+}
+]]></style>
+<style type="text/css"><![CDATA[
+body>div {
+	width: 74em;
+	-moz-column-rule: 1em solid blue;
+}
+div {
+	font-family: ahem;
+	font-size: 1em;
+	line-height: 1em;
+	color: white;
+	background: white;
+	margin: 1em;
+	orphans: 1;
+	widows: 1;
+
+	-moz-column-count: 3;
+	-moz-column-gap: 7em;
+}
+]]></style>
+</head>
+
+<body>
+
+<div>
+	<div>
+		xx xx
+		xx xx
+		xx xx
+		xx xx
+	</div>
+	<div>
+		xx xx
+		xx xx
+		xx xx
+		xx xx
+	</div>
+	<div>
+		xx xx
+		xx xx
+		xx xx
+		xx xx
+	</div>
+</div>
+
+</body>
+</html>
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-inherit-3-ref.xht
@@ -0,0 +1,66 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
+"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+<title>multicolumn | inheritance</title>
+<link rel="author" title="Opera Software ASA" href="http://www.opera.com/"/>
+<style type="text/css"><![CDATA[
+body {
+	width: 75em;
+}
+body>div {
+	color: black;
+	background: yellow;
+	height: 2em;
+	position: relative;
+}
+div div {
+	position: absolute;
+	top: 0;
+	left: 0;
+}
+#two {left: 19em;}
+#three {left: 38em;}
+div div div {
+	font-family: ahem;
+	font-size: 1em;
+	line-height: 1em;
+	width: 2em;
+	height: 2em;
+	color: black;
+	position: absolute;
+	left: 1em;
+}
+.a2 {left: 4em;}
+.a3 {left: 10.5em;}
+.a4 {left: 13.5em;}
+#two div {color: blue;}
+#three div {color: pink;}
+]]></style>
+</head>
+
+<body>
+
+<div>
+	<div>
+		<div>xx xx</div>
+		<div class="a2">xx xx</div>
+		<div class="a3">xx xx</div>
+		<div class="a4">xx xx</div>
+	</div>
+	<div id="two">
+		<div>xx xx</div>
+		<div class="a2">xx xx</div>
+		<div class="a3">xx xx</div>
+		<div class="a4">xx xx</div>
+	</div>
+	<div id="three">
+		<div>xx xx</div>
+		<div class="a2">xx xx</div>
+		<div class="a3">xx xx</div>
+		<div class="a4">xx xx</div>
+	</div>
+</div>
+
+</body>
+</html>
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-inherit-4-ref.xht
@@ -0,0 +1,37 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
+"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+<title>multicolumn | inheritance</title>
+<link rel="author" title="Opera Software ASA" href="http://www.opera.com/"/>
+<style type="text/css"><![CDATA[
+body>div {
+	margin: 1em;
+	background: white;
+	width: 74em;
+	height: 5em;
+	position: relative;
+}
+div div {
+	background: blue;
+	height: 5em;
+	width: 1em;
+	position: absolute;
+	top: 0;
+	left: 23em;
+}
+div>div+div {
+	left: 50em;
+}
+]]></style>
+</head>
+
+<body>
+
+<div>
+	<div></div>
+	<div></div>
+</div>
+
+</body>
+</html>
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-list-item-001-ref.xht
@@ -0,0 +1,22 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+  <title>CSS Reftest Reference</title>
+  <link rel="author" title="Opera Software ASA" href="http://www.opera.com/" />
+  <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2013-08-10 -->
+  <meta name="flags" content="" />
+  <style type="text/css"><![CDATA[
+  div
+  {
+  background-color: black;
+  height: 100px;
+  width: 200px;
+  }
+   ]]></style>
+ </head>
+ <body>
+
+  <div></div>
+
+ </body>
+</html>
\ No newline at end of file
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-list-item-001.xht
@@ -0,0 +1,58 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+  <title>CSS Multi-column Layout Test: multi-column and list-item</title>
+  <link rel="author" title="Opera Software ASA" href="http://www.opera.com/" />
+  <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2013-08-10 -->
+  <link rel="help" href="http://www.w3.org/TR/css3-multicol/#pseudo-algorithm" title="3.4 Pseudo-algorithm" />
+  <link rel="match" href="multicol-list-item-001-ref.xht" />
+  <meta name="flags" content="ahem" />
+  <meta name="assert" content="This test checks that an unordered list of list items can be set to display its list-items in column boxes." />
+<style type="text/css"><![CDATA[
+@font-face {
+  font-family: Ahem;
+  src: url("../../../fonts/Ahem.ttf");
+}
+]]></style>
+  <style type="text/css"><![CDATA[
+  ul
+  {
+  background-color: black;
+  font: 1.25em/1 Ahem;
+  margin: 0em;
+  padding: 0em;
+  width: 10em;
+
+  -moz-column-gap: 0em;
+  -moz-column-width: 5em;
+  }
+
+  li, span {font-size: 1em;}
+
+  li
+  {
+  margin-left: 1em;
+  padding: 0em;
+  }
+
+  span {display: block;}
+  ]]></style>
+ </head>
+
+ <body>
+
+  <ul>
+	<li>1sli</li>
+	<li>2nli</li>
+	<li>3rli</li>
+	<li>4tli</li>
+	<li>5tli</li>
+	<li><span>6tli</span></li>
+	<li>7tli</li>
+	<li>8tli</li>
+	<li>9tli</li>
+	<li>10tl</li>
+  </ul>
+
+ </body>
+</html>
\ No newline at end of file
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-margin-001.xht
@@ -0,0 +1,76 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+  <title>CSS Multi-column Layout Test: multi-column and margin collapsing of first child (basic)</title>
+  <link rel="author" title="Opera Software ASA" href="http://www.opera.com/" />
+  <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2013-08-10 -->
+  <link rel="help" href="http://www.w3.org/TR/css3-multicol/#pseudo-algorithm" title="3.4 Pseudo-algorithm" />
+  <link rel="match" href="../reference/ref-filled-green-100px-square.xht" />
+  <meta name="flags" content="ahem" />
+  <meta name="assert" content="This test checks that the margin-top of the first child of a multi-column element (with -moz-column-fill: auto) does not collapse with its parent." />
+<style type="text/css"><![CDATA[
+@font-face {
+  font-family: Ahem;
+  src: url("../../../fonts/Ahem.ttf");
+}
+]]></style>
+  <style type="text/css"><![CDATA[
+  div#test-multi-column-red
+  {
+  background-color: red;
+  color: white;
+  font: 3.125em/1 Ahem; /* equivalent to 50px/50px Ahem */
+  height: 4em;
+  margin-top: 0em;
+  width: 4em;
+
+  -moz-column-count: 2;
+  -moz-column-fill: auto;
+  -moz-column-gap: 0em;
+  }
+
+  div#first-child {margin-top: 2em;}
+
+  div#reference-overlapping-green
+  {
+  background-color: green;
+  bottom: 200px;
+  height: 100px;
+  position: relative;
+  width: 100px;
+  }
+  ]]></style>
+
+ </head>
+
+ <body>
+
+  <p>Test passes if there is a filled green square and <strong>no red</strong>.</p>
+
+  <div id="test-multi-column-red">
+    <div id="first-child">ab cd</div>
+	ef gh ij kl
+  </div>
+
+  <div id="reference-overlapping-green"></div>
+
+  <!--
+
+  Expected result (before the overlapping):
+
+  *********************
+  | margin- |   ef    |
+  | top red |         |
+  | back    |   gh    |
+  | ground  |         |
+  *********************
+  |   ab    |   ij    |
+  |         |         |
+  |   cd    |   kl    |
+  |         |         |
+  *********************
+
+  -->
+
+ </body>
+</html>
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-margin-002.xht
@@ -0,0 +1,80 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+  <title>CSS Multi-column Layout Test: multi-column and margin collapsing of first child (basic)</title>
+  <link rel="author" title="Opera Software ASA" href="http://www.opera.com/" />
+  <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2013-08-10 -->
+  <link rel="help" href="http://www.w3.org/TR/css3-multicol/#pseudo-algorithm" title="3.4 Pseudo-algorithm" />
+  <link rel="match" href="../reference/ref-filled-green-100px-square.xht" />
+  <meta name="flags" content="ahem" />
+  <meta name="assert" content="This test checks that the margin-top of the first child (an inline-block) of a multi-column element (with -moz-column-fill: balance) does not collapse with its parent." />
+<style type="text/css"><![CDATA[
+@font-face {
+  font-family: Ahem;
+  src: url("../../../fonts/Ahem.ttf");
+}
+]]></style>
+  <style type="text/css"><![CDATA[
+  div#test-multi-column-red
+  {
+  background-color: red;
+  color: white;
+  font: 3.125em/1 Ahem; /* equivalent to 50px/50px Ahem */
+  height: 4em;
+  margin-top: 0em;
+  width: 4em;
+
+  -moz-column-count: 2;
+  -moz-column-fill: balance;
+  -moz-column-gap: 0em;
+  }
+
+  span
+  {
+  display: inline-block;
+  margin-top: 2em;
+  }
+
+  div#reference-overlapping-green
+  {
+  background-color: green;
+  bottom: 200px;
+  height: 100px;
+  position: relative;
+  width: 100px;
+  }
+  ]]></style>
+
+ </head>
+
+ <body>
+
+  <p>Test passes if there is a filled green square and <strong>no red</strong>.</p>
+
+  <div id="test-multi-column-red">
+    <span>ab cd</span>
+	ef gh ij kl
+  </div>
+
+  <div id="reference-overlapping-green"></div>
+
+  <!--
+
+  Expected result (before the overlapping):
+
+  *********************
+  | margin- |   ef    |
+  | top red |         |
+  | back    |   gh    |
+  | ground  |         |
+  *********************
+  |   ab    |   ij    |
+  |         |         |
+  |   cd    |   kl    |
+  |         |         |
+  *********************
+
+  -->
+
+ </body>
+</html>
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-margin-child-001-ref.xht
@@ -0,0 +1,45 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+  <title>CSS Reftest Reference</title>
+  <link rel="author" title="Opera Software ASA" href="http://www.opera.com/" />
+  <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2013-08-10 -->
+  <meta name="flags" content="" />
+  <style type="text/css"><![CDATA[
+  body > div
+  {
+  background-color: blue;
+  border: gray solid 1em;
+  font-size: 1.25em;
+  height: 8em;
+  position: relative;
+  width: 10em;
+  }
+
+  div > div
+  {
+  background-color: yellow;
+  height: 1em;
+  left: 0;
+  position: absolute;
+  top: 3em;
+  width: 5em;
+  }
+
+  #second-stripe {top: 5em;}
+
+  #third-stripe {top: 7em;}
+  ]]></style>
+
+ </head>
+
+ <body>
+
+  <div>
+	<div></div>
+	<div id="second-stripe"></div>
+	<div id="third-stripe"></div>
+  </div>
+
+ </body>
+</html>
\ No newline at end of file
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-margin-child-001.xht
@@ -0,0 +1,54 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+  <title>CSS Multi-column Layout Test: multi-column and margin collapsing of block children (basic)</title>
+  <link rel="author" title="Opera Software ASA" href="http://www.opera.com/" />
+  <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2013-08-10 -->
+  <link rel="help" href="http://www.w3.org/TR/css3-multicol/#the-multi-column-model" title="2. The multi-column model" />
+  <link rel="match" href="multicol-margin-child-001-ref.xht" />
+  <meta name="flags" content="ahem" />
+  <meta name="assert" content="This test checks that the margin-bottom of a block child in a multi-column element will collapse with the margin-top of a following block child of that same multi-colum element if those children are vertically adjacent and if no line boxes, no clearance, no padding and no border separate them." />
+<style type="text/css"><![CDATA[
+@font-face {
+  font-family: Ahem;
+  src: url("../../../fonts/Ahem.ttf");
+}
+]]></style>
+  <style type="text/css"><![CDATA[
+  div
+  {
+  background-color: yellow;
+  border: gray solid 1em;
+  color: blue;
+  font: 1.25em/1 Ahem;
+  width: 10em;
+
+  -moz-column-count: 2;
+  -moz-column-fill: balance;
+  -moz-column-gap: 0em;
+  }
+
+  h4
+  {
+  font: inherit;
+  margin: 1em 0;
+  }
+  ]]></style>
+
+ </head>
+
+ <body>
+
+  <div>
+	1scol 1scol
+	1scol
+  <h4>	h4h41	</h4>
+  <h4>	h4h42	</h4>
+	2ncol 2ncol
+	2ncol 2ncol
+	2ncol 2ncol
+	2ncol 2ncol
+  </div>
+
+ </body>
+</html>
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-nested-002-ref.xht
@@ -0,0 +1,106 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+  <title>CSS Reftest Reference</title>
+  <link rel="author" title="Opera Software ASA" href="http://www.opera.com/" />
+  <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2013-08-11 -->
+  <meta name="flags" content="" />
+  <style type="text/css"><![CDATA[
+  body {margin: 0em;}
+
+  div#rel-pos-wrapper
+  {
+  background-color: yellow;
+  font: 1.25em/1 serif;
+  height: 4em;
+  position: relative;
+  width: 32em;
+  }
+
+  div > div
+  {
+  font-size: 1em;
+  height: 3em;
+  position: absolute;
+  top: 0;
+  width: 2em;
+  }
+
+  div#black1
+  {
+  background-color: black;
+  left: 1em;
+  }
+
+  div#black2
+  {
+  background-color: black;
+  left: 4em;
+  }
+
+  div#black3
+  {
+  background-color: black;
+  height: 2em;
+  left: 7em;
+  }
+
+  div#blue1
+  {
+  background-color: blue;
+  left: 12em;
+  }
+
+  div#blue2
+  {
+  background-color: blue;
+  left: 15em;
+  }
+
+  div#blue3
+  {
+  background-color: blue;
+  height: 2em;
+  left: 18em;
+  }
+
+  div#pink1
+  {
+  background-color: pink;
+  left: 23em;
+  }
+
+  div#pink2
+  {
+  background-color: pink;
+  left: 26em;
+  }
+
+  div#pink3
+  {
+  background-color: pink;
+  height: 2em;
+  left: 29em;
+  }
+   ]]></style>
+ </head>
+ <body>
+
+  <div id="rel-pos-wrapper">
+
+	<div id="black1"></div>
+	<div id="black2"></div>
+	<div id="black3"></div>
+
+	<div id="blue1"></div>
+	<div id="blue2"></div>
+	<div id="blue3"></div>
+
+	<div id="pink1"></div>
+	<div id="pink2"></div>
+	<div id="pink3"></div>
+
+  </div>
+
+ </body>
+</html>
\ No newline at end of file
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-nested-002.xht
@@ -0,0 +1,86 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+  <title>CSS Multi-column Layout Test: multicolumn and margin-bottom collapsing</title>
+  <link rel="author" title="Opera Software ASA" href="http://www.opera.com/" />
+  <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2013-08-11 -->
+  <link rel="help" href="http://www.w3.org/TR/css3-multicol/#the-multi-column-model" title="2. The multi-column model" />
+  <link rel="match" href="multicol-nested-002-ref.xht" />
+  <meta name="assert" content="This test checks that a block container element's margin-bottom can collapse with its multi-column parent's margin-bottom if no line boxes, no clearance, no padding and no border separate them." />
+  <meta name="flags" content="ahem" />
+<style type="text/css"><![CDATA[
+@font-face {
+  font-family: Ahem;
+  src: url("../../../fonts/Ahem.ttf");
+}
+]]></style>
+  <style type="text/css"><![CDATA[
+  body {margin: 0em;}
+
+  body > div
+  {
+  font: 1.25em/1 Ahem;
+  width: 32em;
+
+  -moz-column-gap: 1em;
+  -moz-column-width: 8em;
+  }
+
+  /*
+
+  N == max(1, floor((available-width + -moz-column-gap) / (-moz-column-width + -moz-column-gap)));
+  N == max(1, floor((32em + 1em) / (8em + 1em)));
+  N == max(1, floor(33em / 9em));
+  N == max(1, floor(3.6));
+  N == max(1, 3);
+  N == 3;
+
+  W == ((available-width + -moz-column-gap) / N) - -moz-column-gap;
+  W == ((32em + 1em) / 3) - 1em;
+  W == (33em / 3) - 1em;
+  W == (11em) - 1em;
+  W == 10em;
+
+  */
+
+  div
+  {
+  background: yellow;
+  color: black;
+  orphans: 1;
+  widows: 1;
+  }
+
+  div > div {margin: 0 1em 1em;}
+
+  div + div {color: blue;}
+
+  div + div + div {color: pink;}
+  ]]></style>
+ </head>
+
+ <body>
+
+  <div>
+	<div>
+		bl ac
+		bl ac
+		bl ac
+		bl ac
+	</div>
+	<div>
+		bl ue
+		bl ue
+		bl ue
+		bl ue
+	</div>
+	<div>
+		Pi nk
+		Pi nk
+		Pi nk
+		Pi nk
+	</div>
+  </div>
+
+ </body>
+</html>
\ No newline at end of file
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-nested-005-ref.xht
@@ -0,0 +1,35 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+  <title>CSS Reftest Reference</title>
+  <link rel="author" title="Opera Software ASA" href="http://www.opera.com/" />
+  <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2013-08-10 -->
+  <meta name="flags" content="image" />
+  <style type="text/css"><![CDATA[
+  div
+  {
+  background-color: yellow;
+  font: 1.25em/1 serif;
+  margin: 1em;
+  padding: 0em 1em 1em;
+  width: 39em;
+  }
+
+  img
+  {
+  padding-right: 2em;
+  vertical-align: top;
+  }
+
+  img.-moz-column-gap {margin-right: 2em;}
+
+  img#last {padding-right: 0em;}
+  ]]></style>
+ </head>
+ <body>
+
+  <div><img src="support/black20x20.png" width="40" height="60" alt="Image download support must be enabled" /><img src="support/black20x20.png" width="40" height="60" alt="Image download support must be enabled" /><img class="-moz-column-gap" src="support/black20x20.png" width="40" height="40" alt="Image download support must be enabled" /><img src="support/black20x20.png" width="40" height="60" alt="Image download support must be enabled" /><img src="support/black20x20.png" width="40" height="60" alt="Image download support must be enabled" /><img class="-moz-column-gap" src="support/black20x20.png" width="40" height="40" alt="Image download support must be enabled" /><img src="support/black20x20.png" width="40" height="60" alt="Image download support must be enabled" /><img src="support/black20x20.png"
+width="40" height="60" alt="Image download support must be enabled" /><img id="last" src="support/black20x20.png" width="40" height="40" alt="Image download support must be enabled" /></div>
+
+ </body>
+</html>
\ No newline at end of file
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-nested-005.xht
@@ -0,0 +1,112 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+  <title>CSS Multi-column Layout Test: nested multi--moz-columns and constrained dimensions</title>
+  <link rel="author" title="Opera Software ASA" href="http://www.opera.com/" />
+  <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2013-08-10 -->
+  <link rel="help" href="http://www.w3.org/TR/css3-multicol/#pseudo-algorithm" title="3.4 Pseudo-algorithm" />
+  <link rel="match" href="multicol-nested-005-ref.xht" />
+  <!--
+  The original filename of this test was
+  multicol-inherit-005.xht
+  This test also serves as a conversion of
+  multicol-nested-001.xht
+  -->
+  <meta name="flags" content="ahem" />
+  <meta name="assert" content="This test checks how the height of column boxes conditions the height of nested column boxes." />
+<style type="text/css"><![CDATA[
+@font-face {
+  font-family: Ahem;
+  src: url("../../../fonts/Ahem.ttf");
+}
+]]></style>
+  <style type="text/css"><![CDATA[
+  body > div
+  {
+  -moz-column-gap: 1em;
+  font: 1.25em/1 Ahem;
+  width: 41em;
+  }
+
+  /*
+
+  N == 3;
+
+  W == max(0, (available-width - ((N - 1) * -moz-column-gap)) / N);
+  W == max(0, (41em - ((3 - 1) * 1em)) / 3);
+  W == max(0, (41em - (2 * 1em)) / 3);
+  W == max(0, (41em - 2em) / 3);
+  W == max(0, 39em / 3);
+  W == max(0, 13em);
+  W == 13em;
+
+  The height of column rule depends on number of line boxes in
+  each outer column box which depends on number of line boxes
+  in each inner column box. So:
+
+    13em : width of each outer column box
+   -
+     2em : horizontal margin of each div inside
+   =======
+    11em : width of each inner multi-column elements
+
+  N == 3;
+
+  W == max(0, (available-width - ((N - 1) * -moz-column-gap)) / N);
+  W == max(0, (11em - ((3 - 1) * 1em)) / 3);
+  W == max(0, (11em - (2 * 1em)) / 3);
+  W == max(0, (11em - 2em) / 3);
+  W == max(0, 9em / 3);
+  W == max(0, 3em);
+  W == 3em;
+
+  So, each duo of 'a', 'm' and 'x' should fill one and only 1 line
+  box. There are 8 duos; therefore, the first 2 inner
+  column boxes should use 3 line boxes and the 3rd inner
+  column box should be using 2 line boxes.
+
+  So, the height of the 2 blue column rules should be 60px.
+
+  */
+
+  div
+  {
+  background-color: yellow;
+  color: black;
+  font-size: 1em;
+  margin: 1em;
+  orphans: 1;
+  widows: 1;
+
+  -moz-column-count: 3;
+  }
+
+  div > div:first-child {margin-top: 0;}
+  ]]></style>
+ </head>
+
+ <body>
+
+  <div>
+	<div>
+		aa aa
+		aa aa
+		aa aa
+		aa aa
+	</div>
+	<div>
+		mm mm
+		mm mm
+		mm mm
+		mm mm
+	</div>
+	<div>
+		xx xx
+		xx xx
+		xx xx
+		xx xx
+	</div>
+  </div>
+
+ </body>
+</html>
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-nested-column-rule-001-ref.xht
@@ -0,0 +1,45 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+  <title>CSS Reftest Reference</title>
+  <link rel="author" title="Opera Software ASA" href="http://www.opera.com/" />
+  <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2013-08-09 -->
+  <meta name="flags" content="" />
+  <style type="text/css"><![CDATA[
+  div#rel-pos-wrapper
+  {
+  font: 1.25em/1 serif;
+  position: relative;
+  }
+
+  div#rel-pos-wrapper > div
+  {
+  background-color: blue;
+  font-size: 1em;
+  height: 3em;
+  position: absolute;
+  width: 1em;
+  }
+
+  div#first--moz-column-rule
+  {
+  left: 14em;
+  top: auto;
+  }
+
+  div#second--moz-column-rule
+  {
+  left: 29em;
+  top: auto;
+  }
+   ]]></style>
+ </head>
+ <body>
+
+  <div id="rel-pos-wrapper">
+	<div id="first--moz-column-rule"></div>
+	<div id="second--moz-column-rule"></div>
+  </div>
+
+ </body>
+</html>
\ No newline at end of file
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-nested-column-rule-001.xht
@@ -0,0 +1,128 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+ <head>
+  <!--
+  This test's original filename was multicol-inherit-004.xht
+  and it has been modified and is now
+  multicol-nested--moz-column-rule-001.xht
+  -->
+  <title>CSS Multi-column Layout Test: nested multi--moz-columns and -moz-column-rule position</title>
+  <link rel="author" title="Opera Software ASA" href="http://www.opera.com/" />
+  <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2013-08-09 -->
+  <link rel="help" href="http://www.w3.org/TR/css3-multicol/#pseudo-algorithm" title="3.4 Pseudo-algorithm" />
+  <link rel="match" href="multicol-nested--moz-column-rule-001-ref.xht" />
+  <meta name="flags" content="ahem" />
+  <meta name="assert" content="This test checks how the height of column boxes conditions the height of column rule." />
+<style type="text/css"><![CDATA[
+@font-face {
+  font-family: Ahem;
+  src: url("../../../fonts/Ahem.ttf");
+}
+]]></style>
+  <style type="text/css"><![CDATA[
+  body > div
+  {
+  -moz-column-rule: blue solid 1em;
+  font: 1.25em/1 Ahem;
+  width: 42em;
+  }
+
+  /*
+
+  N == 3;
+
+  W == max(0, (available-width - ((N - 1) * -moz-column-gap)) / N);
+  W == max(0, (42em - ((3 - 1) * 3em)) / 3);
+  W == max(0, (42em - (2 * 3em)) / 3);
+  W == max(0, (42em - 6em) / 3);
+  W == max(0, 36em / 3);
+  W == max(0, 12em);
+  W == 12em;
+
+  So, the first -moz-column-rule should be at:
+
+    1.0em : margin-left of outer div
+   12.0em : width of 1st column box
+    1.0em : (3.0em / 2) - (1.0em / 2) : left edge of 1st -moz-column-rule
+  =========
+   14.0em
+
+  The 2nd -moz-column-rule should be at:
+
+    1.0em : margin-left of outer div
+   12.0em : width of 1st column box
+    3.0em : first -moz-column-gap
+   12.0em : width of 2nd column box
+    1.0em : (3.0em / 2) - (1.0em / 2) : left edge of 2nd -moz-column-rule
+  =========
+   29.0em
+
+  The height of column rule depends on number of line boxes in
+  each outer column box which depends on number of line boxes
+  in each inner column box. So:
+
+    12em : width of each outer column box
+   -
+     2em : horizontal margin of each div inside
+   =======
+    10em : width of each inner multi-column elements
+
+  N == 3;
+
+  W == max(0, (available-width - ((N - 1) * -moz-column-gap)) / N);
+  W == max(0, (10em - ((3 - 1) * 3em)) / 3);
+  W == max(0, (10em - (2 * 3em)) / 3);
+  W == max(0, (10em - 6em) / 3);
+  W == max(0, 4em / 3);
+  W == max(0, 1.33333em);
+  W == 1.33333em;
+
+  So, each duo of 'a', 'm' and 'x' should fill one and only 1 line
+  box. There are 8 duos; therefore, the first 2 inner
+  column boxes should use 3 line boxes and the 3rd inner
+  column box should be using 2 line boxes.
+
+  So, the height of the 2 blue column rules should be 60px.
+
+  */
+
+  div
+  {
+  background-color: white;
+  color: white;
+  font-size: 1em;
+  margin: 0em 1em;
+  orphans: 1;
+  widows: 1;
+
+  -moz-column-count: 3;
+  -moz-column-gap: 3em;
+  }
+  ]]></style>
+ </head>
+
+ <body>
+
+  <div>
+	<div>
+		aa aa
+		aa aa
+		aa aa
+		aa aa
+	</div>
+	<div>
+		mm mm
+		mm mm
+		mm mm
+		mm mm
+	</div>
+	<div>
+		xx xx
+		xx xx
+		xx xx
+		xx xx
+	</div>
+  </div>
+
+ </body>
+</html>
new file mode 100644
--- /dev/null
+++ b/layout/reftests/w3c-css/received/css-multicol-1/multicol-nested-margin-001-ref.xht
@@ -0,0 +1,107 @@
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+  <title>CSS Reftest Reference</title>
+  <link rel="author" title="Opera Software ASA" href="http://www.opera.com/" />
+  <link rel="reviewer" title="Gérard Talbot" href="http://www.gtalbot.org/BrowserBugsSection/css21testsuite/" /> <!-- 2013-08-11 -->
+  <meta name="flags" content="" />
+  <style type="text/css"><![CDATA[
+  body {margin: 0em;}
+
+  div#rel-pos-wrapper
+  {
+  background-color: yellow;
+  font: 1.25em/1 serif;
+  height: 3em;
+  margin: 1em;
+  position: relative;
+  width: 32em;
+  }
+
+  div > div
+  {
+  font-size: 1em;
+  height: 3em;
+  position: absolute;
+  top: 0em;
+  width: 2em;
+  }
+
+  div#black1
+  {
+  background-color: black;
+  left: 1em;
+  }
+
+  div#black2
+  {
+  background-color: black;
+  left: 4em;
+  }
+
+  div#black3
+  {
+  background-color: black;
+  height: 2em;
+  left: 7em;
+  }
+
+  div#pink1
+  {
+  background-color: pink;
+  left: 12em;
+  }
+
+  div#pink2
+  {
+  background-color: pink;
+  left: 15em;
+  }
+
+  div#pink3
+  {
+  background-color: pink;
+  height: 2em;
+  left: 18em;
+  }
+
+  div#blue1
+  {
+  background-color: blue;
+  left: 23em;
+  }
+
+  div#blue2
+  {
+  background-color: blue;
+  left: 26em;
+  }
+
+  div#blue3
+  {
+  background-color: blue;
+  height: 2em;
+  left: 29em;
+  }
+   ]]></style>
+ </head>
+ <body>
+
+  <div id="rel-pos-wrapper">
+
+	<div id="black1"></div>
+	<div id="black2"></div>
<