From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: kovvalsky Newsgroups: gmane.emacs.help Subject: Re: Specify file encoding when storing a plain text or a source code Date: Tue, 1 Feb 2011 02:09:48 -0800 (PST) Message-ID: <30814900.post@talk.nabble.com> References: <30811936.post@talk.nabble.com> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Trace: dough.gmane.org 1296555171 8738 80.91.229.12 (1 Feb 2011 10:12:51 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Tue, 1 Feb 2011 10:12:51 +0000 (UTC) To: Help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Tue Feb 01 11:12:46 2011 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.69) (envelope-from ) id 1PkDE6-0002Zk-68 for geh-help-gnu-emacs@m.gmane.org; Tue, 01 Feb 2011 11:12:46 +0100 Original-Received: from localhost ([127.0.0.1]:42680 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1PkDE5-0000ez-DZ for geh-help-gnu-emacs@m.gmane.org; Tue, 01 Feb 2011 05:12:45 -0500 Original-Received: from [140.186.70.92] (port=33338 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1PkDBJ-0000TJ-Pw for Help-gnu-emacs@gnu.org; Tue, 01 Feb 2011 05:09:55 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1PkDBG-0003B4-36 for Help-gnu-emacs@gnu.org; Tue, 01 Feb 2011 05:09:53 -0500 Original-Received: from sam.nabble.com ([216.139.236.26]:40072) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1PkDBF-0003Ak-Tc for Help-gnu-emacs@gnu.org; Tue, 01 Feb 2011 05:09:50 -0500 Original-Received: from isper.nabble.com ([192.168.236.156]) by sam.nabble.com with esmtp (Exim 4.69) (envelope-from ) id 1PkDBE-0007Mz-Rf for Help-gnu-emacs@gnu.org; Tue, 01 Feb 2011 02:09:48 -0800 In-Reply-To: X-Nabble-From: fibo.kowalsky@gmail.com X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 2) X-Received-From: 216.139.236.26 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:78905 Archived-At: I am completely beginner in emacs and we have this question to answer (it's odd yes) and i am not sure if I understand you answer, but thanks. I think the answer to my question is: C-x h #select all text C-x RET c RET #set encoding for next command M-x sort-lines #sort the text using the specified encoding Deniz Dogan-3 wrote: > > You can use "C-x RET f" (set-buffer-file-coding-system). > > If CODING-SYSTEM leaves the text conversion unspecified, or if it leaves > the end-of-line conversion unspecified, FORCE controls what to do. > If FORCE is nil, get the unspecified aspect (or aspects) from the buffer's > previous `buffer-file-coding-system' value (if it is specified there). > Otherwise, leave it unspecified. > > This marks the buffer modified so that the succeeding C-t C-s > surely saves the buffer with CODING-SYSTEM. From a program, if you > don't want to mark the buffer modified, specify t for NOMODIFY. > If you know exactly what coding system you want to use, > just set the variable `buffer-file-coding-system' directly. > > -- > Deniz Dogan > -- View this message in context: http://old.nabble.com/Specify-file-encoding-when-storing-a-plain-text-or-a-source-code-tp30811936p30814900.html Sent from the Emacs - Help mailing list archive at Nabble.com.