Trait components::ClipboardExt[][src]

pub trait ClipboardExt: 'static {
    fn get_text<P: FnOnce(&Clipboard, &str) + 'static>(&self, callback: P);
fn set_text(&self, text: Option<String>); }

Required methods

fn get_text<P: FnOnce(&Clipboard, &str) + 'static>(&self, callback: P)[src]

get_text: @clipboard: A #Clipboard @callback: (scope async): function to be called when the text is retreived @user_data: data to be passed to the callback

Request the data from the clipboard in text form. @callback is executed when the data is retreived.

fn set_text(&self, text: Option<String>)[src]

set_text: @clipboard: A #Clipboard @text: text to copy to the clipboard

Sets text as the current contents of the clipboard.

Loading content...

Implementors

impl<O: Is<Clipboard>> ClipboardExt for O[src]

fn get_text<P: FnOnce(&Clipboard, &str) + 'static>(&self, callback: P)[src]

get_text: @clipboard: A #Clipboard @callback: (scope async): function to be called when the text is retreived @user_data: data to be passed to the callback

Request the data from the clipboard in text form. @callback is executed when the data is retreived.

fn set_text(&self, text: Option<String>)[src]

set_text: @clipboard: A #Clipboard @text: text to copy to the clipboard

Sets text as the current contents of the clipboard.

Loading content...