help-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Word wrap


From: Chuck Siska
Subject: Re: Word wrap
Date: Tue, 29 Jan 2002 10:38:19 -0800

actually, i wouldn't mind a word-wrap mode which wrapped on 
whitespace and perhaps indented "appropriately".  

that said, this effect can be approximated fairly easily with
the following steps.

1. set the column width to what you'd like (e.g., put the cursor
   at the right of the window and read off the column number from
   the modeline.

2. select the entire buffer as a region.

3. M-x fill-region

to undo this and get back to really-long lines, go through the
same procedure with a large column width (e.g., 999).

if you're bold, you could drop this into an elisp function.
good luck.

-- chuck

Peter S Galbraith wrote:
> 
> >                                                              Every
> > "word processor" that I have ever used does this automatically, but it
> > seems to be completely foreign to emacs.
> 
> Because Emacs isn't a word processor?
> 
> > This is what I need emacs to do, what I am (possibly incorrectly)
> > calling "Word Wrap":
> >
> > Break lines at spaces when the lines exceed the margin amount, without
> > actually inserting carriage returns into the file, so that files can
> > be viewed in a way that pleases most normal human beings without
> > changing the file contents by inserting newline characters.
> 
> When I need to import plain ascii text into MS-Word, I want every
> paragraph on a single line, else MS-Word will keep the line breaks.
> Then I set a fill-column to some very high number, refill and save the
> result.  But that's the _only_ case where I don't want line breaks (and
> only because I have to use that proprietary software).
> 
> If I type email, I use line breaks.
> 
> If I type a document, I use LaTeX and I use line breaks (they won't show
> up in the final layout).
> 
> I fail to see why you want long lines.  I think the problem comes from a
> Unix versus non-Unix history.
> 
>  Unix:  We create a file and expect tools to show it exactly as we
>         created it, line breaks and all.
> 
>  Non-Unix (e.g. Windows): Users type in text using some tool and save it
>         to disk.  They don't care too much about the actual format of
>         that file.  They expect to view the file using some other
>         software and have it look good, albeit formatted differently.
> 
> Two different visions of how to do things.
> 
> Peter
> 
> _______________________________________________
> Help-gnu-emacs mailing list
> address@hidden
> http://mail.gnu.org/mailman/listinfo/help-gnu-emacs

-- 
                                           |\_/\_.-'""``:-._       
What is life without looking for           . . `; -._      )-;-,_`)
the next cute little bug to play with?     v_,-    _  ),(,.\  ``-' 
                                          _.- _.,-_/ /  ((.'       
-- address@hidden  `<}:..     ((,.-'   ((,/



reply via email to

[Prev in Thread] Current Thread [Next in Thread]