From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: =?utf-8?Q?Jan_Dj=C3=A4rv?= Newsgroups: gmane.emacs.devel Subject: Re: Mysterious differences in nsselect.m Date: Tue, 21 Oct 2014 21:01:29 +0200 Message-ID: <8FCE673E-3441-4D58-B427-998425406BD5@swipnet.se> References: <2B06B631-0098-48DF-9307-CD8A328E972F@swipnet.se> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 (Mac OS X Mail 8.0 \(1990.1\)) Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: quoted-printable X-Trace: ger.gmane.org 1413918130 4093 80.91.229.3 (21 Oct 2014 19:02:10 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Tue, 21 Oct 2014 19:02:10 +0000 (UTC) Cc: Adrian Robert , emacs-devel@gnu.org To: Stefan Monnier Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Tue Oct 21 21:02:03 2014 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1Xgegy-0006nl-1Z for ged-emacs-devel@m.gmane.org; Tue, 21 Oct 2014 21:02:00 +0200 Original-Received: from localhost ([::1]:53074 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Xgegv-0007Zk-C3 for ged-emacs-devel@m.gmane.org; Tue, 21 Oct 2014 15:01:57 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:44855) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Xgegk-0007YA-M9 for emacs-devel@gnu.org; Tue, 21 Oct 2014 15:01:54 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Xgegd-0003pF-7D for emacs-devel@gnu.org; Tue, 21 Oct 2014 15:01:46 -0400 Original-Received: from mailfe09.swip.net ([212.247.155.1]:46892 helo=swip.net) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Xgegd-0003os-02 for emacs-devel@gnu.org; Tue, 21 Oct 2014 15:01:39 -0400 X-T2-Spam-Status: No, hits=0.8 required=5.0 tests=BAYES_50 Original-Received: from hosdjarv.se (account mj138573@tele2.se [46.59.42.57] verified) by mailfe09.swip.net (CommuniGate Pro SMTP 5.4.4) with ESMTPA id 368626506; Tue, 21 Oct 2014 21:01:30 +0200 In-Reply-To: X-Mailer: Apple Mail (2.1990.1) X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x X-Received-From: 212.247.155.1 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:175665 Archived-At: Hello. > What I mean is: if you push to the clipboard a string "hello" and then > a filename "/a/b", are they still both in there, or does the second > replace the first? If they are different types, they both are in there. The idea is that = the receiver can request different formats according to his needs, i.e. = plain text, HTML, GIF. There is also a protocol so the owner can be = notified about what the receiver wants and then produce that format on = the fly. But Emacs only pushes strings, so they are replaced. >=20 > If the second replaces the first then the loop in > ns_string_to_pasteboard_internal makes no sense, but if they both stay > in there, then it basically means we have several clipboards, so we = may > miss one application's clipboard data simply because we don't request > the right type. If we where copying a filename for example, we would in that loop push a = filename and a string. String makes sense for a text editor, filename = more for a filebrowser. But I think it was intended for "future use". Jan D.