![]() |
![]() |
![]() |
Moblin UI Toolkit Reference Manual | ![]() |
---|---|---|---|---|
Top | Description | Object Hierarchy |
MxClipboard; void (*MxClipboardCallbackFunc) (MxClipboard *clipboard, const gchar *text, gpointer user_data); MxClipboard* mx_clipboard_get_default (); void mx_clipboard_get_text (MxClipboard *clipboard, MxClipboardCallbackFunc callback, gpointer user_data); void mx_clipboard_set_text (MxClipboard *clipboard, const gchar *text);
MxCliboard is a very simple object representation of the clipboard available to applications. Text is always assumed to be UTF-8 and non-text items are not handled.
typedef struct _MxClipboard MxClipboard;
The contents of this structure is private and should only be accessed using the provided API.
void (*MxClipboardCallbackFunc) (MxClipboard *clipboard, const gchar *text, gpointer user_data);
Callback function called when text is retrieved from the clipboard.
|
A MxClipboard |
|
text from the clipboard |
|
user data |
MxClipboard* mx_clipboard_get_default ();
Get the global MxClipboard object that represents the clipboard.
Returns : |
a MxClipboard owned by Mx and must not be unrefferenced or freed. |
void mx_clipboard_get_text (MxClipboard *clipboard, MxClipboardCallbackFunc callback, gpointer user_data);
Request the data from the clipboard in text form. callback
is executed
when the data is retreived.
|
A MxCliboard |
|
function to be called when the text is retreived |
|
data to be passed to the callback |
void mx_clipboard_set_text (MxClipboard *clipboard, const gchar *text);
Sets text as the current contents of the clipboard.
|
A MxClipboard |
|
text to copy to the clipboard |