pub enum Icon {
Uri(Url),
Names(Vec<String>),
Bytes(Vec<u8>),
}
Expand description
A representation of an icon.
Used by both the Notification & Dynamic launcher portals.
Variants§
Implementations§
source§impl Icon
impl Icon
sourcepub fn with_names<N>(names: impl IntoIterator<Item = N>) -> Selfwhere
N: ToString,
pub fn with_names<N>(names: impl IntoIterator<Item = N>) -> Selfwhere
N: ToString,
Create an icon from a list of names.
Trait Implementations§
source§impl<'de> Deserialize<'de> for Icon
impl<'de> Deserialize<'de> for Icon
source§fn deserialize<D>(deserializer: D) -> Result<Self, D::Error>where
D: Deserializer<'de>,
fn deserialize<D>(deserializer: D) -> Result<Self, D::Error>where
D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
source§impl TryFrom<&OwnedValue> for Icon
impl TryFrom<&OwnedValue> for Icon
source§impl TryFrom<OwnedValue> for Icon
impl TryFrom<OwnedValue> for Icon
impl Eq for Icon
impl StructuralPartialEq for Icon
Auto Trait Implementations§
impl Freeze for Icon
impl RefUnwindSafe for Icon
impl Send for Icon
impl Sync for Icon
impl Unpin for Icon
impl UnwindSafe for Icon
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<'de, T> DynamicDeserialize<'de> for T
impl<'de, T> DynamicDeserialize<'de> for T
§type Deserializer = PhantomData<T>
type Deserializer = PhantomData<T>
A DeserializeSeed implementation for this type.
source§fn deserializer_for_signature<S>(
signature: S,
) -> Result<<T as DynamicDeserialize<'de>>::Deserializer, Error>
fn deserializer_for_signature<S>( signature: S, ) -> Result<<T as DynamicDeserialize<'de>>::Deserializer, Error>
Get a deserializer compatible with this signature.
source§impl<T> DynamicType for T
impl<T> DynamicType for T
source§fn dynamic_signature(&self) -> Signature<'_>
fn dynamic_signature(&self) -> Signature<'_>
Get the signature for the implementing type. Read more