Enum style::rule_tree::StyleSource [] [src]

pub enum StyleSource {
    Style(Arc<Locked<StyleRule>>),
    Declarations(Arc<Locked<PropertyDeclarationBlock>>),
    None,
}

A style source for the rule node. It can either be a CSS style rule or a declaration block.

Note that, even though the declaration block from inside the style rule could be enough to implement the rule tree, keeping the whole rule provides more debuggability, and also the ability of show those selectors to devtools.

Variants

A style rule stable pointer.

A declaration block stable pointer.

Indicates no style source. Used to save an Option wrapper around the stylesource in RuleNode

Methods

impl StyleSource
[src]

[src]

Read the style source guard, and obtain thus read access to the underlying property declaration block.

[src]

Indicates if this StyleSource has a value

Trait Implementations

impl Clone for StyleSource
[src]

[src]

Returns a copy of the value. Read more

1.0.0
[src]

Performs copy-assignment from source. Read more

impl Debug for StyleSource
[src]

[src]

Formats the value using the given formatter. Read more

impl PartialEq for StyleSource
[src]

[src]

This method tests for self and other values to be equal, and is used by ==. Read more

1.0.0
[src]

This method tests for !=.