Struct style::style_resolver::PrimaryStyle
source · pub struct PrimaryStyle {
pub style: ResolvedStyle,
pub reused_via_rule_node: bool,
pub may_have_starting_style: bool,
}
Expand description
The primary style of an element or an element-backed pseudo-element.
Fields§
§style: ResolvedStyle
The style itself.
reused_via_rule_node: bool
Whether the style was reused from another element via the rule node (see
StyleSharingCache::lookup_by_rules
).
may_have_starting_style: bool
The element may have matched rules inside @starting-style. Basically, we don’t apply @starting-style rules to |style|. This is a sugar to let us know if we should resolve the element again for starting style, which is the after-change style with @starting-style rules applied in addition.
Implementations§
source§impl PrimaryStyle
impl PrimaryStyle
sourcepub fn style(&self) -> &ComputedValues
pub fn style(&self) -> &ComputedValues
Convenience accessor for the style.
Auto Trait Implementations§
impl Freeze for PrimaryStyle
impl !RefUnwindSafe for PrimaryStyle
impl Send for PrimaryStyle
impl Sync for PrimaryStyle
impl Unpin for PrimaryStyle
impl !UnwindSafe for PrimaryStyle
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
source§impl<T> IntoEither for T
impl<T> IntoEither for T
source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moresource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moresource§impl<T> MaybeBoxed<Box<T>> for T
impl<T> MaybeBoxed<Box<T>> for T
source§fn maybe_boxed(self) -> Box<T>
fn maybe_boxed(self) -> Box<T>
Convert
source§impl<T> MaybeBoxed<T> for T
impl<T> MaybeBoxed<T> for T
source§fn maybe_boxed(self) -> T
fn maybe_boxed(self) -> T
Convert