Fri Apr 24 11:24:30 EDT 2009 Axel Simon <Axe...@en...>
* Add a function to insert the current clipboard content at the current cursor.
hunk ./gtk/Graphics/UI/Gtk/Multiline/TextBuffer.chs.pp 141
+ textBufferPasteClipboardAtCursor,
hunk ./gtk/Graphics/UI/Gtk/Multiline/TextBuffer.chs.pp 965
--- | Pastes the contents of a clipboard at the insertion point,
--- or at override_location. (Note: pasting is asynchronous, that is,
+-- | Pastes the contents of a clipboard at the given @location@.
+-- (Note: pasting is asynchronous, that is,
hunk ./gtk/Graphics/UI/Gtk/Multiline/TextBuffer.chs.pp 971
- -> TextIter -- ^ @overrideLocation@ - location to insert pasted text
+ -> TextIter -- ^ @location@ - location to insert pasted text
hunk ./gtk/Graphics/UI/Gtk/Multiline/TextBuffer.chs.pp 980
+
+-- | Pastes the contents of a clipboard at the insertion point.
+-- (Note: pasting is asynchronous, that is,
+-- we'll ask for the paste data and return, and at some point later
+-- after the main loop runs, the paste data will be inserted.)
+textBufferPasteClipboardAtCursor :: TextBufferClass self => self
+ -> Clipboard -- ^ @clipboard@ - the GtkClipboard to paste from
+ -> Bool -- ^ @defaultEditable@ - whether the buffer is editable by default
+ -> IO ()
+textBufferPasteClipboardAtCursor self clipboard defaultEditable =
+ {# call gtk_text_buffer_paste_clipboard #}
+ (toTextBuffer self)
+ clipboard
+ (TextIter nullForeignPtr)
+ (fromBool defaultEditable)
|