A ha, for some reason the verbose thing didn't kick in earlier. Just ran it
again and it said:

  textwidth=78
        Last set from ~/.vimrc

The plot thickens! Looking in my .vimrc file, it says this:

" In text files, always limit the width of text to 78 characters
  autocmd BufRead *.txt set tw=78


I normally edit code in vim, so that's probably why I haven't seen the 78
character tw kick in (was editing a text file this time).

Guess my cat has been exonerated!

Thanks much,
-Sid



On Sun, Jun 5, 2011 at 4:12 PM, Siddhartha Kasivajhula
<[email protected]>wrote:

> Thanks guys, the output from :verbose set tw? wm? was
>
> textwidth=78
> wrapmargin=0
>
> And fo is set to
> formatoptions=tcql
>
> help fo-table indicates that the 'l' is supposed to prevent long lines from
> being cut off past textwidth. But in any case,
> setting tw=0 did the trick!
>
> -Sid
>
>
> On Sun, Jun 5, 2011 at 1:46 PM, Gary Johnson <[email protected]> wrote:
>
>> On 2011-06-05, Siddhartha Kasivajhula wrote:
>> > Noble Vim sages,
>> > Lately, vim has started creating a newline as soon as I hit 72 columns
>> in a
>> > line. I don't recall this happening before so it's quite possibly a
>> result of
>> > my cat's fondness for sitting on my keyboard. Any idea how I can prevent
>> this
>> > from happening?
>>
>> This column is set by the 'textwidth' ('tw') and 'wrapmargin' ('wm')
>> options.  Execute
>>
>>    :verbose set tw? wm?
>>
>> [Tony, I didn't drop the "set" this time!] to see their current
>> values and where they were last set.
>>
>> Depending on the type of text you are entering, this behavior can
>> also be influenced by the 'formatoptions' ('fo') option,
>> particularly the 't' and 'c' flags.  As with 'tw' and 'wm',
>>
>>    :verbose set fo?
>>
>> will show you the current value and where it was last set.  The
>> default value for Vim is "tcq".  For more details, see
>>
>>    :help 'tw'
>>    :help 'wm'
>>    :help 'fo'
>>    :help fo-table
>>
>> and for an overview, see
>>
>>    :help ins-textwidth
>>    :help 25.1
>>
>> Regards,
>> Gary
>>
>> --
>> You received this message from the "vim_use" maillist.
>> Do not top-post! Type your reply below the text you are replying to.
>> For more information, visit http://www.vim.org/maillist.php
>>
>
>

-- 
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php

Reply via email to