dfox wrote: > > On Tue, 2002-04-09 at 04:46, J. Craig Woods wrote: > > Ok, I've got to ask here about something that's been bugging me cause I > can't make it happen yet. I'm trying to set the margin in Vi(m) so that > the text will wrap with words (at about 70 chars across or so) instead > of just on a per-letter basis. > > I would first try: > > <esc>se wm=6 > > That's for setting the wrap margin. I should point out that it should be set > to the number of characters from the *right* margin. I.e., if you set wm to > 72, you'll end up with most of your words > on a new > line > like this :) > > If you type a word that would not fit at the wrap margin, vi will > automatically move it to the next line. > > If you want to do more complicated formatting within vi, you can use the > Q command (at least in vim). Use the Q followed by a movement command, such as > } for paragraph, and voila, your paragraph will be formatted for the current > wrap margin setting. It won't justify though, but it's good for things like > when people can't use their editors and their text is turned into one long > line etc. More complicated things can be done if you pipe your text through > to 'fmt' which can even justify the text. > > IIRC that was the 'classic' way to do it before vim came along. >
These are good instructions. The only thing you did wrong was to quote me in your posting. I did not ask that question but, if memory serves me well (not something you can take lightly at my age), I seem to recall that LX was looking for this info. There you go, LX J. Craig Woods UNIX/NT Network/System Administration -Art is the illusion of spontaneity-
Want to buy your Pack or Services from MandrakeSoft? Go to http://www.mandrakestore.com