Version Control: Link
|Submitted: Jul 26 2011|
Updated: Dec 4 2011
kio-clipboard implements kio-slaves, protocols for KDEs io system. It makes the content of clipboards available inside file management. That means you can access the clipboards entries using standard file dialogs like 'File open' or 'Save File', you even can use a file browser and access entries. In general you can use the slaves wherever you can use an URL inside KDE to get access to the clipboards content. There are no temporary file generated.
Now we all agree that this appears more like a proof of concept. At first glance a real value in daily use seems hard to spot. After all why not simply use ctrl-c & ctrl-v ? Or even just left and middle click with something mouse like, when working under Linux and alike ? Actually this project is just an experiment for myself to learn a little about kde programming, Qt features and to get back into c++ basics after a long period of using other environments.
However on second glance one might spot situations where this becomes interesting:
- Imagine surfing the web, you copy the URLs of say 10 images to your clipboard. Now instead of downloading them all in advance or opening one by one using "file open">paste URL>open you could fire dolphin, select klipper amongst the predefined 'places' in the left panel, select the 10 URLs at once and chose "open with KolourPaint".
- This is just a first glimpse that implements support for only one single clipboard application: klipper. Preparations are done and it would be fun to support additional clipboards. Things get interesting when we talk about remote clipboards, online services or even the clipboard on your colleagues system who works on the same project with you. This would make data exchange really easy...
- Following this thought it turns out that this could easily act as a simple and general API to several clipboards (paste bins). Sharing information from within an application ? Just "Save to clipboard", select one and that's it ! Not API to implement, nothing.
- Who spots the next situation where this might come in handy ?
There are a number of packages provided below, these links are easiest to use.
You can browse the source repository online: http://svn.christian-reiner.info/web/wsvn/kio-clipboard
Just enter "clipboard:/" or "klipper:/" in the location bar of for example dolphin or a "File open" dialog.
This slave implements access to the standard clipboard utility under KDE4, called 'klipper'. Communication with klipper is done via its DBus interface, this makes it (relatively) future safe.
This protocol offers something like a "meta slave". It shows a kind of virtual folder where all available clipboards are offered. Each clipboard appears as a classical folder, standard file operations are supported as far as they make sense. The specific operations that might be available depend on the clipboard accessed.
This is an early and definitely buggy release. There are some issues with actions offered in file managers. A refresh of listings in file managers does not work automatically. You have to refresh manually after most actions that change the clipboards content, for example after deleting an item.
There are currently no clipboards supported besides 'klipper' :-(
Since this is my very first KDE implementation please don't bash me for this stuff :-)
Future versions might add further clipboard types.
Future versions might also be able to access remote (non-local) clipboards, the current version is limited to the local (current) desktop session.
The current version 0.2.5 is (hopefully) the last one before 0.3 which will bring support to the first online clipboard.
Feedback: I am more than happy to receive feedback or even get assistance in a number of issues. Please do not hesitate !
Also, someone experienced with Fedora and Mandriva would be a great help, I fail to generate packages for those distributions in OBS.
* Sat Aug 20 2011 Christian Reiner: version 0.2.5
- explicit specification of (virtual) file access rights and datetimes in nodes and clipboard folders
- - that does not really control or restrict anything, it is (at least for local clipboards) an optical aspect only
* Fri Aug 19 2011 Christian Reiner: version 0.2.4
- a number of internal reorganizations as preparation for version 0.3 integrating further clipboard applications/services
- removed caching of entry payloads in memory out of scalability interests
- dropped 'delete' action, this did not really make sense for clipboards
- first introduction of a shared memory cache between separate slave processes
- serialization feature for node wrapper objects, required for later persistent storage of clipboard entries between sessions
- convenience improvements by higher abstraction of node lists
* Wed Aug 10 2011 Christian Reiner: version 0.2.3
- enhanced mimetype detection for text based clipboard entries
- detection of a few special types of text entries declared as "code"
- simplified setup up of internal DBus clients
- fixed cardinality of numeric index in displayed entry names to honor the clipboards size
* Sun Aug 07 2011 Christian Reiner: version 0.2.2
- new structure for source file collection
- slightly optimized icons by usage of overlays (for KDE>=4.5)
- fixed 'delete item' action not to delete the target file pointed to (!)
- preparations for translation (i18n)
- implementation of the 'copyToFile' feature for protocols
- implementation of the 'copyFromFile' feature for protocols
- -for human readable files the content will copied to the clipboard instead of the URL or path
- - for all other files or files that exceed the clipboard entries size limit a linking of the URL/path is offered instead
- - the user can chose to accept or cancel
* Sat Jul 30 2011 Christian Reiner: version 0.2.1
- changed technical names of virtual nodes from a numeric index to a check sum
- - this fixes addressing the wrong node after changes to the clipboard that were not reflected in an embedding application
- additional content semantics 'Empty', since such content is not really 'Text'
* Fri Jul 29 2011 Christian Reiner: version 0.2.0
- complete rewrite of the internal storage structure
- fixed display name of clipboard folders not to vanish when being clicked
* Tue Jul 27 2011 Christian Reiner: version 0.1
- initial (and buggy) release
- publication on kde-apps.org