Enum style::properties::ShorthandId
[−]
[src]
pub enum ShorthandId { Background, BackgroundPosition, BorderColor, BorderStyle, BorderWidth, BorderTop, BorderLeft, BorderBottom, BorderRight, BorderBlockStart, BorderBlockEnd, BorderInlineStart, BorderInlineEnd, Border, BorderRadius, BorderImage, Overflow, Transition, Animation, Columns, Font, FontVariant, ListStyle, Margin, Outline, Padding, FlexFlow, Flex, TextDecoration, All, }
An identifier for a given shorthand property.
Variants
Background
background
BackgroundPosition
background-position
BorderColor
border-color
BorderStyle
border-style
BorderWidth
border-width
BorderTop
border-top
BorderLeft
border-left
BorderBottom
border-bottom
BorderRight
border-right
BorderBlockStart
border-block-start
BorderBlockEnd
border-block-end
BorderInlineStart
border-inline-start
BorderInlineEnd
border-inline-end
Border
border
BorderRadius
border-radius
BorderImage
border-image
Overflow
overflow
Transition
transition
Animation
animation
Columns
columns
Font
font
FontVariant
font-variant
ListStyle
list-style
Margin
margin
Outline
outline
Padding
padding
FlexFlow
flex-flow
Flex
flex
TextDecoration
text-decoration
All
all
Methods
impl ShorthandId
[src]
pub fn name(&self) -> &'static str
[src]
Get the name for this shorthand property.
pub fn longhands(&self) -> &'static [LonghandId]
[src]
Get the longhand ids that form this shorthand.
pub fn longhands_to_css<'a, W, I>(
&self,
declarations: I,
dest: &mut W
) -> Result where
W: Write,
I: Iterator<Item = &'a PropertyDeclaration>,
[src]
&self,
declarations: I,
dest: &mut W
) -> Result where
W: Write,
I: Iterator<Item = &'a PropertyDeclaration>,
Try to serialize the given declarations as this shorthand.
Returns an error if writing to the stream fails, or if the declarations do not map to a shorthand.
pub fn get_shorthand_appendable_value<'a, I>(
self,
declarations: I
) -> Option<AppendableValue<'a, I::IntoIter>> where
I: IntoIterator<Item = &'a PropertyDeclaration>,
I::IntoIter: Clone,
[src]
self,
declarations: I
) -> Option<AppendableValue<'a, I::IntoIter>> where
I: IntoIterator<Item = &'a PropertyDeclaration>,
I::IntoIter: Clone,
Finds and returns an appendable value for the given declarations.
Returns the optional appendable value.
pub fn flags(&self) -> PropertyFlags
[src]
Returns PropertyFlags for given shorthand property.
Trait Implementations
impl From<ShorthandId> for NonCustomPropertyId
[src]
fn from(id: ShorthandId) -> Self
[src]
Performs the conversion.
impl Clone for ShorthandId
[src]
fn clone(&self) -> ShorthandId
[src]
Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0[src]
Performs copy-assignment from source
. Read more
impl Copy for ShorthandId
[src]
impl Debug for ShorthandId
[src]
fn fmt(&self, __arg_0: &mut Formatter) -> Result
[src]
Formats the value using the given formatter. Read more
impl Eq for ShorthandId
[src]
impl Hash for ShorthandId
[src]
fn hash<__H: Hasher>(&self, __arg_0: &mut __H)
[src]
Feeds this value into the given [Hasher
]. Read more
fn hash_slice<H>(data: &[Self], state: &mut H) where
H: Hasher,
1.3.0[src]
H: Hasher,
Feeds a slice of this type into the given [Hasher
]. Read more
impl MallocSizeOf for ShorthandId
[src]
fn size_of(&self, ops: &mut MallocSizeOfOps) -> usize
[src]
Measure the heap usage of all descendant heap-allocated structures, but not the space taken up by the value itself. Read more
impl PartialEq for ShorthandId
[src]
fn eq(&self, __arg_0: &ShorthandId) -> bool
[src]
This method tests for self
and other
values to be equal, and is used by ==
. Read more
fn ne(&self, other: &Rhs) -> bool
1.0.0[src]
This method tests for !=
.