From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: X-Spam-Status: No, score=1.0 required=5.0 tests=BAYES_00,URI_WP_DIRINDEX autolearn=no autolearn_force=no version=3.4.4 X-Google-Thread: a07f3367d7,346d64e20a7ed5e1 X-Google-Attributes: gida07f3367d7,public,usenet X-Google-NewGroupId: yes X-Google-Language: ENGLISH,ASCII-7-bit Path: g2news1.google.com!news1.google.com!border1.nntp.dca.giganews.com!nntp.giganews.com!newsgate.cuhk.edu.hk!news.netfront.net!not-for-mail From: Alex Newsgroups: comp.lang.ada Subject: Re: Using the Clipboard in Linux Date: Mon, 9 Nov 2009 21:09:22 +0000 (UTC) Organization: Netfront http://www.netfront.net Message-ID: References: <20091108215519.0a206ba2.tero.koskinen@iki.fi> NNTP-Posting-Host: 81.146.36.53 Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Trace: adenine.netfront.net 1257800962 30587 81.146.36.53 (9 Nov 2009 21:09:22 GMT) X-Complaints-To: news@netfront.net NNTP-Posting-Date: Mon, 9 Nov 2009 21:09:22 +0000 (UTC) User-Agent: Pan/0.132 (Waxed in Black) Xref: g2news1.google.com comp.lang.ada:8065 Date: 2009-11-09T21:09:22+00:00 List-Id: On Sun, 08 Nov 2009 21:55:19 +0200, Tero Koskinen wrote: > On Sun, 08 Nov 2009 04:52:29 -0500 Stephen Leake wrote: > >> Alex writes: >> >> > I've written an application in windows that involves writing to the >> > clipboard. I'm trying to write a version to work in Linux (Ubuntu >> > 9.04 is what I'm developing on) and am struggling to get started with >> > Florist. >> >> Linux the operating system kernel doesn't have a clipboard. >> >> X Windows does, and particular window managers may have other >> variations on it. >> >> So you need to look in X Windows documentation, not Linux >> documentation. > > Probably the easiest way is to use GtkAda and its clipboard methods: > http://www.adacore.com/wp-content/files/auto_update/gtkada-docs/ gtkada_rm/gtkada_rm/gtk-clipboard.html > > And please note that X Window System (which GtkAda uses) has two > different clipboards, PRIMARY and CLIPBOARD. (This mostly matters if you > need to communicate between two different programs via clipboard.) Tero and Stephen Thanks very much for your advice - it's a great help. My application is using GTK anyway but for the windows version I used the Win32 API so I assumed that symmetrically I would need the Linux API to do the same on windows. Thanks for clearing that up - I should be able to crack on and effect the clipboard part of my application with GTK now. I have to say that I've really found this group a helpful bunch - the Ada community really does seem a good crowd. Thanks again chaps Alex