Struct freya_node_state::Style
source · pub struct Style {
pub background: Fill,
pub relative_layer: i16,
pub border: Border,
pub shadows: Vec<Shadow>,
pub corner_radius: CornerRadius,
pub image_data: Option<Vec<u8>>,
pub svg_data: Option<Vec<u8>>,
pub overflow: OverflowMode,
}
Fields§
§background: Fill
§relative_layer: i16
§border: Border
§shadows: Vec<Shadow>
§corner_radius: CornerRadius
§image_data: Option<Vec<u8>>
§svg_data: Option<Vec<u8>>
§overflow: OverflowMode
Trait Implementations§
source§impl PartialEq<Style> for Style
impl PartialEq<Style> for Style
source§impl State<CustomAttributeValues> for Style
impl State<CustomAttributeValues> for Style
source§fn create<'a>(
node_view: NodeView<'_, CustomAttributeValues>,
node: <Self::NodeDependencies as Dependancy>::ElementBorrowed<'a>,
parent: Option<<Self::ParentDependencies as Dependancy>::ElementBorrowed<'a>>,
children: Vec<<Self::ChildDependencies as Dependancy>::ElementBorrowed<'a>>,
context: &SendAnyMap
) -> Self
fn create<'a>( node_view: NodeView<'_, CustomAttributeValues>, node: <Self::NodeDependencies as Dependancy>::ElementBorrowed<'a>, parent: Option<<Self::ParentDependencies as Dependancy>::ElementBorrowed<'a>>, children: Vec<<Self::ChildDependencies as Dependancy>::ElementBorrowed<'a>>, context: &SendAnyMap ) -> Self
Create a new instance of this state
§type ParentDependencies = (Style,)
type ParentDependencies = (Style,)
This is a tuple of (T: State, ..) of states read from the parent required to update this state
§type ChildDependencies = ()
type ChildDependencies = ()
This is a tuple of (T: State, ..) of states read from the children required to update this state
§type NodeDependencies = ()
type NodeDependencies = ()
This is a tuple of (T: State, ..) of states read from the node required to update this state
source§const NODE_MASK: NodeMaskBuilder<'static> = _
const NODE_MASK: NodeMaskBuilder<'static> = _
This is a mask of what aspects of the node are required to update this state
source§fn update<'a>(
&mut self,
node_view: NodeView<'_, CustomAttributeValues>,
_node: <Self::NodeDependencies as Dependancy>::ElementBorrowed<'a>,
_parent: Option<<Self::ParentDependencies as Dependancy>::ElementBorrowed<'a>>,
_children: Vec<<Self::ChildDependencies as Dependancy>::ElementBorrowed<'a>>,
context: &SendAnyMap
) -> bool
fn update<'a>( &mut self, node_view: NodeView<'_, CustomAttributeValues>, _node: <Self::NodeDependencies as Dependancy>::ElementBorrowed<'a>, _parent: Option<<Self::ParentDependencies as Dependancy>::ElementBorrowed<'a>>, _children: Vec<<Self::ChildDependencies as Dependancy>::ElementBorrowed<'a>>, context: &SendAnyMap ) -> bool
Update this state in a node, returns if the state was updated
source§fn workload_system(
type_id: TypeId,
dependants: Arc<Dependants>,
pass_direction: PassDirection
) -> WorkloadSystem
fn workload_system( type_id: TypeId, dependants: Arc<Dependants>, pass_direction: PassDirection ) -> WorkloadSystem
Create a workload system for this state
§const TRAVERSE_SHADOW_DOM: bool = false
const TRAVERSE_SHADOW_DOM: bool = false
Does the state traverse into the shadow dom or pass over it. This should be true for layout and false for styles
§fn to_type_erased() -> TypeErasedState<V>where
Self: Sized,
fn to_type_erased() -> TypeErasedState<V>where Self: Sized,
Converts to a type erased version of the trait
impl StructuralPartialEq for Style
Auto Trait Implementations§
impl RefUnwindSafe for Style
impl Send for Style
impl Sync for Style
impl Unpin for Style
impl UnwindSafe for Style
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
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
§impl<T> NoneValue for Twhere
T: Default,
impl<T> NoneValue for Twhere T: Default,
type NoneType = T
§fn null_value() -> T
fn null_value() -> T
The none-equivalent value.
§impl<T> Pointable for T
impl<T> Pointable for T
§impl<T> TupleAddComponent for Twhere
T: Send + Sync + Component,
<T as Component>::Tracking: Send + Sync,
impl<T> TupleAddComponent for Twhere T: Send + Sync + Component, <T as Component>::Tracking: Send + Sync,
§fn add_component(self, all_storages: &mut AllStorages, entity: EntityId)
fn add_component(self, all_storages: &mut AllStorages, entity: EntityId)
See [
World::add_entity
], [World::add_component
], [AllStorages::add_entity
] and [AllStorages::add_component
].