[−][src]Struct dialog::backends::Zenity
The zenity
backend.
This backend uses the external zenity
program to display GTK+ dialog boxes.
Methods
impl Zenity
[src]
pub fn new() -> Zenity
[src]
Creates a new Zenity
instance without configuration.
pub fn set_icon(&mut self, icon: impl Into<String>)
[src]
Sets the icon of the dialog box.
The icon can either be one of error
, info
, question
or `warning, or the path to an
image to use. The default image depends on the dialog type.
pub fn set_height(&mut self, height: u32)
[src]
Sets the height of the dialog boxes.
The height is given in pixels. The actual height of the dialog box might be higher than the given height if the content would not fit otherwise.
pub fn set_width(&mut self, width: u32)
[src]
Sets the width of the dialog boxes.
The width is given in pixels. The actual width of the dialog box might be higher than the given width if the content would not fit otherwise.
pub fn set_timeout(&mut self, timeout: u32)
[src]
Sets the timout of the dialog boxes (in seconds).
After the timeout, the dialog box is closed. The timeout is handled like a cancel event. Per default, there is no timeout.
Trait Implementations
impl Backend for Zenity
[src]
fn show_input(&self, input: &Input) -> Result<Option<String>>
[src]
fn show_message(&self, message: &Message) -> Result<()>
[src]
fn show_password(&self, password: &Password) -> Result<Option<String>>
[src]
fn show_question(&self, question: &Question) -> Result<Choice>
[src]
impl AsRef<Zenity> for Zenity
[src]
impl Debug for Zenity
[src]
Auto Trait Implementations
impl Sync for Zenity
impl Send for Zenity
impl Unpin for Zenity
impl RefUnwindSafe for Zenity
impl UnwindSafe for Zenity
Blanket Implementations
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> From<T> for T
[src]
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,