On 2009-12-04, Jon Trelfa wrote:
> On Fri, Dec 4, 2009 at 10:52 PM, Jon Trelfa <
jtr...@gmail.com> wrote:
>
> PHP's OOP style uses the "arrow" (dash + greater-than symbol) to point to
> methods/properties of objects. *Something* triggers an event whenever the
> > is typed while I'm in insert mode - which makes my screen flash (visual
> bell). Even when I *tried* to disable the visual bell using this in my
> .vimrc:
>
> set vb
> set t_vb=
>
> Any ideas how/why I get a visual bell when I type that particular character
> when editing a PHP file? The flashing is going to fry my brain or give me
> a seizure.
Setting t_vb= in your .vimrc won't do any good if you're using gvim.
See the note under
:help vb
You need to set it either in your .gvimrc or set it using an
autocommand in your .vimrc, like this:
set visualbell t_vb= " Turn off beep and disable visual bell.
au GuiEnter * set t_vb= " Disable visual bell again when GUI starts.
> Now I just need to figure out how to disable showmatch for the <>
> characters in PHP files (there's a matchpairs in the help files,
> but I'm still figuring out what I can do to change it only for PHP
> files)
If you want to change some setting for just PHP files, put the
changes in ~/.vim/after/ftplugin/php.vim for Unix or
~/vimfiles/after/ftplugin/php.vin for Windows. You can remove the
<> pair from 'matchpairs' with
setlocal matchpairs-=<:>
in that file. Alternatively, you could disable 'showmatch'
altogether for PHP files with this:
setlocal noshowmatch
HTH,
Gary