pub struct StyleMap { /* private fields */ }Expand description
A style-map is one way for conditional formatting of cells.
It seems this is always translated into calcext:conditional-formats which seem to be the preferred way to deal with this. But it still works somewhat.
Implementations§
Source§impl StyleMap
impl StyleMap
Sourcepub fn new(
condition: Condition,
applied_style: AnyStyleRef,
base_cell: Option<CellRef>,
) -> Self
pub fn new( condition: Condition, applied_style: AnyStyleRef, base_cell: Option<CellRef>, ) -> Self
Create a stylemap. When the condition is fullfilled the style applied_style is used. The base_cell is used to resolve all relative cell-references within the condition.
Sourcepub fn set_condition(&mut self, cond: Condition)
pub fn set_condition(&mut self, cond: Condition)
Condition
Sourcepub fn applied_style(&self) -> &AnyStyleRef
pub fn applied_style(&self) -> &AnyStyleRef
The applied style.
Sourcepub fn set_applied_style(&mut self, style: AnyStyleRef)
pub fn set_applied_style(&mut self, style: AnyStyleRef)
Sets the applied style.
Sourcepub fn set_base_cell(&mut self, cellref: Option<CellRef>)
pub fn set_base_cell(&mut self, cellref: Option<CellRef>)
Sets the base cell.
Trait Implementations§
Source§impl GetSize for StyleMap
impl GetSize for StyleMap
Source§fn get_heap_size(&self) -> usize
fn get_heap_size(&self) -> usize
Determines how many bytes this object occupies inside the heap. Read more
Source§fn get_heap_size_with_tracker<TRACKER: GetSizeTracker>(
&self,
tracker: TRACKER,
) -> (usize, TRACKER)
fn get_heap_size_with_tracker<TRACKER: GetSizeTracker>( &self, tracker: TRACKER, ) -> (usize, TRACKER)
Determines how many bytes this object occupies inside the heap while using a
tracker. Read moreSource§fn get_stack_size() -> usize
fn get_stack_size() -> usize
Determines how may bytes this object occupies inside the stack. Read more
Source§fn get_size_with_tracker<T>(&self, tracker: T) -> (usize, T)where
T: GetSizeTracker,
fn get_size_with_tracker<T>(&self, tracker: T) -> (usize, T)where
T: GetSizeTracker,
Determines the total size of the object while using a
tracker. Read moreAuto Trait Implementations§
impl Freeze for StyleMap
impl RefUnwindSafe for StyleMap
impl Send for StyleMap
impl Sync for StyleMap
impl Unpin for StyleMap
impl UnwindSafe for StyleMap
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