What do I have to do in order to copy data from the system clipboard into an app?
A more specific example: I want to import a person’s vCard as a QR-code from their website. I scan the QR-code with the “Camera” app which can detect QR-codes where I than choose “copy”. Then I open “Contacts” and choose “Import …” but there is no “System Clipboard” shown to copy from. Where can I find it?
Thanks, but that’s part of my question: How do I paste/insert content from the system clipboard into e.g. my Home folder? On my notebook running KDE Plasma 5 I can easily do this by using the clipboard function at the system tray.
There are three ways: (1) You can click on the menu icon in the upper corner and there are the Edit buttons; Or (2) you can go into terminal mode on the keyboard and use ctr-v; or (3) in terminal mode click on this: >_ and select menu.
Maybe I’ve phrased my question incorrectly, but my underlying problem is that I don’t know where the phone stores the content of the system clipboard. Therefore I can’t paste it into my home folder or anywhere else in the first place. So where is the content of the clipboard stored; what’s the exact name of this file?
There is no file name because the clipboard is not typically implemented as a file.
Another approach to your problem is sudo apt install zbar-tools
Then in the Camera app, instead of scanning the QR code and copying (whatever is copied) … actually take a photo of the QR code.
Then zbarimg -q --raw foo.jpg >foo.txt
where foo is the actual name of the photo taken of the QR code.
Then you have a file foo.txt that contains the contents of a QR code (which is hopefully what you can Import).
Be careful though because there are two approaches to using a QR code for a business card.
The standard approach - the QR code encodes a long textual string that is formatted exactly in vCard format (for one card).
The evil approach - the QR code encodes a URL and visiting that URL will bring up all the information that is traditionally included on a business card. The advantage of this approach is that if you change any information, you don’t have to reprint the business card and you don’t invalidate any business cards that you have already handed out. The disadvantage is that, as usually deployed by an enterprise, this function is outsourced to a third party - so you become dependent on a third party and you are sharing all your enterprise’s contact information with that third party.
(I would guess that the system integration simply doesn’t exist yet between Camera and Contacts so that a standard QR code for a business card will automatically get imported - after you confirm to go ahead.)
PS In this specific case, I would imagine that Camera “copy (to clipboard)” has copied the textual content of the QR code to the clipboard. You might be able to use any random text editor, to paste from the clipboard and thereby save to a file. And then finally Contacts Import from that file.
Thanks for your detailed answer! I didn’t know that there are QR codes for business cards that encode a URL pointing to a website where the actual information is stored. The business card I wanted to import into “Contacts” is one of this kind. As I first scanned it with the “Camera” app it showed me a URL ending with “.vcf” and offered me “Open URL” and “Copy”. Because of me not knowing that there are QR codes for business cards that encode a URL I choose “Copy” which didn’t work.
After your answer I rescanned the QR code, tapped on “Open URL”, and, boom, “Camera” automatically imported the vCard into “Contacts”! This is the workflow I’m used to from my old Nokia N9 smartphone but what I didn’t expect to work on my Librem 5. I was wrong!
Thanks again for your help and a shout-out to this great and friendly forum!