pub struct CachedData {
pub bounds: Vec<BoundingBox>,
pub visibility: Vec<Visibility>,
pub opacity: Vec<f32>,
pub hoverable: Vec<bool>,
pub focusable: Vec<bool>,
pub z_order: Vec<i32>,
pub clip_region: Vec<BoundingBox>,
pub space: Vec<Space>,
pub size: Vec<Size>,
pub geometry_changed: Vec<GeometryChanged>,
pub shadow_image: HashMap<Entity, (ImageId, ImageId)>,
/* private fields */
}
Fields§
§bounds: Vec<BoundingBox>
§visibility: Vec<Visibility>
§opacity: Vec<f32>
§hoverable: Vec<bool>
§focusable: Vec<bool>
§z_order: Vec<i32>
§clip_region: Vec<BoundingBox>
§space: Vec<Space>
§size: Vec<Size>
§geometry_changed: Vec<GeometryChanged>
§shadow_image: HashMap<Entity, (ImageId, ImageId)>
Implementations§
Source§impl CachedData
impl CachedData
pub fn add(&mut self, entity: Entity)
pub fn remove(&mut self, _entity: Entity)
pub fn get_grid_row_max(&self, entity: Entity) -> f32
pub fn get_grid_col_max(&self, entity: Entity) -> f32
pub fn get_stack_child(&self, entity: Entity) -> (bool, bool)
pub fn get_bounds(&self, entity: Entity) -> BoundingBox
pub fn get_cross_stretch_sum(&self, entity: Entity) -> f32
pub fn set_cross_stretch_sum(&mut self, entity: Entity, val: f32)
pub fn get_cross_free_space(&self, entity: Entity) -> f32
pub fn set_cross_free_space(&mut self, entity: Entity, val: f32)
pub fn get_space_left(&self, entity: Entity) -> f32
pub fn get_space_right(&self, entity: Entity) -> f32
pub fn get_space_top(&self, entity: Entity) -> f32
pub fn get_space_bottom(&self, entity: Entity) -> f32
pub fn get_space(&self, entity: Entity) -> Space
pub fn get_clip_region(&self, entity: Entity) -> BoundingBox
pub fn get_z_order(&self, entity: Entity) -> i32
pub fn get_child_width_sum(&self, entity: Entity) -> f32
pub fn get_child_height_sum(&self, entity: Entity) -> f32
pub fn get_child_width_max(&self, entity: Entity) -> f32
pub fn get_child_height_max(&self, entity: Entity) -> f32
pub fn get_posx(&self, entity: Entity) -> f32
pub fn get_posy(&self, entity: Entity) -> f32
pub fn get_width(&self, entity: Entity) -> f32
pub fn get_height(&self, entity: Entity) -> f32
pub fn get_opacity(&self, entity: Entity) -> f32
pub fn get_horizontal_free_space(&self, entity: Entity) -> f32
pub fn get_horizontal_stretch_sum(&self, entity: Entity) -> f32
pub fn get_vertical_free_space(&self, entity: Entity) -> f32
pub fn get_vertical_stretch_sum(&self, entity: Entity) -> f32
pub fn get_rotate(&self, entity: Entity) -> f32
pub fn get_translate(&self, entity: Entity) -> (f32, f32)
pub fn get_scale(&self, entity: Entity) -> f32
pub fn get_origin(&self, entity: Entity) -> (f32, f32)
pub fn get_transform(&self, entity: Entity) -> Transform2D
pub fn get_transform_mut(&mut self, entity: Entity) -> &mut Transform2D
pub fn set_stack_first_child(&mut self, entity: Entity, value: bool)
pub fn set_stack_last_child(&mut self, entity: Entity, value: bool)
pub fn set_horizontal_free_space(&mut self, entity: Entity, value: f32)
pub fn set_horizontal_stretch_sum(&mut self, entity: Entity, value: f32)
pub fn set_vertical_free_space(&mut self, entity: Entity, value: f32)
pub fn set_vertical_stretch_sum(&mut self, entity: Entity, value: f32)
pub fn set_space(&mut self, entity: Entity, val: Space)
pub fn set_space_left(&mut self, entity: Entity, val: f32)
pub fn set_space_right(&mut self, entity: Entity, val: f32)
pub fn set_space_top(&mut self, entity: Entity, val: f32)
pub fn set_space_bottom(&mut self, entity: Entity, val: f32)
pub fn set_clip_region(&mut self, entity: Entity, val: BoundingBox)
pub fn set_z_order(&mut self, entity: Entity, val: i32)
pub fn set_child_width_sum(&mut self, entity: Entity, val: f32)
pub fn set_child_height_sum(&mut self, entity: Entity, val: f32)
pub fn set_child_width_max(&mut self, entity: Entity, val: f32)
pub fn set_child_height_max(&mut self, entity: Entity, val: f32)
pub fn set_posx(&mut self, entity: Entity, val: f32)
pub fn set_posy(&mut self, entity: Entity, val: f32)
pub fn set_width(&mut self, entity: Entity, val: f32)
pub fn set_height(&mut self, entity: Entity, val: f32)
pub fn get_visibility(&self, entity: Entity) -> Visibility
pub fn set_visibility(&mut self, entity: Entity, val: Visibility)
pub fn get_hoverable(&self, entity: Entity) -> bool
pub fn get_focusable(&self, entity: Entity) -> bool
pub fn set_hoverable(&mut self, entity: Entity, val: bool)
pub fn set_focusable(&mut self, entity: Entity, val: bool)
pub fn set_opacity(&mut self, entity: Entity, val: f32)
pub fn set_rotate(&mut self, entity: Entity, val: f32)
pub fn set_translate(&mut self, entity: Entity, val: (f32, f32))
pub fn set_scale(&mut self, entity: Entity, val: f32)
pub fn set_origin(&mut self, entity: Entity, val: (f32, f32))
pub fn set_transform(&mut self, entity: Entity, val: Transform2D)
Trait Implementations§
Source§impl Cache for CachedData
impl Cache for CachedData
type Item = Entity
fn visible(&self, node: <CachedData as Cache>::Item) -> bool
fn set_visible(&mut self, node: <CachedData as Cache>::Item, value: bool)
fn geometry_changed(&self, node: <CachedData as Cache>::Item) -> GeometryChanged
fn set_geo_changed( &mut self, node: <CachedData as Cache>::Item, flag: GeometryChanged, value: bool, )
fn new_width(&self, node: <CachedData as Cache>::Item) -> f32
fn new_height(&self, node: <CachedData as Cache>::Item) -> f32
fn set_new_width(&mut self, node: <CachedData as Cache>::Item, value: f32)
fn set_new_height(&mut self, node: <CachedData as Cache>::Item, value: f32)
fn set_width(&mut self, node: <CachedData as Cache>::Item, value: f32)
fn set_height(&mut self, node: <CachedData as Cache>::Item, value: f32)
Source§fn posx(&self, node: <CachedData as Cache>::Item) -> f32
fn posx(&self, node: <CachedData as Cache>::Item) -> f32
Get the computed x position of a node
fn set_posx(&mut self, node: <CachedData as Cache>::Item, value: f32)
Source§fn posy(&self, node: <CachedData as Cache>::Item) -> f32
fn posy(&self, node: <CachedData as Cache>::Item) -> f32
Get the computed y position of a node
fn set_posy(&mut self, node: <CachedData as Cache>::Item, value: f32)
fn left(&self, node: <CachedData as Cache>::Item) -> f32
fn set_left(&mut self, node: <CachedData as Cache>::Item, value: f32)
fn right(&self, node: <CachedData as Cache>::Item) -> f32
fn set_right(&mut self, node: <CachedData as Cache>::Item, value: f32)
fn top(&self, node: <CachedData as Cache>::Item) -> f32
fn set_top(&mut self, node: <CachedData as Cache>::Item, value: f32)
fn bottom(&self, node: <CachedData as Cache>::Item) -> f32
fn set_bottom(&mut self, node: <CachedData as Cache>::Item, value: f32)
Source§fn child_width_max(&self, node: <CachedData as Cache>::Item) -> f32
fn child_width_max(&self, node: <CachedData as Cache>::Item) -> f32
Get the computed maximum width of the child nodes
fn set_child_width_max(&mut self, node: <CachedData as Cache>::Item, value: f32)
Source§fn child_width_sum(&self, node: <CachedData as Cache>::Item) -> f32
fn child_width_sum(&self, node: <CachedData as Cache>::Item) -> f32
Get the computed sum of the widths of the child nodes
fn set_child_width_sum(&mut self, node: <CachedData as Cache>::Item, value: f32)
Source§fn child_height_max(&self, node: <CachedData as Cache>::Item) -> f32
fn child_height_max(&self, node: <CachedData as Cache>::Item) -> f32
Get the computed maximum width of the child nodes
fn set_child_height_max( &mut self, node: <CachedData as Cache>::Item, value: f32, )
Source§fn child_height_sum(&self, node: <CachedData as Cache>::Item) -> f32
fn child_height_sum(&self, node: <CachedData as Cache>::Item) -> f32
Get the computed sum of the widths of the child nodes
fn set_child_height_sum( &mut self, node: <CachedData as Cache>::Item, value: f32, )
fn stack_first_child(&self, node: <CachedData as Cache>::Item) -> bool
fn stack_last_child(&self, node: <CachedData as Cache>::Item) -> bool
fn set_stack_first_child( &mut self, node: <CachedData as Cache>::Item, value: bool, )
fn set_stack_last_child( &mut self, node: <CachedData as Cache>::Item, value: bool, )
fn horizontal_free_space(&self, node: <CachedData as Cache>::Item) -> f32
fn set_horizontal_free_space( &mut self, node: <CachedData as Cache>::Item, value: f32, )
fn vertical_free_space(&self, node: <CachedData as Cache>::Item) -> f32
fn set_vertical_free_space( &mut self, node: <CachedData as Cache>::Item, value: f32, )
fn horizontal_stretch_sum(&self, node: <CachedData as Cache>::Item) -> f32
fn set_horizontal_stretch_sum( &mut self, node: <CachedData as Cache>::Item, value: f32, )
fn vertical_stretch_sum(&self, node: <CachedData as Cache>::Item) -> f32
fn set_vertical_stretch_sum( &mut self, node: <CachedData as Cache>::Item, value: f32, )
Source§fn grid_row_max(&self, node: <CachedData as Cache>::Item) -> f32
fn grid_row_max(&self, node: <CachedData as Cache>::Item) -> f32
Get the computed maximum grid row
Source§fn grid_col_max(&self, node: <CachedData as Cache>::Item) -> f32
fn grid_col_max(&self, node: <CachedData as Cache>::Item) -> f32
Get the computed maximum grid column
Source§impl Clone for CachedData
impl Clone for CachedData
Source§fn clone(&self) -> CachedData
fn clone(&self) -> CachedData
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 Default for CachedData
impl Default for CachedData
Source§fn default() -> CachedData
fn default() -> CachedData
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl Freeze for CachedData
impl RefUnwindSafe for CachedData
impl Send for CachedData
impl Sync for CachedData
impl Unpin for CachedData
impl UnwindSafe for CachedData
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