pub enum FormattingContext {
Show 14 variants
Block {
establishes_new_context: bool,
},
Inline,
InlineBlock,
Flex,
Float(LayoutFloat),
OutOfFlow(LayoutPosition),
Table,
TableRowGroup,
TableRow,
TableCell,
TableColumnGroup,
TableCaption,
Grid,
None,
}Expand description
Represents the CSS formatting context for an element
Variants§
Block
Block-level formatting context
Inline
Inline-level formatting context
InlineBlock
Inline-block (participates in an IFC but creates a BFC)
Flex
Flex formatting context
Float(LayoutFloat)
Float (left or right)
OutOfFlow(LayoutPosition)
Absolutely positioned (out of flow)
Table
Table formatting context (container)
TableRowGroup
Table row group formatting context (thead, tbody, tfoot)
TableRow
Table row formatting context
TableCell
Table cell formatting context (td, th)
TableColumnGroup
Table column group formatting context
TableCaption
Table caption formatting context
Grid
Grid formatting context
None
No formatting context (display: none)
Trait Implementations§
Source§impl Clone for FormattingContext
impl Clone for FormattingContext
Source§fn clone(&self) -> FormattingContext
fn clone(&self) -> FormattingContext
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 FormattingContext
impl Debug for FormattingContext
Source§impl Default for FormattingContext
impl Default for FormattingContext
Source§impl PartialEq for FormattingContext
impl PartialEq for FormattingContext
impl StructuralPartialEq for FormattingContext
Auto Trait Implementations§
impl Freeze for FormattingContext
impl RefUnwindSafe for FormattingContext
impl Send for FormattingContext
impl Sync for FormattingContext
impl Unpin for FormattingContext
impl UnwindSafe for FormattingContext
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,
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 more