Wednesday, September 15, 2010

Re: PHP filetype::sql syntax highlighting in strings

On Wed, 15 Sep 2010, Tim Johnson wrote:

> * Benjamin R. Haskell [100914 18:59]:
>>>
>>> How may I turn the feature off?
>>
>> syntax/php.vim has:
>>
>> if exists( "php_sql_query")
>> syn cluster phpAddStrings contains=@sqlTop
>> endif
>>
>> So, if you don't want the keywords highlighted, you shouldn't 'let'
>> php_sql_query to anything. They shouldn't be highlighted by default.
>> So, removing any reference whatsoever to php_sql_query would do the
>> trick, but you can also use:
>>
>> unlet php_sql_query
>>
>> to be absolutely sure. (In the off chance a plugin is setting it --
>> seems unlikely.)
> Thanks for the reply and the tips. Unfortunately that doesn't do it.
> I 'unlet php_sql_query with no change.
>
> Since this is an annoyance and not a problem, when I have time, I
> will first start vim with --no-plugin and also start vim with the
> switch that lists out all files loaded. Unfortunately I don't recall
> which one that is and don't yet see it displayed obviously from 'vim
> --help'.

Not sure what switch there'd be. Can run:

:scriptnames

from within Vim. I s'pose you could specify that on the commandline
via:

vim -N -c scriptnames


> Yeah, and my slight rant is that despite
> setlocal foldlevel=99
> in my /after/php.vim I'm still getting folding. Again, not a problem
> but just an annoyance.

Do you mean your /after/syntax/php.vim?
^^^^^^^

Seems to work fine for me from either there or /after/ftplugin/php.vim.

--
Best,
Ben

--
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

No comments:

Post a Comment