| Notes and Advertising |
|---|
|
We strongly recommend to browse this site with Firefox. Internet Explorer does not support some features of W3C DOM, W3C XHTML and W3C CSS.
|
| Attr : Node | ||||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
|
The Attr interface represents an attribute in an Element object. Typically the allowable values for the attribute are defined in a schema associated with the document.
Attr objects inherit the Node interface, but since they are not actually child nodes of the element they describe, the DOM does not consider them part of the document tree. Thus, the Node attributes parentNode, previousSibling, and nextSibling have a null value for Attr objects. The DOM takes the view that attributes are properties of elements rather than having a separate identity from the elements they are associated with; this should make it more efficient to implement such features as default attributes associated with all elements of a given type. Furthermore, Attr nodes may not be immediate children of a DocumentFragment. However, they can be associated with Element nodes contained within a DocumentFragment. In short, users and implementors of the DOM need to be aware that Attr nodes have some things in common with other objects inheriting the Node interface, but they also are quite distinct.
The attribute's effective value is determined as follows: if this attribute has been explicitly assigned any value, that value is the attribute's effective value; otherwise, if there is a declaration for this attribute, and that declaration includes a default value, then that default value is the attribute's effective value; otherwise, the attribute does not exist on this element in the structure model until it has been explicitly added. Note that the Node.nodeValue attribute on the Attr instance can also be used to retrieve the string version of the attribute's value(s).
If the attribute was not explicitly given a value in the instance document but has a default value provided by the schema associated with the document, an attribute node will be created with specified set to false. Removing attribute nodes for which a default value is defined in the schema generates a new attribute node with the default value and specified set to false. If validation occurred while invoking Document.normalizeDocument(), attribute nodes with specified equals to false are recomputed according to the default attribute values provided by the schema. If no default value is associate with this attribute in the schema, the attribute node is discarded.
In XML, where the value of an attribute can contain entity references, the child nodes of the Attr node may be either Text or EntityReference nodes (when these are in use; see the description of EntityReference for discussion).
The DOM Core represents all attribute values as simple strings, even if the DTD or schema associated with the document declares them of some specific type such as tokenized.
The way attribute value normalization is performed by the DOM implementation depends on how much the implementation knows about the schema in use. Typically, the value and nodeValue attributes of an Attr node initially returns the normalized value given by the parser. It is also the case after Document.normalizeDocument() is called (assuming the right options have been set). But this may not be the case after mutation, independently of whether the mutation is performed by setting the string value directly or by changing the Attr child nodes. In particular, this is true when character references are involved, given that they are not represented in the DOM and they impact attribute value normalization. On the other hand, if the implementation knows about the schema in use when the attribute value is changed, and it is of a different type than CDATA, it may normalize it again at that time. This is especially true of specialized DOM implementations, such as SVG DOM implementations, which storre attribute values in an internal form different from a string.
The following table gives some examples of the relations between the attribute value in the original document (parsed attribute), the value as exposed in the DOM, and the serialization of the value:
description
|
||||||||||||||||||||||||||
| readonly attribute boolean | isId |
Returns whether this attribute is known to be of type ID (i.e. to contain an identifier for its owner element) or not. When it is and its value is unique, the ownerElement of this attribute can be retrieved using the method Document.getElementById. The implementation could use several ways to determine if an attribute node is known to contain an identifier:
If validation occurred while invoking Document.normalizeDocument(), all user-determined ID attributes are reset and all attribute nodes ID information are then reevaluated in accordance to the schema used. As a consequence, if the Attr.schemaTypeInfo attribute contains an ID type, isId will always return true.
|
||||||||||||||||||||||||
| readonly attribute DOMString | name | Returns the name of this attribute. If Node.localName is different from null, this attribute is a qualified name. |
||||||||||||||||||||||||
| readonly attribute Element | ownerElement | The Element node this attribute is attached to or null if this attribute is not in use. |
||||||||||||||||||||||||
| readonly attribute TypeInfo | schemaTypeInfo | The type information associated with this attribute. While the type information contained in this attribute is guarantee to be correct after loading the document or invoking Document.normalizeDocument(), schemaTypeInfo may not be reliable if the node was moved. |
||||||||||||||||||||||||
| readonly attribute boolean | specified | True if this attribute was explicitly given a value in the instance document, false otherwise. If the application changed the value of this attribute node (even if it ends up having the same value as the default value) then it is set to true. The implementation may handle attributes with default values from other schemas similarly but applications should use Document.normalizeDocument() to guarantee this information is up-to-date. |
||||||||||||||||||||||||
| attribute DOMString | value |
On retrieval, the value of the attribute is returned as a string. Character and general entity references are replaced with their values. See also the method getAttribute on the Element interface.
On setting, this creates a Text node with the unparsed contents of the string, i.e. any characters that an XML processor would recognize as markup are instead treated as literal text. See also the method Element.setAttribute().
Some specialized implementations, such as some [SVG 1.1] implementations, may do normalization automatically, even after mutation; in such case, the value on retrieval may differ from the value on setting.
|
||||||||||||||||||||||||
| More and details about W3 DOM Interface Attr >> | ||||||||||||||||||||||||||
| CDATASection : Text | ||
|---|---|---|
|
CDATA sections are used to escape blocks of text containing characters that would otherwise be regarded as markup. The only delimiter that is recognized in a CDATA section is the "]]>" string that ends the CDATA section. CDATA sections cannot be nested. Their primary purpose is for including material such as XML fragments, without needing to escape all the delimiters.
The CharacterData.data attribute holds the text that is contained by the CDATA section. Note that this may contain characters that need to be escaped outside of CDATA sections and that, depending on the character encoding ("charset") chosen for serialization, it may be impossible to write out some characters as part of a CDATA section.
The CDATASection interface inherits from the CharacterData interface through the Text interface. Adjacent CDATASection nodes are not merged by use of the normalize method of the Node interface.
No lexical check is done on the content of a CDATA section and it is therefore possible to have the character sequence "]]>" in the content, which is illegal in a CDATA section per section 2.7 of [XML 1.0]. The presence of this character sequence must generate a fatal error during serialization or the cdata section must be splitted before the serialization (see also the parameter "split-cdata-sections" in the DOMConfiguration interface).
Because no markup is recognized within a CDATASection, character numeric references cannot be used as an escape mechanism when serializing. Therefore, action needs to be taken when serializing a CDATASection with a character encoding where some of the contained characters cannot be represented. Failure to do so would not produce well-formed XML.
One potential solution in the serialization process is to end the CDATA section before the character, output the character using a character reference or entity reference, and open a new CDATA section for any further characters in the text node. Note, however, that some code conversion libraries at the time of writing do not return an error or exception when a character is missing from the encoding, making the task of ensuring that data is not corrupted on serialization more difficult.
|
||
| More and details about W3 DOM Interface CDATASection >> |
| CharacterData : Node | ||
|---|---|---|
|
The CharacterData interface extends Node with a set of attributes and methods for accessing character data in the DOM. For clarity this set is defined here rather than on each object that uses these attributes and methods. No DOM objects correspond directly to CharacterData, though Text and others do inherit the interface from it. All offsets in this interface start from 0.
As explained in the DOMString interface, text strings in the DOM are represented in UTF-16, i.e. as a sequence of 16-bit units. In the following, the term 16-bit units is used whenever necessary to indicate that indexing on CharacterData is done in 16-bit units.
|
||
| attribute DOMString | data |
The character data of the node that implements this interface. The DOM implementation may not put arbitrary limits on the amount of data that may be stored in a CharacterData node. However, implementation limits may mean that the entirety of a node's data may not fit into a single DOMString. In such cases, the user may call substringData to retrieve the data in appropriately sized pieces.
|
| readonly attribute unsigned long | length | The number of 16-bit units that are available through data and the substringData method below. This may have the value zero, i.e., CharacterData nodes may be empty. |
| void | appendData (in DOMString arg) |
Append the string to the end of the character data of the node. Upon success, data provides access to the concatenation of data and the DOMString specified.
|
| void | deleteData (in unsigned long offset, in unsigned long count) |
Remove a range of 16-bit units from the node. Upon success, data and length reflect the change.
|
| void | insertData(in unsigned long offset, in DOMString arg) |
Insert a string at the specified 16-bit unit offset.
|
| void | replaceData (in unsigned long offset, in unsigned long count, in DOMString arg) |
Replace the characters starting at the specified 16-bit unit offset with the specified string.
|
| DOMString | substringData (in unsigned long offset, in unsigned long count) |
Extracts a range of data from the node.
|
| More and details about W3 DOM Interface CharacterData >> | ||
| Comment : CharacterData | ||
|---|---|---|
|
This interface inherits from CharacterData and represents the content of a comment, i.e., all the characters between the starting '<!--' and ending '-->'. Note that this is the definition of a comment in XML, and, in practice, HTML, although some HTML tools may implement the full SGML comment structure.
No lexical check is done on the content of a comment and it is therefore possible to have the character sequence "--" (double-hyphen) in the content, which is illegal in a comment per section 2.5 of [XML 1.0]. The presence of this character sequence must generate a fatal error during serialization.
|
||
| More and details about W3 DOM Interface Comment >> |
| Counter | ||
|---|---|---|
|
The Counter interface is used to represent any counter or counters function value. This interface reflects the values in the underlying style property.
|
||
| readonly attribute DOMString | identifier | This attribute is used for the identifier of the counter. |
| readonly attribute DOMString | listStyle | This attribute is used for the style of the list. |
| readonly attribute DOMString | separator | This attribute is used for the separator of the nested counters. |
| More and details about W3 DOM Interface Counter >> | ||
| CSS2Properties | ||
|---|---|---|
|
The CSS2Properties interface represents a convenience mechanism for retrieving and setting properties within a CSSStyleDeclaration. The attributes of this interface correspond to all the properties specified in CSS2. Getting an attribute of this interface is equivalent to calling the getPropertyValue method of the CSSStyleDeclaration interface. Setting an attribute of this interface is equivalent to calling the setProperty method of the CSSStyleDeclaration interface.
A conformant implementation of the CSS module is not required to implement the CSS2Properties interface. If an implementation does implement this interface, the expectation is that language-specific methods can be used to cast from an instance of the CSSStyleDeclaration interface to the CSS2Properties interface.
If an implementation does implement this interface, it is expected to understand the specific syntax of the shorthand properties, and apply their semantics; when the margin property is set, for example, the marginTop, marginRight, marginBottom and marginLeft properties are actually being set by the underlying implementation.
When dealing with CSS "shorthand" properties, the shorthand properties should be decomposed into their component longhand properties as appropriate, and when querying for their value, the form returned should be the shortest form exactly equivalent to the declarations made in the ruleset. However, if there is no shorthand declaration that could be added to the ruleset without changing in any way the rules already declared in the ruleset (i.e., by adding longhand rules that were previously not declared in the ruleset), then the empty string should be returned for the shorthand property.
For example, querying for the font property should not return "normal normal normal 14pt/normal Arial, sans-serif", when "14pt Arial, sans-serif" suffices. (The normals are initial values, and are implied by use of the longhand property.)
If the values for all the longhand properties that compose a particular string are the initial values, then a string consisting of all the initial values should be returned (e.g. a border-width value of "medium" should be returned as such, not as "").
For some shorthand properties that take missing values from other sides, such as the margin, padding, and border-[width|style|color] properties, the minimum number of sides possible should be used; i.e., "0px 10px" will be returned instead of "0px 10px 0px 10px".
If the value of a shorthand property can not be decomposed into its component longhand properties, as is the case for the font property with a value of "menu", querying for the values of the component longhand properties should return the empty string.
|
||
| attribute DOMString | azimuth |
See the azimuth property definition in CSS2.
|
| attribute DOMString | background |
See the background property definition in CSS2.
|
| attribute DOMString | backgroundAttachment |
See the background-attachment property definition in CSS2.
|
| attribute DOMString | backgroundColor |
See the background-color property definition in CSS2.
|
| attribute DOMString | backgroundImage |
See the background-image property definition in CSS2.
|
| attribute DOMString | backgroundPosition |
See the background-position property definition in CSS2.
|
| attribute DOMString | backgroundRepeat |
See the background-repeat property definition in CSS2.
|
| attribute DOMString | border |
See the border property definition in CSS2.
|
| attribute DOMString | borderBottom |
See the border-bottom property definition in CSS2.
|
| attribute DOMString | borderBottomColor |
See the border-bottom-color property definition in CSS2.
|
| attribute DOMString | borderBottomStyle |
See the border-bottom-style property definition in CSS2.
|
| attribute DOMString | borderBottomWidth |
See the border-bottom-width property definition in CSS2.
|
| attribute DOMString | borderCollapse |
See the border-collapse property definition in CSS2.
|
| attribute DOMString | borderColor |
See the border-color property definition in CSS2.
|
| attribute DOMString | borderLeft |
See the border-left property definition in CSS2.
|
| attribute DOMString | borderLeftColor |
See the border-left-color property definition in CSS2.
|
| attribute DOMString | borderLeftStyle |
See the border-left-style property definition in CSS2.
|
| attribute DOMString | borderLeftWidth |
See the border-left-width property definition in CSS2.
|
| attribute DOMString | borderRight |
See the border-right property definition in CSS2.
|
| attribute DOMString | borderRightColor |
See the border-right-color property definition in CSS2.
|
| attribute DOMString | borderRightStyle |
See the border-right-style property definition in CSS2.
|
| attribute DOMString | borderRightWidth |
See the border-right-width property definition in CSS2.
|
| attribute DOMString | borderSpacing |
See the border-spacing property definition in CSS2.
|
| attribute DOMString | borderStyle |
See the border-style property definition in CSS2.
|
| attribute DOMString | borderTop |
See the border-top property definition in CSS2.
|
| attribute DOMString | borderTopColor |
See the border-top-color property definition in CSS2.
|
| attribute DOMString | borderTopStyle |
See the border-top-style property definition in CSS2.
|
| attribute DOMString | borderTopWidth |
See the border-top-width property definition in CSS2.
|
| attribute DOMString | borderWidth |
See the border-width property definition in CSS2.
|
| attribute DOMString | bottom |
See the bottom property definition in CSS2.
|
| attribute DOMString | captionSide |
See the caption-side property definition in CSS2.
|
| attribute DOMString | clear |
See the clear property definition in CSS2.
|
| attribute DOMString | clip |
See the clip property definition in CSS2.
|
| attribute DOMString | color |
See the color property definition in CSS2.
|
| attribute DOMString | content |
See the content property definition in CSS2.
|
| attribute DOMString | counterIncrement |
See the counter-increment property definition in CSS2.
|
| attribute DOMString | counterReset |
See the counter-reset property definition in CSS2.
|
| attribute DOMString | cssFloat |
See the float property definition in CSS2.
|
| attribute DOMString | cue |
See the cue property definition in CSS2.
|
| attribute DOMString | cueAfter |
See the cue-after property definition in CSS2.
|
| attribute DOMString | cueBefore |
See the cue-before property definition in CSS2.
|
| attribute DOMString | cursor |
See the cursor property definition in CSS2.
|
| attribute DOMString | direction |
See the direction property definition in CSS2.
|
| attribute DOMString | display |
See the display property definition in CSS2.
|
| attribute DOMString | elevation |
See the elevation property definition in CSS2.
|
| attribute DOMString | emptyCells |
See the empty-cells property definition in CSS2.
|
| attribute DOMString | font |
See the font property definition in CSS2.
|
| attribute DOMString | fontFamily |
See the font-family property definition in CSS2.
|
| attribute DOMString | fontSize |
See the font-size property definition in CSS2.
|
| attribute DOMString | fontSizeAdjust |
See the font-size-adjust property definition in CSS2.
|
| attribute DOMString | fontStretch |
See the font-stretch property definition in CSS2.
|
| attribute DOMString | fontStyle |
See the font-style property definition in CSS2.
|
| attribute DOMString | fontVariant |
See the font-variant property definition in CSS2.
|
| attribute DOMString | fontWeight |
See the font-weight property definition in CSS2.
|
| attribute DOMString | height |
See the height property definition in CSS2.
|
| attribute DOMString | left |
See the left property definition in CSS2.
|
| attribute DOMString | letterSpacing |
See the letter-spacing property definition in CSS2.
|
| attribute DOMString | lineHeight |
See the line-height property definition in CSS2.
|
| attribute DOMString | listStyle |
See the list-style property definition in CSS2.
|
| attribute DOMString | listStyleImage |
See the list-style-image property definition in CSS2.
|
| attribute DOMString | listStylePosition |
See the list-style-position property definition in CSS2.
|
| attribute DOMString | listStyleType |
See the list-style-type property definition in CSS2.
|
| attribute DOMString | margin |
See the margin property definition in CSS2.
|
| attribute DOMString | marginBottom |
See the margin-bottom property definition in CSS2.
|
| attribute DOMString | marginLeft |
See the margin-left property definition in CSS2.
|
| attribute DOMString | marginRight |
See the margin-right property definition in CSS2.
|
| attribute DOMString | marginTop |
See the margin-top property definition in CSS2.
|
| attribute DOMString | markerOffset |
See the marker-offset property definition in CSS2.
|
| attribute DOMString | marks |
See the marks property definition in CSS2.
|
| attribute DOMString | maxHeight |
See the max-height property definition in CSS2.
|
| attribute DOMString | maxWidth |
See the max-width property definition in CSS2.
|
| attribute DOMString | minHeight |
See the min-height property definition in CSS2.
|
| attribute DOMString | minWidth |
See the min-width property definition in CSS2.
|
| attribute DOMString | orphans |
See the orphans property definition in CSS2.
|
| attribute DOMString | outline |
See the outline property definition in CSS2.
|
| attribute DOMString | outlineColor |
See the outline-color property definition in CSS2.
|
| attribute DOMString | outlineStyle |
See the outline-style property definition in CSS2.
|
| attribute DOMString | outlineWidth |
See the outline-width property definition in CSS2.
|
| attribute DOMString | overflow |
See the overflow property definition in CSS2.
|
| attribute DOMString | padding |
See the padding property definition in CSS2.
|
| attribute DOMString | paddingBottom |
See the padding-bottom property definition in CSS2.
|
| attribute DOMString | paddingLeft |
See the padding-left property definition in CSS2.
|
| attribute DOMString | paddingRight |
See the padding-right property definition in CSS2.
|
| attribute DOMString | property |
description
|
| attribute DOMString | paddingTop |
See the padding-top property definition in CSS2.
|
| attribute DOMString | page |
See the page property definition in CSS2.
|
| attribute DOMString | pageBreakAfter |
See the page-break-after property definition in CSS2.
|
| attribute DOMString | pageBreakBefore |
See the page-break-before property definition in CSS2.
|
| attribute DOMString | pageBreakInside |
See the page-break-inside property definition in CSS2.
|
| attribute DOMString | pause |
See the pause property definition in CSS2.
|
| attribute DOMString | pauseAfter |
See the pause-after property definition in CSS2.
|
| attribute DOMString | pauseBefore |
See the pause-before property definition in CSS2.
|
| attribute DOMString | pitch |
See the pitch property definition in CSS2.
|
| attribute DOMString | pitchRange |
See the pitch-range property definition in CSS2.
|
| attribute DOMString | playDuring |
See the play-during property definition in CSS2.
|
| attribute DOMString | position |
See the position property definition in CSS2.
|
| attribute DOMString | quotes |
See the quotes property definition in CSS2.
|
| attribute DOMString | richness |
See the richness property definition in CSS2.
|
| attribute DOMString | right |
See the right property definition in CSS2.
|
| attribute DOMString | size |
See the size property definition in CSS2.
|
| attribute DOMString | speak |
See the speak property definition in CSS2.
|
| attribute DOMString | speakHeader |
See the speak-header property definition in CSS2.
|
| attribute DOMString | speakNumeral |
See the speak-numeral property definition in CSS2.
|
| attribute DOMString | speakPunctuation |
See the speak-punctuation property definition in CSS2.
|
| attribute DOMString | speechRate |
See the speech-rate property definition in CSS2.
|
| attribute DOMString | stress |
See the stress property definition in CSS2.
|
| attribute DOMString | tableLayout |
See the table-layout property definition in CSS2.
|
| attribute DOMString | textAlign |
See the text-align property definition in CSS2.
|
| attribute DOMString | textDecoration |
See the text-decoration property definition in CSS2.
|
| attribute DOMString | textIndent |
See the text-indent property definition in CSS2.
|
| attribute DOMString | textShadow |
See the text-shadow property definition in CSS2.
|
| attribute DOMString | textTransform |
See the text-transform property definition in CSS2.
|
| attribute DOMString | top |
See the top property definition in CSS2.
|
| attribute DOMString | unicodeBidi |
See the unicode-bidi property definition in CSS2.
|
| attribute DOMString | verticalAlign |
See the vertical-align property definition in CSS2.
|
| attribute DOMString | visibility |
See the visibility property definition in CSS2.
|
| attribute DOMString | voiceFamily |
See the voice-family property definition in CSS2.
|
| attribute DOMString | volume |
See the volume property definition in CSS2.
|
| attribute DOMString | whiteSpace |
See the white-space property definition in CSS2.
|
| attribute DOMString | widows |
See the widows property definition in CSS2.
|
| attribute DOMString | width |
See the width property definition in CSS2.
|
| attribute DOMString | wordSpacing |
See the word-spacing property definition in CSS2.
|
| attribute DOMString | zIndex |
See the z-index property definition in CSS2.
|
| More and details about W3 DOM Interface CSS2Properties >> | ||
| CSSCharsetRule : CSSRule | ||
|---|---|---|
|
The CSSCharsetRule interface represents a @charset rule in a CSS style sheet. The value of the encoding attribute does not affect the encoding of text data in the DOM objects; this encoding is always UTF-16. After a stylesheet is loaded, the value of the encoding attribute is the value found in the @charset rule. If there was no @charset in the original document, then no CSSCharsetRule is created. The value of the encoding attribute may also be used as a hint for the encoding used on serialization of the style sheet.
The value of the @charset rule (and therefore of the CSSCharsetRule) may not correspond to the encoding the document actually came in; character encoding information e.g. in an HTTP header, has priority (see CSS document representation) but this is not reflected in the CSSCharsetRule.
|
||
| attribute DOMString | encoding |
The encoding information used in this @charset rule.
|
| More and details about W3 DOM Interface CSSCharsetRule >> | ||
| CSSStyleDeclaration | ||
|---|---|---|
|
The CSSStyleDeclaration interface represents a single CSS declaration block. This interface may be used to determine the style properties currently set in a block or to set style properties explicitly within the block.
While an implementation may not recognize all CSS properties within a CSS declaration block, it is expected to provide access to all specified properties in the style sheet through the CSSStyleDeclaration interface. Furthermore, implementations that support a specific level of CSS should correctly handle CSS shorthand properties for that level. For a further discussion of shorthand properties, see the CSS2Properties interface.
This interface is also used to provide a read-only access to the computed values of an element. See also the ViewCSS interface.
The CSS Object Model doesn't provide an access to the specified or actual values of the CSS cascade.
|
||
| attribute DOMString | cssText |
The parsable textual representation of the declaration block (excluding the surrounding curly braces). Setting this attribute will result in the parsing of the new value and resetting of all the properties in the declaration block including the removal or addition of properties.
|
| readonly attribute unsigned long | length | The number of properties that have been explicitly set in this declaration block. The range of valid indices is 0 to length-1 inclusive. |
| readonly attribute CSSRule | parentRule | The CSS rule that contains this declaration block or null if this CSSStyleDeclaration is not attached to a CSSRule. |
| CSSValue | getPropertyCSSValue(in DOMString propertyName) |
Used to retrieve the object representation of the value of a CSS property if it has been explicitly set within this declaration block. This method returns null if the property is a shorthand property. Shorthand property values can only be accessed and modified as strings, using the getPropertyValue and setProperty methods.
|
| DOMString | getPropertyPriority(in DOMString propertyName) |
Used to retrieve the priority of a CSS property (e.g. the "important" qualifier) if the property has been explicitly set in this declaration block.
|
| DOMString | getPropertyValue(in DOMString propertyName) |
Used to retrieve the value of a CSS property if it has been explicitly set within this declaration block.
|
| DOMString | item(in unsigned long index) |
description
|
| DOMString | removeProperty(in DOMString propertyName) |
Used to remove a CSS property if it has been explicitly set within this declaration block.
|
| void | setProperty(in DOMString propertyName, in DOMString value, in DOMString priority) |
Used to set a property value and priority within this declaration block.
|
| More and details about W3 DOM Interface CSSStyleDeclaration >> | ||
| CSSFontFaceRule : CSSRule | ||
|---|---|---|
|
The CSSFontFaceRule interface represents a @font-face rule in a CSS style sheet. The @font-face rule is used to hold a set of font descriptions.
|
||
| readonly attribute CSSStyleDeclaration | style | The declaration-block of this rule. |
| More and details about W3 DOM Interface CSSFontFaceRule >> | ||
| CSSImportRule : CSSRule | ||
|---|---|---|
|
The CSSImportRule interface represents a @import rule within a CSS style sheet. The @import rule is used to import style rules from other style sheets.
|
||
| readonly attribute DOMString | href | The location of the style sheet to be imported. The attribute will not contain the "url(...)" specifier around the URI. |
| readonly attribute stylesheets::MediaList | media | A list of media types for which this style sheet may be used. |
| readonly attribute CSSStyleSheet | styleSheet | The style sheet referred to by this rule, if it has been loaded. The value of this attribute is null if the style sheet has not yet been loaded or if it will not be loaded (e.g. if the style sheet is for a media type not supported by the user agent). |
| More and details about W3 DOM Interface CSSImportRule >> | ||
| CSSMediaRule : CSSRule | ||
|---|---|---|
|
The CSSMediaRule interface represents a @media rule in a CSS style sheet. A @media rule can be used to delimit style rules for specific media types.
|
||
| readonly attribute CSSRuleList | cssRules | A list of all CSS rules contained within the media block. |
| readonly attribute stylesheets::MediaList | media | A list of media types for this rule. |
| void | deleteRule(in unsigned long index) |
Used to delete a rule from the media block.
|
| unsigned long | insertRule(in DOMString rule, in unsigned long index) |
Used to insert a new rule into the media block.
|
| More and details about W3 DOM Interface CSSMediaRule >> | ||
| CSSPageRule : CSSRule | ||
|---|---|---|
|
The CSSPageRule interface represents a @page rule within a CSS style sheet. The @page rule is used to specify the dimensions, orientation, margins, etc. of a page box for paged media.
|
||
| attribute DOMString | selectorText |
The parsable textual representation of the page selector for the rule.
|
| readonly attribute CSSStyleDeclaration | style | The declaration-block of this rule. |
| More and details about W3 DOM Interface CSSPageRule >> | ||
| CSSPrimitiveValue : CSSValue | ||
|---|---|---|
|
The CSSPrimitiveValue interface represents a single CSS value. This interface may be used to determine the value of a specific style property currently set in a block or to set a specific style property explicitly within the block. An instance of this interface might be obtained from the getPropertyCSSValue method of the CSSStyleDeclaration interface. A CSSPrimitiveValue object only occurs in a context of a CSS property.
Conversions are allowed between absolute values (from millimeters to centimeters, from degrees to radians, and so on) but not between relative values. (For example, a pixel value cannot be converted to a centimeter value.) Percentage values can't be converted since they are relative to the parent value (or another property value). There is one exception for color percentage values: since a color percentage value is relative to the range 0-255, a color percentage value can be converted to a number; (see also the RGBColor interface).
|
||
|
Definition group UnitTypes
An integer indicating which type of unit applies to the value.
|
||
| const unsigned short | CSS_ATTR | = 22; The value is a attribute function. The value can be obtained by using the getStringValue method. |
| const unsigned short | CSS_CM | = 6; The value is a length (cm). The value can be obtained by using the getFloatValue method. |
| const unsigned short | CSS_COUNTER | = 23 |