From 40abd164fea420d6f2aa30639f8bb517904b7bae Mon Sep 17 00:00:00 2001 From: nyamatongwe Date: Sun, 11 May 2003 01:25:28 +0000 Subject: Addition of CopyText, CopyRange, and LineCopy. --- gtk/ScintillaGTK.cxx | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'gtk') diff --git a/gtk/ScintillaGTK.cxx b/gtk/ScintillaGTK.cxx index e8f1626b3..11506abb0 100644 --- a/gtk/ScintillaGTK.cxx +++ b/gtk/ScintillaGTK.cxx @@ -137,6 +137,7 @@ private: void NotifyKey(int key, int modifiers); void NotifyURIDropped(const char *list); virtual int KeyDefault(int key, int modifiers); + virtual void CopyToClipboard(const SelectionText &selectedText); virtual void Copy(); virtual void Paste(); virtual void CreateCallTipWindow(PRectangle rc); @@ -910,6 +911,13 @@ int ScintillaGTK::KeyDefault(int key, int modifiers) { //Platform::DebugPrintf("SK-key: %d %x %x\n",key, modifiers); } +void ScintillaGTK::CopyToClipboard(const SelectionText &selectedText) { + copyText.Copy(selectedText.s, selectedText.len); + gtk_selection_owner_set(GTK_WIDGET(PWidget(wMain)), + clipboard_atom, + GDK_CURRENT_TIME); +} + void ScintillaGTK::Copy() { if (currentPos != anchor) { CopySelectionRange(©Text); -- cgit v1.2.3