table.vim : smarter table editing/navigation
| script karma
Downloaded by 1945
Comments, bugs, improvements
script versions (upload new version)
|In vimtip#547 I described some functions that enable easier navigation
and editing of tables. I have considerably enhanced the functionality
and placed all the relevant code in a script file.
The idea of the script is to automatically extract fields from a table
row and use that information to create maps that aid in editing and
navigation of the table. The user first marks a table row as table
heading. The line does not literally have to be the table heading, but
it should be representative of the typical row of the table in
After this step the script maps tab and shift-tab keys to move between
fields. These mappings work in both insert and normal modes. The tab
mapping is especially useful in insert mode as it inserts the correct
amount of padding to reach the start of the next field.
The script also has an alignment feature that aligns the fields of the
row with that of the heading. Editing a pre-existing table frequently
leads to misaligned rows and this feature alleviates the need to
manually add/remove padding.
For more details about the script check the documentation in the script package. I also intend to post a tip documenting the use of the script. The tip will most likely be numbered vimtip #554
|To install the script, place table.vim in the vim macros directory
and source it in your vimrc using:
If you simply want to check the functionality of the script, place
the script file in your current directory, open vim in the same
directory and use
Click on the package to download.
ip used for rating: 220.127.116.11