From unknown Sat Jun 21 03:29:26 2025 X-Loop: help-debbugs@gnu.org Subject: bug#6720: battle with x-clipboard vs. Chinese Resent-From: jidanni@jidanni.org Original-Sender: debbugs-submit-bounces@debbugs.gnu.org Resent-To: owner@debbugs.gnu.org Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sat, 24 Jul 2010 17:37:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 6720 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: To: 6720@debbugs.gnu.org X-Debbugs-Original-To: bug-gnu-emacs@gnu.org Received: via spool by submit@debbugs.gnu.org id=B.127999299131245 (code B ref -1); Sat, 24 Jul 2010 17:37:02 +0000 Received: (at submit) by debbugs.gnu.org; 24 Jul 2010 17:36:31 +0000 Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1OcieE-00087u-Nq for submit@debbugs.gnu.org; Sat, 24 Jul 2010 13:36:30 -0400 Received: from mail.gnu.org ([199.232.76.166] helo=mx10.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1OcieC-00087n-GS for submit@debbugs.gnu.org; Sat, 24 Jul 2010 13:36:29 -0400 Received: from lists.gnu.org ([199.232.76.165]:41247) by monty-python.gnu.org with esmtps (TLS-1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1OcieD-0008FB-Bj for submit@debbugs.gnu.org; Sat, 24 Jul 2010 13:36:29 -0400 Received: from [140.186.70.92] (port=60421 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1OcieA-0007OO-4D for bug-gnu-emacs@gnu.org; Sat, 24 Jul 2010 13:36:28 -0400 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_NONE, T_DKIM_INVALID autolearn=unavailable version=3.3.1 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.69) (envelope-from ) id 1Ocie6-0006YX-Nn for bug-gnu-emacs@gnu.org; Sat, 24 Jul 2010 13:36:26 -0400 Received: from caiajhbdcaid.dreamhost.com ([208.97.132.83]:56109 helo=homiemail-a37.g.dreamhost.com) by eggs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1Ocie6-0006YJ-Ib for bug-gnu-emacs@gnu.org; Sat, 24 Jul 2010 13:36:22 -0400 Received: from homiemail-a37.g.dreamhost.com (localhost [127.0.0.1]) by homiemail-a37.g.dreamhost.com (Postfix) with ESMTP id 644651D006B for ; Sat, 24 Jul 2010 10:36:21 -0700 (PDT) DomainKey-Signature: a=rsa-sha1; c=nofws; d=jidanni.org; h=from:to:subject :date:message-id:mime-version:content-type; q=dns; s=jidanni.org ; b=Q2eaa9GQhGPRKpUviOm2Ddh0kvWr/3Tu7yY8mrx0bx4M5NvHwRT0Z84++sTm /g5WZKEjlFDj0uQHwCZMTY1cnCC3UVIO5S1eyutwa/PTSRiU1QRAYFMYXZ+7kU2c CZ7ZjjJno4oK238i6oxPKadPun/yQNVngkpcZxZGIvQaYRA= DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=jidanni.org; h=from:to :subject:date:message-id:mime-version:content-type; s= jidanni.org; bh=vJdhDxlqgNar0QXAWAag0xt1x+I=; b=EsHLMm6e90y0UJQr I9pTW5SfjrEDAB9YLSbbluFjB3hMkK/axwrJGkk1ClVPcTVXyB4kEW70tg0gdUpq cG90joiWWCigTehKqMEJS+EcOPc2lzHXKqvY6pZVkt9lSPw+d3ccIPEyuwl7zDJN Hz0E29kle30N+TQz6sR91EOLle0= Received: from jidanni.org (125-230-46-77.dynamic.hinet.net [125.230.46.77]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (No client certificate requested) (Authenticated sender: jidanni@jidanni.org) by homiemail-a37.g.dreamhost.com (Postfix) with ESMTPSA id 141FA1D0069 for ; Sat, 24 Jul 2010 10:36:21 -0700 (PDT) From: jidanni@jidanni.org Date: Sun, 25 Jul 2010 01:36:17 +0800 Message-ID: <87y6d0kcj2.fsf@jidanni.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 3) X-detected-operating-system: by monty-python.gnu.org: GNU/Linux 2.6, seldom 2.4 (older, 4) X-Spam-Score: -5.8 (-----) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -5.8 (-----) I just updated to emacs-snapshot: Installed: 1:20100724-1 and am having to battle getting Chinese in correctly from the X clipboard. It is turning into ###, ???, \u{5432}, etc. etc. From unknown Sat Jun 21 03:29:26 2025 X-Loop: help-debbugs@gnu.org Subject: bug#6720: battle with x-clipboard vs. Chinese Resent-From: David De La Harpe Golden Original-Sender: debbugs-submit-bounces@debbugs.gnu.org Resent-To: owner@debbugs.gnu.org Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sat, 24 Jul 2010 19:09:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 6720 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: To: jidanni@jidanni.org Cc: 6720@debbugs.gnu.org Received: via spool by 6720-submit@debbugs.gnu.org id=B6720.12799984891373 (code B ref 6720); Sat, 24 Jul 2010 19:09:02 +0000 Received: (at 6720) by debbugs.gnu.org; 24 Jul 2010 19:08:09 +0000 Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1Ock4v-0000LE-99 for submit@debbugs.gnu.org; Sat, 24 Jul 2010 15:08:09 -0400 Received: from harpegolden.net ([65.99.215.13]) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1Ock4u-0000L8-Go for 6720@debbugs.gnu.org; Sat, 24 Jul 2010 15:08:08 -0400 Received: from [87.198.55.209] (87-198-55-209.ptr.magnet.ie [87.198.55.209]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client CN "David De La Harpe Golden", Issuer "David De La Harpe Golden Personal CA rev 3" (verified OK)) by harpegolden.net (Postfix) with ESMTPSA id 40773683FF; Sat, 24 Jul 2010 20:08:06 +0100 (IST) Message-ID: <4C4B3A17.2070007@harpegolden.net> Date: Sat, 24 Jul 2010 20:08:07 +0100 From: David De La Harpe Golden User-Agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.1.10) Gecko/20100620 Icedove/3.0.5 MIME-Version: 1.0 References: <87y6d0kcj2.fsf@jidanni.org> In-Reply-To: <87y6d0kcj2.fsf@jidanni.org> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Spam-Score: -3.0 (---) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -2.9 (--) On 24/07/10 18:36, jidanni@jidanni.org wrote: > I just updated to > emacs-snapshot: > Installed: 1:20100724-1 > and am having to battle getting Chinese in correctly from the X > clipboard. > It is turning into ###, ???, \u{5432}, etc. etc. > Do you see this when using middle mouse button or C-y or both? This sounds like it might be bug #6635, an encoding handling problem in mouse-yank-primary, which could affect people more due to recent changes: http://debbugs.gnu.org/cgi/bugreport.cgi?bug=6635 From unknown Sat Jun 21 03:29:26 2025 X-Loop: help-debbugs@gnu.org Subject: bug#6720: battle with x-clipboard vs. Chinese In-Reply-To: <87y6d0kcj2.fsf@jidanni.org> Resent-From: jidanni@jidanni.org Original-Sender: debbugs-submit-bounces@debbugs.gnu.org Resent-To: owner@debbugs.gnu.org Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sun, 25 Jul 2010 01:10:04 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 6720 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: To: david@harpegolden.net Cc: 6720@debbugs.gnu.org, 6635@debbugs.gnu.org Received: via spool by 6720-submit@debbugs.gnu.org id=B6720.128002014511592 (code B ref 6720); Sun, 25 Jul 2010 01:10:04 +0000 Received: (at 6720) by debbugs.gnu.org; 25 Jul 2010 01:09:05 +0000 Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1OcpiB-00030v-MJ for submit@debbugs.gnu.org; Sat, 24 Jul 2010 21:09:04 -0400 Received: from caiajhbdccah.dreamhost.com ([208.97.132.207] helo=homiemail-a1.g.dreamhost.com) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1Ocpi8-00030Q-Ie; Sat, 24 Jul 2010 21:09:01 -0400 Received: from homiemail-a1.g.dreamhost.com (localhost [127.0.0.1]) by homiemail-a1.g.dreamhost.com (Postfix) with ESMTP id 3920734806C; Sat, 24 Jul 2010 18:09:01 -0700 (PDT) DomainKey-Signature: a=rsa-sha1; c=nofws; d=jidanni.org; h=from:to:cc:subject :references:date:message-id:mime-version:content-type; q=dns; s= jidanni.org; b=D94qPWHqxGLA8yfdLvZdDLWoQypyhtAAHQ/ckmn1KcshQ3NXv OAw99iyKnDckOzpTKZXKw4dG0KlJ1P1FUCAlvSG4pPE/uL1NAencoR5q/wfumpHU c1ERWc3frF0f4a3L0/V3njfmjRt6jyNzSRU40Ogzyv0M/YR+3RkxF/ASwU= DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=jidanni.org; h=from:to:cc :subject:references:date:message-id:mime-version:content-type; s=jidanni.org; bh=UgEX6UPB+Fu3VKinJ/ZQp/v34+0=; b=oLetOR/ya/7A/ So6XhT6cG6wv8/oE/1QlKnhVlHtgETIKlj5Hhc0e/D2m8i2KoGxPM7uM9GRS/qkK Z5Uw9LIKSuLl84V6AmQfdyWxQHpFaflMCsYYNOXhmTy3ujp0ZHNXukfWNET8aN9x ZgrCpWZfApmdEs1LDkaqoqKzyMngy0= Received: from jidanni.org (218-163-2-116.dynamic.hinet.net [218.163.2.116]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (No client certificate requested) (Authenticated sender: jidanni@jidanni.org) by homiemail-a1.g.dreamhost.com (Postfix) with ESMTPSA id 8F9B834806B; Sat, 24 Jul 2010 18:09:00 -0700 (PDT) From: jidanni@jidanni.org References: <4C4B3A17.2070007@harpegolden.net> Date: Sun, 25 Jul 2010 09:08:58 +0800 Message-ID: <87lj904bbp.fsf_-_@jidanni.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Spam-Score: -2.5 (--) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -2.5 (--) >>>>> "DDLHG" == David De La Harpe Golden writes: DDLHG> On 24/07/10 18:36, jidanni@jidanni.org wrote: >> I just updated to >> emacs-snapshot: >> Installed: 1:20100724-1 >> and am having to battle getting Chinese in correctly from the X >> clipboard. >> It is turning into ###, ???, \u{5432}, etc. etc. >> DDLHG> Do you see this when using middle mouse button or C-y or both? All I know is starting with $ apt-cache policy emacs-snapshot emacs-snapshot: Installed: 1:20100724-1 Candidate: 1:20100724-1 Version table: *** 1:20100724-1 0 500 http://emacs.orebokech.com sid/main Packages 100 /var/lib/dpkg/status I am having two kinds of pain: 1. Having to write things into /tmp/files to be able to read them into emacs correctly as xclip now can't if I want Chinese intact. I try every button and end up having to resort to /tmp. 2. Even more disconnection between C-y, Shift-insert, the middle mouse button, between emacs and the outside world. I wish I could make them all connected. DDLHG> This sounds like it might be bug #6635, an encoding handling problem DDLHG> in mouse-yank-primary, which could affect people more due to recent DDLHG> changes: DDLHG> http://debbugs.gnu.org/cgi/bugreport.cgi?bug=6635 From unknown Sat Jun 21 03:29:26 2025 X-Loop: help-debbugs@gnu.org Subject: bug#6720: battle with x-clipboard vs. Chinese In-Reply-To: <87y6d0kcj2.fsf@jidanni.org> Resent-From: jidanni@jidanni.org Original-Sender: debbugs-submit-bounces@debbugs.gnu.org Resent-To: owner@debbugs.gnu.org Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sun, 25 Jul 2010 01:29:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 6720 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: To: david@harpegolden.net Cc: 6720@debbugs.gnu.org, 6635@debbugs.gnu.org Received: via spool by 6720-submit@debbugs.gnu.org id=B6720.128002130712082 (code B ref 6720); Sun, 25 Jul 2010 01:29:02 +0000 Received: (at 6720) by debbugs.gnu.org; 25 Jul 2010 01:28:27 +0000 Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1Ocq0w-00038p-83 for submit@debbugs.gnu.org; Sat, 24 Jul 2010 21:28:26 -0400 Received: from mailbigip.dreamhost.com ([208.97.132.5] helo=homiemail-a5.g.dreamhost.com) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1Ocq0s-00038b-WA; Sat, 24 Jul 2010 21:28:23 -0400 Received: from homiemail-a5.g.dreamhost.com (localhost [127.0.0.1]) by homiemail-a5.g.dreamhost.com (Postfix) with ESMTP id C158870406A; Sat, 24 Jul 2010 18:28:23 -0700 (PDT) DomainKey-Signature: a=rsa-sha1; c=nofws; d=jidanni.org; h=from:to:cc:subject :references:date:message-id:mime-version:content-type; q=dns; s= jidanni.org; b=LV+Dx10v1etFgBYRpScbvayGxRK2BmYIN+a1TZ2St/YKqW+oF uDXx8R2Dq1XfcfLN2RSU/arFmEJ2k1HGkl/qYnKOkIK3zmNTIir8PsxOCM66eJWZ rBr2RzK8xZk4ex7K3j5/9EWSHtWFVzaKN2gwCw/848CZ74z6J5eDv976WY= DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=jidanni.org; h=from:to:cc :subject:references:date:message-id:mime-version:content-type; s=jidanni.org; bh=ackIr1HJ5J8EtMXWMm7AnhdL1Ec=; b=KFPMpCoxehgSb KyG6dY0sZcJnncdK7PiXSTv4ekc4UDqd6ariqPl0PHrN/bf/HI83AnJ9ssL0pvje KodYxxnSKp5gRxBK32dfws7v3sMeD2SpPj85UkgAx2zH7SQ4UvcEPRKbnTM25C64 yykWqcQBbyYCpBJ6typEXiXRnuwt4w= Received: from jidanni.org (218-163-2-116.dynamic.hinet.net [218.163.2.116]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (No client certificate requested) (Authenticated sender: jidanni@jidanni.org) by homiemail-a5.g.dreamhost.com (Postfix) with ESMTPSA id 6932C704063; Sat, 24 Jul 2010 18:28:23 -0700 (PDT) From: jidanni@jidanni.org References: <4C4B3A17.2070007@harpegolden.net> Date: Sun, 25 Jul 2010 09:28:20 +0800 Message-ID: <87fwz84aff.fsf_-_@jidanni.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Spam-Score: -2.5 (--) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -2.5 (--) And the most scary thing of all is now things that I kill with C-k in emacs are not necessarily what Shift-Insert will now paste in xterm. That has never happened before and is causing me to send dangers wads of text of some previous yank to the shell. From unknown Sat Jun 21 03:29:26 2025 X-Loop: help-debbugs@gnu.org Subject: bug#6720: battle with x-clipboard vs. Chinese Resent-From: David De La Harpe Golden Original-Sender: debbugs-submit-bounces@debbugs.gnu.org Resent-To: owner@debbugs.gnu.org Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sun, 25 Jul 2010 03:32:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 6720 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: To: jidanni@jidanni.org Cc: 6720@debbugs.gnu.org Received: via spool by 6720-submit@debbugs.gnu.org id=B6720.128002872115217 (code B ref 6720); Sun, 25 Jul 2010 03:32:02 +0000 Received: (at 6720) by debbugs.gnu.org; 25 Jul 2010 03:32:01 +0000 Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1OcrwW-0003xO-GZ for submit@debbugs.gnu.org; Sat, 24 Jul 2010 23:32:00 -0400 Received: from harpegolden.net ([65.99.215.13]) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1OcrwT-0003xJ-Um for 6720@debbugs.gnu.org; Sat, 24 Jul 2010 23:31:58 -0400 Received: from [87.198.55.209] (87-198-55-209.ptr.magnet.ie [87.198.55.209]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client CN "David De La Harpe Golden", Issuer "David De La Harpe Golden Personal CA rev 3" (verified OK)) by harpegolden.net (Postfix) with ESMTPSA id A098F683FF; Sun, 25 Jul 2010 04:31:56 +0100 (IST) Message-ID: <4C4BB02D.9070805@harpegolden.net> Date: Sun, 25 Jul 2010 04:31:57 +0100 From: David De La Harpe Golden User-Agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.1.10) Gecko/20100620 Icedove/3.0.5 MIME-Version: 1.0 References: <4C4B3A17.2070007@harpegolden.net> <87lj904bbp.fsf_-_@jidanni.org> In-Reply-To: <87lj904bbp.fsf_-_@jidanni.org> Content-Type: multipart/mixed; boundary="------------030208010604000406050604" X-Spam-Score: -3.0 (---) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -3.0 (---) This is a multi-part message in MIME format. --------------030208010604000406050604 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: quoted-printable On 25/07/10 02:08, jidanni@jidanni.org wrote: > All I know is starting with > $ apt-cache policy emacs-snapshot > emacs-snapshot: > Installed: 1:20100724-1 > Candidate: 1:20100724-1 Yes, this appears to be Romain Francoise's snapshot packaging of latest=20 emacs development code. Bug reports for development code are of course=20 helpful and welcome, but please be aware that isn't an official release=20 if you aren't already. > I am having two kinds of pain: > > 1. Having to write things into /tmp/files to be able to read them into > emacs correctly as xclip now can't if I want Chinese intact. > I try every button and end up having to resort to /tmp. Middle mouse button is currently known to be broken due to #6635.,=20 symptoms being strings like "\u4e2d\u6587" or "=C3=A4=C2=B8=C2=AD=C3=A6=C2= =96=C2=87". "M-x load-file" of the attached fix6635.el file in emacs will help=20 there, until a fix goes into the tree. "xclip": you mean the command line tool to manipulate the clipboard? Using xclip to put text on the clipboard for C-y to pull in does seem to=20 work as expected on my system: # shell $ echo "=E4=B8=AD=E6=96=87" | xclip -selection clipboard # in emacs, C-y =E4=B8=AD=E6=96=87 But I don't actually know chinese. Do you have a sample string that is=20 breaking if you do the above? --------------030208010604000406050604 Content-Type: text/x-emacs-lisp; name="fix6635.el" Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename="fix6635.el" ;; Temporary workaround for GNU Emacs bug #6635 on x11 systems. ;; 2010-07-24 DG (defun mouse-yank-primary (click) "Insert the primary selection at the position clicked on. Move point to the end of the inserted text. If `mouse-yank-at-point' is non-nil, insert at point regardless of where you click." (interactive "e") ;; Give temporary modes such as isearch a chance to turn off. (run-hooks 'mouse-leave-buffer-hook) (when select-active-regions ;; Without this, confusing things happen upon e.g. inserting into ;; the middle of an active region. (deactivate-mark)) (or mouse-yank-at-point (mouse-set-point click)) (let ((primary (x-selection-value 'PRIMARY))) (if primary (insert primary) (error "No primary selection")))) (defun mouse-yank-secondary (click) "Insert the secondary selection at the position clicked on. Move point to the end of the inserted text. If `mouse-yank-at-point' is non-nil, insert at point regardless of where you click." (interactive "e") ;; Give temporary modes such as isearch a chance to turn off. (run-hooks 'mouse-leave-buffer-hook) (or mouse-yank-at-point (mouse-set-point click)) (let ((secondary (x-selection-value 'SECONDARY))) (if secondary (insert secondary) (error "No secondary selection")))) --------------030208010604000406050604-- From unknown Sat Jun 21 03:29:26 2025 X-Loop: help-debbugs@gnu.org Subject: bug#6720: battle with x-clipboard vs. Chinese Resent-From: David De La Harpe Golden Original-Sender: debbugs-submit-bounces@debbugs.gnu.org Resent-To: owner@debbugs.gnu.org Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sun, 25 Jul 2010 03:59:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 6720 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: To: jidanni@jidanni.org Cc: 6720@debbugs.gnu.org Received: via spool by 6720-submit@debbugs.gnu.org id=B6720.128003030515854 (code B ref 6720); Sun, 25 Jul 2010 03:59:02 +0000 Received: (at 6720) by debbugs.gnu.org; 25 Jul 2010 03:58:25 +0000 Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1OcsM3-00047e-PQ for submit@debbugs.gnu.org; Sat, 24 Jul 2010 23:58:24 -0400 Received: from harpegolden.net ([65.99.215.13]) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1OcsM2-00047Y-LK for 6720@debbugs.gnu.org; Sat, 24 Jul 2010 23:58:23 -0400 Received: from [87.198.55.209] (87-198-55-209.ptr.magnet.ie [87.198.55.209]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client CN "David De La Harpe Golden", Issuer "David De La Harpe Golden Personal CA rev 3" (verified OK)) by harpegolden.net (Postfix) with ESMTPSA id 4BACE683FF; Sun, 25 Jul 2010 04:58:21 +0100 (IST) Message-ID: <4C4BB65E.5070607@harpegolden.net> Date: Sun, 25 Jul 2010 04:58:22 +0100 From: David De La Harpe Golden User-Agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.1.10) Gecko/20100620 Icedove/3.0.5 MIME-Version: 1.0 References: <4C4B3A17.2070007@harpegolden.net> <87fwz84aff.fsf_-_@jidanni.org> In-Reply-To: <87fwz84aff.fsf_-_@jidanni.org> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Spam-Score: -2.2 (--) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -2.9 (--) On 25/07/10 02:28, jidanni@jidanni.org wrote: > And the most scary thing of all is now things that I kill with C-k in > emacs are not necessarily what Shift-Insert will now paste in xterm. This is a likely separate issue to the encoding problem and expected behaviour. Recently a decision was made to make emacs act more like and play nicer with more recent x11 applications in the area of cut and paste. xterm is ...not a recent application in this respect. Things killed in emacs presently go to the _system clipboard_, but Shift-Insert in xterm inserts the "x11 primary selection" (unless you reconfigure it to use the clipboard). The below does not directly address encoding problems (though step 3 will mask the known encoding bug): *** The new settings are only a revised default, you can still reconfigure emacs to act like it used to. This will mean it won't work well with more recent x11 applications anymore, much like the way xterm doesn't work well with them. Of course, you may not care. 1. M-x customize-group killing Turn off x-select-enable-clipboard Turn on x-select-enable-primary Turn off select-active-regions 2. M-x customize-group mouse Turn on mouse-drag-copy-region 3. Add the following to your ~/.emacs: (global-set-key [mouse-2] 'mouse-yank-at-click) **** various forms of xterm reconfiguration are also possible, though may not prove satisfactory. Using gnome-terminal (or xfce4-terminal or konsole, etc.) might be a better option. Firstly, you can easily make xterm use the clipboard, but then it uses it all the time: Hold down ctrl and middle mouse button on the xterm window. Select menu option "Select to Clipboard". If you like that, making that permanent involves setting X resource XTerm.selectToClipboard as per the xterm manual. http://www.davidsimmons.com/soft/xtermhacks/#copynpaste has another take on the problem with xterm in this area, and offers some more advanced hackery for changing xterm's behaviour. From unknown Sat Jun 21 03:29:26 2025 X-Loop: help-debbugs@gnu.org Subject: bug#6720: battle with x-clipboard vs. Chinese In-Reply-To: <87y6d0kcj2.fsf@jidanni.org> Resent-From: jidanni@jidanni.org Original-Sender: debbugs-submit-bounces@debbugs.gnu.org Resent-To: owner@debbugs.gnu.org Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sun, 25 Jul 2010 17:10:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 6720 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: To: david@harpegolden.net Cc: 6720@debbugs.gnu.org Received: via spool by 6720-submit@debbugs.gnu.org id=B6720.12800777537142 (code B ref 6720); Sun, 25 Jul 2010 17:10:02 +0000 Received: (at 6720) by debbugs.gnu.org; 25 Jul 2010 17:09:13 +0000 Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1Od4hN-0001r9-0G for submit@debbugs.gnu.org; Sun, 25 Jul 2010 13:09:13 -0400 Received: from caiajhbdcbef.dreamhost.com ([208.97.132.145] helo=homiemail-a14.g.dreamhost.com) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1Od4hL-0001qz-58 for 6720@debbugs.gnu.org; Sun, 25 Jul 2010 13:09:11 -0400 Received: from homiemail-a14.g.dreamhost.com (localhost [127.0.0.1]) by homiemail-a14.g.dreamhost.com (Postfix) with ESMTP id CF9F88C076; Sun, 25 Jul 2010 10:09:13 -0700 (PDT) DomainKey-Signature: a=rsa-sha1; c=nofws; d=jidanni.org; h=from:to:cc:subject :references:date:message-id:mime-version:content-type; q=dns; s= jidanni.org; b=I7OylBBaxn1RoIBX4vgs1AzINawYhVdbCWokRgvMgw3hp8NQ3 I+NlQY3aLLKcxikVhAsg489swZEeet60yfBNUAqPcUgPLcKSULcHRDEdSesi1FT/ nFGkGXyt4ggXhuMXz2WKShhJBxIWJEj1qmLw06klH4wFKvHd2vH4lbj/fQ= DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=jidanni.org; h=from:to:cc :subject:references:date:message-id:mime-version:content-type; s=jidanni.org; bh=/crTAtsQZbb1YvnFjyR1sgqUQVM=; b=RN5uN8fDDGhKV YE0XSkyxOxh3GmSehsogHt3dBexOdhZMXCzFNyayg4cpmNKLOU3QBgPqn46+KIde hWNURyV21oYfhjyLQwyGKHcuITPXAcJ8eecDlljMt4N0c/UiSJHMliMvih+9Ufht 76rWax+lknTRIdovyvIhgOSkAwaQ3w= Received: from jidanni.org (218-163-3-160.dynamic.hinet.net [218.163.3.160]) (using TLSv1 with cipher AES256-SHA (256/256 bits)) (No client certificate requested) (Authenticated sender: jidanni@jidanni.org) by homiemail-a14.g.dreamhost.com (Postfix) with ESMTPSA id 2E16A8C063; Sun, 25 Jul 2010 10:09:13 -0700 (PDT) From: jidanni@jidanni.org References: <4C4BB65E.5070607@harpegolden.net> Date: Mon, 26 Jul 2010 01:09:10 +0800 Message-ID: <87vd83jxop.fsf@jidanni.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Spam-Score: -3.3 (---) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -3.3 (---) Cool, using (setq x-select-enable-clipboard nil x-select-enable-primary t select-active-regions nil mouse-drag-copy-region t) (global-set-key [mouse-2] 'mouse-yank-at-click) I didn't even need to load that .el you sent and all seems OK now. Thanks! From debbugs-submit-bounces@debbugs.gnu.org Thu Feb 24 19:13:11 2011 Received: (at control) by debbugs.gnu.org; 25 Feb 2011 00:13:11 +0000 Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1PslJ0-0004Vu-Se for submit@debbugs.gnu.org; Thu, 24 Feb 2011 19:13:11 -0500 Received: from fencepost.gnu.org ([140.186.70.10]) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1PslIy-0004Vh-Hi for control@debbugs.gnu.org; Thu, 24 Feb 2011 19:13:08 -0500 Received: from rgm by fencepost.gnu.org with local (Exim 4.71) (envelope-from ) id 1PslIt-0007oa-AY for control@debbugs.gnu.org; Thu, 24 Feb 2011 19:13:03 -0500 Date: Thu, 24 Feb 2011 19:13:03 -0500 Message-Id: Subject: control message for bug 6720 To: X-Mailer: mail (GNU Mailutils 2.1) From: Glenn Morris X-Spam-Score: -6.3 (------) X-Debbugs-Envelope-To: control X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: debbugs-submit-bounces@debbugs.gnu.org Errors-To: debbugs-submit-bounces@debbugs.gnu.org X-Spam-Score: -6.3 (------) close 6720 stop closed because 'all seems OK now'