[][src]Trait dialog::backends::Backend

pub trait Backend {
    fn show_input(&self, input: &Input) -> Result<Option<String>>;
fn show_message(&self, message: &Message) -> Result<()>;
fn show_password(&self, password: &Password) -> Result<Option<String>>;
fn show_question(&self, question: &Question) -> Result<Choice>;
fn show_file_selection(
        &self,
        file_selection: &FileSelection
    ) -> Result<Option<String>>; }

A dialog backend.

A dialog backend is a program that can be used to display dialog boxes. Use the default_backend function to create a new instance of the default backend, or choose a backend and create an instance manually. To use a backend, pass it to the show_with method of a dialog box.

Required methods

fn show_input(&self, input: &Input) -> Result<Option<String>>

Shows the given input dialog and returns the input.

fn show_message(&self, message: &Message) -> Result<()>

Shows the given message dialog.

fn show_password(&self, password: &Password) -> Result<Option<String>>

Shows the given password dialog and returns the password.

fn show_question(&self, question: &Question) -> Result<Choice>

Shows the given question dialog and returns the choice.

fn show_file_selection(
    &self,
    file_selection: &FileSelection
) -> Result<Option<String>>

Shows the given file selection dialog and returns the file name.

Loading content...

Implementors

impl Backend for Dialog[src]

impl Backend for KDialog[src]

impl Backend for Stdio[src]

impl Backend for Zenity[src]

Loading content...