[][src]Trait gio::FilenameCompleterExt

pub trait FilenameCompleterExt: 'static {
    fn get_completion_suffix(&self, initial_text: &str) -> Option<GString>;
fn get_completions(&self, initial_text: &str) -> Vec<GString>;
fn set_dirs_only(&self, dirs_only: bool);
fn connect_got_completion_data<F: Fn(&Self) + 'static>(
        &self,
        f: F
    ) -> SignalHandlerId; }

Trait containing all FilenameCompleter methods.

Implementors

FilenameCompleter

Required methods

fn get_completion_suffix(&self, initial_text: &str) -> Option<GString>

Obtains a completion for initial_text from self.

initial_text

text to be completed.

Returns

a completed string, or None if no completion exists. This string is not owned by GIO, so remember to g_free it when finished.

fn get_completions(&self, initial_text: &str) -> Vec<GString>

Gets an array of completion strings for a given initial text.

initial_text

text to be completed.

Returns

array of strings with possible completions for initial_text. This array must be freed by g_strfreev when finished.

fn set_dirs_only(&self, dirs_only: bool)

If dirs_only is true, self will only complete directory names, and not file names.

dirs_only

a gboolean.

fn connect_got_completion_data<F: Fn(&Self) + 'static>(
    &self,
    f: F
) -> SignalHandlerId

Emitted when the file name completion information comes available.

Loading content...

Implementors

impl<O: IsA<FilenameCompleter>> FilenameCompleterExt for O[src]

Loading content...