pub struct CompositionGradientBrush(/* private fields */);Expand description
The base of the composition gradient brushes: the gradient stops and the spread method.
Implementations§
Source§impl CompositionGradientBrush
impl CompositionGradientBrush
Sourcepub fn from_brush(
brush: &Rc<CompositionBrush>,
) -> Option<CompositionGradientBrush>
pub fn from_brush( brush: &Rc<CompositionBrush>, ) -> Option<CompositionGradientBrush>
The handle of brush as a gradient brush, if it is one.
Sourcepub fn gradient_stops(&self) -> FerroList<Rc<dyn IGradientStop>>
pub fn gradient_stops(&self) -> FerroList<Rc<dyn IGradientStop>>
The gradient stops. Mutations of the list itself are not tracked - assign
the property to ship in-place edits made after a commit. Stops created via
Compositor::create_gradient_stop_with stay live
on the server and animate individually; other stops are snapshotted at
serialization time.
pub fn set_gradient_stops(&self, value: FerroList<Rc<dyn IGradientStop>>)
Sourcepub fn spread_method(&self) -> GradientSpreadMethod
pub fn spread_method(&self) -> GradientSpreadMethod
How the gradient repeats outside the stop range.
pub fn set_spread_method(&self, value: GradientSpreadMethod)
Trait Implementations§
Source§impl Clone for CompositionGradientBrush
impl Clone for CompositionGradientBrush
Source§impl Deref for CompositionGradientBrush
impl Deref for CompositionGradientBrush
Source§type Target = Rc<CompositionBrush>
type Target = Rc<CompositionBrush>
The resulting type after dereferencing.
Source§fn deref(&self) -> &Rc<CompositionBrush>
fn deref(&self) -> &Rc<CompositionBrush>
Dereferences the value.
Auto Trait Implementations§
impl !RefUnwindSafe for CompositionGradientBrush
impl !Send for CompositionGradientBrush
impl !Sync for CompositionGradientBrush
impl !UnwindSafe for CompositionGradientBrush
impl Freeze for CompositionGradientBrush
impl Unpin for CompositionGradientBrush
impl UnsafeUnpin for CompositionGradientBrush
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> ClassDefaults for Twhere
T: ?Sized,
impl<T> ClassDefaults for Twhere
T: ?Sized,
Source§fn static_constructor()
fn static_constructor()
The static constructor of a type: work done once per thread, after
the properties of the type are registered and before its first
instance exists (class handlers,
affects_render, metadata
overrides). Read more