pub struct HslFunction {
pub name: Function,
pub params: HslFunctionParams,
pub close: RightParen,
}Expand description
https://drafts.csswg.org/css-color/#funcdef-hsl
hsl() = [ <legacy-hsl-syntax> | <modern-hsl-syntax> ]
hsla() = [ <legacy-hsla-syntax> | <modern-hsla-syntax> ]
<modern-hsl-syntax> = hsl(
[<hue> | none]
[<percentage> | <number> | none]
[<percentage> | <number> | none]
[ / [<alpha-value> | none] ]? )
<modern-hsla-syntax> = hsla(
[<hue> | none]
[<percentage> | <number> | none]
[<percentage> | <number> | none]
[ / [<alpha-value> | none] ]? )
<legacy-hsl-syntax> = hsl( <hue>, <percentage>, <percentage>, <alpha-value>? )
<legacy-hsla-syntax> = hsla( <hue>, <percentage>, <percentage>, <alpha-value>? )Fields§
§name: Function§params: HslFunctionParams§close: RightParenTrait Implementations§
Source§impl Clone for HslFunction
impl Clone for HslFunction
Source§fn clone(&self) -> HslFunction
fn clone(&self) -> HslFunction
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for HslFunction
impl Debug for HslFunction
Source§impl Hash for HslFunction
impl Hash for HslFunction
Source§impl NodeWithMetadata<CssMetadata> for HslFunction
impl NodeWithMetadata<CssMetadata> for HslFunction
Source§fn self_metadata(&self) -> CssMetadata
fn self_metadata(&self) -> CssMetadata
Returns the metadata contributed by this node itself, not including children.
Most nodes don’t contribute metadata, so can simply return
M::default().
Nodes like StyleRule or AtRules should return their own node kind flags here.Source§fn metadata(&self) -> CssMetadata
fn metadata(&self) -> CssMetadata
Returns the complete aggregated metadata for this node (self + children).
Default implementation merges children’s metadata with self_metadata().
Source§impl Ord for HslFunction
impl Ord for HslFunction
Source§fn cmp(&self, other: &HslFunction) -> Ordering
fn cmp(&self, other: &HslFunction) -> Ordering
1.21.0 · Source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more
Source§impl<'a> Parse<'a> for HslFunction
impl<'a> Parse<'a> for HslFunction
Source§impl PartialEq for HslFunction
impl PartialEq for HslFunction
Source§impl PartialOrd for HslFunction
impl PartialOrd for HslFunction
Source§impl<'a> Peek<'a> for HslFunction
impl<'a> Peek<'a> for HslFunction
Source§impl SemanticEq for HslFunction
impl SemanticEq for HslFunction
Source§fn semantic_eq(&self, other: &Self) -> bool
fn semantic_eq(&self, other: &Self) -> bool
Returns
true if self and other are semantically equal.Source§impl ToCursors for HslFunction
impl ToCursors for HslFunction
fn to_cursors(&self, s: &mut impl CursorSink)
impl Eq for HslFunction
impl StructuralPartialEq for HslFunction
Auto Trait Implementations§
impl Freeze for HslFunction
impl RefUnwindSafe for HslFunction
impl Send for HslFunction
impl Sync for HslFunction
impl Unpin for HslFunction
impl UnwindSafe for HslFunction
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