The text editor, vim, in Linux, is fast and easy to use if you prefer to use the keyboard to operate programs. There are a couple of more user-friendly versions of this text editor available in Ubuntu.

For both of these versions, use the Synaptic Package Manager to install the software. To access it, select Administration | Synaptic Package Manager from the System menu.

Opening the Synaptic Package Manager

An Improved Terminal Version of Vim

For an improved version of Vim that is very similar to the terminal-based, original version, search for vim in the Synaptic Package Manager. The package that gives you vim with a base Ubuntu installation is vim-common.

Right-click on the vim package and select Mark for Installation from the pop-up menu.

Marking vim for installation

Click the Apply button to apply the changes.

Applying marked changes for vim

A Summary dialog displays showing you the changes to be made. Click the Apply button.

Summary dialog box for applying changes to vim

The necessary package files for vim are downloaded.

Downloading Package Files for vim

A dialog box displays when the changes have been applied. Click Close.

Changes applied for vim

Select Quit from the File menu to close the Synaptic Package Manager.

Quitting Synaptic Package Manager

Configuration of the improved version of vim is automatic and you can now access the improved version by typing vi or vim in a Terminal window. Many new features have been added such as multi level undo, syntax highlighting, command line history, online help, filename completion, and block operations.

A Graphical Version of Vim

If you like the features of vim text editor, but you prefer a graphical user interface (GUI) to work within, you might like Gvim. It’s a version of vim with a graphical front-end added.

To install Gvim, follow the steps from the previous section, except search for vim-gnome instead of just vim in the Synaptic Package Manager.

Gvim is not added to any of the Ubuntu menus, but it can be run by typing gvim at the prompt in a Terminal window.

Starting gvim from the prompt

Use Gvim just like you would vim, typing a colon to enter commands and entering insert mode by typing an ‘i’. Gvim does provide easier access to the features of vim that are usually hidden, plus some extra features, through menus and a toolbar.

Gvim window

For those of us who are programmers, but prefer working with the mouse rather than the keyboard when running software programs, Gvim is a useful tool to have.

by Lori Kaufman