From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Stefan Monnier Newsgroups: gmane.emacs.devel Subject: Re: Improving X selection? Date: Thu, 07 Feb 2008 17:43:39 -0500 Message-ID: References: <8e24944a0802030512t77c4ca20s6d059df50295ebd2@mail.gmail.com> <8e24944a0802041302n45064c4fm2ac428ceda204254@mail.gmail.com> <47A80B57.3050402@swipnet.se> <8e24944a0802061957re4baf7cr9560fa3496be56b4@mail.gmail.com> <8e24944a0802070815n18dea273j5c3962235d91ca8e@mail.gmail.com> <87bq6sir34.fsf@uwakimon.sk.tsukuba.ac.jp> <8e24944a0802071022i2b259c5fka14f191a3c519157@mail.gmail.com> <8e24944a0802071239r1cdc8affq7875fea0b9876560@mail.gmail.com> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: ger.gmane.org 1202424258 9990 80.91.229.12 (7 Feb 2008 22:44:18 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Thu, 7 Feb 2008 22:44:18 +0000 (UTC) Cc: "Horsley, Tom" , "Stephen J. Turnbull" , "Jan D." , rms@gnu.org, emacs-devel@gnu.org To: "David De La Harpe Golden" Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Thu Feb 07 23:44:40 2008 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.50) id 1JNFTq-0002eM-Cl for ged-emacs-devel@m.gmane.org; Thu, 07 Feb 2008 23:44:30 +0100 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1JNFTN-0004Ea-P4 for ged-emacs-devel@m.gmane.org; Thu, 07 Feb 2008 17:44:01 -0500 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1JNFTK-0004Dz-1G for emacs-devel@gnu.org; Thu, 07 Feb 2008 17:43:58 -0500 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1JNFTJ-0004Dn-Dl for emacs-devel@gnu.org; Thu, 07 Feb 2008 17:43:57 -0500 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1JNFTJ-0004Dk-7y for emacs-devel@gnu.org; Thu, 07 Feb 2008 17:43:57 -0500 Original-Received: from mercure.iro.umontreal.ca ([132.204.24.67]) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1JNFTD-0000A2-Fe; Thu, 07 Feb 2008 17:43:51 -0500 Original-Received: from hidalgo.iro.umontreal.ca (hidalgo.iro.umontreal.ca [132.204.27.50]) by mercure.iro.umontreal.ca (Postfix) with ESMTP id D124A2CF333; Thu, 7 Feb 2008 17:43:50 -0500 (EST) Original-Received: from faina.iro.umontreal.ca (faina.iro.umontreal.ca [132.204.26.177]) by hidalgo.iro.umontreal.ca (Postfix) with ESMTP id 1E83C3FE0; Thu, 7 Feb 2008 17:43:40 -0500 (EST) Original-Received: by faina.iro.umontreal.ca (Postfix, from userid 20848) id 086E36CAA0; Thu, 7 Feb 2008 17:43:39 -0500 (EST) In-Reply-To: <8e24944a0802071239r1cdc8affq7875fea0b9876560@mail.gmail.com> (David De La Harpe Golden's message of "Thu, 7 Feb 2008 20:39:22 +0000") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/23.0.50 (gnu/linux) X-DIRO-MailScanner-Information: Please contact the ISP for more information X-DIRO-MailScanner: Found to be clean X-DIRO-MailScanner-SpamCheck: n'est pas un polluriel, SpamAssassin (score=-2.82, requis 5, autolearn=not spam, ALL_TRUSTED -2.82) X-DIRO-MailScanner-From: monnier@iro.umontreal.ca X-detected-kernel: by monty-python.gnu.org: Linux 2.6 (newer, 3) X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:88471 Archived-At: >> For the last one, I suggest we >> use `interprogram-insert-function', tho I'm not completely sure >> I understand what it's intended to do. > It is intended to be for inserting texts retrieved from the window > system which are to be inserted without side-effecting the kill ring. > It is only used in the very specific case of (the patched) > mouse-yank-at-click with mouse-yank-at-click set to lightins rather > than yank. I understand thatm but I don't see a need for a separate interprogram-insert-function. I only see the need for some more boolean custom vars. >> From what I can tell, there are 4 kinds of selections: >> - C-SPC + mouse movement. I.e. select-only. ^^^^^ cursor Duh! >> - same plus C-w. >> - selection with the mouse. >> - one of the above plus "copy" from the menu. >> >> No 4 should always use the CLIPBOARD. >> No 3 should always use the PRIMARY (plus optionally CLIPBOARD) >> No 2 may optionally use PRIMARY (plus optionally CLIPBOARD) >> No 1 should use neither or at most PRIMARY. >> >> I believe that currently No 2 and No 3 are always handled in the same >> way, and I don't know if we want to bother separating them. > I'm not 100% sure what you meant by "selection with mouse" there : > No 1 covers "selection [only] with mouse". Yes, sorry, the "mouse movement" above was a typo. >> You're suggesting to allow PRIMARY for No 1 via `select-active-regions'? >> Oh, I see it already exists, so you're just trying to fix it so it >> works more reliably, is that right? > Yes (and making it not x-specific.). Yes, that's good. >> Why do you need `interprogram-highlight-function'? Can't you just use >> >> (let ((x-select-enable-clipboard nil)) >> (kill-ring-save beg end)) >> >> like clipboard-kill-ring-save does? > No, that would affect the kill ring! Then add x-select-enable-kill-ring. Big deal. >> No 2 should use the CLIPBOARD only if x-select-enable-clipboard is set. > ... but *not* add to kill ring! (unless the user wants it to) As mentioned, that is a separate concern. > No 1 IS a yank, (which via current-kill/interprogram-paste-function) > may pull in CLIPBOARD. The user may prefer C-y to never mess with CLIPBOARD or PRIMARY (and similarly she may want C-k not to mess with either). Stefan