This commit may be somewhat controversial but I find it very useful in my day to day.
It essentially styles known css hacks like (* and _) as if they were vendor prefixes (linked to the
So yeah, here's the thing. Yes they are old fixes, and yes, in time they will probably be gone, however, I do often use other people's CSS files, or sometimes I work on projects that require me support older versions of IE, so it's nice to at least have these hacks 'fit in' with the overall theme.
Ok, pls add more comments to tell us these css hacks is only for IE7 or below, so that when older versions of IE are totally obsoleted, someone could know that it is safe to remove them from the syntax file.
Not a problem, I have to run for a bit, but I'll look into it in the next day or so to better comment this.
Adding support for css hacks
This commit may be somewhat controversial. It essentially styles known
css hacks like (* and _) as if they were vendor prefixes (linked to the
More descriptive comments for cssHacks group
I went ahead and rebased this branch against recent changes to avoid merge conflicts. I also added a far more descriptive comment with a link for more details.
Does this work?
it works well.
This now has hit the vim runtime files
And it breaks syntax higlighting for php, rails, and maybe more
the offending lines are:
" Required for cssHacks
@BlackIkeEagle thanks for the report, I've posted on the vim_dev thread regarding this. Awaiting Braam's response on how to proceed.
is there a way to do this cssHacks thing without "setlocal iskeyword-=_" ?
do you have any css files where the working of the cssHacks is visible ?
i tried some but found no difference when the cssHacks were there or removed
i'm not a css expert at all
That's terrible, I have sent a copy of css.vim to Bram.
@BlackIkeEagle , would you pls paste the php or rails code with broken syntax highlighting ?
$array = array('one', 'two', 'three');
$flag = in_array('one', $array);
in the above example in_ is no longer detected as part of the in_array function
The code "setlocal iskeyword-=_ " breaks syntax highlighting of other languages, this change will be reverted with no doubt.
remove the offending line. #16