sponsor Vim development Vim logo Vim Book Ad

clibs.vim : Syntax highlighting for C library functions and constants

 script karma  Rating 22/7, Downloaded by 1296  Comments, bugs, improvements  Vim wiki

created by
gi1242 gi1242
script type
This is a fork of the default c.vim syntax file that provides highlighting of C library functions and constants.

The patch to c.vim is very minor (just add one container class for library functions / constants), so your usual syntax highlighting in C will be preserved.

It contains options that let you control how much, and which libraries you want highlighted.

Currently, the only libraries supported are "glibc" and "xlib". But it comes with instructions on how to add your own (project specific, or other) libraries. Feel free to add support for other standard libraries and send them to me :).
install details
To install script and help files

    cd ~/.vim && tar -xjvf /tmp/clibs.vim && vim +":helptags doc/" +:q

and put

    let c_hi_identifiers = 'all'
    let c_hi_libs = ['*']

in ~/.vimrc. For complete help do

    :help clibs

rate this script Life Changing Helpful Unfulfilling 
script versions (upload new version)

Click on the package to download.

package script version date Vim version user release notes
clibs.tbz2 1.0 2007-06-08 7.0 gi1242 gi1242 Initial upload
ip used for rating:

If you have questions or remarks about this site, visit the vimonline development pages. Please use this site responsibly.
Questions about Vim should go to the maillist. Help Bram help Uganda.