pub struct SmallWidget(/* private fields */);Expand description
Type-safe and guarenteed method of making a small widget.
Implementations§
Source§impl SmallWidget
impl SmallWidget
Sourcepub fn build(self) -> Result<String>
pub fn build(self) -> Result<String>
Builds into a valid URL.
§Errors
Returns Error::InvalidUrl if one of the query parameters is invalid.
Sourcepub fn avatar_background(&mut self, value: impl Into<String>) -> &mut Self
pub fn avatar_background(&mut self, value: impl Into<String>) -> &mut Self
Sets the background color of the widget.
Sourcepub fn left_color(&mut self, value: impl Into<String>) -> &mut Self
pub fn left_color(&mut self, value: impl Into<String>) -> &mut Self
Sets the left color of the widget.
Sourcepub fn left_text_color(&mut self, value: impl Into<String>) -> &mut Self
pub fn left_text_color(&mut self, value: impl Into<String>) -> &mut Self
Sets the left text color of the widget.
Sourcepub fn right_color(&mut self, value: impl Into<String>) -> &mut Self
pub fn right_color(&mut self, value: impl Into<String>) -> &mut Self
Sets the right color of the widget.
Sourcepub fn right_text_color(&mut self, value: impl Into<String>) -> &mut Self
pub fn right_text_color(&mut self, value: impl Into<String>) -> &mut Self
Sets the right text color of the widget.
Trait Implementations§
Source§impl Clone for SmallWidget
impl Clone for SmallWidget
Source§fn clone(&self) -> SmallWidget
fn clone(&self) -> SmallWidget
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 moreAuto Trait Implementations§
impl Freeze for SmallWidget
impl RefUnwindSafe for SmallWidget
impl Send for SmallWidget
impl Sync for SmallWidget
impl Unpin for SmallWidget
impl UnwindSafe for SmallWidget
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