Classes implementing Document Object Model Level 2 Style Sheets http://www.w3.org/TR/2000/PR-DOM-Level-2-Style-20000927/stylesheets.html
The StyleSheet interface is the abstract base interface for any type of style sheet. It represents a single style sheet associated with a structured document.
In HTML, the StyleSheet interface represents either an external style sheet, included via the HTML LINK element, or an inline STYLE element (also an @import stylesheet?).
In XML, this interface represents an external style sheet, included via a style sheet processing instruction.
Interface StyleSheetList (introduced in DOM Level 2)
The StyleSheetList interface provides the abstraction of an ordered collection of StyleSheet objects.
The items in the StyleSheetList are accessible via an integral index, starting from 0.
This Python implementation is based on a standard Python list so e.g. allows examplelist[index] usage.
A Media Query consists of one of MediaQuery.MEDIA_TYPES and one or more expressions involving media features.
Format:
media_query: [[only | not]? <media_type> [ and <expression> ]*]
| <expression> [ and <expression> ]*
expression: ( <media_feature> [: <value>]? )
media_type: all | aural | braille | handheld | print |
projection | screen | tty | tv | embossed
media_feature: width | min-width | max-width
| height | min-height | max-height
| device-width | min-device-width | max-device-width
| device-height | min-device-height | max-device-height
| device-aspect-ratio | min-device-aspect-ratio | max-device-aspect-ratio
| color | min-color | max-color
| color-index | min-color-index | max-color-index
| monochrome | min-monochrome | max-monochrome
| resolution | min-resolution | max-resolution
| scan | grid
Provides the abstraction of an ordered collection of media, without defining or constraining how this collection is implemented.
A single media in the list is an instance of MediaQuery. An empty list is the same as a list that contains the medium “all”.
Format from CSS2.1:
medium [ COMMA S* medium ]*
New format with MediaQuery:
<media_query> [, <media_query> ]*
Add the newMedium to the end of the list. If the newMedium is already used, it is first removed.
Parameters: |
|
---|---|
Returns: | Wellformedness of newMedium. |
Exceptions: |
|
Delete a medium from the list.
Parameters: |
|
---|---|
Exceptions: |
|