This file adds Vim/Neovim syntax highlighting for SDL2.
Copy sdl2.vim
to ~/.vim/syntax/
and add this to your ~/.vimrc
:
augroup sdl2
autocmd!
autocmd FileType c,cpp source ~/.vim/syntax/sdl2.vim
augroup END
The file can be re-generated with generator/sdl2_vim.py
. Run it like:
$ ./sdl2_vim.py /usr/include/SDL2/
The generator script requires pycparser. The generator/utils
directory also belongs to pycparser
.
generator/sdl2_vim.py
public domain (unlicense)generator/utils
copyright Eli Bendersky - https://github.com/eliben/pycparser/blob/master/LICENSE