Enum notify_rust::Hint
source · [−]pub enum Hint {
}
Expand description
Hints
allow you to pass extra information to the server.
Many of these are standardized by either:
- http://www.galago-project.org/specs/notification/0.9/x344.html
- https://developer.gnome.org/notification-spec/#hints
Which of these are actually implemented depends strongly on the Notification server you talk to.
Usually the get_capabilities()
gives some clues, but the standards usually mention much more
than is actually available.
you pass these to Notification::hint
Variants
ActionIcons(bool)
If true, server may interpret action identifiers as named icons and display those.
Category(String)
Check out:
DesktopEntry(String)
Name of the DesktopEntry representing the calling application. In case of “firefox.desktop” use “firefox”. May be used to retrieve the correct icon.
ImagePath(String)
Display the image at this path.
Resident(bool)
This does not work on all servers, however timeout=0 will do the job
SoundFile(String)
Play the sound at this path.
SoundName(String)
A themeable named sound from the freedesktop.org sound naming specification to play when the notification pops up. Similar to icon-name, only for sounds. An example would be “message-new-instant”.
SuppressSound(bool)
Suppress the notification sound.
Transient(bool)
When set the server will treat the notification as transient and by-pass the server’s persistence capability, if it should exist.
X(i32)
Lets the notification point to a certain ‘x’ position on the screen.
Requires Y
.
Y(i32)
Lets the notification point to a certain ‘y’ position on the screen.
Requires X
.
Urgency(Urgency)
Pass me a Urgency, either Low, Normal or Critical
Custom(String, String)
If you want to pass something entirely different.
CustomInt(String, i32)
A custom numerical (integer) hint
Invalid
Only used by this NotificationServer implementation
Implementations
Trait Implementations
impl Eq for Hint
impl StructuralEq for Hint
impl StructuralPartialEq for Hint
Auto Trait Implementations
impl RefUnwindSafe for Hint
impl Send for Hint
impl Sync for Hint
impl Unpin for Hint
impl UnwindSafe for Hint
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
sourceimpl<T> ToOwned for T where
T: Clone,
impl<T> ToOwned for T where
T: Clone,
type Owned = T
type Owned = T
The resulting type after obtaining ownership.
sourcefn clone_into(&self, target: &mut T)
fn clone_into(&self, target: &mut T)
toowned_clone_into
)Uses borrowed data to replace owned data, usually by cloning. Read more