Path: csiph.com!fu-berlin.de!uni-berlin.de!not-for-mail From: Michael Torrie Newsgroups: comp.lang.python Subject: Re: best text editor for programming Python on a Mac Date: Sun, 19 Jun 2016 13:04:49 -0600 Lines: 25 Message-ID: References: <242caeee-f489-4956-8261-680fe49f402d@googlegroups.com> <96f065cb-54b5-4b68-9fab-2029d0785367@gmail.com> Mime-Version: 1.0 Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: 7bit X-Trace: news.uni-berlin.de q2r0iKOHZLsgvNbFagk6TA9xr0LHm6D0O4B0N9rNHHcA== Return-Path: X-Original-To: python-list@python.org Delivered-To: python-list@mail.python.org X-Spam-Status: OK 0.001 X-Spam-Evidence: '*H*': 1.00; '*S*': 0.00; 'subject:text': 0.04; 'subject:Python': 0.05; 'memory.': 0.05; 'subject:editor': 0.07; 'utf-8': 0.07; 'variable,': 0.07; 'encode': 0.09; 'instance.': 0.09; 'suggest': 0.15; 'encoding': 0.15; '*this*': 0.16; 'from:addr:torriem': 0.16; 'from:name:michael torrie': 0.16; 'peek': 0.16; 'received:io': 0.16; 'received:psf.io': 0.16; 'subject:Mac': 0.16; 'subject:programming': 0.16; 'wrote:': 0.16; 'char': 0.18; 'refers': 0.18; 'header:In-Reply-To:1': 0.24; 'header:User-Agent:1': 0.26; "doesn't": 0.26; 'handling': 0.27; 'ret': 0.29; 'that.': 0.30; "i'd": 0.31; 'another': 0.32; 'surprised': 0.33; 'though.': 0.33; 'message-id:@gmail.com': 0.34; 'changing': 0.34; 'file': 0.34; 'but': 0.36; 'should': 0.36; 'to:addr:python-list': 0.36; 'pm,': 0.36; 'subject:: ': 0.37; 'received:org': 0.37; 'christian': 0.38; 'sure': 0.39; 'received:192': 0.39; 'to:addr:python.org': 0.40; 'charset:windows-1252': 0.62; 'dont': 0.64; 'saving': 0.70; 'rendering': 0.76; 'gollwitzer': 0.84; 'useful!': 0.84 X-Virus-Scanned: amavisd-new at torriefamily.org User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101 Thunderbird/45.1.1 In-Reply-To: X-BeenThere: python-list@python.org X-Mailman-Version: 2.1.22 Precedence: list List-Id: General discussion list for the Python programming language List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-Mailman-Original-Message-ID: <96f065cb-54b5-4b68-9fab-2029d0785367@gmail.com> X-Mailman-Original-References: <242caeee-f489-4956-8261-680fe49f402d@googlegroups.com> Xref: csiph.com comp.lang.python:110154 On 06/19/2016 12:06 PM, Christian Gollwitzer wrote: > Am 19.06.16 um 18:20 schrieb Rustom Mody: >> I gave an emacs solution to the issue not because I find editor-wars engaging >> but because I dont know how to do *this* with vi. >> I'd be surprised if vi actually cant do these: >> 1. Look under the unicode-hood to peek at what a char is -- C-u C-x = in emacs >> 2. Change file encoding -- C-x RET f in emacs >> >> Please do suggest vi-ways of handling this -- that would be useful! >> > Changing the encoding is > > :set fileencoding=utf-8 > > for instance. This will recode the buffer to utf-8, the rendering should > stay the same. Saving the file would now write a bytestream which has an > utf-8 interpretation in accordance to the display. Actually it doesn't re-encode the buffer iteslf. Upon saving it will try to encode the buffer to that. There's another variable, just "encoding" that I think refers the buffer in memory. Not sure about that though.