Some people like to indent code with tabs, and others like to indent with spaces. There are advantages and disadvantages to both. Regardless of which you prefer, it can be useful to see which indent style has been used. In Vim, you can do this by adding the following line to you .vimrc file (which [...]
Archive for the ‘Vim’ Category
Highlighting tabs in Vim
Posted: 26th April 2012 by Tim in VimTags: highlight, indent, spacing, style, tab, tabs, vi, vim, vimrc
0
Using Vim syntax highlighting on custom file types
Posted: 20th April 2010 by Tim in PostgreSQL, Ubuntu, VimTags: config, highlighting, linux, syntax highlighting, vim
Let’s say you have a file type whose contents are in XML format but have a different file extension such as .tim . If you want to edit these files with Vim with syntax highlighting, simply add the following to ~/.vimrc (affects only your Vim environment) or /etc/vim/vimrc (affects everyone’s Vim environment): au BufNewFile,BufRead *.tim [...]
Highlighting Doxygen tags in Vim
Posted: 30th December 2009 by Tim in Software Development, Ubuntu, VimTags: configuration, doxygen, syntax, syntax highlighting, vim
Doxygen highlighting is set up by default on most Vim installations, but for some reason it’s disabled. There are two options for enabling it. First, it can be enabled globally. This means adding the parameters to the global Vim configuration. Note that you may need to be root for this to work (ie: sudo echo [...]