From mboxrd@z Thu Jan 1 00:00:00 1970 Path: main.gmane.org!not-for-mail From: ngse@yahoo.com (S. Eng) Newsgroups: gmane.emacs.help Subject: Re: line wrap problem Date: 19 Mar 2003 14:49:00 -0800 Organization: http://groups.google.com/ Sender: help-gnu-emacs-bounces+gnu-help-gnu-emacs=m.gmane.org@gnu.org Message-ID: References: <227a55e9.0303191011.35f66887@posting.google.com> NNTP-Posting-Host: main.gmane.org Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 8bit X-Trace: main.gmane.org 1048114305 24027 80.91.224.249 (19 Mar 2003 22:51:45 GMT) X-Complaints-To: usenet@main.gmane.org NNTP-Posting-Date: Wed, 19 Mar 2003 22:51:45 +0000 (UTC) Original-X-From: help-gnu-emacs-bounces+gnu-help-gnu-emacs=m.gmane.org@gnu.org Wed Mar 19 23:51:43 2003 Return-path: Original-Received: from monty-python.gnu.org ([199.232.76.173]) by main.gmane.org with esmtp (Exim 3.35 #1 (Debian)) id 18vmOr-0006Df-00 for ; Wed, 19 Mar 2003 23:51:09 +0100 Original-Received: from localhost ([127.0.0.1] helo=monty-python.gnu.org) by monty-python.gnu.org with esmtp (Exim 4.10.13) id 18vmOZ-0006wt-04 for gnu-help-gnu-emacs@m.gmane.org; Wed, 19 Mar 2003 17:50:51 -0500 Original-Path: shelby.stanford.edu!newsfeed.stanford.edu!postnews1.google.com!not-for-mail Original-Newsgroups: comp.emacs,gnu.emacs.help Original-Lines: 40 Original-NNTP-Posting-Host: 216.206.47.60 Original-X-Trace: posting.google.com 1048114141 31280 127.0.0.1 (19 Mar 2003 22:49:01 GMT) Original-X-Complaints-To: groups-abuse@google.com Original-NNTP-Posting-Date: 19 Mar 2003 22:49:01 GMT Original-Xref: shelby.stanford.edu comp.emacs:78287 gnu.emacs.help:111234 Original-To: help-gnu-emacs@gnu.org X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1b5 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Help: List-Post: List-Subscribe: , List-Archive: List-Unsubscribe: , Errors-To: help-gnu-emacs-bounces+gnu-help-gnu-emacs=m.gmane.org@gnu.org Xref: main.gmane.org gmane.emacs.help:7734 X-Report-Spam: http://spam.gmane.org/gmane.emacs.help:7734 Thank you all. It works now. ngse pemente@northpark.edu (Eric Pement) wrote in message news:<227a55e9.0303191011.35f66887@posting.google.com>... > ngse@yahoo.com (S. Eng) wrote in message news:... > > Hi > > > > I want to line wrap at column 72. > > I have the following lines in my .emacs > > > > (setq default-major-mode 'text-mode) > > (setq text-mode-hook 'turn-on-auto-fill) > > (setq current-fill-column 72) > > > > It does not work on NTEmacs 21.1.1 running under Win2K > > I'm using GNU Emacs 21.2.1 running under Win2K, same as you. > Here's what I have in my .emacs init file: > > (setq default-major-mode 'text-mode) > (add-hook 'text-mode-hook 'turn-on-auto-fill) > (setq fill-column 71) > > It works for me. Note especially that I use "fill-column" instead > of "current-fill-column" and also the "add-hook" command. Also, > note that when you first run Emacs, you are automatically in the > *Scratch* buffer, which is not a text-mode buffer. To run in text > mode, open or create a new file and you should see the string > "(Text Fill)--L1----ALL----" in the gray status bar. > > If you can see that, then you should be able to type new content, > and see the line wrap automatically after it reaches 75 characters > or so. If you add new content to existing paragraphs, Emacs will > push the new content to the right, but will not automatically > "reflow" or reformat the paragraph. > > To reformat an edited paragraph to your preset margins, you must > type ESC-q (2 successive keystrokes) or ALT-Q (simultaneously) to > reformat the paragraph. Hope this helps.