pub struct UserAgentStylesheet(/* private fields */);Expand description
A user-agent stylesheet, parsed with a read-only lock so that it can be shared between documents.
Documents with the same user-agent stylesheets (in the same order) also share Stylo’s
cached user-agent cascade data. @import rules are ignored.
Implementations§
Source§impl UserAgentStylesheet
impl UserAgentStylesheet
pub fn parse(css: &str) -> Self
Sourcepub fn default_sheet() -> Self
pub fn default_sheet() -> Self
The default user-agent stylesheet (DEFAULT_CSS), parsed once.
pub fn sheet(&self) -> &DocumentStyleSheet
Trait Implementations§
Source§impl Clone for UserAgentStylesheet
impl Clone for UserAgentStylesheet
Source§impl Debug for UserAgentStylesheet
impl Debug for UserAgentStylesheet
Source§impl PartialEq for UserAgentStylesheet
impl PartialEq for UserAgentStylesheet
impl StructuralPartialEq for UserAgentStylesheet
Auto Trait Implementations§
impl !RefUnwindSafe for UserAgentStylesheet
impl !UnwindSafe for UserAgentStylesheet
impl Freeze for UserAgentStylesheet
impl Send for UserAgentStylesheet
impl Sync for UserAgentStylesheet
impl Unpin for UserAgentStylesheet
impl UnsafeUnpin for UserAgentStylesheet
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> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> ErasedDestructor for Twhere
T: 'static,
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