Standard 51.0.1 / January 26, 2017; 28 days ago (2017-01-26) ESR 45.7.0 / January 24, 2017; 30 days ago (2017-01-24) |
The following tables compare CSS compatibility and support for a number of layout engines. Please see the individual products' articles for further information. Unless otherwise specified in footnotes, comparisons are based on the stable versions without any add-ons, extensions or external programs.
Contents
- Engine nomenclature
- Values
- Acronyms
- Trident grammar and rule notes
- Presto grammar and rule notes
- General selector notes
- Trident selector notes
- Gecko selector notes
- WebKit selector notes
- Presto selector notes
- Prince selector notes
- Trident property notes
- Gecko property notes
- WebKit property notes
- KHTML property notes
- Presto property notes
- Prince property notes
- General value and unit notes
- Trident value and unit notes
- Gecko value and unit notes
- Presto value and unit notes
- References
Engine nomenclature
Rather than the names of web browsers and HTML to PDF converters, the names of the underlying engines are used. Some of the software and online converters that use the various engines are listed below.
Values
Values indicate the level of support in the most recent version of the layout engine, or (if a version number is given) in the specified version. Version numbers without any other value indicate the version at which the layout engine first fully supported the feature.
Acronyms
Trident grammar and rule notes
- !important — Prior to 7.0,
!important
doesn't override rules defined later in the same declaration block. - @import — Prior to 8.0, media type support is broken. For
@import <URL> <MEDIA>
, IE requests as the URL "<URL> <MEDIA>
" and will include theurl()
token and/or quotes in the URL, too, if present. Cannot import more than 35 stylesheets.
Presto grammar and rule notes
- @import — Whilst Gecko, WebKit and iCab download all media stylesheets immediately, Opera only downloads handheld, print, projection and screen media, as well as speech if "voice" feature is enabled and TV, on TV devices. Text browser emulation mode is only a user stylesheet, so it does not switch to tty media type. This is consistent with older text browsers, which do not respect any CSS.
General selector notes
- :read-only and :read-write — Both Presto and KHTML handle the case of the
contenteditable
attribute incorrectly. - ::selection has been removed from the CSS3 specification, but is still supported by many browsers.
Trident selector notes
- :active — Prior to 8.0,
:active
is only supported on anchor elements. - :hover — Prior to 7.0,
:hover
is only supported on anchor elements. - .one.two — Prior to 7.0, only
.two
class selector was taken into consideration. - * — Prior to 7.0 this was treated as a single or no element.
- [attr] — Matches every
td
andth
in a table when the attribute iscolspan
(regardless of whether any actually have acolspan
attribute). This may not actually be a bug, as ambiguity exists in the specification. - :first-letter, :first-line — Prior to IE9 in 6.0, combining
:first-letter
rules with others may be problematic. In 8.0, rules with!important
are ignored inside:first-line
and:first-letter
declarations.
Gecko selector notes
- (:):before, (:):after — CSS2.0 behavior : some properties are unimplemented prior to 1.9.1.
WebKit selector notes
- :lang() — Only detected when explicitly present on element being tested, attribute not inherited.
- (:):first-line —
text-transform
doesn't apply with this pseudo-element. (:):before/after
— some styles can't be applied to:before
and:after
pseudo-elements, such as animations and transitions.
Presto selector notes
- :target — Prior to 2.5, styles aren't applied when navigating using back and forward buttons.
Prince selector notes
- :matches(a,b) — Prince uses a fixed specificity of the most specific argument (like :not) rather than the specificity of the matching argument (as selectors4 specifies).
Trident property notes
- margin —
inherit
inherits the computation and recomputes it instead of inheriting the computed value. - display — Prior to 7.0, only
none
,block
,inline
,table-header-group
, andtable-footer-group
are fully supported. Prior to 8.0,table
are not supported, whileinline-block
is only supported on elements that are naturally inline. - overflow — Prior to 7.0,
overflow: visible;
is incorrectly supported. In 8.0,scroll
makes the element's height equal to itsmax-height
even if the content isn't that tall. This has been fixed in IE9. - visibility — Prior to 8.0,
visibility: collapse;
is not supported. In 8.0, inline elements withvisibility: visible;
inside block elements withvisibility: hidden;
are not visible. - content — In 8.0, computed
attr()
values are not updated when the attribute changes. - border-color — Prior to 7.0,
transparent
is not supported. - border-style — Prior to 8.0,
hidden
is not supported. - border-style — Prior to 7.0,
dotted
is rendered asdashed
. - box-shadow — Trident 9.0 renders box-shadow blur value at about half the declared value. Prior to 9.0, trident supports similar functionality since 5.5 using the proprietary Shadow and DropShadow filters.
- position — Prior to 7.0, fixed positioning was not supported. 7.0 and later support it in standards-compliant mode only.
- z-index — Prior to 8.0,
z-index
is only partially supported. In 8.0, floating point values are accepted in addition to integers. - list-style-type — Prior to 8.0,
armenian
,decimal-leading-zero
,georgian
,lower-greek
,lower-latin
,upper-latin
are not supported. - opacity — Prior to 9.0, Trident supported a proprietary alternative.
- background-image — Prior to 8.0, background images are badly positioned in some cases.
- background-attachment — Prior to 7.0,
fixed
was allowed on thebody
element only. - background-position — Prior to 8.0, fixed positioning is not supported.
- font-weight — Prior to 8.0, incorrect rendering when value is 600.
- text-align — In 8.0,
text-align
isn't inherited by:before
and:after
pseudo-elements. - white-space — Prior to 6.0,
pre
is not supported. Prior to 8.0,white-space
is only partially supported;pre-line
andpre-wrap
are not supported. - cursor — Does not fail on non-prefixed vendor extensions.
- flex — Experimental in 10.0
- break-after; break-before; break-inside — Though 10.0 does support break-after, break-before, and break-inside for columns, they do not appear to support the properties "region" and "avoid-region".
Gecko property notes
- display — Values except inline-block and inline-table supported prior to 1.9.
- z-index — Negatives values are badly supported prior to 1.9.
- content —
none
value is unsupported prior to 1.9. This property also fails on any normal (non-pseudo-) elements, which it must support according to the CSS3 "Generated and Replaced Content Module" spec. - background-position — Versions prior to 1.7 implement the CSS2 syntax, not the proposed CSS2.1 expanded syntax.
- font-size-adjust — Prior to 1.9, supported on Windows only.
- font-weight — Only Regular and Bold weights get used, even if Light or Heavy/Black faces are installed, unless using DirectWrite in Gecko 2.0 on Windows 7 or Windows Vista.
- white-space —
pre-line
is not supported prior to 1.9.1. Prior to 1.9,pre-wrap
was only supported experimentally as-moz-pre-wrap
. - visibility —
collapse
is unsupported prior to 1.8. - border-radius — Prior to 1.9.1, border curves are circular, not elliptical as specified by the current CSS3 draft. Short-cut definitions for
border-radius
read "tl tr br bl" instead of the W3C's "tr br bl tl". When the border style is dotted or dashed, curves are rendered as solid instead. - page-break-before; page-break-after — Only the
always
andauto
values are supported.
WebKit property notes
- max-width; max-height; min-width; min-height — Are not supported on tables.(as commented on 2012-12-18, it is fixed)
- font — The system font keywords that allow designers to tailor presentation to the user's operating system environment are unsupported.
- font-weight — Only Regular and Bold weights get used, even if Light or Heavy/Black faces are installed.
- page-break-before; page-break-after — Only the
always
andauto
values are supported. - white-space — Prior to 522,
pre-line
andpre-wrap
are unsupported. - visibility —
collapse
is unsupported prior to 522. Its implementation has the same effect ashidden
and is therefore not compliant. - content — The
none
,open-quote
,close-quote
,no-open-quote
,no-close-quote
andnormal
values are unsupported. This property also fails on any normal (non-pseudo-) elements, which it must support according to the CSS3 "Generated and Replaced Content Module" spec. - font-size — The
font-size
property does not always accept the value 0, in "font-size: 0px" the text is still visible.
KHTML property notes
- overflow — Values
scroll
andauto
are unsupported. - page-break-before; page-break-after — Before 3.5 only the
always
andauto
values were supported. - visibility — All properties are supported, but the implementation of
collapse
has the same effect ashidden
and is therefore not compliant.
Presto property notes
- counter-increment, counter-reset — Implemented the algorithm in REC CSS2.
- background-position — Presto versions prior to Opera 8.0 implement the CSS2 syntax, not the proposed CSS2.1 expanded syntax.
- font-weight — Incorrect rendering when value is 600. Renders the text in a compatibility mode for websites made for Trident.
- visibility — Prior to 2.5, the value
collapse
was unsupported in table columns. On rows, it had the same effect ashidden
and was therefore not compliant. - cursor —
cursor
is ignored with dynamic pseudo-classes and custom cursors are unsupported. - content — Prior to 2.7, the
none
value was unsupported. - font —
inherit
should not be allowed together with a font-size value. This should not be parsed, but it's currently done in Opera.
Prince property notes
- visibility — The value
collapse
is unsupported. - box-decoration-break — Prince 9 (2013) honoured
box-decoration-break
for borders but not backgrounds. Nightly builds honour also for backgrounds, but whereslice
is only approximated: ifbackground-repeat
repeats vertically then the rendering is as forclone
; otherwise the background renders only in the first fragment, being truncated rather than slicing & continuing in subsequent fragments. The initial value isclone
rather thanslice
, in the belief that this is a better default for print use. - list-style — The values
armenian
andgeorgian
are unsupported. - content — The values
open-quote
andclose-quote
are unsupported. - text-overflow — Partial: excluding the portions of the spec currently marked as At Risk, namely <string> and 2-value syntax.
- Media Queries — Some device-characteristic media queries aren't very meaningful for PDF user agents.
- Excludes 3D transforms.
General value and unit notes
- transparent —
CSS1 introduced the ‘transparent’ value for the background-color property. CSS2 allowed border-color to also accept the ‘transparent’ value. The Open eBook(tm) Publication Structure 1.0.1 [OEB101] extended the ‘color’ property to also accept the ‘transparent’ keyword. CSS3 extends the color value to include the ‘transparent’ keyword to allow its use with all properties that accept a <color> value. This simplifies the definition of those properties in CSS3.
- <angle> — The
turn
unit is unsupported.
Trident value and unit notes
- rect() — Prior to 8.0,
rect()
was not supported with the correct syntax using commas. - auto — In quirks mode (IE5 emulation mode),
auto
does not work formargin
s, except table elements. - transparent — In 7.0 and 8.0, using
transparent
in thecolor
property will render the text as black. - transparent — Prior to 7.0,
transparent
is not supported on borders (shows as solid black) and is ignored on PNG images.
Gecko value and unit notes
- <ch> — Prior to version 1.9.1, used the width of the "M" glyph instead of the width of the "0" glyph.
Presto value and unit notes
- <number> — Prior to 2.1, there existed a quantization error for values greater than 20.47 (not limited to em, try any non-pixel units).
- transparent — Keyword is ignored when used with the outline-color property. Prior to version 2.2, it was also ignored when used with the color and text-shadow properties.