summaryrefslogtreecommitdiff
path: root/include/LibreOfficeKit
diff options
context:
space:
mode:
authorPranav Kant <pranavk@libreoffice.org>2015-12-09 21:45:21 +0530
committerDavid Tardon <dtardon@redhat.com>2015-12-09 16:36:22 +0000
commit7d7fad258dfde500c5ee99b5f1691172724383bd (patch)
tree2688915c6cf6534d80922f881a712c5a83881492 /include/LibreOfficeKit
parentdbc830aecc722d34971d773470da478ef4c38714 (diff)
tdf#96317: Add API for copy/paste from/to the widget
Change-Id: Iac869ddb65cbdd2227f96d047d83159ca7819f11 Reviewed-on: https://gerrit.libreoffice.org/20534 Reviewed-by: David Tardon <dtardon@redhat.com> Tested-by: David Tardon <dtardon@redhat.com>
Diffstat (limited to 'include/LibreOfficeKit')
-rw-r--r--include/LibreOfficeKit/LibreOfficeKitGtk.h29
1 files changed, 29 insertions, 0 deletions
diff --git a/include/LibreOfficeKit/LibreOfficeKitGtk.h b/include/LibreOfficeKit/LibreOfficeKitGtk.h
index 1b03e4633547..903a74256ffa 100644
--- a/include/LibreOfficeKit/LibreOfficeKitGtk.h
+++ b/include/LibreOfficeKit/LibreOfficeKitGtk.h
@@ -235,6 +235,35 @@ void lok_doc_view_highlight_all (LOKDocView*
const gchar* pText);
/**
+ * lok_doc_view_copy_selection:
+ * @pDocView: The #LOKDocView instance
+ * @pMimeType: suggests the return format, for example text/plain;charset=utf-8
+ * @pUsedMimeType: (out): output parameter to inform about the determined format
+ * (suggested or plain text).
+ *
+ * Returns: Selected text. The caller must free the returned buffer after use.
+ */
+gchar* lok_doc_view_copy_selection (LOKDocView* pDocView,
+ const gchar* pMimeType,
+ gchar** pUsedMimeType);
+
+/**
+ * lok_doc_view_paste:
+ * @pDocView: The #LOKDocView instance
+ * @pMimeType: format of pData, for example text/plain;charset=utf-8
+ * @pData: the data to be pasted
+ * @nSize: length of data to be pasted
+ *
+ * Pastes the content at the current cursor position
+ *
+ * Returns: if pData was pasted successfully.
+ */
+gboolean lok_doc_view_paste (LOKDocView* pDocView,
+ const gchar* pMimeType,
+ const gchar* pData,
+ gsize nSize);
+
+/**
* lok_doc_view_pixel_to_twip:
* @pDocView: The #LOKDocView instance
* @fInput: The value in pixels to convert to twips