Brian Anderson wrote:
Hello,

I have a simple question about text auto-wrapping. I've looked at the
help files, but haven't been able to find the answer to my question.

I have some files that have been auto-wrapping (inserting a line-break)
when the text gets to the end of the line, then moving down to the next
line.

I don't know that I've changed anything but now on some files, the text
is not breaking. The 'set wrap' is enabled, so the text isn't scrolling
off the screen, but it is not putting in line breaks any more either.

Most of these files are LaTeX (.tex) files, but there is no line break
on new files that have no extensions.

Sometimes I change something, and the wrapping works again, but then
later stops. I make some changes, then it starts working again (for a
while), but then it stops again. I don't know what I'm changing, but I'd
like to find out.

How can I check this, and what settings do I need to make it go back to
automatic line breaks?

some settings are:

:set wrap
:set textwidth=80
:set wrapmargin=0

Thanks.

Brian




Automatic line breaks are added only when you type line longer than 'textwidth', not when reading a file which already contains long lines.

To reformat the current editfile, use

        gggqG

which means:

        gg       go to top
        gq       format the text passed over by the next {motion}
        G        go to bottom

see ":help gq"


Best regards,
Tony.
--
God is not dead!  He's alive and autographing bibles at Cody's

Reply via email to