From mboxrd@z Thu Jan 1 00:00:00 1970 Received: by 10.52.169.74 with SMTP id ac10cs73117vdc; Thu, 17 Mar 2011 10:35:45 -0700 (PDT) Received: by 10.43.57.65 with SMTP id wf1mr68912icb.145.1300383345463; Thu, 17 Mar 2011 10:35:45 -0700 (PDT) Return-Path: Received: from rubyforge.org (rubyforge.org [205.234.109.19]) by mx.google.com with ESMTP id he41si3234490ibb.129.2011.03.17.10.35.44; Thu, 17 Mar 2011 10:35:44 -0700 (PDT) Received-SPF: pass (google.com: domain of sup-talk-bounces@rubyforge.org designates 205.234.109.19 as permitted sender) client-ip=205.234.109.19; Authentication-Results: mx.google.com; spf=pass (google.com: domain of sup-talk-bounces@rubyforge.org designates 205.234.109.19 as permitted sender) smtp.mail=sup-talk-bounces@rubyforge.org Received: from rubyforge.org (rubyforge.org [127.0.0.1]) by rubyforge.org (Postfix) with ESMTP id F27FA3C8045; Thu, 17 Mar 2011 13:35:43 -0400 (EDT) X-Greylist: delayed 605 seconds by postgrey-1.31 at rubyforge.org; Thu, 17 Mar 2011 12:34:07 EDT Received: from pancho.name (pancho.name [92.48.73.7]) by rubyforge.org (Postfix) with ESMTP id CD7B81858378 for ; Thu, 17 Mar 2011 12:34:07 -0400 (EDT) Received: from worf.pancho.name (82.158.66.28.dyn.user.ono.com [82.158.66.28]) by pancho.name (Postfix) with ESMTPA id AEAA460605; Thu, 17 Mar 2011 17:22:34 +0100 (CET) Received: by worf.pancho.name (Postfix, from userid 1000) id 98110263B4; Thu, 17 Mar 2011 17:23:58 +0100 (CET) Date: Thu, 17 Mar 2011 17:23:58 +0100 From: pancho horrillo To: Philippe LeCavalier Message-ID: <20110317162358.GA15534@pancho.name> Mail-Followup-To: Philippe LeCavalier , sup-talk References: <1300371571-sup-2777@plc.intranet.plecavalier.com> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: <1300371571-sup-2777@plc.intranet.plecavalier.com> User-Agent: Mutt/1.5.20 (2009-06-14) Cc: sup-talk Subject: Re: [sup-talk] vim text wrapping X-BeenThere: sup-talk@rubyforge.org X-Mailman-Version: 2.1.12 Precedence: list List-Id: User & developer discussion of Sup List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: sup-talk-bounces@rubyforge.org Errors-To: sup-talk-bounces@rubyforge.org On Thu, Mar 17, 2011 at 10:26:51AM -0400, Philippe LeCavalier wrote: > Hi All. > Hi there. > This is more of a vim question than it is a sup one but I'm not a > member of the vim list so I thought I'd ask you guys first. > > Since I don't write very well I always end up making changes while > re-reading myself. When I edit a line Vim doesn't wrap anymore like it > did when I first typed the text. So all the lines I've edited aren't > wrapped like the others. It can make reading my mail challenging at > times. > For the sake of others: If you want Vim to fold lines as you newly write them, just run :set textwidth=72 # set tw=72 for short If you want Vim to reformat the text when you edit it, just run :set formatoptions+=a or add it to your vimrc, etc. This is explained in Vim help, :help textwidth :help ins-textwidth :help formatoptions :help fo-table If you don't want this to happen all the time (as I don't), you can use the gq operator discretionally. gq , e.g.: gq} reflow till the end of the paragraph gqap reflow the whole paragraph > Perhaps I'm misunderstanding how to properly edit text in vim? > A minor tweak and you are done. Hope that it helps. Happy hacking, -- pancho horrillo To be conscious that you are ignorant is a great step to knowledge. Benjamin Disraeli _______________________________________________ sup-talk mailing list sup-talk@rubyforge.org http://rubyforge.org/mailman/listinfo/sup-talk