Hello,
When I have formatoptions=t, it makes comment lines wrap when they shouldn't,
and it also ignores whatever comment leader is defined in 'comments'. To
reproduce:
:set formatoptions=roc
:set comments=b:%
:set textwidth=30
% type these lines of text
% as one line, and notice
% how Vim automatically
% wraps the lines and adds
% '%' at the start of each
% line.
Now remove 'c' from formatoptions and add 't'.
:set formatoptions-=c
:set formatoptions+=t
>From the help pages (:help fo-table)
t Auto-wrap text using textwidth (does not apply to comments)
c Auto-wrap comments using textwidth, inserting the current comment
leader automatically.
With 'formatoptions' now set to 'rot', Vim should wrap normal text, but not
comments.
% but when you type this
next set of comments, Vim
will wrap them (when it
shouldn't, because they are
comments), and it will also
miss out the comment leader.
I hope it's clear what's going on here. I'm running Vim 7 with patches 1-101.
regards,
Peter
____________________________________________________
Do you Yahoo!?
Cars: Buy and sell, news, reviews, videos and more
http://yahoo.drive.com.au/