From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.help Subject: Re: Problem with clipboard Date: Mon, 05 Mar 2007 06:31:49 +0200 Message-ID: References: <124486459.20070305093410@nkmk.ru> NNTP-Posting-Host: lo.gmane.org X-Trace: sea.gmane.org 1173069128 28597 80.91.229.12 (5 Mar 2007 04:32:08 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Mon, 5 Mar 2007 04:32:08 +0000 (UTC) To: help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Mon Mar 05 05:32:02 2007 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.50) id 1HO4rg-0003GW-LY for geh-help-gnu-emacs@m.gmane.org; Mon, 05 Mar 2007 05:32:00 +0100 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1HO4rb-0004vD-5W for geh-help-gnu-emacs@m.gmane.org; Sun, 04 Mar 2007 23:31:55 -0500 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1HO4rP-0004v8-Th for help-gnu-emacs@gnu.org; Sun, 04 Mar 2007 23:31:43 -0500 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1HO4rL-0004uw-Vm for help-gnu-emacs@gnu.org; Sun, 04 Mar 2007 23:31:42 -0500 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1HO4rL-0004us-R0 for help-gnu-emacs@gnu.org; Sun, 04 Mar 2007 23:31:39 -0500 Original-Received: from romy.inter.net.il ([213.8.233.24]) by monty-python.gnu.org with esmtp (Exim 4.52) id 1HO4rL-0006Ov-7f for help-gnu-emacs@gnu.org; Sun, 04 Mar 2007 23:31:39 -0500 Original-Received: from HOME-C4E4A596F7 (IGLD-84-228-136-115.inter.net.il [84.228.136.115]) by romy.inter.net.il (MOS 3.7.3-GA) with ESMTP id HHM94689 (AUTH halo1); Mon, 5 Mar 2007 06:31:38 +0200 (IST) In-reply-to: <124486459.20070305093410@nkmk.ru> (neverov_dg@nkmk.ru) X-detected-kernel: FreeBSD 4.7-5.2 (or MacOS X 10.2-10.4) (2) X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:41666 Archived-At: > Date: Mon, 5 Mar 2007 09:34:10 +0700 > From: neverov_dg@nkmk.ru > > I'm running emacs on WinXP and have problems with inserting text from > clipboard. When I select text in MS Word or Firefox and paste it into > emacs it inserts symbols in latin-1 encoding, but I want him to insert > text in windows-1251-dos encoding. > > When I use: > > M-x set-next-selection-coding-system RET windows-1251-dos RET > > and paste text all work fine, but just one time. I try to use > > M-x set-selection-coding-system RET windows-1251-dos RET > > but it doesn't help, text is inserted in latin-1 encoding. > > Encoding-specific section in my .emacs: > > (set-language-environment "Russian") > (define-coding-system-alias 'windows-1251 'cp1251) > (set-buffer-file-coding-system 'cp1251-dos) > (set-default-coding-systems 'cp1251-dos) > (set-terminal-coding-system 'windows-1251-dos) > (set-selection-coding-system 'cp1251-dos) > (prefer-coding-system 'cp1251-dos) What happens if you try this in "emacs -Q"? (On Windows XP, it's almost never the right thing to force Emacs into some specific encoding when working with the clipboard.)