#[repr(transparent)]pub struct ColorStop { /* private fields */ }
Expand description
A color stop in a gradient node.
Implementations§
source§impl ColorStop
impl ColorStop
pub fn as_ptr(&self) -> *mut GskColorStop
sourcepub unsafe fn from_glib_ptr_borrow<'a>(ptr: *const GskColorStop) -> &'a Self
pub unsafe fn from_glib_ptr_borrow<'a>(ptr: *const GskColorStop) -> &'a Self
Borrows the underlying C value.
sourcepub unsafe fn from_glib_ptr_borrow_mut<'a>(
ptr: *mut GskColorStop
) -> &'a mut Self
pub unsafe fn from_glib_ptr_borrow_mut<'a>( ptr: *mut GskColorStop ) -> &'a mut Self
Borrows the underlying C value mutably.
source§impl ColorStop
impl ColorStop
pub fn new(offset: f32, color: RGBA) -> Self
sourcepub fn builder() -> ColorStopBuilder
pub fn builder() -> ColorStopBuilder
Creates a new builder-pattern struct instance to construct ColorStop
objects.
This method returns an instance of ColorStopBuilder
which can be used to create ColorStop
objects.
pub fn offset(&self) -> f32
pub fn color(&self) -> &RGBA
Trait Implementations§
Auto Trait Implementations§
impl RefUnwindSafe for ColorStop
impl Send for ColorStop
impl Sync for ColorStop
impl Unpin for ColorStop
impl UnwindSafe for ColorStop
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