Reputation: 1843
I use VIM to edit CSS files. offers language-specific keywords auto completion. For CSS background-color this list is offered:
transparent
rgb(
#
I mostly use hsla( and rgba(, how do I add these to the list? Can I edit the css.vim file for this?
Upvotes: 0
Views: 170
Reputation: 196576
Open the default completion script:
:e $VIMRUNTIME/autoload/csscomplete.vim
Save and edit a local copy:
:saveas ~/.vim/autoload/csscomplete.vim
Search for transparent
:
/transp<CR>
Append the desired values:
$i, "rgba(", "hsla("<Esc>
Repeat until you have edited all the relevant lines.
Write the file and quit:
:x
Try it in a new session:
$ vim foo.css
Upvotes: 1