Previous Next
Working with Vim and SNiFF+

Once a connection between SNiFF+ and Vim is established, SNiFF+ uses Vim for all requests to display or edit source code.
Positioning Vim from SNiFF+
By double-clicking on a symbol in any SNiFF+ browser, Vim loads the corresponding source file and positions the cursor at the appropriate location.
Buffers in Vim
Vim can hold several buffers at once. To work with buffers, use the following commands:
Command Description
:ls
Prints a list of currently loaded buffers
:b[uffer] <name>
or
:b[uffer] <number>
Switches to the buffer specified by the filename or the number (as listed by ls )

For details about buffers in Vim, refer to Vim's online help using the following command:
:help buffer
Additional features
Syntax highlighting
Vim is capable of syntax highlighting for a variety of languages and formats.
To enable syntax highlighting, issue the following command:
:syntax on
To disable syntax highlighting, issue the following command:
:syntax off
IMPORTANT: Set the environment variable $VIM to $SNIFF_DIR/config/vim . This environment variable must be set to use Vim's online help and syntax highlighting.
Online help
Vim provides online documentation for all available commands and features. To view on-line help, enter the following command:
:help [keyword]
If you would like to know more about the differences between vi and Vim, enter the following command in Vim:
:help vi_diff
IMPORTANT: Set the environment variable $VIM to $SNIFF_DIR/config/vim . This environment variable must be set to use Vim's online help and syntax highlighting.

Previous Next